can't read /etc/xinetd.d/nrpe: No such file or directory

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
christian_oracle
Posts: 3
Joined: Fri Oct 31, 2014 7:07 am

can't read /etc/xinetd.d/nrpe: No such file or directory

Post by christian_oracle »

I've just used the latest nrpe installer (from the documentation 2014 v1.2 pointing at http://assets.nagios.com/downloads/nagi ... ent.tar.gz) on a OEL7 (this should happen on all RHEL7, CentOS7 derivatives), and got the error in the subject title.

xinetd was not installed, so I made sure it was, still fails

I used sudo, logged in as root, neither seemed to matter, still the script confessed to not finding /etc/xinet.d/nrpe. Which I'm not surprised about, this script is supposed to be installing the file.

Effectively the script is broken. It will not create an xinetd nrpe conf from scratch, which is really stupid, and only amend an existing configuration. I've made my own file which is listed below, feel free to copy and use.

Code: Select all

service nrpe
{
        flags           = REUSE
        socket_type     = stream
        port            = 5666
        wait            = no
        user            = nagios
        group           = nagios
        server          = /usr/sbin/nrpe
        server_args     = -c /usr/local/nagios/etc/nrpe.cfg --inetd
        log_on_failure  += USERID
        disable         = no
        only_from       = 127.0.0.1
}
jdalrymple
Skynet Drone
Posts: 2620
Joined: Wed Feb 11, 2015 1:56 pm

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by jdalrymple »

On CentOS7 I cannot reproduce that behavior. Using our fullinstall script xinetd was installed and the nrpe config appropriately placed.

Code: Select all

[jdalrymple@localhost linux-nrpe-agent]$ grep xinetd install.log
---> Package xinetd.x86_64 2:2.3.15-12.el7 will be installed
 xinetd                  x86_64     2:2.3.15-12.el7           base        128 k
  Installing : 2:xinetd-2.3.15-12.el7.x86_64                              15/18
  Verifying  : 2:xinetd-2.3.15-12.el7.x86_64                               7/18
  xinetd.x86_64 2:2.3.15-12.el7
config.status: creating sample-config/nrpe.xinetd
/bin/install -c -m 644 sample-config/nrpe.xinetd /etc/xinetd.d/nrpe
config.status: creating sample-config/nsca.xinetd
You might want to look over your install.log to see where it all went wrong.
israel
Posts: 1
Joined: Fri Mar 27, 2015 11:56 am

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by israel »

I am having this very same issue on OEL 7. Thank you for this. After I created the file, I was able to complete the install.
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by tmcdonald »

Great!

We'll keep this topic open until christian_oracle returns.
Former Nagios employee
cpss454
Posts: 11
Joined: Tue Nov 10, 2015 5:11 pm
Location: Denver, Colorado, US

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by cpss454 »

I had the same problem on Oracle Linux 6.6. Here is what I had to do before I got fullinstall to run successfully. Even so I still get "Return code of 255 is out of bounds" after I run the Linux Server wizard in XI. Drats. :(

1. Download, install, and build libmcrypt:
cd /etc/ld.so.conf.d
vi libmcrypt-64.conf (new file) and add the following line:
/usr/local/lib
ldconfig
Install the libmcrypt package:
Download the MCRYPT library libmcrypt from http://mcrypt.sourceforge.net/
Copy libmcrypt-2.5.8.tar.gz to /tmp.
cd /tmp
tar xzf libmcrypt-2.5.8.tar.gz
cd libmcrypt-2.5.8
./configure
make
make install
2. Download and install the xinetd package (I just used the Gnome Software Installer.)
3. Create the /etc/xinetd.d/nrpe file (as provided by christian_oracle in this blog post.)
4. Start the xinetd service and make sure it starts at every boot:
service xinetd restart
chkconfig xinetd on
5. cd to the linux-nrpe-agent directory and ./fullinstall
6. If anything goes wrong and you have to restart the installation:
rm -rf /tmp/linux-nrpe-agent
rm -rf /usr/local/nagios
groupdel nagcmd
userdel nagios
cd /tmp
tar xzf linux-nrpe-agent.tar.gz
cd linux-nrpe-agent
./fullinstall

Checking the boards to see why it doesn't work. I'm in my 60-day free trial so getting this to work is important or no purchase order.
cpss454
Posts: 11
Joined: Tue Nov 10, 2015 5:11 pm
Location: Denver, Colorado, US

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by cpss454 »

Fixed!!
yum install openssl-devel

Cleaned up, installed OpenSSL-develm ran fullinstall, and now everything is working fine. :)
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by hsmith »

Thanks for posting your fix. Is there anything else we can help you with on this one?
Former Nagios Employee.
me.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: can't read /etc/xinetd.d/nrpe: No such file or directory

Post by rkennedy »

Thanks for the contribution on how you fixed this. :D

As this thread is fairly old, I am going to lock it up for now. Feel free to open another if any assistance is needed in the future.
Former Nagios Employee
Locked