check_snmp on Ubuntu Server 12.04 - Bug?
Posted: Wed May 30, 2012 12:37 pm
None of my 12.04 Ubuntu servers can run the check_snmp command without hanging when trying to access a router/switch. It does not matter what what OID I try to access (as long as it is valid)
I issue the same command on a 10.04 server and it works.
Here are the versions for each program per platform:
EDIT: check_snmp v1.4.14 was also tested on 12.04 but had identical failure as v1.4.15
Ubuntu Server 12.04 LTS (64-bit)
Ubuntu Server 10.04.4 LTS (64-bit)
Here is the check_snmp command issued the 12.04 server:
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o .iso.3.6.1.2.1.1.3.0 -C public
or
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o sysUpTime.0 -C public
No result (fails)...just sits there and does not even timeout (even if you add -t 10)
Here is the check_snmp command issued the 10.04 server:
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o .iso.3.6.1.2.1.1.3.0 -C public
or
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o sysUpTime.0 -C public
Here is the result (works):
SNMP OK - Timeticks: (83867600) 9 days, 16:57:56.00 |
Here is the snmpget command issued on the 12.04 server:
snmpget -v1 -c public -Ovq 192.168.1.1 .iso.3.6.1.2.1.1.3.0
or
snmpget -v1 -c public -Ovq 192.168.1.1 sysUpTime.0
Here is the result (works):
9:16:59:28.00
Here is the snmpget command issued on the 10.04 server:
snmpget -v1 -c public -Ovq 192.168.1.1 .iso.3.6.1.2.1.1.3.0
or
snmpget -v1 -c public -Ovq 192.168.1.1 sysUpTime.0
Here is the result (works):
9:17:01:12.00
Installation Notes:
- All servers had the plugins installed using aptitude install nagios-plugins (except the Nagios server)
- The Nagios server had the plugins compiled from source, however, it is still the same version as 12.04 servers (1.4.15)
I'm stumped at this point. The snmp commands worked for all my switches when the Nagios server was running on 10.04. This is the only thing not working like it did on the old operating system and I have about 1,000 services defined.
If I cannot get the Nagios server to poll snmp correctly, my backup plan is to use a 10.04 server (which cannot be upgraded yet because of the mail application) and have it issue all the snmp queries (via NRPE). Yuck.
EDIT: I added the verbose option to see if anything extra shows up that might indicate a difference but it did not help. On both servers, it showed the following:
LHammonds
I issue the same command on a 10.04 server and it works.
Here are the versions for each program per platform:
EDIT: check_snmp v1.4.14 was also tested on 12.04 but had identical failure as v1.4.15
Ubuntu Server 12.04 LTS (64-bit)
Code: Select all
uname -a
Linux srv-wiki 3.2.0-24-generic #39-Ubuntu SMP Mon May 21 16:52:17 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
/usr/lib/nagios/plugins/check_snmp -V
check_snmp v1.4.15 (nagios-plugins 1.4.15)
/usr/bin/snmpget -V
NET-SNMP version: 5.4.3
Code: Select all
uname -a
Linux srv-mail 2.6.32-41-server #89-Ubuntu SMP Fri Apr 27 22:33:31 UTC 2012 x86_64 GNU/Linux
/usr/lib/nagios/plugins/check_snmp -V
check_snmp v1.4.14 (nagios-plugins 1.4.14)
/usr/bin/snmpget -V
NET-SNMP version: 5.4.2.1
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o .iso.3.6.1.2.1.1.3.0 -C public
or
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o sysUpTime.0 -C public
No result (fails)...just sits there and does not even timeout (even if you add -t 10)
Here is the check_snmp command issued the 10.04 server:
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o .iso.3.6.1.2.1.1.3.0 -C public
or
/usr/lib/nagios/plugins/check_snmp -H 192.168.1.1 -o sysUpTime.0 -C public
Here is the result (works):
SNMP OK - Timeticks: (83867600) 9 days, 16:57:56.00 |
Here is the snmpget command issued on the 12.04 server:
snmpget -v1 -c public -Ovq 192.168.1.1 .iso.3.6.1.2.1.1.3.0
or
snmpget -v1 -c public -Ovq 192.168.1.1 sysUpTime.0
Here is the result (works):
9:16:59:28.00
Here is the snmpget command issued on the 10.04 server:
snmpget -v1 -c public -Ovq 192.168.1.1 .iso.3.6.1.2.1.1.3.0
or
snmpget -v1 -c public -Ovq 192.168.1.1 sysUpTime.0
Here is the result (works):
9:17:01:12.00
Installation Notes:
- All servers had the plugins installed using aptitude install nagios-plugins (except the Nagios server)
- The Nagios server had the plugins compiled from source, however, it is still the same version as 12.04 servers (1.4.15)
I'm stumped at this point. The snmp commands worked for all my switches when the Nagios server was running on 10.04. This is the only thing not working like it did on the old operating system and I have about 1,000 services defined.
If I cannot get the Nagios server to poll snmp correctly, my backup plan is to use a 10.04 server (which cannot be upgraded yet because of the mail application) and have it issue all the snmp queries (via NRPE). Yuck.
EDIT: I added the verbose option to see if anything extra shows up that might indicate a difference but it did not help. On both servers, it showed the following:
Code: Select all
/usr/bin/snmpget -t 1 -r 5 -m ALL -v 1 [authpriv] 192.168.1.1:161 sysUpTime.0