Page 1 of 1

How to change host check time to every second ?

Posted: Wed Nov 25, 2020 10:16 am
by haseebraza
Hi folks, as you always doing great by helping others once again i need help in tiny matter !!!
I have added switches and routers to nagios core 4.46 but i was able to reduce to host check time to every 15 second.
Can we change this to lower value in seconds like every second ?

Re: How to change host check time to every second ?

Posted: Fri Nov 27, 2020 6:40 am
by is_kim
Hi,

As far I know Nagios was built to run checks every minute. I know some situations you'd like to reduce this time between checks, but I think the purpose of Nagios was not meant to be a real-time monitoring. Of course, you can use passive checks to deploy results with less than one minute (because Nagios is awaiting to receive this data), but I don't know if the log generation will work properly, specially when you want to generate Trends/Availability Reports.

I hope this helps you. If not, I suggest you take a look at the documentation ; )
https://assets.nagios.com/downloads/nag ... core/4/en/

Re: How to change host check time to every second ?

Posted: Sat Nov 28, 2020 7:33 pm
by Rfferrao13
Yes, you can -- although, as pointed by @is_kim, Nagios may not be able to handle it properly (and/or even keep up with it if there's a large amount of checks running at once). The interval_length option in nagios.cfg is used with the time interval specification for the object configuration files.

As per the Main Configuration File Options documentation (https://assets.nagios.com/downloads/nag ... gmain.html):
Timing Interval Length

Format: interval_length=<seconds>
Example: interval_length=60

This is the number of seconds per "unit interval" used for timing in the scheduling queue, re-notifications, etc. "Units intervals" are used in the object configuration file to determine how often to run a service check, how often to re-notify a contact, etc.

Important: The default value for this is set to 60, which means that a "unit value" of 1 in the object configuration file will mean 60 seconds (1 minute). I have not really tested other values for this variable, so proceed at your own risk if you decide to do so!

Re: How to change host check time to every second ?

Posted: Thu Dec 03, 2020 9:00 am
by haseebraza
Really appreciated for your help, i am able to change the check_host and check_ping time to 15 sec.
if i go down then it produces some unknown issue like some times it gives duration of 7 second then 15 then 8 then 20+.
So i think 15 sec is enough.

Re: How to change host check time to every second ?

Posted: Fri Dec 11, 2020 9:33 am
by scottwilkerson
haseebraza wrote:Really appreciated for your help, i am able to change the check_host and check_ping time to 15 sec.
if i go down then it produces some unknown issue like some times it gives duration of 7 second then 15 then 8 then 20+.
So i think 15 sec is enough.
Glad to see it is solved

Locking thread