Vamos a ver como instalar NRPE en GNU/Linux, Unix y Windows.
NRPE es un software cliente/servidor con el cual nos permite la monitorización de servidores, switches, firewall…etc.
Instalación de NRPE en el Servidor Nagios
Instalamos dependencias.
root@nagios: # apt-get install xinetd libssl-devDescargamos NRPE
root@nagios: # wget http://sourceforge.net/projects/nagios/files/nrpe-2.x/nrpe-2.13/nrpe-2.13.tar.gzDescomprimimos.
root@nagios: # tar xvf nrpe-2.13.tar.gzAccedemos al directorio
root@nagios: # cd nrpe-2.13/Compilamos
root@nagios: # ./configure
root@nagios: # make all
root@nagios: # make install-plugin
root@nagios: # make install-daemon
root@nagios: # make install-daemon-config
root@nagios: # make install-xinetdEditar /etc/xinetd.d/nrpe para aceptar peticiones solo de nuestro Nagios Server:
only_from = 127.0.0.1 192.168.1.10Añadiremos al /etc/services el puerto de NRPE para poder identificar las conexiones
nrpe 5666/tcp # NRPEReiniciamos xinetd
root@nagios: # /etc/init.d/xinetd restartPruebas de funcionamiento
root@nagios:# netstat -ant | grep 5666
tcp 0 0 0.0.0.0:5666 0.0.0.0:* LISTEN
root@nagios: # /usr/local/nagios/libexec/check_nrpe -H localhost
NRPE v2.13Instalación de NRPE en el cliente en GNU/Linux y UNIX
root@nagios: # wget http://sourceforge.net/projects/nagios/files/nrpe-2.x/nrpe-2.13/nrpe-2.13.tar.gzDescomprimimos.
root@nagios: # tar xvf nrpe-2.13.tar.gzAccedemos al directorio
root@nagios: # cd nrpe-2.13/Compilamos
root@nagios: # ./configure –prefix=/opt –with-nagios-user=nagios –with-nagios-group=nagios
root@nagios: # make all
root@nagios: # make install-pluginComprobamos que funciona
netstat -at | grep nrpe
tcp 0 0 *:nrpe *:* LISTENInstalación de NRPE en el cliente en Windows
Para el cliente de Windows podemos emplear NSClient++ o nrpe_nt (Entre otros). en nuestro caso yo voy a instalar nrpe_nt
Descargamos nrpe_nt
http://sourceforge.net/projects/nrpent/files/nrpent/
y lo descomprimimos. en mi caso en C:\nrpe
Accedemos mediante el CMD
cd c:\nrpe\binInstalamos…
c:\nrpe\bin>Nrpe_nt.exe -i
NRPE_NT Service sucessfully installed!
c:\nrpe\bin>Iniciamos el servicio
c:\nrpe\bin>net start nrpe_nt
El servicio de Nagios Remote Plugin Executor for NT/W2K está iniciándose.
El servicio de Nagios Remote Plugin Executor for NT/W2K se ha iniciado correctam
ente.
c:\nrpe\bin>Listo, ya solo faltaría instalar los plugins que los podéis descargar de aquí:
Un saludo, rokitoh
:wq!
Comentarios