You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In particular, we were trying to use this tool for rate checking; the checks always came back as "UNKNOWN." We enabled verbose mode and went through check_snmp.c until we realized that our system-wide configuration setting of quickPrinting true was messing with the results.
If this tool is expecting a certain output it should be asking for it with the appropriate options (in this case by explicitly passing --quickPrinting=false to snmpget) or – more properly – importing the net-snmp libraries and doing the checks in C instead of running CLI utilities.
The text was updated successfully, but these errors were encountered:
Probably also worth mentioning, the output read loop in main() breaks early due to lack of separator character ":" as excpected. But the check at the end for calculate_rate doesn't take the possibility of an early exit from the loop into account. It should also be checking if total_oids > 0. We were seeing verbose outputs like this, but it probably should have been an error condition:
Previous State for 0=`????
/usr/bin/snmpget -Le -t 3 -r 5 -m ALL -v 2c [context] [authpriv] example.com:161 ifInOctets.24
IF-MIB::ifInOctets.24 4103007855
State string=`?b??
SNMP RATE UNKNOWN - |
Hi @miken32, thanks for reaching out. Both of your suggestions sound reasonable - We'll be doing another bugfix release sometime this month, and I'll try to at least handle your first suggestion then.
In particular, we were trying to use this tool for rate checking; the checks always came back as "UNKNOWN." We enabled verbose mode and went through check_snmp.c until we realized that our system-wide configuration setting of
quickPrinting true
was messing with the results.If this tool is expecting a certain output it should be asking for it with the appropriate options (in this case by explicitly passing
--quickPrinting=false
tosnmpget
) or – more properly – importing the net-snmp libraries and doing the checks in C instead of running CLI utilities.The text was updated successfully, but these errors were encountered: