[Nagiosplug-help] Check_snmp and Could not open pipe: error VERSION 2

Pietro Bandera pietrob at lansystems.it
Wed Jun 11 05:10:11 CEST 2003


Hi all

I need to check the disk of some ibm server by this oid

enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ib
mServeRaidPhysDeviceEntry.ibmServeRaidPhysDeviceStatus

Unfortunatly the output of that snmp call i this:

enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."110" = empty(7)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."111" = empty(7)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."112" = empty(7)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."113" = online(2)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."114" = empty(7)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."115" = online(2)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."116" = empty(7)
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."117" = empty(7)

I said unfortunatly because, as you can see, the identifier fo the disk
i betweeen "comma"!!!(arggg damn ibm)

That seems not to be a problem for snmpget command in fact if i do this:

[]# snmpget 192.168.0.37 public
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus.\"113\"
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."113" = online(2)

I got a right answer 

while if i use the check_snmp command with the same sintax i got this:


[]# /usr/local/netsaint/libexec/check_snmp 192.168.0.37 -C public -o
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus.\"113\" -l Disco -s "online(2)" Could
not open pipe: /usr/bin/snmpget -m ALL -v 1 192.168.0.37 public
enterprises.ibm.ibmProd.ibmServeRaid.ibmServeRaidMIB.ibmServeRaidMibObje
cts.ibmServeRaidInfo.ibmServeRaidPhysDeviceTable.ibmServeRaidPhysDeviceE
ntry.ibmServeRaidPhysDeviceStatus."113"


Why?

Well i found out what seems to be...

>From netsaint/nagios FAQ

"If you have defined a process check command that uses the
check_netsaint 
plugin, make sure that the plugin is functioning as it should. Execute 
the check_netsaint plugin from the command line and check the results. 
If the plugin is reporting that the NetSaint process cannot be found or 
if it returns a "Could not open pipe" message, you may need to edit the 
PS_RAW_COMMAND definition in the common/config.h file of the plugin 
distribution to match the syntax for the *ps* command on your system. 
For example, under FreeBSD you should use either /"/bin/ps -ao 'state 
user ppid args'"/ or /"/bin/ps -axo 'state user ppid command'"/ (it 
seems to vary). Once you've changed the PS_RAW_COMMAND definition, 
recompile the plugins and test the newly compiled check_netsaint plugin 
to see if it works."

All right this seems exactly to be the problem...i have seen all the
stuff..but i don't get how to resolve it?

Can someone help me?

Thanks 

Pietro






More information about the Help mailing list