diff options
author | Steven Rostedt (VMware) <rostedt@goodmis.org> | 2020-03-09 16:00:11 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-03-18 07:17:51 +0100 |
commit | 3625e9dfd80ad21dc5af3a05f2abe5aea6291143 (patch) | |
tree | 14aeb6c5d208b1d96a679a2db5ac9d4d2e302dae /tools | |
parent | a67ada0dcd9a55ff0515907b11a8363fec656ab8 (diff) | |
download | linux-stable-3625e9dfd80ad21dc5af3a05f2abe5aea6291143.tar.gz linux-stable-3625e9dfd80ad21dc5af3a05f2abe5aea6291143.tar.bz2 linux-stable-3625e9dfd80ad21dc5af3a05f2abe5aea6291143.zip |
ktest: Add timeout for ssh sync testing
commit 4d00fc477a2ce8b6d2b09fb34ef9fe9918e7d434 upstream.
Before rebooting the box, a "ssh sync" is called to the test machine to see
if it is alive or not. But if the test machine is in a partial state, that
ssh may never actually finish, and the ktest test hangs.
Add a 10 second timeout to the sync test, which will fail after 10 seconds
and then cause the test to reboot the test machine.
Cc: stable@vger.kernel.org
Fixes: 6474ace999edd ("ktest.pl: Powercycle the box on reboot if no connection can be made")
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/testing/ktest/ktest.pl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl index 220d04f958a6..42b6cd41d2ea 100755 --- a/tools/testing/ktest/ktest.pl +++ b/tools/testing/ktest/ktest.pl @@ -1383,7 +1383,7 @@ sub reboot { } else { # Make sure everything has been written to disk - run_ssh("sync"); + run_ssh("sync", 10); if (defined($time)) { start_monitor; |