[Nagiosplug-devel] [ nagiosplug-Feature Requests-1650176 ] check_snmp: Passing -Pu to snmpget command

SourceForge.net noreply at sourceforge.net
Thu Feb 1 22:58:29 CET 2007


Feature Requests item #1650176, was opened at 2007-02-01 21:58
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397600&aid=1650176&group_id=29880

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Priority: 5
Private: No
Submitted By: Andrew Elwell (elwell2000)
Assigned to: Nobody/Anonymous (nobody)
Summary: check_snmp: Passing -Pu to snmpget command

Initial Comment:
Using a (Badly written) vendor supplied MIB from Areca for a raid card (see http://www.areca.us/support/download/RaidCards/AP_Driver/SNMP_MIBs.zip ) snmpget is only happy if we pass the "-Pu" (ignore underscores) flag to it. I have made a workaround by permanently patching the source of check_snmp.c

PROBLEM:
# snmpget -v1 -c public hostname ARECA-SNMP-MIB::raidState.0              Bad operator (_): At line 20 in /usr/share/snmp/mibs/ARECA-SNMP-MIB.txt
ARECA-SNMP-MIB::raidState.0: Unknown Object Identifier


# snmpget -v1 -c public -Pu hostname ARECA-SNMP-MIB::raidState.0
ARECA-SNMP-MIB::raidState.0 = STRING: "Normal"

WORKAROUND:

                /* asprintf (&command_line, "%s -t %d -r %d -m %s -v %s %s %s:%s %s", */
                /* Hack below to accept underscores as areca mib broken */
                asprintf (&command_line, "%s -Pu -t %d -r %d -m %s -v %s %s %s:%s %s",


But it'd be nice to be able to pass this flag to the check_snmp if needed


Andrew

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=397600&aid=1650176&group_id=29880




More information about the Devel mailing list