Page 2 of 4
Re: Monitor remote machine's memory using Nagios Core
Posted: Thu Dec 05, 2013 5:40 pm
by abrist
vinothsethuram wrote:/usr/local/nagios/libexec/check_nrpe -H localhost
connect to address 127.0.0.1 port 5666: Connection refused
If I specify a host other than local host then I am getting socket time out
Are you starting nrpe through xinetd or an init script?
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 9:40 am
by vinothsethuram
I started the daemon. Do we need to install nagios in remote server which we are going to monitor. And also please give syntax/example.
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 11:14 am
by abrist
vinothsethuram wrote:Do we need to install nagios in remote server which we are going to monitor.
No, the nrpe daemon runs on the remote host. Your nagios server checks the remote host with check_nrpe.
vinothsethuram wrote:And also please give syntax/example.
Of what?
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 11:21 am
by vinothsethuram
Syntax/Example about disk usage and processor check
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 11:35 am
by abrist
I would suggest you start with the following doc as examples without an understanding of the syntax will not get you very far:
http://nagios.sourceforge.net/docs/nrpe/NRPE.pdf
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 4:11 pm
by vinothsethuram
Given link is very useful. I'm able to get output for local host. however i couldn't get output for remote host. getting port 5666: Connection refused
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 4:26 pm
by tmcdonald
vinothsethuram wrote:Given link is very useful. I'm able to get output for local host. however i couldn't get output for remote host. getting port 5666: Connection refused
Did you open port 5666 in the firewall?
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 4:38 pm
by vinothsethuram
Added nrpe 5666/tcp # NRPE in services file and executed this command
iptables -A INPUT -p tcp --dport 5666 -j ACCEPT
Re: Monitor remote machine's memory using Nagios Core
Posted: Tue Dec 10, 2013 4:44 pm
by tmcdonald
You forgot the -m flag, might make a difference:
Code: Select all
iptables -A INPUT -p tcp -m tcp --dport 5666 -j ACCEPT
Then also make sure to run:
so changes will persist after a reboot.
Re: Monitor remote machine's memory using Nagios Core
Posted: Wed Dec 11, 2013 12:55 pm
by vinothsethuram
Still getting port 5666: Connection refused