check_snmp not returning results


#1

Hello All.

I’m trying to test the check_snmp plugin with Nagios to monitor disk space on an XP box. I have SNMP installed on XP and the XP box has been monitored via Cacti for some time.

When I run this command from my Nagios plugins directory on the Linux box:

./check_snmp -H 192.168.9.105 -o .1.3.6.1.2.1.25.2.3.1.6 -C public -P 2c

I get this result:

SNMP problem - No data received from host
CMD: /usr/bin/snmpget -t 1 -r 5 -m ‘’ -v 2c -c public 192.168.9.105:106 1.3.6.1.2.1.25.2.3.1.6

Strangely, when I run snmpget from /usr/bin with the following command:
snmpget -v 2c -c public -H 192.168.9.105 -o .1.3.6.1.2.1.25.2.3.1.6

I receive the result:
Configuration Directives Understood:
No log handling enabled - turning on stderr logging
in snmp.conf. and snmp.local.conf:
(followed by a long list of output)

When I run snmpwalk from the same directory using:
snmpwalk -v 2c -c public -m ALL 192.168.9.105 .1.3.6.1.2.1.25.2.3.1.5

The result is:
HOST-RESOURCES-MIB:hrstoragesize.1 = INTEGER: 0
HOST-RESOURCES-MIB:hrstoragesize.2 = INTEGER: 38262813
HOST-RESOURCES-MIB:hrstoragesize.3 = INTEGER: 0
HOST-RESOURCES-MIB:hrstoragesize.4 = INTEGER: 0
HOST-RESOURCES-MIB:hrstoragesize.5 = INTEGER: 488386032
HOST-RESOURCES-MIB:hrstoragesize.6 = INTEGER: 54853
HOST-RESOURCES-MIB:hrstoragesize.7 = INTEGER: 32737

I’m clearly missing something. Why is check_snmp not returning any data from the host?

Thanks for any assistance.

Best,
Wanabe


#2

.1.3.6.1.2.1.25.2.3.1.6 should have the index value at the end.
For example
.1.3.6.1.2.1.25.2.3.1.6.2