I have an NMS and a Client machine. I want the client to send traps to the NMS. I have been configuring the snmpd.conf file testing if i disable a process do i receive an alert or not. For the changes to reflect that were made in the conf file i restarted the snmpd daemon each time. The testing was going fine. All of a sudden when i restarted snmpd i recieved the error msg "snmpd dead but subsys locked". I googled for answer as to what it actually meant and found out that when a service is started a logfile is created in the /var/lock/subsys. Sometimes if the service is not stopped properly or whatever the logfile remains created. Though i started/stopped the snmpd service properly it didnt go away so i removed the file manually (via rm cmd). when i checked the status the error "snmpd dead but subsys locked" was gone. On my NMS i recieved the alert of snmpd coldstart. i started the snmpd service everything goes fine! BUT after 5 mins again i recieve the same error message and this keeps on happening..what do i need to do now?
Snmpd dead but subsys locked
snmpsyslog
Best Answer
Your snmp daemon keeps dying. Look in your logs. If you're using RedHat or similar (their
init.d
scripts touch files in/var/lock/subsys
) try looking in/var/log/messages
.You can enable verbose logging by passing the
-DALL
option tosnmpd
; on a RedHat-style distro you can add this flag to theOPTIONS
line in/etc/sysconfig/snmpd.options
file (or on older releases/etc/snmpd/snmpd.options
).