From ee5f23944217c23a2432e0f3dd9fa117f6c52308 Mon Sep 17 00:00:00 2001 From: Thierry Parmentelat Date: Fri, 6 Mar 2015 11:12:37 +0100 Subject: [PATCH] a utility script for hammering on the ping-node step --- system/iterate-ping-node | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100755 system/iterate-ping-node diff --git a/system/iterate-ping-node b/system/iterate-ping-node new file mode 100755 index 0000000..e9c74dc --- /dev/null +++ b/system/iterate-ping-node @@ -0,0 +1,34 @@ +#!/bin/bash + +# do be run on testmaster in a buildname/ + +[[ -n "$@" ]] && iterations=$1 || iterations=10 + +buildname=$(basename $(pwd)) + +echo buildname=$buildname, $iterations iterations + +for attempt in $(seq $iterations); do + + attempt=$(printf "%02d" $attempt) + + echo ======================================== attempt $attempt + + run qemu-kill-mine >& /dev/null + echo KILLED + ssh boxtops rm /vservers/$buildname/\*/log.txt + echo CLEANED +# run qemu-list-mine + sleep 5 + run qemu-start >& /dev/null + echo RESTARTED +# run qemu-list-mine + sleep 40 + run ping-node >& /dev/null && msg=OK || msg=KO + + log=$buildname-$attempt-$msg.log.txt + rsync boxtops:/vservers/$buildname/\*/log.txt $log + + echo ==================== attempt $attempt $msg - see $log + +done -- 2.43.0