help with check_snmp

Frank Altpeter <[email protected]> Fri, 2 Dec 2016 12:53:07 +0100
Newsgroups gmane.network.nagios.plugins,gmane.network.monitoring.plugins.user
Message-ID <[email protected]>
Hi,

I'm trying to use check_snmp to monitor power outlet consumation. I set up
something like this:

check_snmp -H <host> -P 1 -C <comm> -o SPGW-MIB::actualCurrentO.3132.4 

which correctly returns
SNMP OK - .36 | 

since there is no consumer connected, this value is correct (0.36A).

But, when I add a warning threshold, like this:

check_snmp -H <host> -P 1 -C <comm> -w @0:0 -o SPGW-MIB::actualCurrentO.3132.4                      

to be warned when the returned value equals zero, the output becomes:

SNMP OK - 36 | SPGW-MIB::actualCurrentO.3132.4=36 

So, the dot seems to get filtered and the returned value is 36 instead of 0.36.

The same happens with another outlet with consumers connected:
Without warning threshold: SNMP OK - 4.42 | SPGW-MIB::actualCurrentO.3132.6=4 
With warning threshold: SNMP OK - 4 | SPGW-MIB::actualCurrentO.3132.6=4 


Any idea on that or did I miss something?

I'm using check_snmp v2.1.2 (monitoring-plugins 2.1.2) on SLES 11.4


With kind regards

	Frank Altpeter
signature.asc (application/pgp-signature, 213 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iF4EAREIAAYFAlhBYKIACgkQ7wRGH3LcIrTw/QD8D6unEfikLcHLdE6MtxhaqsYt
jxO/O8XvccuphqB7TNwA/32hPoCNfSSv4+zfaLYE2pkqT9kFNPO/ZKi2Mf0rb4gR
=V//m
-----END PGP SIGNATURE-----