Page 2 of 7
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 12:44 pm
by abrist
Could you run the check with very verbose mode? (-vvv):
Code: Select all
/usr/local/nagios/libexec# ./check_snmp -P 1 -C COMMUNITY -H 192.168.1.1 -vvv -o iso.3.6.1.2.1.31.1.1.1.16.1
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 1:07 pm
by Kerflumpre
Code: Select all
root@nagios:/usr/local/nagios/libexec# ./check_snmp -P 1 -C COMMUNITY -H 192.168.1.1 -vvv -o iso.3.6.1.2.1.2.2.1.9.10001
/usr/bin/snmpget -Le -t 1 -r 5 -m ALL -v 1 [authpriv] 192.168.1.1:161 iso.3.6.1.2.1.2.2.1.9.10001
CRITICAL - Plugin timed out while executing system call
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 2:59 pm
by slansing
Please run the exact command that was requested (including the OID) and show the output.
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 3:11 pm
by Kerflumpre
My mistake. I didn't see the OID was different. Same result.
Code: Select all
root@nagios:/usr/local/nagios/libexec# ./check_snmp -P 1 -C COMMUNITY -H 192.168.1.1 -vvv -o iso.3.6.1.2.1.31.1.1.1.16.1
/usr/bin/snmpget -Le -t 1 -r 5 -m ALL -v 1 [authpriv] 192.168.1.1:161 iso.3.6.1.2.1.31.1.1.1.16.1
CRITICAL - Plugin timed out while executing system call
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 3:24 pm
by sreinhardt
Let's get a tcpdump and see if it is actually sending an snmp request, and a few other things.
tcpdump port 161
send a check or two
Are there additional lines of output after the tcpdump command?
ls /usr/bin/snmpget -l
./check_snmp -V
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 3:43 pm
by rhassing
tcpdump is a very good idea Spencer
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 4:48 pm
by Kerflumpre
the check_snmp shows nothing in the tcpdump.
The snmpget shows this:
Code: Select all
16:51:30.106087 IP 192.168.1.2.60241 > 192.168.1.1.snmp: C=COMMUNITY GetRequest(31) 31.1.1.1.16.1
16:51:30.108329 IP 192.168.1.1.snmp > 192.168.1.2.60241: C=COMMUNITY GetResponse(32) 31.1.1.1.16.1=2
Re: check_snmp not working but snmpget works
Posted: Fri Nov 07, 2014 10:39 pm
by rhassing
I think there is something wrong with the package you installed.
Are you familiar with compiling from source?
Re: check_snmp not working but snmpget works
Posted: Sat Nov 08, 2014 7:57 am
by Kerflumpre
Yes. That's what I did from the start. Sorry, I said it was a package. I had a brain fart. I've recompiled again and even tried the 1.5 plugins.
Re: check_snmp not working but snmpget works
Posted: Sat Nov 08, 2014 9:42 am
by rhassing
Are you using a 32 or 64 bit system?