Page 1 of 2

Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 11:59 am
by rickwilson7425
I did a quick search and didn't find anything on this here so...

I have tried to install the client with apt-get following the procedures outlined in several places on the web and in a Nagios document for XI but none of those work. I keep getting a failure to locate the packages that are specified in the procedures, i.e., "nagios-nrpe-server" and "nagios-plugins".

I have tried to install the client from source code. Using the 2.13 source that we have been using on Redhat. I have gotten these errors:

root@denxxxxxd:/var/tmp/nagios/nrpe-2.13# ./configure --prefix=/apps/nagios --enable-command-args --with-ssl=/usr/bin/openssl --with-ssl-lib=/usr/lib/x86_64-linux-gnu
configure: error: Cannot find ssl headers


root@denxxxxxd:/var/tmp/nagios/nrpe-2.13# ./configure --prefix=/apps/nagios --enable-command-args --without-ssl
configure: error: Cannot find ssl headers


It is confusing to say the least that I get the ssl headers error when I tell it to not compile with ssl.

Any help would be appreciated.

Rick

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 12:06 pm
by lmiltchev
It is confusing to say the least that I get the ssl headers error when I tell it to not compile with ssl.
As far as I can tell, you ARE compiling with ssl...
root@denxxxxxd:/var/tmp/nagios/nrpe-2.13# ./configure --prefix=/apps/nagios --enable-command-args --with-ssl=/usr/bin/openssl --with-ssl-lib=/usr/lib/x86_64-linux-gnu
configure: error: Cannot find ssl headers
Can you try the following?

Code: Select all

./configure --prefix=/apps/nagios --enable-command-args --without-ssl

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 12:12 pm
by rickwilson7425
the second snippet in blue is that command....

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 12:41 pm
by jolson
Try the following to find the libssl path:

Code: Select all

apt-file search libssl | grep libssl-dev
You can use that path to compile using the --with-ssl and --with-ssl-libs flags.

It's also possible that you don't have libssl on the server at all:

Code: Select all

sudo apt-get install libssl-dev

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 12:50 pm
by rickwilson7425
been there done that - for some reason "apt-file" isn't on that system, nor is "apt-cache". When I try to install them I get the same message as below trying to install libssl-dev: (I can install other packages however like "buildessential", go figure...)

root@denxxxxxd:/var/tmp/nagios/nrpe-2.13# apt-file search libssl | grep libssl-dev
The program 'apt-file' is currently not installed. You can install it by typing:
apt-get install apt-file

root@denxxxxxxd:/var/tmp/nagios/nrpe-2.13# apt-get install libssl-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package libssl-dev

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 1:23 pm
by jolson
E: Unable to locate package libssl-dev
Could we see your sources file? It looks like libssl-dev isn't available in your current repositories.

Code: Select all

cat /etc/apt/sources.list
You could attempt an upgrade before attempting to install libssl-dev to see if that makes a difference:

Code: Select all

apt-get update
apt-get install libssl-dev

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 1:41 pm
by rickwilson7425
Here is the output of the "cat /etc/apt/sources.list" command:

Code: Select all

cat /etc/apt/sources.list
#

# deb cdrom:[Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1)]/ trusty main restricted

#deb cdrom:[Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1)]/ trusty main restricted

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb cdrom:[Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1)]/ trusty main restricted
deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty main restricted

## Major bug fix updates produced after the final release of the
## distribution.
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ trusty universe
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://us.archive.ubuntu.com/ubuntu/ trusty multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty multiverse
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates multiverse

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse

deb http://security.ubuntu.com/ubuntu trusty-security main restricted
deb-src http://security.ubuntu.com/ubuntu trusty-security main restricted
deb http://security.ubuntu.com/ubuntu trusty-security universe
deb-src http://security.ubuntu.com/ubuntu trusty-security universe
deb http://security.ubuntu.com/ubuntu trusty-security multiverse
deb-src http://security.ubuntu.com/ubuntu trusty-security multiverse

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu trusty partner
# deb-src http://archive.canonical.com/ubuntu trusty partner

## Uncomment the following two lines to add software from Ubuntu's
## 'extras' repository.
## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
# deb http://extras.ubuntu.com/ubuntu trusty main
# deb-src http://extras.ubuntu.com/ubuntu trusty main
When I try "apt-get update", it hangs at this point:

Ign cdrom://Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1) trusty InRelease
Ign cdrom://Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1) trusty/main Translation-en_US
Ign cdrom://Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1) trusty/main Translation-en
Ign cdrom://Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1) trusty/restricted Translation-en_US
Ign cdrom://Ubuntu-Server 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1) trusty/restricted Translation-en
69% [Connecting to us.archive.ubuntu.com (91.189.91.14)] [Connecting to securit


it finally fails with this:

Code: Select all

Err http://us.archive.ubuntu.com trusty InRelease                              
  
Err http://us.archive.ubuntu.com trusty-updates InRelease                      
  
Err http://us.archive.ubuntu.com trusty-backports InRelease                    
  
Err http://us.archive.ubuntu.com trusty Release.gpg                            
  Cannot initiate the connection to us.archive.ubuntu.com:80 (2001:67c:1562::13). - connect (101: Network is unreachable) [IP: 2001:67c:1562::13 80]
Err http://us.archive.ubuntu.com trusty-updates Release.gpg
  Cannot initiate the connection to us.archive.ubuntu.com:80 (2001:67c:1562::13). - connect (101: Network is unreachable) [IP: 2001:67c:1562::13 80]
Err http://us.archive.ubuntu.com trusty-backports Release.gpg
  Cannot initiate the connection to us.archive.ubuntu.com:80 (2001:67c:1562::13). - connect (101: Network is unreachable) [IP: 2001:67c:1562::13 80]

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 3:09 pm
by ssax
Do you have the firewall on? Maybe you are blocking outgoing?

Code: Select all

sudo ufw status verbose

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 3:14 pm
by rickwilson7425
It says inactive:

# ufw status verbose
Status: inactive

I'm going to check some other things too with the network guys, maybe I need a firewall rule to allow that. I didn't with other installs, but maybe that one goes somewhere else????

Re: Installing NRPE on Ubuntu 14.04

Posted: Tue May 19, 2015 3:24 pm
by ssax
Definitely could be a remote firewall or ACL blocking it, I also stumbled upon this: http://askubuntu.com/a/371067

I'm not sure if that would resolve your issue but it could be worth a try if your security guys say that it should be working.