Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a service that I'd like to change the check command for during different time periods. I see that you can change the check_command live using external commands, but I would like to be able to configure this to happen in the object definition.

Any ideas?

share|improve this question

1 Answer 1

up vote 3 down vote accepted

You could write a custom script that takes a time period specification and two check commands and runs the appropriate command. You might have to implement the time period checks yourself, but it shouldn't be too difficult.

You could also write two separate service checks with non-overlapping notification times (so that you either get alerts from one or the other but not both).

share|improve this answer
    
Can you do that for the same service (that is, same service_name)? –  cpuguy83 Aug 14 '12 at 17:56
    
I suspect that you would need two service definitions for that option. –  Bob the Angry Coder Aug 14 '12 at 17:57
    
Seems to be the only way to do this. –  cpuguy83 Aug 17 '12 at 22:07

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.