Still I am not able to understand.
Could you please give simple example on three setting
Calling from nagios with -the 120
Changing nrpe timeout 70
Changing the external script 60
Changing the vbs=casript.exe//T:120
What is the difference between -t 120 in check command and n
-
- Posts: 222
- Joined: Thu Jul 06, 2017 8:55 am
Re: What is the difference between -t 120 in check command a
Here's an explanation on timeouts from the NSClient++ documentation:
https://docs.nsclient.org/faq/#42-timeout-issues
The problem is that there are many places where you can set up timeout values. They are used (usually) in different checks. However, there is some overlap. For example, most plugins, including check_nrpe have a flag for a timeout (-t).
This will work, as long as it doesn't exceed the "global" timeout setting in the main nagios config file (nagios.cfg). The default value is 60.
Using nrpe with NSClient++ adds to the complexity. The NRPE section in the nsclient.ini file has a timeout setting, that would be used as well. Also, you are not just running a check_nrpe check... You are calling a script, which is run on the Windows machine. So, NSClient++ has a timeout section for external scripts too.
The bottom line is - make sure that there is no "bottleneck" somewhere, that could cause your check to timeout, before it is done running. You could increase all of the values that you need to, knowing how much it takes to usually execute the script. I hope this makes sense.
https://docs.nsclient.org/faq/#42-timeout-issues
The problem is that there are many places where you can set up timeout values. They are used (usually) in different checks. However, there is some overlap. For example, most plugins, including check_nrpe have a flag for a timeout (-t).
Code: Select all
./check_nrpe -H <ip address> -t <timeout interval> -c <command> -a <arguments>
Code: Select all
service_check_timeout=60
The bottom line is - make sure that there is no "bottleneck" somewhere, that could cause your check to timeout, before it is done running. You could increase all of the values that you need to, knowing how much it takes to usually execute the script. I hope this makes sense.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
- Posts: 222
- Joined: Thu Jul 06, 2017 8:55 am
Re: What is the difference between -t 120 in check command a
What does it mean below T:120
/settings/external scripts/wrappings]
vbs = cscript.exe //T:120 //NoLogo scripts\\lib\\wrapper.vbs %SCRIPT% %ARGS%
/settings/external scripts/wrappings]
vbs = cscript.exe //T:120 //NoLogo scripts\\lib\\wrapper.vbs %SCRIPT% %ARGS%
Re: What is the difference between -t 120 in check command a
This is yet another timeout value (for the script.exe).
Again, make sure none of these timeout values is shorter than the time it takes to run the script. I hope you don't have many checks like this one. It is preferable that Nagios gets "immediate" or "quick" results, instead of being help for a long time. I understand that this is not always possible as some scripts take a long time to run, but just wanted to mention this as a FYI.
Let us know if you have any further questions or it is OK to close this thread. Thank you!
Again, make sure none of these timeout values is shorter than the time it takes to run the script. I hope you don't have many checks like this one. It is preferable that Nagios gets "immediate" or "quick" results, instead of being help for a long time. I understand that this is not always possible as some scripts take a long time to run, but just wanted to mention this as a FYI.
Let us know if you have any further questions or it is OK to close this thread. Thank you!
You do not have the required permissions to view the files attached to this post.
Be sure to check out our Knowledgebase for helpful articles and solutions!