Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #2712 - Handle Net::SSH::Disconnect gracefully #748

Closed

Conversation

GregSutcliffe
Copy link
Member

No description provided.

@@ -72,7 +72,7 @@ def logger
def initiate_connection!
Timeout::timeout(360) do
begin
Timeout::timeout(8) do
Timeout::timeout(30) do
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why 30? this would make every time you try to ssh to wait for 30 seconds? I think its better to try in shorter intervals?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's only the total timeout, accumulated over each failure. Given I can get 2-3 Econn::Refused followed by Net::SSH::Disconnect for 10-15s while it generates new Host keys, a total timeout of 8s is not enough.

@domcleal
Copy link
Contributor

Thanks @GregSutcliffe, merged as 0b5d270.

@domcleal domcleal closed this Jun 28, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants