check_snmp Plugin timed out while executing system
check_snmp Plugin timed out while executing system
Trouble with Nagios Plugins v2.1.1
When a service check_snmp timeouts with no reponse, Nagios produces CRITICAL - Plugin timed out while executing system call alert. It should show the timeout alert. I'm not able to find what is producing this error. Playing with the timeout and retries have no impact.
CentOS 7 complied from source.
When a service check_snmp timeouts with no reponse, Nagios produces CRITICAL - Plugin timed out while executing system call alert. It should show the timeout alert. I'm not able to find what is producing this error. Playing with the timeout and retries have no impact.
CentOS 7 complied from source.
- Box293
- Too Basu
- Posts: 5126
- Joined: Sun Feb 07, 2010 10:55 pm
- Location: Deniliquin, Australia
- Contact:
Re: check_snmp Plugin timed out while executing system
Can you run check_snmp with the -v argument and post the results here please (including the full command executed).
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
Re: check_snmp Plugin timed out while executing system
./check_snmp -H xx.xx.xx.xx -C COMM -o sysName.0 -v
/usr/bin/snmpget -Le -t 3 -r 5 -m ALL -v 1 [authpriv] xx.xx.xx.xx:161 sysName.0
CRITICAL - Plugin timed out while executing system call
/usr/bin/snmpget -Le -t 3 -r 5 -m ALL -v 1 [authpriv] xx.xx.xx.xx:161 sysName.0
CRITICAL - Plugin timed out while executing system call
Re: check_snmp Plugin timed out while executing system
Is this with all SNMP checks, or just a single one?
Former Nagios Employee.
me.
me.
Re: check_snmp Plugin timed out while executing system
When the host is down or the snmp timeout. The hosts I'm monitoring are on high latency links (radio), typical response time is 1 to 2 seconds but can go upwards to 5 to 10 seconds. I would expect that there would be a UNKNOWN No SNMP response received before timeout snmp alert and not the CRITICAL - Plugin timed out while executing system call.
Re: check_snmp Plugin timed out while executing system
I believe the plugin has a ten second timeout by default. Can you try using -t 30 in your check to see if it helps?
Former Nagios Employee.
me.
me.
Re: check_snmp Plugin timed out while executing system
No change when there is a timeout. However when specifying the -t 30, a -t 7 is passed to the snmpget?
# ./check_snmp -t 30 -C COMM -H xx.xx.xx.xx -o sysName.0 -vvv
/usr/bin/snmpget -Le -t 7 -r 5 -m ALL -v 1 [authpriv] xx.xx.xx.xx:161 sysName.0
CRITICAL - Plugin timed out while executing system call
# ./check_snmp -t 30 -C COMM -H xx.xx.xx.xx -o sysName.0 -vvv
/usr/bin/snmpget -Le -t 7 -r 5 -m ALL -v 1 [authpriv] xx.xx.xx.xx:161 sysName.0
CRITICAL - Plugin timed out while executing system call
Re: check_snmp Plugin timed out while executing system
That's pretty strange. Can you try a few other values? I don't have a host with SNMP set up in my lab environment currently, and will be in a meeting for the next couple hours. Try something like 60s, 90s for timeout.
Former Nagios Employee.
me.
me.
Re: check_snmp Plugin timed out while executing system
Changing the -t still produced the Plugin timed out. Now it seems that if I set the check_snmp -t in multiples of 4, it will send 1 to the snmpget binary.
check-snmp -t 1-4 = /usr/bin/snmpget -Le -t 1
check-snmp -t 5-9 = /usr/bin/snmpget -Le -t 2
check-snmp -t 10-14 = /usr/bin/snmpget -Le -t 3
check-snmp -t 15-19 = /usr/bin/snmpget -Le -t 4
so on... so on...
check-snmp -t 1-4 = /usr/bin/snmpget -Le -t 1
check-snmp -t 5-9 = /usr/bin/snmpget -Le -t 2
check-snmp -t 10-14 = /usr/bin/snmpget -Le -t 3
check-snmp -t 15-19 = /usr/bin/snmpget -Le -t 4
so on... so on...
Re: check_snmp Plugin timed out while executing system
First I tried
Looks good, so I tried
Still looks good...
It all looks fine. Let's compare versions:
Code: Select all
[root@xi libexec]# ./check_snmp -H 172.16.0.200 -o sysName.0 -vvv
/usr/bin/snmpget -Le -t 1 -r 5 -m ALL -v 1 [authpriv] 172.16.0.200:161 sysName.0
SNMPv2-MIB::sysName.0 = STRING: potus
Processing oid 1 (line 1)
oidname: SNMPv2-MIB::sysName.0
response: STRING: potus
SNMP OK - potus |
Code: Select all
[root@xi libexec]# ./check_snmp -H 172.16.0.200 -o sysName.0 -vvv -t 10
/usr/bin/snmpget -Le -t 10 -r 5 -m ALL -v 1 [authpriv] 172.16.0.200:161 sysName.0
SNMPv2-MIB::sysName.0 = STRING: potus
Processing oid 1 (line 1)
oidname: SNMPv2-MIB::sysName.0
response: STRING: potus
SNMP OK - potus |
Code: Select all
[root@xi libexec]# ./check_snmp -H 172.16.0.200 -o sysName.0 -vvv -t 50000
/usr/bin/snmpget -Le -t 50000 -r 5 -m ALL -v 1 [authpriv] 172.16.0.200:161 sysName.0
SNMPv2-MIB::sysName.0 = STRING: potus
Processing oid 1 (line 1)
oidname: SNMPv2-MIB::sysName.0
response: STRING: potus
SNMP OK - potus |
Code: Select all
[root@xi libexec]# ./check_snmp -V
check_snmp v2.0.3 (nagios-plugins 2.0.3)
Former Nagios Employee.
me.
me.