Page 1 of 1

About on-demand check of host

Posted: Tue Jan 15, 2019 7:54 am
by nagioslinux
I use Nagios Core 4.3.2 with CentOS 7.3, and I am monitoring it with nagios. I would like to set the host's life / death monitoring to be on-demand checking rather than regular monitoring.

In the case of monitored targets that are active checking both host and service, only on-demand check of the host is working normally.

However, in the case of a monitored object that is active checking the host and passively checking the service, setting it as on-demand check of the host does not work well.
The setting difference of both host definitions is only the value of "event_handler_enabled", the former being set to "0" and the latter to "1".

What is the cause of this problem and how can I avoid it?

Also, what should I do if you want to monitor host death monitoring not only on a periodic basis but on the host only for on-demand checking?
Should it be set as follows?

----
check_interval = 0
active_checks_enabled = 1
----

Also, is there anything that the transition of status by passive monitoring does not trigger on-demand check of the host?

Re: About on-demand check of host

Posted: Tue Jan 15, 2019 5:59 pm
by scottwilkerson
I'm not 100% sure what your desired behavior is but I am guessing you want to work with the cached_host_check_horizon directive.
https://assets.nagios.com/downloads/nag ... ck_horizon

additional information is available here
https://assets.nagios.com/downloads/nag ... hecks.html

Re: About on-demand check of host

Posted: Tue Jan 15, 2019 7:04 pm
by nagioslinux
thank you for your comment.

If you set cached_host_check_horizon (15s), check_interval = 0, active_checks_enabled = 1, you can only check on-demand checking of the host's alive monitoring instead of regular monitoring. Is it Correct?

Also, is there anything that the transition of status by passive monitoring does not trigger on-demand check of the host? Can you tell me if you understand?

Re: About on-demand check of host

Posted: Tue Jan 15, 2019 7:07 pm
by nagioslinux
scottwilkerson wrote:I'm not 100% sure what your desired behavior is but I am guessing you want to work with the cached_host_check_horizon directive.
https://assets.nagios.com/downloads/nag ... ck_horizon

additional information is available here
https://assets.nagios.com/downloads/nag ... hecks.html
thank you for your comment.

If you set cached_host_check_horizon (15s), check_interval = 0, active_checks_enabled = 1, you can only check on-demand checking of the host's alive monitoring instead of regular monitoring. Is it Correct?

Also, is there anything that the transition of status by passive monitoring does not trigger on-demand check of the host? Can you tell me if you understand?

Re: About on-demand check of host

Posted: Tue Jan 15, 2019 7:26 pm
by nagioslinux
scottwilkerson wrote:I'm not 100% sure what your desired behavior is but I am guessing you want to work with the cached_host_check_horizon directive.
https://assets.nagios.com/downloads/nag ... ck_horizon

additional information is available here
https://assets.nagios.com/downloads/nag ... hecks.html
I'm sorry. I was wrong.
It was "cached_host_check_horizon (0s)" instead of "cached_host_check_horizon (15s)".

Re: About on-demand check of host

Posted: Wed Jan 16, 2019 3:21 pm
by scottwilkerson
for cached_host_check_horizon from the documentation

Code: Select all

Use a value of 0 if you want to disable host check caching.