Page 1 of 1

Monitoring Windows Servers with NagiosCore with scripts

Posted: Sun Nov 04, 2012 4:48 am
by TNTGav
Hello all,

I've spent quite a while getting my head around how Nagios works and I feel I have a relatively good grip of it now but there is one thing that is confusing me.

Lets say I have 200 remote hosts, and I find a script on Nagios Exchange that I want to run against them. As I understand the concept of NSClient++ and NRPE, I'd have to manually put the script (lets say a VBS) on these servers and then execute it somehow through NSClient++ strings.

My question: am I thinking about this wrong. How can I run say VBS/PS code against remote servers without having to get a script out to 200 servers. Can someone give an example or point to a tutorial for running something that isn't one of the default plugins for NSClient++ or NRPE.

Thanks in advance for any advice!

Re: Monitoring Windows Servers with NagiosCore with scripts

Posted: Sun Nov 04, 2012 5:06 pm
by jsmurphy
You can't.

If you want to use NSClient or NRPE to check a remote server it needs a local copy of the script to execute. Distribution and version maintenance is usually done by your companies package management solution or your automation solution (i.e. chef or puppet).

There isn't really a way around this, you could rely on alternative plugins like check_wmi_plus but you would be limiting your monitoring options.

Re: Monitoring Windows Servers with NagiosCore with scripts

Posted: Mon Nov 05, 2012 3:20 pm
by slansing
In addition if you would like an example of a simple script that gets executed on a remote server please see this document set.
It is from the perspective of a Nagios XI Admin but it should serve the purpose of showing you the steps without reading up on NSClient++ or NRPE documents:

http://library.nagios.com/library/produ ... -nagios-xi