diff options
author | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-11-21 17:20:10 +0300 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@rambler-co.ru> | 2011-11-21 17:20:10 +0300 |
commit | d4ddd7be3fb96efe6607fccf18cbf5dba0da6bda (patch) | |
tree | 24b12b7a4473ac3bab298d82e1900a31f4ed1721 /debian | |
parent | efe1a722f2804d5a5d7905ed80158e97f7fe01f6 (diff) | |
download | rspamd-d4ddd7be3fb96efe6607fccf18cbf5dba0da6bda.tar.gz rspamd-d4ddd7be3fb96efe6607fccf18cbf5dba0da6bda.zip |
Small fixes to start script.
Diffstat (limited to 'debian')
-rwxr-xr-x | debian/rspamd.init | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/debian/rspamd.init b/debian/rspamd.init index c8d7cd695..e0ed45cfd 100755 --- a/debian/rspamd.init +++ b/debian/rspamd.init @@ -72,17 +72,9 @@ do_stop() # 1 if daemon was already stopped # 2 if daemon could not be stopped # other if a failure occurred - start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE --name $NAME + start-stop-daemon --stop --quiet --retry=TERM/30/KILL/5 --pidfile $PIDFILE RETVAL="$?" [ "$RETVAL" = 2 ] && return 2 - # Wait for children to finish too if this is a daemon that forks - # and if the daemon is only ever run from this initscript. - # If the above conditions are not satisfied then add some other code - # that waits for the process to drop all resources that could be - # needed by services started subsequently. A last resort is to - # sleep for some time. - start-stop-daemon --stop --quiet --oknodo --retry=0/30/KILL/5 --exec $DAEMON - [ "$?" = 2 ] && return 2 # Many daemons don't delete their pidfiles when they exit. rm -f $PIDFILE return "$RETVAL" @@ -92,7 +84,7 @@ do_stop() # Function that sends a SIGHUP to the daemon/service # do_reload() { - start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE --name $NAME + start-stop-daemon --stop --signal 1 --quiet --pidfile $PIDFILE return 0 } |