@@ -20,6 +20,7 @@
### END INIT INFO
SOFTFLOWD_BIN=/usr/sbin/softflowd
+SOFTFLOWD_PID=/var/run/softflowd.pid
test -x $SOFTFLOWD_BIN || { echo "$SOFTFLOWD_BIN not installed";
if [ "$1" = "stop" ]; then exit 0; else exit 5; fi; }
@@ -52,12 +53,12 @@
case "$1" in
start)
echo -n "Starting softflowd"
- startproc $SOFTFLOWD_BIN $SOFTFLOWD_OPTIONS $OPTIONS
+ startproc -p $SOFTFLOWD_PID $SOFTFLOWD_BIN $SOFTFLOWD_OPTIONS $OPTIONS
rc_status -v
;;
stop)
echo -n "Shutting down softflowd"
- killproc -TERM $SOFTFLOWD_BIN
+ killproc -p $SOFTFLOWD_PID -TERM $SOFTFLOWD_BIN
rc_status -v
;;
try-restart|condrestart)
@@ -83,23 +84,23 @@
;;
force-reload)
echo -n "Reload service softflowd"
- killproc -HUP $SOFTFLOWD_BIN
+ killproc -p $SOFTFLOWD_PID -HUP $SOFTFLOWD_BIN
rc_status -v
;;
reload)
echo -n "Reload service softflowd"
- killproc -HUP $SOFTFLOWD_BIN
+ killproc -p $SOFTFLOWD_PID -HUP $SOFTFLOWD_BIN
rc_status -v
;;
status)
echo -n "Checking for softflowd: "
- checkproc $SOFTFLOWD_BIN
+ checkproc -p $SOFTFLOWD_PID $SOFTFLOWD_BIN
rc_status -v
;;
probe)
- if [ /etc/softflowd/softflowd.cf -nt /var/run/softflowd.pid ]; then
+ if [ /etc/softflowd/softflowd.conf -nt $SOFTFLOWD_PID ]; then
echo reload
- elif [ $SOFTFLOWD_CONFIG -nt /var/run/softflowd.pid ]; then
+ elif [ $SOFTFLOWD_CONFIG -nt $SOFTFLOWD_PID ]; then
echo restart
fi
;;
|