[Nagiosplug-help] check_snmp help

Tom Diehl tdiehl at rogueind.com
Wed Dec 17 14:22:01 CET 2003


Hi all,
I am trying to use check_snmp to check disk space. The example
in checkcommands is
/usr/lib/nagios/plugins/check_snmp -H $HOSTADDRESS$ -C $ARG1$ -o .1.3.6.1.4.1.2021.9.1.7.$ARG2$,.1.3.6.1.4.1.2021.9.1.9.$ARG2$ -w $ARG3$:,:$ARG4$ -c $ARG5$:,:$ARG6$ -u 'kB free (','% used)' -l 'disk space'

when I look at the mib for the machine I am trying to test
I do not have the oid listed above.
For disk checks I have the following oid's
HOST-RESOURCES-MIB::hrStorageDescr.1 = STRING: A:\
HOST-RESOURCES-MIB::hrStorageDescr.2 = STRING: C:\ Label:  Serial Number ac2a1db5
HOST-RESOURCES-MIB::hrStorageDescr.3 = STRING: D:\
HOST-RESOURCES-MIB::hrStorageDescr.4 = STRING: E:\ Label:  Serial Number ec31976f
HOST-RESOURCES-MIB::hrStorageDescr.5 = STRING: Virtual Memory
HOST-RESOURCES-MIB::hrStorageAllocationUnits.1 = INTEGER: 0 Bytes
HOST-RESOURCES-MIB::hrStorageAllocationUnits.2 = INTEGER: 4096 Bytes
HOST-RESOURCES-MIB::hrStorageAllocationUnits.3 = INTEGER: 0 Bytes
HOST-RESOURCES-MIB::hrStorageAllocationUnits.4 = INTEGER: 4096 Bytes
HOST-RESOURCES-MIB::hrStorageAllocationUnits.5 = INTEGER: 65536 Bytes
HOST-RESOURCES-MIB::hrStorageSize.1 = INTEGER: 0
HOST-RESOURCES-MIB::hrStorageSize.2 = INTEGER: 4982150
HOST-RESOURCES-MIB::hrStorageSize.3 = INTEGER: 0
HOST-RESOURCES-MIB::hrStorageSize.4 = INTEGER: 767607
HOST-RESOURCES-MIB::hrStorageSize.5 = INTEGER: 9264
HOST-RESOURCES-MIB::hrStorageUsed.1 = INTEGER: 0
HOST-RESOURCES-MIB::hrStorageUsed.2 = INTEGER: 1174945
HOST-RESOURCES-MIB::hrStorageUsed.3 = INTEGER: 0
HOST-RESOURCES-MIB::hrStorageUsed.4 = INTEGER: 420126
HOST-RESOURCES-MIB::hrStorageUsed.5 = INTEGER: 2269

The above values seem to be 
hrStorageSize * hrStorageAllocationUnits = total disk size and
hrStorageUsed * hrStorageAllocationUnits = disk used.

So my question is how can I feed this to check_snmp to get 
a disk space check out of nagios that is useful?

If there is a doc I am missing a pointer would be appreciated.

Can someone please tell me what I am missing??

................Tom




More information about the Help mailing list