summaryrefslogtreecommitdiff
path: root/lib/oxidized/input
diff options
context:
space:
mode:
authorSaku Ytti <saku@ytti.fi>2013-10-24 12:48:53 +0300
committerSaku Ytti <saku@ytti.fi>2013-10-24 12:48:53 +0300
commit0060d65fb92c2e09ec04e6bccb25f53338b71d0a (patch)
tree8d22c80d4ff36a1bc18d275d60e71020bd02b1c6 /lib/oxidized/input
parent1b4cf651d5b7e9e032a7bc0636c569d0419f2ded (diff)
parentedaf887b86d84378c94ef02fe7200e70f93f9279 (diff)
Merge https://github.com/p-sherratt/oxidized work
* IOS model conditional support for enable password * rest_client fix * rescue more errors in ssh
Diffstat (limited to 'lib/oxidized/input')
-rw-r--r--lib/oxidized/input/ssh.rb2
-rw-r--r--lib/oxidized/input/telnet.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/oxidized/input/ssh.rb b/lib/oxidized/input/ssh.rb
index c0594db..dc90354 100644
--- a/lib/oxidized/input/ssh.rb
+++ b/lib/oxidized/input/ssh.rb
@@ -39,7 +39,7 @@ module Oxidized
disconnect_cli
@ssh.loop
@ssh.close if not @ssh.closed?
- rescue Net::SSH::Disconnect
+ rescue Errno::ECONNRESET, Net::SSH::Disconnect
end
end
diff --git a/lib/oxidized/input/telnet.rb b/lib/oxidized/input/telnet.rb
index c4c8bab..26755ca 100644
--- a/lib/oxidized/input/telnet.rb
+++ b/lib/oxidized/input/telnet.rb
@@ -17,7 +17,7 @@ module Oxidized
expect password
@telnet.puts @node.auth[:password]
expect @node.prompt
- rescue Timeout::Error, Errno::ECONNREFUSED, Errno::ECONNRESET, Errno::EHOSTUNREACH
+ rescue Timeout::Error, Errno::ECONNREFUSED, Errno::ECONNRESET, Errno::EPIPE, Errno::EHOSTUNREACH
return false
end
end