Page 1 of 1

Unable to start nrpe on Linux server

Posted: Fri Aug 07, 2020 5:07 am
by Pratapa
Hi,

We are unable to start nrpe on Linux server which is a client machine.

OS on client machine is RHEL 7.4


[root@host1 ~]# service nrpe start
Redirecting to /bin/systemctl start nrpe.service
[root@host1 ~]# /bin/systemctl start nrpe.service
[root@host1 ~]# service nrpe status
Redirecting to /bin/systemctl status nrpe.service
● nrpe.service - Nagios Remote Program Executor
Loaded: loaded (/usr/lib/systemd/system/nrpe.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2020-08-07 19:59:20 AEST; 5s ago
Docs: http://www.nagios.org/documentation
Process: 9982 ExecStopPost=/bin/rm -f /var/run/nrpe/nrpe.pid (code=exited, status=0/SUCCESS)
Process: 9980 ExecStart=/usr/sbin/nrpe -c /etc/nagios/nrpe.cfg -f $NRPE_SSL_OPT (code=exited, status=2)
Main PID: 9980 (code=exited, status=2)

Aug 07 19:59:20 host1 systemd[1]: Started Nagios Remote Program Executor.
Aug 07 19:59:20 host1 systemd[1]: Starting Nagios Remote Program Executor...
Aug 07 19:59:20 host1 nrpe[9980]: Starting up daemon
Aug 07 19:59:20 host1 systemd[1]: nrpe.service: main process exited, code=exited, status=2/INVALIDARGUMENT
Aug 07 19:59:20 host1 systemd[1]: Unit nrpe.service entered failed state.
Aug 07 19:59:20 host1 systemd[1]: nrpe.service failed.


No output returned when we type the following command.

[root@host1 ~]# netstat -an|grep 5666
[root@host1 ~]#


It seems port 5666 is not open. Could this be one of the reasons for not able to start nrpe.

Re: Unable to start nrpe on Linux server

Posted: Fri Aug 07, 2020 3:28 pm
by gormank
The status shows invalid argument so chances are the nrpe config has something wrong in it.

Aug 07 19:59:20 host1 systemd[1]: nrpe.service: main process exited, code=exited, status=2/INVALIDARGUMENT

Re: Unable to start nrpe on Linux server

Posted: Mon Aug 10, 2020 12:26 am
by Pratapa
Earlier it used to run.

Attached nrpe.cfg file. Please look into it and let me know what is the error.

Re: Unable to start nrpe on Linux server

Posted: Mon Aug 10, 2020 3:46 pm
by gormank
Nothing jumps out at me. Do you hHAASHV0x75eb1a cany files in the include dir?

include_dir=/etc/nagios/nrpe.d/

A closer look at the status output shows it's an SSL option that it doesn't like. You might have a close look at those.

Is $NRPE_SSL_OPT defined? Maybe try echoing it from the shell.

echo $NRPE_SSL_OPT

Process: 9980 ExecStart=/usr/sbin/nrpe -c /etc/nagios/nrpe.cfg -f $NRPE_SSL_OPT (code=exited, status=2)

Re: Unable to start nrpe on Linux server

Posted: Tue Aug 11, 2020 1:24 am
by Pratapa
Thanks for the help. This issue is resolved.