Add socket_open check to SSH connections for better host-down detection

Issue #15 closed
Jesse Almanrode
repo owner created an issue

In order to keep connections to "dead" servers from hanging (2 minutes by default) we should add a socket_open test before attempting an SSH connection to allow for a "fail-fast" condition. This should be separate from the Paramiko connection timeout we already have in the sshreader.ssh.SSH class.

The idea would be to return SSH timeout text faster for a connection to a "down" server:

ssh: connect to host <host> port <port>: Operation timed out

We should have the text be more clear though that there was no connection established. Error code returned from this text in standard ssh is 255.

Comments (1)

  1. Log in to comment