Skip to content

Instantly share code, notes, and snippets.

@filipepgoes
Last active February 23, 2018 16:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save filipepgoes/1c3e802532eafed797436b39fc2cff66 to your computer and use it in GitHub Desktop.
Save filipepgoes/1c3e802532eafed797436b39fc2cff66 to your computer and use it in GitHub Desktop.
#!/bin/sh
set -u
yum -y update
yum -y install git openssl-devel
mkdir ./downloads
cd ./downloads
wget http://nagios-plugins.org/download/nagios-plugins-2.2.1.tar.gz
tar xzf nagios-plugins-2.2.1.tar.gz
cd nagios-plugins-2.2.1
./configure
make
make install
yum -y install xinetd
cd ..
git clone https://github.com/NagiosEnterprises/nrpe.git
cd nrpe
git checkout tags/nrpe-3.0.0
./configure
make all
make install-groups-users
make install
make install-config
make install-init
cd ../..
systemctl restart xinetd
systemctl enable nrpe && systemctl start nrpe
echo "Must show 'LISTENING':"
netstat -at | egrep "5666"
echo "Must show NRPE 3.0:"
/usr/local/nagios/libexec/check_nrpe -H localhost
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment