proc, procfix and automated restart of failed process
"Lambert, Eric" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <FA5C3DE5A5443C4EBD3C5935484222BB010EDD6C@CHMAIL03.citadelgroup.com> |
I've done a little archival reading and understand that the proc directive specifies which process to look for (under essentially a 'ps -e | grep procname' format). The procfix directive then names what command to run, and here's the key, when the associated prErrFix.# flag is set to 1 using snmpset. My question, and the logical one that follows I believe, is...how does one go about automating the execution of said snmpset command upon given process failure? Secondly, while I see alert trigger when I restart snmpd, why do I not see it trigger when I kill the process while snmpd is up and running? Here are the relevant portions of my snmpd.conf file: monitor -u citadelInternal -r 60 -o prNames -o prErrMessage "process table" prErrorFlag != 0 proc ntpd 1 procfix ntpd /sbin/service ntpd restart And here is some related output from snmpwalk and snmpset: root@lx-chtdell2950 snmp# snmpwalk -v 2c -c xxxxxx lx-chtdell2950 prErrMessage UCD-SNMP-MIB::prErrMessage.1 = STRING: UCD-SNMP-MIB::prErrMessage.2 = STRING: UCD-SNMP-MIB::prErrMessage.3 = STRING: Too few crond running (# = 0) UCD-SNMP-MIB::prErrMessage.4 = STRING: UCD-SNMP-MIB::prErrMessage.5 = STRING: UCD-SNMP-MIB::prErrMessage.6 = STRING: UCD-SNMP-MIB::prErrMessage.7 = STRING: Too few ntpd running (# = 0) UCD-SNMP-MIB::prErrMessage.8 = STRING: root@lx-chtdell2950 snmp# snmpset -v2c -c xxxxxx lx-chtdell2950 UCD-SNMP-MIB::prErrFix.7 = 1 UCD-SNMP-MIB::prErrFix.7 = INTEGER: 1 root@lx-chtdell2950 snmp# snmpwalk -v 2c -c publ1cr0 lx-chtdell2950 prErrMessage UCD-SNMP-MIB::prErrMessage.1 = STRING: UCD-SNMP-MIB::prErrMessage.2 = STRING: UCD-SNMP-MIB::prErrMessage.3 = STRING: Too few crond running (# = 0) UCD-SNMP-MIB::prErrMessage.4 = STRING: UCD-SNMP-MIB::prErrMessage.5 = STRING: UCD-SNMP-MIB::prErrMessage.6 = STRING: UCD-SNMP-MIB::prErrMessage.7 = STRING: UCD-SNMP-MIB::prErrMessage.8 = STRING: ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users