UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 second

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
comfone
Posts: 127
Joined: Fri May 01, 2015 3:28 am

UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 second

Post by comfone »

Hi All
We are using Nagios XI (5.3.1) VM appliance.
I'm trying to query our NetApp Storage aboard with SNMP using the pluging "check_netapp3.pl".
The timeout of 60 seconds is not enough, but the Plugins does not let me to increase this value.
If I try I "./check_netapp3.pl -H IP -v PERINODE -t 120", I get "UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 seconds"
An other strange thing is that only requests for "PERINODE - percentage inode space avail" and "PERUSED - percentage space used" are timing out.
Can anybody help?
Last edited by comfone on Tue Dec 20, 2016 5:44 am, edited 2 times in total.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 se

Post by tgriep »

That plugin uses the NET::SNMP perl module and it has a default maximum timeout set to 60. Follow these steps to increase that to 120 seconds.
Edit this file

Code: Select all

/usr/share/perl5/Net/SNMP/Transport.pm
Fine this line

Code: Select all

sub TIMEOUT_MAXIMUM() { 60.0 }
and change it to

Code: Select all

sub TIMEOUT_MAXIMUM() { 120.0 }
That will set the max timeout to 120 seconds.
If you update the NET:SNMP perl modules in the future on your server, you will have to change this again.
Be sure to check out our Knowledgebase for helpful articles and solutions!
comfone
Posts: 127
Joined: Fri May 01, 2015 3:28 am

Re: UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 se

Post by comfone »

Worked. Thank you.
comfone
Posts: 127
Joined: Fri May 01, 2015 3:28 am

Re: UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 se

Post by comfone »

Hi All
I tried to set the timeout in "/usr/share/perl5/Net/SNMP/Transport.pm" to 480 seconds.
But I still get the message:
SERVICE ALERT: hostname;NetApp percentage space used;CRITICAL;SOFT;1;(Service check timed out after 120.01 seconds)
Why does the setting not take effect?
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: UNKNOWN:Invalid timeout value [120], range 1.0 - 60.0 se

Post by tgriep »

The timeout setting in the nagios.cfg file has to be increased to the same timeout value you need for your check or it will timeout the check as well.
Edit the following file

Code: Select all

/use/local/nagios/etc/nagios.cfg
Change this from

Code: Select all

service_check_timeout=120
to

Code: Select all

service_check_timeout=480
Save the file and restart the nagios processes by running

Code: Select all

service nagios restart
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked