port 5666: Connection refused SAVE ME , I tried everything

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by lmiltchev »

Is 192.168.0.93 the correct IP address of your nagios server? Have you restarted xinetd after modifying the nrpe file, so that the changes can take effect? have you tried stopping the iptables temporarily just in case, and running your check again?
Be sure to check out our Knowledgebase for helpful articles and solutions!
pohlin
Posts: 18
Joined: Wed Jan 31, 2018 10:08 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by pohlin »

yes 192.168.0.93 is the correct ip adress of the nagios server.
Yup, restarted.
tried stopping iptables ,output still the same.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by lmiltchev »

Are you using TCP wrappers? Do you have host.allow or host.deny configured on this system? Run the following commands on the remote box, and show the output:

Code: Select all

ip a
uname -a
cat /etc/*release
netstat -anp | grep 5666
/usr/local/nagios/bin/nrpe -V
/usr/local/nagios/libexec/check_nrpe -H 127.0.0.1
Also, upload the nrpe.cfg file on the forum. Thank you!
Be sure to check out our Knowledgebase for helpful articles and solutions!
pohlin
Posts: 18
Joined: Wed Jan 31, 2018 10:08 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by pohlin »

im sorry, i am new to everything..so i dont know if im using a tcp wrapper or not, and also dont know i have host.deny or host.allow... :cry:
here are the screenshot and file, thank you for trying to help me
n1.png
n2.png
nrpe.cfg
(7.05 KiB) Downloaded 509 times
npolovenko
Support Tech
Posts: 3457
Joined: Mon May 15, 2017 5:00 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by npolovenko »

@pohlin, I looked at your nrpe.cfg config file and the line:

Code: Select all

allowed_hosts=127.0.0.1
Doesn't have the entry for the Nagios server. Please change it to:

Code: Select all

allowed_hosts=127.0.0.1,192.168.0.93
Exit out of the file and restart nrpe with:

Code: Select all

service nrpe restart
Then, from the nagios server run the following command:

Code: Select all

/usr/local/nagios/libexec/check_nrpe -H 192.168.0.137
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
pohlin
Posts: 18
Joined: Wed Jan 31, 2018 10:08 pm

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by pohlin »

HI everyone ,thank you so much for helping me, but i've moved on to install nagios core on an real server, ubuntu 14.04, and i am still facing connection refuse issue. i have posted a new thread : https://support.nagios.com/forum/viewto ... 20&t=47623
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: port 5666: Connection refused SAVE ME , I tried everythi

Post by tmcdonald »

I will be closing this thread and we will continue in the other.
Former Nagios employee
Locked