About check_by_ssh

David Elze elze at bytemine.net
Thu Nov 24 19:32:37 CET 2005


Am Donnerstag, den 24.11.2005, 16:47 +0100 schrieb Jean Frontin:

Hey, 

> Is there anybody who runs this plugin within nagios. 

Yes I do without any problems :-)

> in the "help" of this plugin One finds  the options -w and -c, but when I 
> insert them in command line I obtain  an error message : argument unknown

Well, if you use that plugin you certainly want to check some remote
command via ssh. To do that, you can simply call check_by_ssh with a
user (-l <username>) and the server (-H <servername>) and then you add
your command (-C '<command>') that sould be run on the remote server.

As an example, we've got server a.server.tld wich is the nagios machine
and server b.server.tld that has installed the nagios-plugins only in,
let's say, /home/nagios/libexec/ (if you use check_by_ssh you should use
a not so priviliged user for that matter, here it could be 'nagios').

So to check the load of b.server.tld you could simply do the following:

check_by_ssh -l nagios -H b.server.tld -C \
'/home/nagios/libexec/check_load -w 7,7,7 -c 10,10,10'

As you can see, the '-w' and '-c' switch are used inside the command
that is executed on the remote host and feeded back via the
check_by_ssh-plugin to you nagios-server a.server.tld.

So if that's something that helps you, perfect, if not (i.e. you really
want to use check_by_ssh itself with '-w' and '-c') you should provide
more info what exactly you try to do.

CU
  David
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <https://www.monitoring-lists.org/archive/users/attachments/20051124/026f07fc/attachment.sig>


More information about the Users mailing list