From 5bddebb8fc6eb85753a030f1d71fe2303969325b Mon Sep 17 00:00:00 2001 From: sanjeev Date: Mon, 22 Sep 2014 16:27:44 +0530 Subject: [PATCH] In case of Hyper-v ssvm/cpvm reboot takes time so made changes to handle this --- tools/marvin/marvin/lib/utils.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/tools/marvin/marvin/lib/utils.py b/tools/marvin/marvin/lib/utils.py index c52e2774466..8788b3b736f 100644 --- a/tools/marvin/marvin/lib/utils.py +++ b/tools/marvin/marvin/lib/utils.py @@ -208,12 +208,16 @@ def get_process_status(hostip, port, username, password, linklocalip, process, h process) # Double hop into router - timeout = 5 + if str(hypervisor).lower() == 'hyperv': + timeout = 12 + else: + timeout = 5 # Ensure the SSH login is successful while True: res = ssh.execute(ssh_command) - - if res[0] != "Host key verification failed.": + if "Connection refused".lower() in res[0].lower(): + pass + elif res[0] != "Host key verification failed.": break elif timeout == 0: break