aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rumba/ssh_support.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/rumba/ssh_support.py b/rumba/ssh_support.py
index e1d23bf..80e079e 100644
--- a/rumba/ssh_support.py
+++ b/rumba/ssh_support.py
@@ -58,7 +58,6 @@ def _print_stream(stream):
return o.rstrip()
def ssh_connect(hostname, port, username, password, time_out, proxy_server):
- logger.debug('Trying to open a connection towards node %s.' % hostname)
retry = 0
max_retries = 10
while retry < max_retries:
@@ -188,12 +187,11 @@ def execute_commands(testbed, ssh_config, commands, time_out=3):
return o
finally:
ssh_config.client.close()
- ssh_config.proxy_client.close()
+ if ssh_config.proxy_client is not None:
+ ssh_config.proxy_client.close()
ssh_config.client = None
ssh_config.proxy_client = None
-
-
def execute_command(testbed, ssh_config, command, time_out=3):
"""
Remote execution of a list of shell command on hostname. By