]> Frank Brehm's Git Trees - profitbricks/jenkins-build-scripts.git/commitdiff
better sleep heuristic
authorHolger Levsen <holger@layer-acht.org>
Tue, 5 Mar 2013 12:29:14 +0000 (13:29 +0100)
committerHolger Levsen <holger@layer-acht.org>
Tue, 5 Mar 2013 12:29:14 +0000 (13:29 +0100)
pxe_install.sh

index eaef0d0387d0c116800c7de389081efcbd3449af..554f3518d75e11de3f651d0e2161118acf5732df 100755 (executable)
@@ -31,8 +31,9 @@ set +x
 #
 echo "Checking for sshd running on $TARGET_HOST..."
 for i in $(seq 1 90) ; do
-       sleep 10
+       sleep 2
        if $(ping -c 1 $TARGET_HOST >/dev/null)  ; then
+               sleep 8 # if it doesnt ping the timeout is 10secs anyway...
                echo -n "ping $TARGET_HOST ok..."
                # check ssh 
                if $(nc -z $TARGET_HOST 22 ) ; then