[Nagiosplug-devel] Does check_by_ssh in passive mode work?

John P. Rouillard rouilj at cs.umb.edu
Fri May 19 19:21:05 CEST 2006


Hi all:

I am trying to use check_by_ssh in passive mode from plugins 1.4.3. I
can't seem to get it to work. I am invoking it with:

   /usr/lib/nagios/plugins/check_by_ssh -v  -H localhost \
     -s A:B:C  -O /tmp/out -n foo \
     -C "/usr/lib/nagios/plugins/check_disk /" \
     -C "/usr/lib/nagios/plugins/check_disk /" \
     -C "/usr/lib/nagios/plugins/check_disk /"

The verbose output looks ok.

    /usr/bin/ssh localhost '/usr/lib/nagios/plugins/check_disk /;
        echo STATUS CODE: $?;/usr/lib/nagios/plugins/check_disk /usr;
        echo STATUS CODE: $?;/usr/lib/nagios/plugins/check_disk /var;
        echo STATUS CODE: $?;'

but it emits the output from the first command:

  DISK OK - free space: / 5399 MB (91% inode=99%);| /=554MB;5953;5953;98;5953

on standard out, and creates a 0 length /tmp/out file. I was expecting
passive service commands for A, B and C for host "foo" in the /tmp/out
file.  (Note the same thing occurs without the -v flag.)

Does anybody have this working? Or have a better description of what
it should be doing? It seems to have a split passive/active output
mode that appears a bit weird. I guess it sort of makes sense since
the plugin would be run by a service that expects an output string
from the plugin.

				-- rouilj
John Rouillard
===========================================================================
My employers don't acknowledge my existence much less my opinions.




More information about the Devel mailing list