Bug #4391
closedStatus | Services | nrpe2 | restart does not restart nrpe
100%
Description
On pfSense 2.2, I am unable to restart nrpe2
I click through: Status | Services | nrpe2 | restart service.
The webui says: nrpe2 has been restarted
The logs:
Feb 9 00:15:00 php-fpm92748: /status_services.php: The command '/usr/local/etc/rc.d/nrpe2.sh stop' returned exit code '1', the output was 'nrpe2 not running? (check /var/run/nrpe2.pid).'
Feb 9 00:15:00 nrpe32629: Starting up daemon
Feb 9 00:15:00 nrpe32629: There's already an NRPE server running (PID 39541). Bailing out...
The console show this before restart attempt
ps auwx | grep nrpe
nagios 39541 0.0 0.2 23188 4912 - Is 8:32PM 0:00.31 /usr/local/sbin/nrpe2 -d -c /usr/pbi/nrpe-amd64/etc/nrpe.cfg
root 98802 0.0 0.1 18884 2380 0 S+ 12:14AM 0:00.00 grep nrpe
And this after restart attempt
ps auwx | grep nrpe
nagios 39541 0.0 0.2 23188 4912 - Is 8:32PM 0:00.31 /usr/local/sbin/nrpe2 -d -c /usr/pbi/nrpe-amd64/etc/nrpe.cfg
root 37472 0.0 0.1 18884 2380 0 S+ 12:15AM 0:00.00 grep nrpe
i.e. nil change
Updated by Jim Pingle about 10 years ago
What's in /var/run/nrpe2.pid ? Is the the current PID? If you killall -9 nrpe2; rm /var/run/nrpe2.pid, and then start it fresh, does it work afterward?
If the PID file were stale it might explain the behavior.
Updated by Dan Langille about 10 years ago
I have since done a kill -TERM and then reloaded: /status_services.php?mode=restartservice&service=nrpe2
This started the service.
At present, yes, it contains the right value:
[2.2-RELEASE][admin@bast.int.unixathome.org]/root: cat /var/run/nrpe2.pid 14372 [2.2-RELEASE][admin@bast.int.unixathome.org]/root: ps auwx | grep nrpe nagios 14372 0.0 0.2 23188 4916 - Is 12:22AM 0:00.03 /usr/local/sbin/nrpe2 -d -c /usr/pbi/nrpe-amd64/etc/nrpe.cfg root 47661 0.0 0.1 18884 2380 0 S+ 12:31AM 0:00.00 grep nrpe [2.2-RELEASE][admin@bast.int.unixathome.org]/root:
After doing a Restart via Webui, the above output of the above commands is the same as shown above.
Updated by Renato Botelho about 10 years ago
- Status changed from New to Feedback
- % Done changed from 0 to 100
Applied in changeset pfsense-packages:commit:11375fe3e8826e02f7a5bec1f6a2d743060dbd76.
Updated by Renato Botelho about 10 years ago
Applied in changeset pfsense-packages:commit:909f0dfd8a1efc99c8392423123fdc0b3d88ffea.
Updated by Chris Buechler about 10 years ago
- Project changed from pfSense to pfSense Packages
- Category set to NRPE
Updated by Chris Buechler about 9 years ago
- Status changed from Feedback to Resolved