Different args for different times

David Corbin dcorbin at machturtle.com
Wed Feb 5 00:18:28 CET 2003


Or, what I want, which is time-based notification....or maybe even 
time-based + severity.


Russell Scibetti wrote:

> I just gave in and did it that way.
>
> Maybe something to keep in mind for future Nagios features - Time 
> based command/arguments.
>
> Russell
>
> Subhendu Ghosh wrote:
>
>>not easy in the current setup.
>>
>>easiest would be to write a wrapper which checks localtime and calls 
>>check_load with the approriate args...
>>
>>-sg
>>
>>On Tue, 4 Feb 2003, Russell Scibetti wrote:
>>
>>    
>>
>>>I want to have a service defined that runs a different command depending 
>>>on the timeperiod.  Example:
>>>
>>>define service{
>>>        use                             GenericService
>>>        host_name                       backup_host
>>>        service_description             Load
>>>        check_command                   check_load!6,6,6!8,8,8
>>>        check_period                    backup_times
>>>        }
>>>
>>>define service{
>>>        use                             GenericService
>>>        host_name                       backup_host
>>>        service_description             Load
>>>        check_command                   check_load!2,2,2!4,4,4
>>>        check_period                    nonbackup_times
>>>        }
>>>
>>>However, Nagios yells about there being 2 services with the same name. 
>>> I tried renaming the first one to backupLoad, which works except that 
>>>if the service is critical at the end of the timeperiod, it continues
>>> to 
>>>display a critical after the backup_times timeperiod is over.  Is there 
>>>anyway around this?  Ideally I would like them to have the same name, so 
>>>that during one timeperiod, one set of args is used and during the other 
>>>timeperiod, the different set is used.  Any help would be appreciated.
>>>
>>>Russell Scibetti
>>>
>>>
>>>      
>>>
>>
>>    
>>
>
>-- 
>Russell Scibetti
>Quadrix Solutions, Inc.
>http://www.quadrix.com
>(732) 235-2335, ext. 7038
>  
>
>




-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com




More information about the Users mailing list