summaryrefslogtreecommitdiff
path: root/jenkins-helpers.sh
diff options
context:
space:
mode:
authorMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-10-11 10:24:38 +0000
committerMaxim Kuvyrkov <maxim.kuvyrkov@linaro.org>2019-10-11 10:24:38 +0000
commit2dc4fca2bd1d91f2a91fd3ae09255696252c56c4 (patch)
tree2c961de615cfa64e9d69040ba40f76b40c29c845 /jenkins-helpers.sh
parenteda203ba569252020f11e7c4a92bd6972d99398c (diff)
jenkins-helpers.sh: Add a timeout for "ssh $board true" in wait_for_ssh_server
I've noticed a strange failure in tcwg-benchmark script/job. When trying to reboot tcwg-tk1-03 the board got wedged (kernel soft lockup), and reboot was hanging. In this case the command, "ssh tcwg-tk1-03.tcwglab true" was also stuck for several hours. Avoid such hangs by adding a timeout. If we see more kernel lockups TK1s/TX1s on reboots, we'll add PDU power-cycling to the scripts. Change-Id: I1f0cdbf6ddb6a1b192b6b5081cc49889e5a62364
Diffstat (limited to 'jenkins-helpers.sh')
-rw-r--r--jenkins-helpers.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/jenkins-helpers.sh b/jenkins-helpers.sh
index 988b0a0c..bed8d428 100644
--- a/jenkins-helpers.sh
+++ b/jenkins-helpers.sh
@@ -633,7 +633,7 @@ wait_for_ssh_server ()
while [ $count -gt 0 ]
do
- ssh -p $session_port $session_host true && break
+ timeout 30s ssh -p $session_port $session_host true && break
echo "SSH server not ready, waiting....."
sleep 5
count=$((count - 1))