]> git.pld-linux.org Git - packages/glibc.git/blobdiff - nscd.init
- skip reload if service is down
[packages/glibc.git] / nscd.init
index dfb86bd02218eec839d26ac7cf84e964b03682fd..c225990cf4b994b2b934371be8cef17338765ac6 100644 (file)
--- a/nscd.init
+++ b/nscd.init
@@ -58,10 +58,14 @@ case "$1" in
        exit $?
        ;;
   reload)
-       for db in passwd group hosts; do
-               show "Invalidating %s cache" $db; busy
-               nscd -i $db && ok || fail
-       done
+       if [ -f /var/lock/subsys/nscd ]; then
+               for db in passwd group hosts; do
+                       show "Invalidating %s cache" $db; busy
+                       nscd -i $db && ok || fail
+               done
+       else
+               msg_not_running "Name Switch Cache Daemon"
+       fi
        ;;
   restart|force-reload)
        stop
This page took 0.056251 seconds and 4 git commands to generate.