Connection refused for nrpe on Ubuntu 14.04

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.
Locked
danoreilly
Posts: 28
Joined: Mon Dec 01, 2014 4:28 pm

Connection refused for nrpe on Ubuntu 14.04

Post by danoreilly »

I installed nagios-plugins 2.0.3 and nrpe 2.15 on Ubuntu 14.04. Everything went fine until I did the check_nrpe and it appears to fail with:

# /usr/local/nagios/libexec/check_nrpe -H localhost
connect to address ::1 port 5666: Connection refused
NRPE v2.15
#

However, doesn't the "NRPE v2.15" line indicate it worked?

My config file is:

# default: on
# description: NRPE (Nagios Remote Plugin Executor)
service nrpe
{
flags = REUSE
socket_type = stream
port = 5666
wait = no
user = nagios
group = nagios
server = /usr/local/nagios/bin/nrpe
server_args = -c /usr/local/nagios/etc/nrpe.cfg --inetd
log_on_failure += USERID
disable = no
only_from = 127.0.0.1 10.18.215.98
}
danoreilly
Posts: 28
Joined: Mon Dec 01, 2014 4:28 pm

Re: Connection refused for nrpe on Ubuntu 14.04

Post by danoreilly »

Found the issue: extra garbage in /etc/hosts. I pared it down to:

127.0.0.1 localhost
10.18.84.42 ubdepot.echostar.com ubdepot

and it worked.
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Connection refused for nrpe on Ubuntu 14.04

Post by slansing »

Awesome, thank you for letting us know!
Locked