Parcourir la source

openrc-init: use service name for pid file to allow multiple instances

Jonas Licht il y a 6 ans
Parent
commit
464201feee
1 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 2 2
      startup/openrc-init.in

+ 2 - 2
startup/openrc-init.in

@@ -8,10 +8,10 @@ command_args="--config=${NRPE_CFG} ${NRPE_OPTS}"
 command_args_background="--daemon"
 description="Nagios Remote Plugin Executor (NRPE) daemon"
 extra_started_commands="reload"
-pidfile="@piddir@/nrpe.pid"
+pidfile="@piddir@/${RC_SVCNAME}.pid"
 
 reload() {
-    ebegin "Reloading ${SVCNAME}"
+    ebegin "Reloading ${RC_SVCNAME}"
     start-stop-daemon --signal HUP --pidfile "${pidfile}"
     eend $?
 }