check_snmp and mulitple oid returns
Steve Bonds
r1p6os402 at sneakemail.com
Mon Jan 27 18:28:11 CET 2003
I've modified the plugin to check all the filesystems on a host at once,
with a regex-based command-line method to change the warn/crit parameters
for groups of filesystems. It also returns the "worst" failure it
detects.
Unfortunately (for most folks) I've also modified it to work with the
rather broken HP-UX SNMP agent. (OID and minor logic changes since this
agent does not support the host resource MIB.)
If you can hack out the HP-UX portions, I would be glad to make the plugin
available to you for a beta. (It's not quite ready for prime-time, but if
anyone wants it, they're welcome to it.)
-- Steve
On Mon, 27 Jan 2003, jgking-at-packetstorm.org |Nagios| wrote:
>
> Ive been searching the list archives for the last 30 minutes have been
> having alot of hits close to it but either im not understanding or its
> different than what im asking.
>
> Instead of having, say 5 seperate snmp check entries in the services.cfg
> file, i would rather consolidate it into one single check and look for an
> oid return value that meets the error criteria.
>
> For example, disk percent usage.
>
> In snmpd.conf i setup the following:
>
> disk / 10000
> disk /boot 10000
> disk /data 10000
> disk /home 817928
> disk /tmp 10000
> disk /usr 10000
> disk /var 10000
>
> Now that this will do is set the errorflag field if anything matches
>
> ..iso.3.6.1.4.1.2021.9.1.101.1 = ""
> ..iso.3.6.1.4.1.2021.9.1.101.2 = ""
> ..iso.3.6.1.4.1.2021.9.1.101.3 = ""
> ..iso.3.6.1.4.1.2021.9.1.101.4 = "/home: less than 817928 free (= 807928)"
> ..iso.3.6.1.4.1.2021.9.1.101.5 = ""
> ..iso.3.6.1.4.1.2021.9.1.101.6 = ""
-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
More information about the Users
mailing list