Commit f3a3bf62 authored by Daniel van Dorp's avatar Daniel van Dorp Committed by Matt Holt

dist/init/linux-sysvinit: improve legacy compatibility (#1002)

* dist/init/linux-sysvinit: pass --oknodo for --start as well

* dist/init/linux-sysvinit: manually rm PIDFILE

Since start-stop-daemon --remove-pidfile is new and not present
everywhere.
parent 81a3101e
...@@ -37,12 +37,13 @@ ulimit -n 8192 ...@@ -37,12 +37,13 @@ ulimit -n 8192
start() { start() {
$USERBIND $DAEMON $USERBIND $DAEMON
start-stop-daemon --start --quiet --make-pidfile --pidfile $PIDFILE \ start-stop-daemon --start --quiet --make-pidfile --pidfile $PIDFILE \
--background --chuid $DAEMONUSER --exec $DAEMON -- $DAEMONOPTS --background --chuid $DAEMONUSER --oknodo --exec $DAEMON -- $DAEMONOPTS
} }
stop() { stop() {
start-stop-daemon --stop --quiet --remove-pidfile --pidfile $PIDFILE \ start-stop-daemon --stop --quiet --pidfile $PIDFILE --retry=$STOP_SCHEDULE \
--retry=$STOP_SCHEDULE --name $NAME --oknodo --name $NAME --oknodo
rm -f $PIDFILE
} }
reload() { reload() {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment