diff options
| author | Noriko Hosoi <nhosoi@redhat.com> | 2007-02-21 21:22:08 +0000 |
|---|---|---|
| committer | Noriko Hosoi <nhosoi@redhat.com> | 2007-02-21 21:22:08 +0000 |
| commit | 4e73e76b8d964ff950bd3c1d105714a18bfd8383 (patch) | |
| tree | 0905287520172c5af80a5c6805d7cfbf37ba9a5e /ldap/admin/src/scripts/template-stop-slapd | |
| parent | fa05437fb16b35caa6337c0d216466a374436a47 (diff) | |
Resolves: 229576
Summary: clean up template-scriptname which is derived from template-scriptname.in
Diffstat (limited to 'ldap/admin/src/scripts/template-stop-slapd')
| -rw-r--r-- | ldap/admin/src/scripts/template-stop-slapd | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/ldap/admin/src/scripts/template-stop-slapd b/ldap/admin/src/scripts/template-stop-slapd deleted file mode 100644 index cc9f9681..00000000 --- a/ldap/admin/src/scripts/template-stop-slapd +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/sh - -# Script that stops the ns-slapd server. -# Exit status can be: -# 0: Server stopped successfully -# 1: Server could not be stopped -# 2: Server was not running - -PIDFILE={{RUN-DIR}}/{{PRODUCT-NAME}}-{{SERV-ID}}.pid -if test ! -f $PIDFILE ; then - echo No ns-slapd PID file found. Server is probably not running - exit 2 -fi -PID=`cat $PIDFILE` -# see if the server is already stopped -kill -0 $PID > /dev/null 2>&1 || { - echo Server not running - if test -f $PIDFILE ; then - rm -f $PIDFILE - fi - exit 2 -} -# server is running - kill it -kill $PID -loop_counter=1 -# wait for 10 minutes (600 times 1 second) -max_count=600 -while test $loop_counter -le $max_count; do - loop_counter=`expr $loop_counter + 1` - if kill -0 $PID > /dev/null 2>&1 ; then - sleep 1; - else - if test -f $PIDFILE ; then - rm -f $PIDFILE - fi - exit 0 - fi -done -if test -f $PIDFILE ; then - echo Server still running!! Failed to stop the ns-slapd process: $PID. Please check the errors log for problems. -fi -exit 1 |
