Merge "Fix ssh timeout issue"
diff --git a/tempest/common/ssh.py b/tempest/common/ssh.py
index be350c8..2ed1057 100644
--- a/tempest/common/ssh.py
+++ b/tempest/common/ssh.py
@@ -114,9 +114,13 @@
err_data = []
poll = select.poll()
poll.register(channel, select.POLLIN)
+ start_time = time.time()
+
while True:
ready = poll.poll(self.channel_timeout)
if not any(ready):
+ if not self._is_timed_out(self.timeout, start_time):
+ continue
raise exceptions.TimeoutException(
"Command: '{0}' executed on host '{1}'.".format(
cmd, self.host))