Hello, Humm, this was quite interesting, is there a way to (from the plink) to detect the status of the connection or does plink "die" when the connection dies even? Would be quite simple to add a "plugin" to run this from within nsclient++, but for it to be useful you would need to be able to detect the status of the link (and I have never used the command myself).
// MickeM > On Tue, 12 Feb 2008 05:06:38 +0100, Paul Aviles > <[EMAIL PROTECTED]> wrote: > >> I am looking for a way to remotely monitor Windows servers. The servers >> are on a remote network and using network address translation so they >> are not directly accessible. I saw that Pandora uses an agent on the >> remote servers to connect via ssh to the main monitoring server and I >> like that idea, but I have not been able to see any documentation on how >> to do it with Nagios. In our configuration we cannot alter or open ports >> on the clients firewalls, but outgoing ssh traffic should not be an >> issue and I guess the monitoring server should not contact the remote >> servers. > > Hi Paul, > > I think it should be quite easy to use putty's plink to connect and tunnel > nsclient++ using remote tunneling (-R option). > > For example assuming NSClient is running on port 12489 you could run > > plink -R 20001:127.0.0.1:12489 [EMAIL PROTECTED] > > And then as long as the SSH connection stays open your nagiosserver will > be able to access NSClient++ by connecting to 127.0.0.1 port 20001. You'd > need to modify check_nt command a bit to always use 127.0.0.1 as an IP. If > it's Nagios 3 you can also use custom variable (like _NSCLIENTPORT) in > host definitions and reuse that in your version of check_nt command (using > $_HOSTNSCLIENTPORT$). > > The solution might not be robust enough if your network is not stable - in > that case you might need a wrapper that will restart plink if a connection > is down... I'm not sure if any working solutions for this exist. I'm > curious myself as I wrote a small wrapper that checks for connection > timeouts - and I'm wondering if there's any better solution on Windows. > > -- > Wojciech Kocjan > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Nagios-users mailing list > Nagios-users@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 > > ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Nagios-users mailing list Nagios-users@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