Hi all,
I am wanting to add a windows server as a Nagios target to be monitored, I would only like to monitor pings from this client. My question is... Is there a way to add a Nagios windows target without using NSClient++. I have been looking around and unable to find any information to add a target in this way.
Any help would be apreciated.
R
Adding Windows Nagios Target
Re: Adding Windows Nagios Target
You could configure a host to use the default check-host-alive command as it's check_command. At a bare minimum, your config file might look something like this:nagiosnoobin wrote:I would only like to monitor pings from this client.
Code: Select all
define host {
host_name <your host name>
use generic-host
alias <your host's alias>
check_command check-host-alive
max_check_attempts 5
check_interval 5
retry_interval 1
check_period 24x7
register 1
address <your host's logical address>
register 1
}
Code: Select all
define command {
command_name check-host-alive
command_line $USER1$/check_ping -H $HOSTADDRESS$ -w 3000.0,80% -c 5000.0,100% -p 5
}
Former Nagios employee
https://www.mcapra.com/
https://www.mcapra.com/
-
nagiosnoobin
- Posts: 2
- Joined: Tue Jul 05, 2016 8:02 am
Re: Adding Windows Nagios Target
Hi mcapra,
To which cfg file would I configure this? I am a true novice at this
Many thanks
R
To which cfg file would I configure this? I am a true novice at this
Many thanks
R
Re: Adding Windows Nagios Target
You can add this into the configuration file of your liking by adding a line to your /usr/local/nagios/etc/nagios.cfg file. The part that matters is this -
(these are just examples)
This would allow you to create a file called timeperiods.cfg, and add your configuration in there, or you could also create a directory called static, which will then absorb any .cfg files placed inside of it. That's what's powerful about Core, the choice is yours!
(these are just examples)
Code: Select all
cfg_file=/usr/local/nagios/etc/objects/timeperiods.cfg
cfg_dir=/usr/local/nagios/etc/static
Former Nagios Employee