Traps Not Processed on 2014R1.2
Posted: Sun Jun 29, 2014 1:02 pm
I have run the NagiosXI-SNMPTrap-setup.sh to update the snmptt.
Traps are not being processed as seen from this command:
ls /var/spool/snmptt|wc -l
61
This seems to be the major problem as the traps arrive at the /var/spool/snmptt but never get processed.
ll /var/spool
drwxrwxr-x 2 snmptt snmptt 4096 Jan 18 11:44 snmptt
I also changed these permissions to nagios:nagios as the new script makes snmptt a member of the nagios group.
ll /var/spool
drwxrwxr-x 2 nagios nagios 4096 Jan 18 11:44 snmptt
I do not understand why the script has changed snmptrapd.conf to this, which for sure will break all updates to 2014 if people have snmptrapd configured:
# Example configuration file for snmptrapd
# No traps are handled by default, you must edit this file!
# authCommunity log,execute,net public
# traphandle SNMPv2-MIB::coldStart /usr/bin/bin/my_great_script cold
My current snmptrapd.conf does not reflect that of the script, here is what is in place:
disableAuthorization yes
traphandle default /usr/sbin/snmptthandler
I am currently receiving traps as seen here, there are no unknown traps:
/var/log/messsages
Jun 29 11:52:12 localhost snmptt[13389]: .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
tail snmptt.log
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
snmpttsystem.log
Sun Jun 29 10:22:38 2014 SNMPTT v1.4beta2 started
Sun Jun 29 10:22:38 2014 Loading /etc/snmp/snmptt.conf
Sun Jun 29 10:22:38 2014 Finished loading 709 lines from /etc/snmp/snmptt.conf
Sun Jun 29 10:22:38 2014 Changing to UID: snmptt (501)
ps aux|grep snmptt
root 13388 0.0 0.1 147596 9592 ? Ss 11:52 0:00 /usr/bin/perl /usr/sbin/snmptt --daemon
snmptt 13389 0.0 0.1 149824 10476 ? Ss 11:52 0:00 /usr/bin/perl /usr/sbin/snmptt --daemon
ps aux|grep snmptrapd
root 10781 0.0 0.0 190920 2340 ? Ss 10:21 0:00 /usr/sbin/snmptrapd -Lsd -On -p /var/run/snmptrapd.pid
Traps are not being processed as seen from this command:
ls /var/spool/snmptt|wc -l
61
This seems to be the major problem as the traps arrive at the /var/spool/snmptt but never get processed.
ll /var/spool
drwxrwxr-x 2 snmptt snmptt 4096 Jan 18 11:44 snmptt
I also changed these permissions to nagios:nagios as the new script makes snmptt a member of the nagios group.
ll /var/spool
drwxrwxr-x 2 nagios nagios 4096 Jan 18 11:44 snmptt
I do not understand why the script has changed snmptrapd.conf to this, which for sure will break all updates to 2014 if people have snmptrapd configured:
# Example configuration file for snmptrapd
# No traps are handled by default, you must edit this file!
# authCommunity log,execute,net public
# traphandle SNMPv2-MIB::coldStart /usr/bin/bin/my_great_script cold
My current snmptrapd.conf does not reflect that of the script, here is what is in place:
disableAuthorization yes
traphandle default /usr/sbin/snmptthandler
I am currently receiving traps as seen here, there are no unknown traps:
/var/log/messsages
Jun 29 11:52:12 localhost snmptt[13389]: .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
tail snmptt.log
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
Fri Jun 27 05:14:37 2014 .1.3.6.1.6.3.1.1.5.4 Normal "Status Events" 192.168.5.10 - A linkUp trap signifies that the SNMP entity, acting in an 49 up up
snmpttsystem.log
Sun Jun 29 10:22:38 2014 SNMPTT v1.4beta2 started
Sun Jun 29 10:22:38 2014 Loading /etc/snmp/snmptt.conf
Sun Jun 29 10:22:38 2014 Finished loading 709 lines from /etc/snmp/snmptt.conf
Sun Jun 29 10:22:38 2014 Changing to UID: snmptt (501)
ps aux|grep snmptt
root 13388 0.0 0.1 147596 9592 ? Ss 11:52 0:00 /usr/bin/perl /usr/sbin/snmptt --daemon
snmptt 13389 0.0 0.1 149824 10476 ? Ss 11:52 0:00 /usr/bin/perl /usr/sbin/snmptt --daemon
ps aux|grep snmptrapd
root 10781 0.0 0.0 190920 2340 ? Ss 10:21 0:00 /usr/sbin/snmptrapd -Lsd -On -p /var/run/snmptrapd.pid