From deb2aebe3c30a332ce87b6b6cd46f62239dde587 Mon Sep 17 00:00:00 2001 From: Fabio Erculiani Date: Mon, 4 Jan 2010 09:37:53 +0100 Subject: [PATCH] [entropy.transceivers] EntropySshUriHandler: fix timeout handling --- .../uri_handlers/plugins/interfaces/ssh_plugin.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libraries/entropy/transceivers/uri_handlers/plugins/interfaces/ssh_plugin.py b/libraries/entropy/transceivers/uri_handlers/plugins/interfaces/ssh_plugin.py index bcd34feed..78a551f2b 100644 --- a/libraries/entropy/transceivers/uri_handlers/plugins/interfaces/ssh_plugin.py +++ b/libraries/entropy/transceivers/uri_handlers/plugins/interfaces/ssh_plugin.py @@ -196,7 +196,9 @@ class EntropySshUriHandler(EntropyUriHandler): def _setup_common_args(self, remote_path): args = [] if const_isnumber(self._timeout): - args += ["-o", "ConnectTimeout=%s" % (self._timeout,)] + args += ["-o", "ConnectTimeout=%s" % (self._timeout,), + "-o", "ServerAliveCountMax=4", # hardcoded + "-o", "ServerAliveInterval=15"] # hardcoded if self._speed_limit: args += ["-l", str(self._speed_limit*8)] # scp wants kbits/sec remote_ptr = os.path.join(self.__dir, remote_path)