Am Montag 22 Mai 2006 12:03 schrieb Joerg Linge:
> Am Montag 22 Mai 2006 11:39 schrieb Jan Kratochvil:
> > > This ist still a quick hack, but it works ;-)
> > > This is IMHO the fastest way without parsing status.dat.
> >
> > Do you have it tested? I do not think it will work. The goal is to
> > reflect the field "last_hard_state", not the field "current_state".
> > "SERVICESTATEID" unfortunately corresponds to "current_state" while
> > "last_hard_state" has no corresponding macro.
>
> This was only a quick example!
> $SERVICESTATETYPE$ gets the state type ( HARD/SOFT )

Hmm, $SERVICESTATETYPE$  always reports an HARD state.

If you use $SERVICEATTEMPT:server1:Connectivity$ you will get the corrent 
check attempts for your Connectivity Service.

So you can return an CRITICAL state to your host check_command if the maximun 
number of service checks are reached.

In my test environment this works fine at the moment. 

I have written a small plugin which return CRITICAL if 
$SERVICESTATEID != 0 && $SERVICEATTEMPTS >= 3

Jörg 

Attachment: pgpAfUenfdiho.pgp
Description: PGP signature

Reply via email to