Skip to content

Commit 90b21bc

Browse files
committed
torture: Properly redirect kvm-remote.sh "echo" commands
The echo commands following initialization of the "oldrun" variable need to be "tee"d to $oldrun/remote-log. This commit fixes several stragglers. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
1 parent b6c9dbf commit 90b21bc

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

tools/testing/selftests/rcutorture/bin/kvm-remote.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -184,16 +184,16 @@ checkremotefile () {
184184
ret=$?
185185
if test "$ret" -eq 255
186186
then
187-
echo " ---" ssh failure to $1 checking for file $2, retry after $sleeptime seconds. `date`
187+
echo " ---" ssh failure to $1 checking for file $2, retry after $sleeptime seconds. `date` | tee -a "$oldrun/remote-log"
188188
elif test "$ret" -eq 0
189189
then
190190
return 0
191191
elif test "$ret" -eq 1
192192
then
193-
echo " ---" File \"$2\" not found: ssh $1 test -f \"$2\"
193+
echo " ---" File \"$2\" not found: ssh $1 test -f \"$2\" | tee -a "$oldrun/remote-log"
194194
return 1
195195
else
196-
echo " ---" Exit code $ret: ssh $1 test -f \"$2\", retry after $sleeptime seconds. `date`
196+
echo " ---" Exit code $ret: ssh $1 test -f \"$2\", retry after $sleeptime seconds. `date` | tee -a "$oldrun/remote-log"
197197
return $ret
198198
fi
199199
sleep $sleeptime
@@ -252,7 +252,7 @@ do
252252
sleep 30
253253
fi
254254
done
255-
echo All batches started. `date`
255+
echo All batches started. `date` | tee -a "$oldrun/remote-log"
256256

257257
# Wait for all remaining scenarios to complete and collect results.
258258
for i in $systems
@@ -261,7 +261,7 @@ do
261261
do
262262
sleep 30
263263
done
264-
echo " ---" Collecting results from $i `date`
264+
echo " ---" Collecting results from $i `date` | tee -a "$oldrun/remote-log"
265265
( cd "$oldrun"; ssh $i "cd $rundir; tar -czf - kvm-remote-*.sh.out */console.log */kvm-test-1-run*.sh.out */qemu[_-]pid */qemu-retval */qemu-affinity; rm -rf $T > /dev/null 2>&1" | tar -xzf - )
266266
done
267267

0 commit comments

Comments
 (0)