Different args for different times

Russell Scibetti russell at quadrix.com
Tue Feb 4 21:21:33 CET 2003


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