Some questions about functionality. check_by_ssh.

nemir nemiria nemir at mindless.com
Thu Jul 8 22:56:18 CEST 2004


Hiya.

Fiurst thing I'd like to know is whether it is possible to nest check_by_ssh in another check_by_ssh command to check something on a third box?

I run a database server.  It is important enough to the business that I have created a second machine of identical hardware and software configuration and run rsync through cron to regularly update the data on it as a standby system.  I have set this up in a separate,  dedicated network,  and run my backups from standby server.  All hosts that connect to this network are therefore multihomed.  This backup network is not routed so there is no way any host that isn't on this backup network can communicate with this host.  The nagios server is not in a position to connect to this directly (it has to sit in a less secure DMZ).  To make sure that the backup daemon is running on the box,  I'd like to run check_procs on that host.    From the live server,  I can run the following command:

./check_by_ssh -H 192.168.16.2 -C "/usr/local/nagios/libexec/check_procs -c 1:3 -C backup"

and I get the response:

OK - 2 processes running with command name backup

>From the nagios server I try running the command


./check_by_ssh -H 172.16.16.12 -C "/usr/local/nagios/libexec/check_by_ssh -H 192.168.16.2 -C "/usr/local/nagios/libexec/check_procs -c 1:3 -C backup""

but I get an error that says 

./check_by_ssh: invalid option -- c



Obviously it isn't passing through the command to the remote server....  I have confirmed that the nagios account on the server has keys set up correctly....   Is this not possible?

Also,   is it possible to set up a notification system where it notifies one person immediately,  and then a second person after 15 minutes or so if there is no acknowledgment and no recovery?

Finally, there is one windows host that requires a reboot once per evening.  This happens at different times each night depending on other circumstances.   Is there a way that I could do something like:

o) Configure a regular downtime period that would immediately be ended once a downtime had been detected?

o) send some sort of signal to the nagios box as part of a reboot script to set up a 10 minute downtime?

o) do something else that guys on this list that are cleverer than I might suggest?



In other news, I have solved many many of my issues by trawling through the archives, re-reading the documentation and diligently checking the FAQs before I ask questions.  I've just written up an "idiot's guide to setting up and configuring check_by_ssh" going into a fair amount of detail.  Is anyone interested in having me posting it or publishing it on a website?    It isn't <i>quite</i> finished,  because I wanted the answer to my first question first,  but it includes deatil on how to set up the ssh keys, and talks about the methods I used to make sure it was going to work.   It is really basic,  cause I can be pretty dumb,  I am thinking a quick summary for guys more advanced might be a good idea too.   I figure this sort of thing is one thing I can contribute,  not being a programmer or anything.

Regards,

Nemir



-- 
___________________________________________________________
Sign-up for Ads Free at Mail.com
http://promo.mail.com/adsfreejump.htm



-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list