summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2024-10-10 10:32:06 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2024-10-11 12:17:03 +0100
commit2f9ba70637402d51e341bd880662500b0441a0f9 (patch)
treefeae9f2781d527d6a2d7c274d562150b1a15d963
parent5f78d78beb3ec5b5ecc4b8423bffb1d217d54387 (diff)
downloadpoky-2f9ba70637402d51e341bd880662500b0441a0f9.tar.gz
oeqa/runtime/ssh: Rework ssh timeout
After the changes to improve this test, we keep seeing image testing ssh failures, particularly on mips. It looks like part of the problem is that on a loaded system, 5s is too short for mips to reliably establish an ssh connection. I've seen logs where it keeps timing out and fails to work, then the debug code successfully uses ssh later after everything else fails. Change the timings/retries to give slow platforms enough time to respond. (From OE-Core rev: ba64ccf3ad6e40461219b72d60eb0fe5cb38fddd) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/runtime/cases/ssh.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oeqa/runtime/cases/ssh.py b/meta/lib/oeqa/runtime/cases/ssh.py
index b86428002f..f5b76edff4 100644
--- a/meta/lib/oeqa/runtime/cases/ssh.py
+++ b/meta/lib/oeqa/runtime/cases/ssh.py
@@ -16,7 +16,7 @@ class SSHTest(OERuntimeTestCase):
16 @OETestDepends(['ping.PingTest.test_ping']) 16 @OETestDepends(['ping.PingTest.test_ping'])
17 @OEHasPackage(['dropbear', 'openssh-sshd']) 17 @OEHasPackage(['dropbear', 'openssh-sshd'])
18 def test_ssh(self): 18 def test_ssh(self):
19 for i in range(20): 19 for i in range(5):
20 status, output = self.target.run("uname -a", timeout=5) 20 status, output = self.target.run("uname -a", timeout=5)
21 if status == 0: 21 if status == 0:
22 break 22 break
@@ -29,7 +29,7 @@ class SSHTest(OERuntimeTestCase):
29 # give it time for the port to open. 29 # give it time for the port to open.
30 # We sometimes see -15 (SIGTERM) on slow emulation machines too, likely 30 # We sometimes see -15 (SIGTERM) on slow emulation machines too, likely
31 # from boot/init not being 100% complete, retry for these too. 31 # from boot/init not being 100% complete, retry for these too.
32 time.sleep(5) 32 time.sleep(30)
33 continue 33 continue
34 else: 34 else:
35 self.fail("uname failed with \"%s\" (exit code %s)" % (output, status)) 35 self.fail("uname failed with \"%s\" (exit code %s)" % (output, status))