Page 1 of 1

Active check that stays CRITICAL until resetted

Posted: Fri Jan 24, 2014 12:11 pm
by Stiuzz
Hi all,
could someone help me to configure an active check that remains in critical state until resetted (For example using "submit passive check result for this service", or creating a script that submit an external check).

An example of what I need is about uptime, I configured an active check that control uptime (check_uptime.pl) every 5 minutes and go in critical state if uptime is below 60 minutes, but when uptime reach 60 minutes the check go in ok state, I would like to configure this check to stay in critical state until manually resetted.

Do you think that is possible?

Regards
Stiuzz

Re: Active check that stays CRITICAL until resetted

Posted: Fri Jan 24, 2014 3:20 pm
by sreinhardt
You would need to save information in a temporary file of some sort and validate the last modified time or something of that nature. Can it be done? Yes absolutely. Is the logic built into nagios? Nope, it would have to be logic handled in the plugin.

Re: Active check that stays CRITICAL until resetted

Posted: Tue Jan 28, 2014 11:14 am
by Stiuzz
Thankyou Spencer,
I agree with you, just wondering if there was another solution as I don't have much time to spend re/writing script ;)

Regards
Stiuzz

Re: Active check that stays CRITICAL until resetted

Posted: Tue Jan 28, 2014 5:52 pm
by tmcdonald
Shouldn't be incredibly hard to write actually. We'd be happy to take a look if you can come up with something close to what you need.

Re: Active check that stays CRITICAL until resetted

Posted: Thu Feb 27, 2014 10:06 am
by wfournier
You could write a script that submits a check result *only* on critical. Disable active checks, enable passive. Then it will stay critical until you submit an OK yourself.

Re: Active check that stays CRITICAL until resetted

Posted: Thu Feb 27, 2014 10:27 am
by slansing
Let us know if you'd like input while writing it.