[Nagiosplug-devel] check_snmp bug on some strings

DonKiShoot donkishoot at neuf.fr
Thu Jun 6 13:50:44 CEST 2013


Hi list,

check_snmp bug on some strings while snmpget has no problem

Client version : net-snmp-5.3.2.2-20.el5
Server version : net-snmp-5.3.2.2-20.el5

To describe a minimum, i'm trying to retreive two oids.
The first oid correspond to a number who represent the exit code from a 
command.
The second oid correspond to the result string of the same command.
For more information see 'extend' parameter from snmpd.conf

Now the bug ...

Example OK :

/usr/lib64/nagios/plugins/check_snmp -H 192.168.1.1 -P 2c -C public -o 
.1.3.6.1.4.1.8072.1.3.2.3.1.4.10.84.97.98.108.101.83.112.97.99.101,.1.3.6.1.4.1.8072.1.3.2.4.1.2.10.84.97.98.108.101.83.112.97.99.101.1 
-w 1 -c 2

SNMP CRITICAL - *3* "Usage: check_oracle --tns <Oracle Sid or 
Hostname/IP address> check_oracle --db <ORACLE_SID> check_oracle --login 
<ORACLE_SID> check_oracle --cache <ORACLE_SID> <USER> <PASS> <CRITICAL> 
<WARNING> check_oracle --tablespace <ORACLE_SID> <USER> <PASS> 
<TABLESPACE> <CRITICAL> <WARNING> check_oracle --oranames <Hostname> 
check_oracle --help check_oracle --version" | 
iso.3.6.1.4.1.8072.1.3.2.3.1.4.10.84.97.98.108.101.83.112.97.99.101=3


Example KO :

/usr/lib64/nagios/plugins/check_snmp -H 192.168.1.1 -P 2c -C public -o 
.1.3.6.1.4.1.8072.1.3.2.3.1.4.10.84.97.98.108.101.83.112.97.99.101,.1.3.6.1.4.1.8072.1.3.2.4.1.2.10.84.97.98.108.101.83.112.97.99.101.1 
-w 1 -c 2

SNMP WARNING - *2* 43 52 49 54 49 43 41 4C 20 2D 20 4F 52 41 2D 31| 
iso.3.6.1.4.1.8072.1.3.2.3.1.4.10.84.97.98.108.101.83.112.97.99.101=2 
iso.3.6.1.4.1.8072.1.3.2.4.1.2.10.84.97.98.108.101.83.112.97.99.101.1=43


check_snmp return hexa characters "43 52 49 54 49 43 41 4C 20 2D 20 4F 
52 41 2D 31 ..." instead of a string like on the first check


With snmpget the string is ok :


snmpget -v2c -c altaread 10.2.50.111 
iso.3.6.1.4.1.8072.1.3.2.4.1.2.10.84.97.98.108.101.83.112.97.99.101.1
NET-SNMP-EXTEND-MIB::nsExtendOutLine."TableSpace".1 = STRING: CRITICAL - 
ORA-12154: TNS : l'identificateur de connexion indiqué n'a pas pu être 
résolu



What can i do to receive the string instead of Hexa characters ???


PS: Sorry for my poor english

Regards,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20130606/2ce8702d/attachment.html>


More information about the Devel mailing list