Linux Nagios Different Port
Uit Rolandow
Versie door Rolandow (Overleg | bijdragen) op 1 jun 2012 om 12:17 (Nieuwe pagina aangemaakt met '= Goal = The gateway server also runs services that need to be monitored with Nagios. So we use another port to forward this to another server. = Server side: comman…')
Goal
The gateway server also runs services that need to be monitored with Nagios. So we use another port to forward this to another server.
Server side: commands.cgi
Changed the file /etc/nagios-plugins/config/check_nrpe.cfg. Added a alternative command.
# nrpe on alternate port define command { command_name check_nrpe_alt command_line /usr/lib/nagios/plugins/check_nrpe -H $HOSTADDRESS$ -p 15666 -c $ARG1$ -a $ARG2$ }
Client side: nrpe
Easy, just change the nrpe config at /etc/nagios/nrpe.cfg
# PORT NUMBER # Port number we should wait for connections on. # NOTE: This must be a non-priviledged port (i.e. > 1024). # NOTE: This option is ignored if NRPE is running under either inetd or xinetd server_port=15666