>> I know this sounds like  a bizarre idea, but I am trying to use the
>> "exit=" parameter to the alert script to limit when an email alert is
sent
>> out, while still logging all failures.
>
> Yes, I hear you. What I did is standardize all my alert scripts to use
> 0=success, 1="real failure", and >2 to mean "some sort of warning
condition
> not meriting an alert". I really didn't care about logging SNMP timeout
> failures, etc. I only wanted to log real, verified failures.
>
> The real solution it seems, is for mon to allow us to utilize $STAT_WARN,

> which I didn't even realize existed until recently but AFAICT is never
> used, except in one part of the trap handling code.
>
> The 'yellow' state in mon.cgi is really just a hack, and mon should IMHO
> have a legitimate WARN status.

How about the possibility of having an optional "severity=number" argument
to the alert keyword?
The severity level would then be available to clients via list_alerthist in
Mon::Client. Default severity would be 1 (highest), and the range would be
open-ended and sites could define their own uses of other severity levels,
with perhaps a convention for "script failure" (e.g. protocol error). It
seems to me this approach would be very flexible, would integrate well with
the existing "exit=" argument, and would require very little work to
implement.

If this sounds like a good idea, I'd be happy to take a whack at it.

Dan
--
Dan Urist
[EMAIL PROTECTED]
[EMAIL PROTECTED]
http://world.std.com/~durist







Reply via email to