- use the pid when sending signnals to nsd

OBS-URL: https://build.opensuse.org/package/show/server:dns/nsd?expand=0&rev=12
This commit is contained in:
Marcus Rückert 2010-02-01 19:52:34 +00:00 committed by Git OBS Bridge
parent c8370b2fc7
commit e1ec0766e6
2 changed files with 11 additions and 4 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Mon Feb 1 19:51:54 UTC 2010 - mrueckert@suse.de
- use the pid when sending signnals to nsd
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Mar 29 17:16:54 CEST 2007 - mrueckert@suse.de Thu Mar 29 17:16:54 CEST 2007 - mrueckert@suse.de

View File

@ -130,6 +130,8 @@ test -x $NSD_BIN || { echo "$NSD_BIN not installed";
# if [ "$1" = "stop" ]; then exit 0; # if [ "$1" = "stop" ]; then exit 0;
# else exit 6; fi; } # else exit 6; fi; }
NSD_PID="/var/lib/nsd/var/run/nsd.pid"
# Read config # Read config
# . $NSD_CONFIG # . $NSD_CONFIG
@ -189,7 +191,7 @@ case "$1" in
## Stop daemon with killproc(8) and if this fails ## Stop daemon with killproc(8) and if this fails
## killproc sets the return value according to LSB. ## killproc sets the return value according to LSB.
killproc -TERM $NSD_BIN killproc -p $NSD_PID -TERM $NSD_BIN
# Remember status and be verbose # Remember status and be verbose
rc_status -v rc_status -v
@ -226,7 +228,7 @@ case "$1" in
echo -n "Reload service nsd " echo -n "Reload service nsd "
## if it supports it: ## if it supports it:
killproc -HUP $NSD_BIN killproc -p $NSD_PID -HUP $NSD_BIN
#touch /var/run/nsd.pid #touch /var/run/nsd.pid
rc_status -v rc_status -v
@ -240,7 +242,7 @@ case "$1" in
# If it supports signaling: # If it supports signaling:
echo -n "Reload service nsd " echo -n "Reload service nsd "
killproc -HUP $NSD_BIN killproc -p $NSD_PID -HUP $NSD_BIN
#touch /var/run/nsd.pid #touch /var/run/nsd.pid
rc_status -v rc_status -v
@ -272,7 +274,7 @@ case "$1" in
## argument to this init script which is required for a reload. ## argument to this init script which is required for a reload.
## Note: probe is not (yet) part of LSB (as of 1.9) ## Note: probe is not (yet) part of LSB (as of 1.9)
test /etc/nsd/nsd.conf -nt /var/run/nsd.pid && echo reload test /etc/nsd/nsd.conf -nt $NSD_PID && echo reload
;; ;;
*) *)
echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}" echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}"