Install NRPE From Source (NRPE)

From vWiki
Jump to navigation Jump to search

The maintainers of Debian have decided that a large proportion of their user base is unable to comprehend the security implications of the dont_blame_nrpe, and have disabled the functionality during compilation, rendering the dont_blame_nrpe useless. Ubuntu is based on Debian, therefore decisions made for Debian impact Ubuntu. To be fair to the maintainer of the package, it appears as if uninformed Debian users have been using the dont_blame_nrpe option and then suffering breaches (see https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=756479).

This page is based on the instructions provided at https://support.nagios.com/kb/article.php?id=515

Procedure

The below assumes you are running as root, if not precede the commands with sudo

  1. Install prerequisite packages to allow compilation of source code
    • apt-get install autoconf gcc libc6 libmcrypt-dev make libssl-dev wget
  2. Download the source code
  3. Compile the source code
    • cd /tmp/nrpe-3.0/
    • ./configure --enable-command-args
    • make all
  4. Create nagios user and group
    • make install-groups-users
  5. Install binaries
    • make install
  6. Install config files
    • make install-config
  7. Update services file
    • sh -c "echo >> /etc/services"
    • sh -c "sudo echo '# Nagios services' >> /etc/services"
    • sh -c "sudo echo 'nrpe 5666/tcp' >> /etc/services"
  8. Install service daemon
    1. Ubuntu version 14 and before
      • make install-init
    2. Ubuntu version 15 and later
      • make install-init
      • systemctl enable nrpe.service
  9. Start the service daemon
    1. Ubuntu version 14 and before
      • start nrpe
    2. Ubuntu version 15 and later
      • systemctl start nrpe.service