check_snmp timeout

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Post Reply
nick-scs
Posts: 2
Joined: Thu Apr 04, 2024 2:52 am

check_snmp timeout

Post by nick-scs »

I'm hoping for some help with check_snmp. I can query an OID with snmpget:

Code: Select all

sudo -u nagios snmpget -v3 -u SNMPUSER -l authPriv -a SHA -A "AUTHPASS" -x AES -X "PRIVPASS" HOST.FQDN 1.3.6.1.2.1.2.2.1.8.818
This works...

Code: Select all

iso.3.6.1.2.1.2.2.1.8.818 = INTEGER: 1
When I try to use check_snmp I get a timeout:

Code: Select all

sudo -u nagios ./check_snmp -H HOST.FQDN —P 3 -U SNMPUSER -L authPriv -a SHA -A "AUTHPASS" -x AES -X "PRIVPASS" -o 1.3.6.1.2.1.2.2.1.8.818 -v

/usr/bin/snmpget -Le -t 3 -r 5 -m '' -v 1 [context] [authpriv] HOST.FQDN:161 .1.3.6.1.2.1.2.2.1.8.818
CRITICAL - Plugin timed out while executing system call
I have tried adding -t to give it more time but no luck, it also looks to me as though its trying to run getsnmp with version 1, have used --protocol=3 but get the same. Any ideas gratefully recieved.

Thanks!
nick-scs
Posts: 2
Joined: Thu Apr 04, 2024 2:52 am

Re: check_snmp timeout

Post by nick-scs »

--protocol needed to be the first argument
jsimon
Posts: 105
Joined: Wed Aug 23, 2023 11:27 am

Re: check_snmp timeout

Post by jsimon »

Hi @nick-scs,

It looks like you solved your issue, if I'm understanding your posts correctly. Do you need any further help with this, or should I close the topic?
Post Reply