From: Holger Levsen Date: Tue, 5 Mar 2013 12:29:14 +0000 (+0100) Subject: better sleep heuristic X-Git-Url: https://git.uhu-banane.de/?a=commitdiff_plain;h=690e37611ed282bb1f586e9c98527c9f175c5e53;p=profitbricks%2Fjenkins-build-scripts.git better sleep heuristic --- diff --git a/pxe_install.sh b/pxe_install.sh index eaef0d0..554f351 100755 --- a/pxe_install.sh +++ b/pxe_install.sh @@ -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