Nagioxi check_snmp: error

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
ericssonvietnam
Posts: 239
Joined: Mon Jun 27, 2016 11:05 pm

Nagioxi check_snmp: error

Post by ericssonvietnam »

I got XI 5.2.9 running on redhat 6 physical server. For Some host we are getting below error while trying to check process on client with "check_snmp_process_wizard.pl "
as :
$USER1$/check_snmp_process_wizard.pl -H $HOSTADDRESS$ $ARG1$ -t 30 -C public --v2c -r -n 'sshd' -w '0,20' -c '0'

ERROR: Alarm signal (Nagios time-out)
ERROR: General time-out (Alarm signal)

For some we are getting:
ERROR: Description/Type table : Requested table is empty or does not exist.

Please suggest a fix.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Nagioxi check_snmp: error

Post by rkennedy »

Can you show us the full check_command that the services are using in conjunction with that command definition? We will need to see what $ARG1$ is equal to.
Former Nagios Employee
ericssonvietnam
Posts: 239
Joined: Mon Jun 27, 2016 11:05 pm

Re: Nagioxi check_snmp: error

Post by ericssonvietnam »

COMMAND: /usr/local/nagios/libexec/check_snmp_process_wizard.pl -H HNRBT10 -C public --v2c -r -n 'sshd' -w '0,20' -c '0' -t 30
OUTPUT: ERROR: Alarm signal (Nagios time-out)

Please keep in mind that..this check is linked with a Hostgroup and that hostgroup has 110 nodes as member. And from most of the nodes response is as per expectation. So we can rule out any issue with command. I am suspecting client snmp settings as issue but not sure what to look at.?
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Nagioxi check_snmp: error

Post by Box293 »

What happens when you execute this at a command line on the Nagios XI server?

Code: Select all

/usr/local/nagios/libexec/check_snmp_process_wizard.pl -H HNRBT10 -C public --v2c -r -n 'sshd' -w '0,20' -c '0' -t 30
Can you make sure that HNRBT10 is resolving to the correct IP address. Also check the HOST object in CCM and make sure it's address is correct (not an incorrect IP address or DNS entry).
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
ericssonvietnam
Posts: 239
Joined: Mon Jun 27, 2016 11:05 pm

Re: Nagioxi check_snmp: error

Post by ericssonvietnam »

I agree that host response is bit slow..but settings are correct. below are some test results..

Code: Select all

time  ssh HNRBT10 "uname -n"
hnrbt10

real    0m7.865s
user    0m0.009s
sys     0m0.003s

[root@RADI ~]# grep -i hnrbt10 /etc/hosts
10.10.165.17    HNRBT10
You have new mail in /var/spool/mail/root
[root@RADI ~]# /usr/local/nagios/libexec/check_snmp_process_wizard.pl -H HNRBT10 -C public --v2c -r -n 'sshd' -w '0,20' -c '0' -t 30
ERROR: Alarm signal (Nagios time-out)
[root@RADI ~]# time /usr/local/nagios/libexec/check_snmp_process_wizard.pl -H 10.10.165.17 -C public --v2c -r -n 'sshd' -w '0,20' -c '0' -t 60
ERROR: Alarm signal (Nagios time-out)
real    0m15.082s
user    0m0.081s
sys     0m0.009s
User avatar
Box293
Too Basu
Posts: 5126
Joined: Sun Feb 07, 2010 10:55 pm
Location: Deniliquin, Australia
Contact:

Re: Nagioxi check_snmp: error

Post by Box293 »

It looks like the plugin has been hard coded for a timeout of 15 seconds.

Edit the plugin and change line 26 from:
my $TIMEOUT = 15;
To:
my $TIMEOUT;

This command will make that change:

Code: Select all

sed -i 's/^my $TIMEOUT.*/my $TIMEOUT;/g' /usr/local/nagios/libexec/check_snmp_process_wizard.pl
Then try the command again.

If it times out again then perhaps your device's SNMP settings are not correct. You can perform an nmap scan to see if that port is open. Run this command on your XI server:

Code: Select all

nmap -Pn -sU -p U:161 HNRBT10
What output do you get?
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
ericssonvietnam
Posts: 239
Joined: Mon Jun 27, 2016 11:05 pm

Re: Nagioxi check_snmp: error

Post by ericssonvietnam »

nmap -Pn -sU -p U:161 HNRBT10

Starting Nmap 5.51 ( http://nmap.org ) at 2016-07-07 17:06 ICT
Nmap scan report for HNRBT10 (10.10.165.17)
Host is up.
PORT STATE SERVICE
161/udp open|filtered snmp

Nmap done: 1 IP address (1 host up) scanned in 2.13 seconds
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Nagioxi check_snmp: error

Post by rkennedy »

It looks like it's filtered, what sort of firewall do you have running between XI and the client machine? This may be preventing it.

Are you able to run a snmpwalk against the machine from the Nagios machine specifically? Is it successful? snmpwalk ip -c public -v 2c (replace ip with the IP of the machine)
Former Nagios Employee
ericssonvietnam
Posts: 239
Joined: Mon Jun 27, 2016 11:05 pm

Re: Nagioxi check_snmp: error

Post by ericssonvietnam »

[root@RADI snmp]# snmpwalk HNRBT10 -c public -v 2c
No log handling enabled - turning on stderr logging
Cannot find module (NET-SNMP-PASS-MIB): At line 0 in (none)
Cannot find module (NET-SNMP-VACM-MIB): At line 0 in (none)
SNMPv2-MIB::sysDescr.0 = STRING: Linux hnrbt10 2.6.32-431.el6.x86_64 #1 SMP Sun Nov 10 22:19:54 EST 2013 x86_64
Timeout: No Response from HNRBT10
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Nagioxi check_snmp: error

Post by rkennedy »

rkennedy wrote:It looks like it's filtered, what sort of firewall do you have running between XI and the client machine? This may be preventing it.
If you are unable to snmpwalk against the machine, and nmap is showing filtered -- there is definitely something stopping the connection.
Former Nagios Employee
Locked