From 985ea21f6e2321d68626bfb8a842529f26b25807 Mon Sep 17 00:00:00 2001 From: Clint Armstrong Date: Thu, 23 Jul 2015 15:09:06 -0400 Subject: [PATCH] make and remove pidfile --- poller-service.init | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/poller-service.init b/poller-service.init index 25c4bd2533..15f2509d57 100755 --- a/poller-service.init +++ b/poller-service.init @@ -36,7 +36,7 @@ case $1 in log_daemon_msg "Starting the process" "$NAME" # Start the daemon with the help of start-stop-daemon # Log the message appropriately - if start-stop-daemon --start --quiet --oknodo --pidfile $PIDFILE --exec $DAEMON --chuid $USER --background; then + if start-stop-daemon --start --quiet --oknodo --make-pidfile --pidfile $PIDFILE --exec $DAEMON --chuid $USER --background; then log_end_msg 0 else log_end_msg 1 @@ -48,7 +48,7 @@ case $1 in if [ -e $PIDFILE ]; then status_of_proc -p $PIDFILE $DAEMON "Stoppping the $NAME process" && status="0" || status="$?" if [ "$status" = 0 ]; then - start-stop-daemon --stop --quiet --oknodo --pidfile $PIDFILE + start-stop-daemon --stop --quiet --oknodo --remove-pidfile --pidfile $PIDFILE /bin/rm -rf $PIDFILE fi else