Hello,
We are currently evaluating Nagios XI and the salesperson told me to post here for pre-sales support questions.
We are a managed service provider and all of our monitored hosts are external to our network. My question is this: If we have the NS++ client installed on a remote server that is behind a firewall, can we create a NAT forward and configure Nagios and the client to communicate on that port? For instance:
Nagios Server on public IP x.x.x.x ---------------> Internet ------------------> Remote firewall with public IP y.y.y.y with port 9677 forwarded to internal Windows Server with NS++ installed and listening on port 9677.
So there would be no need to configure passive checks and each individual service on each individual monitored host via the local config file.
Thanks,
Brad
Monitoring remote servers
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Monitoring remote servers
Sure. You can do this with both the check_nrpe command as well as the check_nt when using with NSClient++
In Nagios XI you would want to do the following to change the checks to use a different port.
Configure -> Core Config Manager -> Commands -> Modify the check_nt command
change
to
Now on your service checks you will need to provide the port in the $ARG3$ field
Configure -> Core Config Manager -> Services -> Modify
$ARG3$ = 9677
In Nagios XI you would want to do the following to change the checks to use a different port.
Configure -> Core Config Manager -> Commands -> Modify the check_nt command
change
Code: Select all
$USER1$/check_nt -H $HOSTADDRESS$ -p $USER7$ -s $USER8$ -v $ARG1$ $ARG2$Code: Select all
$USER1$/check_nt -H $HOSTADDRESS$ -p $ARG3$ -s $USER8$ -v $ARG1$ $ARG2$Configure -> Core Config Manager -> Services -> Modify
$ARG3$ = 9677
Re: Monitoring remote servers
In addition to what scottwilkerson said, I would like to add that the default port for NSClient++ is 12489. You can change the NSClient++ port by modifying the NSC.ini file, located at C:\Program Files\NSClient++
After changing the port, you must restart the NSClient++ service, so that the changes can take effect.
Code: Select all
;# NSCLIENT PORT NUMBER
; This is the port the NSClientListener.dll will listen to.
port=12489Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: Monitoring remote servers
Awesome. Thank you so much for the replies. So it sounds like I can just install the NS++ client on the server, configure the ports, configure the check_nt command and then it can communicate through the firewall and monitor just like it was on the local LAN?
Thanks,
Brad
Thanks,
Brad
Re: Monitoring remote servers
That's correct. Please, let us know if you have any issues setting up NSClient++. You can open a new post - I will be locking this one. Thank you!So it sounds like I can just install the NS++ client on the server, configure the ports, configure the check_nt command and then it can communicate through the firewall and monitor just like it was on the local LAN?
Be sure to check out our Knowledgebase for helpful articles and solutions!