nrpe running with wrong file

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Post Reply
Pratapa
Posts: 148
Joined: Tue Oct 01, 2019 1:33 am

nrpe running with wrong file

Post by Pratapa »

Hi,

On one of the client machines nrpe.cfg is located in two paths
1. /etc/nrpe.cfg
2. /usr/local/nagios/etc/nrpe.cfg

when we run ps -ef|grep nrpe, the output is showing as

$ps -ef|grep nrpe.cfg
nagios <pid> /usr/sbin/nrpe -c /etc/nrpe.cfg

Expected output:
$ps -ef|grep nrpe.cfg
nagios <pid> /usr/sbin/nrpe -c /usr/local/nagios/etc/nrpe.cfg -n -d

what should be done to run nrpe with the file /usr/loca/nagios/etc/nrpe.cfg during next reboot.

Pratap
kg2857
Posts: 339
Joined: Wed Apr 12, 2023 5:48 pm

Re: nrpe running with wrong file

Post by kg2857 »

You might want to look at the start script for nrpe and edit it. I'd guess a version not from nagios was installed and the version from nagios was also installed.
What OS? I'd maybe start with a yum list nrpe or what rpm -qa nrpe.
Nanasi
Posts: 1
Joined: Wed Aug 23, 2023 9:06 pm

Re: nrpe running with wrong file

Post by Nanasi »

Thank you for this information bitlife
maruusa0106
Posts: 2
Joined: Wed Sep 04, 2024 4:38 am

Re: nrpe running with wrong file

Post by maruusa0106 »

good
Sophiana
Posts: 1
Joined: Thu Feb 13, 2025 4:16 am

Re: nrpe running with wrong file

Post by Sophiana »

Pratapa wrote: Thu Jul 20, 2023 6:42 am Hi,

On one of the client machines nrpe.cfg is located in two paths
1. /etc/nrpe.cfg
2. /usr/local/nagios/etc/nrpe.cfg

when we run ps -ef|grep nrpe, the output is showing as

$ps -ef|grep nrpe.cfg
nagios <pid> /usr/sbin/nrpe -c /etc/nrpe.cfg

Expected output:
$ps -ef|grep nrpe.cfg
nagios <pid> /usr/sbin/nrpe -c /usr/local/nagios/etc/nrpe.cfg -n -d

what should be done to run nrpe with the file /usr/loca/nagios/etc/nrpe.cfg during next reboot.

Pratap
What steps can be taken to ensure that the NRPE service uses the configuration file located at /usr/local/nagios/etc/nrpe.cfg instead of the one in /etc/nrpe.cfg after a system reboot?
Post Reply