After configuring things some time ago, I'm seeing lots of traps in /var/log/messages. I'll create a test trap to make this specific to one host. These are ILOs, 3PAR SAN, fiber switches, etc., not servers.
If I go into the ilo and create a test trap, there it is:
Code: Select all
Sep 16 18:02:26 txslm2mlnag001 snmptrapd[1464]: 2015-09-16 18:02:26 10.133.133.23(via UDP: [10.133.133.23]:59232->[10.133.133.74]) TRAP, SNMP v1, community sp1der#012#011.1.3.6.1.4.1.232 Enterprise Specific Trap (11003) Uptime: 415 days, 5:54:40.00#012#011.1.3.6.1.2.1.1.5.0 = STRING: txslm2mlapp002-ilo.#011.1.3.6.1.4.1.232.11.2.11.1.0 = INTEGER: 4#011.1.3.6.1.4.1.232.11.2.8.1.0 = STRING: "Remote Insight Test Trap"
Sep 16 18:02:56 txslm2mlnag001 snmptrapd[1464]: 2015-09-16 18:02:56 10.133.133.23(via UDP: [10.133.134.96]:50005->[10.133.134.84]) TRAP, SNMP v1, community sp1der#012#011.1.3.6.1.4.1.232 Enterprise Specific Trap (11003) Uptime: 0:00:00.00#012#011.1.3.6.1.2.1.1.5.0 = STRING: txslm2mlapp002-ilo.#011.1.3.6.1.4.1.232.11.2.11.1.0 = INTEGER: 4#011.1.3.6.1.4.1.232.11.2.8.1.0 = STRING: "Remote Insight Test Trap"
Code: Select all
# grep 10.133.133.23 *
txslm2mlapp002-ilo.cfg: address 10.133.133.23
[root@txslm2mlnag001 hosts]# pwd
/usr/local/nagios/etc/hostsCode: Select all
# grep -v ^# ../services/SNMP_Trap_Wizard_test.cfg
define service {
host_name txslm2m3prf001,txslm2mlnag001
service_description SNMP_Trap_Wizard_test
use xiwizard_snmptrap_service
hostgroup_name 1VZW_SNMP_trap_hosts
max_check_attempts 1
check_interval 1
retry_interval 1
check_period xi_timeperiod_24x7
notification_interval 1
notification_period xi_timeperiod_24x7
contacts nagiosadmin
icon_image snmptrap.png
_xiwizard snmp_trap
register 1
}
Code: Select all
define service {
name xiwizard_snmptrap_service
service_description SNMP Traps
use xiwizard_generic_service
check_command check_dummy!0!"TRAP RESET"!!!!!!
is_volatile 1
initial_state o
active_checks_enabled 0
passive_checks_enabled 1
flap_detection_enabled 0
stalking_options o,w,c,u,
icon_image snmptrap.png
register 0
}
The traps aren't in the unknown log or unknown traps in Nagios.
Code: Select all
# ll /var/log/snmptt/snmpt*log
-rw-rw-r-- 1 snmptt root 0 Sep 13 03:31 /var/log/snmptt/snmptt.log
-rw-rw-r-- 1 snmptt snmptt 0 Sep 6 03:08 /var/log/snmptt/snmpttsystem.log
-rw-rw-r-- 1 snmptt root 0 Sep 13 03:31 /var/log/snmptt/snmpttunknown.log