[Nagiosplug-devel] New threshold syntax (New thread)
Vonnahme, Nathan
nathan.vonnahme at bannerhealth.com
Fri Apr 11 19:53:27 CEST 2008
> [mailto:nagiosplug-devel-bounces at lists.sourceforge.net] On Behalf Of
> Thomas Guyot-Sionnest
> Sent: Saturday, April 05, 2008 12:46 AM
> Issue #1:
>
> The current specification of thresholds says the new system will use
> "--{metric} {definition}" to define new thresholds. The definition is
> a
> getsubopt(3) list . In regard to this method the new specification
> will
> cause conflicts because some plugins already us similar longopt names
> for thresholds that will be converted to the new format.
>
> Instead, I suggest using "--threshold" (or the shorter "--thresh" if
> it's too long) to specify the threshold string, and add the suboption
> "metric" to define which metric we're setting the threshold against.
>
> For example, to check the SSL certificate using check_tcp (that
> already
> has "--certificate") I could use:
>
> check_tcp -H myhst -S
> --thresh metric=certificate,warn=<...>,crit=<...>
That is not as concise as
--certificate=ok=28..inf,warn=14..28
But I guess it will be necessary in most cases and will simplify
backwards compatibility. It is still easy to read.
> Issue #2:
>
> The specs should clearly state what uom is and also add uom_prefix
> (or
> just prefix if it's preferred). The current meaning of uom should
> actually be uom_prefix. Both would be optionnal.
The SI units lists seems adequate, though probably it would be good to
have a shorter list in the plugin documentation, since we don't need
most of the physics units.
I think the number of bits and abbreviation of binary units (gigabyte
etc) should agree with `df -h` and `ls -lh` and other utilities. NIST
is defining KB, MB, and GB differently from how they are usually used in
practice on most OSes, and I think that would confuse users, because
they'll be comparing plugin results with the results from those tools.
I'm also guessing that beyond recommending a syntax and a list of valid
uom values, the threshold parsing library we're talking about won't do
much with the units, but it would be left to each plugin. A widget
assembly line plugin might need a weird unit of measure like "thousands
of widgets per hour" or KWpH :)
More information about the Devel
mailing list