Can anyone let me know how I would reduce time between Last Check Time and Next Scheduled Check on a particular services.
I need this to be 30 second if it not possible at least 1 minutes.
can someone tell me which files need to configure and which values need to set.
Reduce time between Last Check Time and Next Scheduled Check
Re: Reduce time between Last Check Time and Next Scheduled C
That would be the check_interval config option for hosts/services that are not in a problem state, and retry_interval for those that are. The value is in minutes, so "check_interval 1" would check every minute.
Former Nagios employee
Re: Reduce time between Last Check Time and Next Scheduled C
thanks..I'll check it againtmcdonald wrote:That would be the check_interval config option for hosts/services that are not in a problem state, and retry_interval for those that are. The value is in minutes, so "check_interval 1" would check every minute.
Re: Reduce time between Last Check Time and Next Scheduled C
I hate contradicting Nagios staff, but the check_interval (and retry_interval) is not technically in minutes, it is in interval_length intervals.
interval_length is defined in /usr/local/nagios/etc/nagios.cfg and by default, it is set to 60 seconds. So interval_length x check_interval = number of seconds between service checks for checks not in a problem state. Since interval_length defaults to 60 seconds, check_interval (and retry_interval) is in minutes. But if you changed interval_length to be 15, for instance, then check_interval (and retry_interval )becomes 1/4 minute intervals.
interval_length is defined in /usr/local/nagios/etc/nagios.cfg and by default, it is set to 60 seconds. So interval_length x check_interval = number of seconds between service checks for checks not in a problem state. Since interval_length defaults to 60 seconds, check_interval (and retry_interval) is in minutes. But if you changed interval_length to be 15, for instance, then check_interval (and retry_interval )becomes 1/4 minute intervals.
Re: Reduce time between Last Check Time and Next Scheduled C
I like being contradicted when I leave out vital information :)eloyd wrote:I hate contradicting Nagios staff
It was somewhat intentional though, since all other checks will need to be modified if OP goes that route.
Re: Reduce time between Last Check Time and Next Scheduled C
True, but I like being painstakingly accurate.
Re: Reduce time between Last Check Time and Next Scheduled C
Just an FYI: Changing interval_length may have odd consequences with the scheduler. All we can do is suggest you try it out. Your mileage may vary.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
Re: Reduce time between Last Check Time and Next Scheduled C
The original question was setting things to check every 30 seconds. To do this, you need to change interval_length from 60 to 30 and then ensure that all of your *_interval config parameters are now calculated based on 30 second intervals instead of 60 second intervals. So anything that you want to have checked every minute needs to be doubled to 2 while everything you want to be checked at 30 seconds needs to be 1.
I've never seen a case of changing the interval_length changing the scheduler. I do see some places in the 4.0.7 code that check_interval is used where I believe (check_interval * interval_Length) should be used, but it looks to be in special cases that probably won't matter (but should still be fixed).
If I get excited over the next few days, I'll take a closer look. But - again, your mileage may vary - I've never had a problem lowering interval_length to 30 seconds.
I've never seen a case of changing the interval_length changing the scheduler. I do see some places in the 4.0.7 code that check_interval is used where I believe (check_interval * interval_Length) should be used, but it looks to be in special cases that probably won't matter (but should still be fixed).
If I get excited over the next few days, I'll take a closer look. But - again, your mileage may vary - I've never had a problem lowering interval_length to 30 seconds.
Re: Reduce time between Last Check Time and Next Scheduled C
It is more about the potential issues of the auto_rescheduling_window and sub one minute checks. Make sure that your auto_rescheduling_window directive in nagios.cfg is set to less than your shortest possible check interval (which is derived from interval_length * check_interval).eloyd wrote:I've never seen a case of changing the interval_length changing the scheduler.
Former Nagios employee
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.
"It is turtles. All. The. Way. Down. . . .and maybe an elephant or two."
VI VI VI - The editor of the Beast!
Come to the Dark Side.