[Nagiosplug-help] Plugins (esp. ssh)
David Douthitt
ssrat at mailbag.com
Thu Dec 19 16:40:02 CET 2002
I have a plugin based on check_by_ssh, and
nothing seems to work! It returns critical
every time with no output, or it says that
the key is invalid, or anything except
something sensible.
In one case, Nagios claimed that the key
was invalid, but in reality, the host key
was not in the known_hosts.
In another case, Nagios claimed that the key
was invalid, but in reality, the key was
an RSA key (SSH1) and not a DSA key (SSH2).
Using the -1 switch to ssh (after a mod to
check_by_ssh) fixed that.
However, now everything returns "no output!"
and a critical state. Note that everything
works from the command line when logged in
as nagios, but not from nagios.
I converted to a perl script, then to a shell
wrapper around the perl script.
Nothing seems to work.
Note that there is no sort of descriptive
logs in /var/log or in the netsaint logs.
This getting to be a REAL pain.
What I'd like to see would be:
* check_by_ssh support for any arbitrary SSH options
* extensive log details when plugins do funny things
Just imagine:
Mon XX 99:99:99 host nagios: ran plugin: "/aaa/bbb/ccc/ddd/xxxx -abc xxxx xxx xxx"
Mon XX 99:99:99 host nagios: plugin xxxx missing: /aaa/bbb/ccc/ddd/xxxx
Mon XX 99:99:99 host nagios: ran plugin: "/aaa/bbb/ccc/ddd/zzzz -abc xxxx xxx xxx"
Mon XX 99:99:99 host nagios: plugin returned: X
Mon XX 99:99:99 host nagios: plugin zzzz output: abcdefghij
Mon XX 99:99:99 host nagios: plugin zzzz output: aft
Mon XX 99:99:99 host nagios: ran plugin: "/aaa/bbb/ccc/ddd/aaaa -abc xxxx xxx xxx"
Mon XX 99:99:99 host nagios: plugin aaaa returned: X
Mon XX 99:99:99 host nagios: plugin aaaa had no output
PS: Hi Jack! (Coates...)
PPS: I wrote a shell script to do the same thing - to check
disks and return a collective status. I might post it
if people are interested. It prints all disks and their
full status (in %) unless there are warnings or critical states -
then it prints only those that are critical or with warnings.
More information about the Help
mailing list