Page 1 of 2
Service timed out change
Posted: Wed May 06, 2015 10:19 am
by sharding
I have a service check that is timing out (according to op center view) as it does not get an answer within 60 seconds, I timed the check and need 4 or 5 mins, where is this found?
I looked all around the service check and did not see 60 anywhere? to be able to change it
-- mod edit --
Fixed spelling error in subject so that the topic is easily searchable in the future.
Re: Serive timed out change
Posted: Wed May 06, 2015 10:34 am
by lmiltchev
I don't know what plugin you are using. Most of the plugins have an option to specify the timeout, i.e. "-t". There is also a setting in the "nagios.cfg" file for the timeout on service checks. It's set to 60 sec by default.
Re: Service timed out change
Posted: Wed May 06, 2015 10:35 am
by jdalrymple
This is in the main nagios.cfg. You can edit this here:
Configure --> Core Configuration Manager --> Advanced --> Nagios Core Main Config
find "service_check_timeout" and change it to suit your needs.
Be aware that changing this can have performance implications. Also your plugin may have its own timeout settings that may need to be adjusted.
Re: Service timed out change
Posted: Wed May 06, 2015 10:36 am
by jolson
Please let us know which plugin you are using to make this check - most plugins have a 'timeout' argument that can be set - '-t 60' or similar, it may be as simple as adding that to the end of your check. We need to know the plugin name to tell you for certain. Thanks!
Re: Service timed out change
Posted: Wed May 06, 2015 11:13 am
by sharding
it's a custom script does snmp walk on a layer 3 switch on a large network segment, it just takes that long, so can I still use a -t with custom scripts ? or is there a tab & field in the other tabs in the gui check?
Re: Service timed out change
Posted: Wed May 06, 2015 12:02 pm
by jdalrymple
You can just add "-t 300" into your snmpwalk command. That is how this would be dealt with in the most simple manner.
Although if memory serves me snmpwalk won't timeout unless it stops receiving data, so that is probably even unnecessary.
Re: Service timed out change
Posted: Wed May 06, 2015 1:12 pm
by sharding
still says (Service check timed out after 60.01 seconds), the script runs fine from cmd and from TEST in the service,
should I e-mail a ticket ? as I would really like someone to remote in to find why
Re: Service timed out change
Posted: Wed May 06, 2015 1:45 pm
by jdalrymple
Did you restart Nagios after changing the configuration in nagios.cfg?
Re: Service timed out change
Posted: Wed May 06, 2015 1:56 pm
by tgriep
In the nagios.cfg file there is a service timeout setting which has the default timeout of 60 seconds.
This is what it is called.
If any service check takes longer than 60 seconds, it will timeout and be stopped by the above timeout setting.
You can adjust this setting higher but it may cause other issues, you need to monitor the Nagios system to see if there are any problems.
Re: Service timed out change
Posted: Wed May 06, 2015 2:23 pm
by sharding
I e-mail a case in, I only want to change these 3 service checks not the whole system and I tried the -t <time> didn't make any difference