]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-linux-rc-wait-for-salvager-20051002
authorJoe Buehler <jbuehler@spirentcom.com>
Mon, 3 Oct 2005 04:14:31 +0000 (04:14 +0000)
committerDerrick Brashear <shadow@dementia.org>
Mon, 3 Oct 2005 04:14:31 +0000 (04:14 +0000)
FIXES 21754

rc file hack to wait for salvage to finish

(cherry picked from commit abde1e6281ff1403e67c6f573dd10be4c892fb9a)

src/afsd/afs.conf.linux
src/afsd/afs.rc.linux

index 4494024d253a74b67f410b08ec5cd65dedea2bf0..6cdc675aaa18184d82f89f5b156f954ee5abbbb3 100644 (file)
@@ -79,6 +79,10 @@ CACHESIZE=AUTOMATIC
 OPTIONS=AUTOMATIC
 #OPTIONS=$SMALL
 
+# force startup script to wait for salvage to finish before proceeding
+# with machine boot
+WAIT_FOR_SALVAGE=no
+
 # you should never need to change these settings
 AFSDIR=/afs
 CACHEDIR=/usr/vice/cache
index 5b2405df8b2d1cbd238f80ae6b0985fb7095274f..9591579d084e402f518dd617d5e12d39befa0e83 100644 (file)
@@ -282,6 +282,14 @@ case "$1" in
        if  is_on $AFS_SERVER && test -x /usr/afs/bin/bosserver  ; then
                /usr/afs/bin/bosserver 
                test "$afs_rh" && touch /var/lock/subsys/afs
+               if is_on $WAIT_FOR_SALVAGE; then
+                       # wait for fileserver to finish salvaging
+                       sleep 10
+                       while /usr/bin/bos status localhost fs 2>&1 | grep 'Auxiliary.*salvaging'; do
+                               echo "Waiting for salvager to finish..... "
+                               sleep 10
+                       done
+               fi
        fi
 
        # Start AFS client