Change ssh_utils parameter to correctly sends keepalive packets
The current implementation of ssh_utils never sends keepalive packets.
In ssh_utils.SSHPool, the socket timeout parameter is set to None
intending to keep ssh connections open.
However, when the parameter is set to None, ssh_utils does not run the
code to compare idle duration and keepalive interval.
This patch reverts the socket timeout parameter to default (0.1 sec).
The ssh_utils compares them every 0.1 seconds, and sends a keepalive
packet if idle duration > keepalive interval (= self.conn_timeout).
Reviewed: https:/ /review. openstack. org/527309 /git.openstack. org/cgit/ openstack/ cinder/ commit/ ?id=fca5fb9acf6 f1fe1aafa8cee94 a39918abaa4b27
Committed: https:/
Submitter: Zuul
Branch: master
commit fca5fb9acf6f1fe 1aafa8cee94a399 18abaa4b27
Author: Shunei Shiono <email address hidden>
Date: Tue Dec 12 14:38:25 2017 +0900
Change ssh_utils parameter to correctly sends keepalive packets
The current implementation of ssh_utils never sends keepalive packets.
In ssh_utils.SSHPool, the socket timeout parameter is set to None
intending to keep ssh connections open.
However, when the parameter is set to None, ssh_utils does not run the
code to compare idle duration and keepalive interval.
This patch reverts the socket timeout parameter to default (0.1 sec).
The ssh_utils compares them every 0.1 seconds, and sends a keepalive
packet if idle duration > keepalive interval (= self.conn_timeout).
Change-Id: I8234083107207b 9ebc0849947e8de 92b5cf3e36e
Closes-Bug: #1673662