Closed wasabi222 closed 7 years ago
Hi @wasabi222 - thanks for reporting this.
I am not sure if this is a IOS-XR specific problem, or general netmiko's - I think the device drops the connection after a while (I've seen the same on IOS, without the is_alive
check).
But it is bizarre however that is_alive
still returns True
. Would you have any NXOS or IOS device to connect via SSH/netmiko and confirm if they still cause the same, but it tells the connection continues to be alive?
Hi Mircea,
The above error happens immediately after opening a connection to an iosxr device, so I'm not sure it's related to a connection timeout after an extended duration.
I was able to test with napalm_ios
connecting to an ios device, and was able to successfully issue methods like get_facts
, etc without issue.
Interesting... can you confirm the user is still connected (show users
)? It might be just because it takes very long for the XML API to reply. Some time ago someone told me that it took like 8 minutes (yeah, that's mental) to reply to a simple request.
Can you enter in xml mode (xml echo format
) and insert the following XML to see if the device responds slowly:
<?xml version="1.0" encoding="UTF-8"?><Request MajorVersion="1" MinorVersion="0">
<Get><Operational><SystemTime/><PlatformInventory/></Operational></Get>
</Request>
Or (if you have the same issue with get_lldp_neighbors
or get_lldp_neighbors_detail
):
<?xml version="1.0" encoding="UTF-8"?><Request MajorVersion="1" MinorVersion="0">
<Get><Operational><LLDP></LLDP></Operational></Get>
</Request>
Moved to https://github.com/napalm-automation/napalm/issues/433
@wasabi222 meanwhile, can you please clarify my question above?
Hi Mircea,
I ran
<?xml version="1.0" encoding="UTF-8"?><Request MajorVersion="1" MinorVersion="0">
<Get><Operational><SystemTime/><PlatformInventory/></Operational></Get>
</Request>
It looks like the response in xml mode took somewhere close to 30 seconds to receive a reply, which could be causing a timeout on netmiko waiting for a reply from the device (Timeout Exceeded!)? I checked and show users does still show me connected.
Description of Issue/Question
I'm able to connect to a device successfully but when I issue a method like get_bgp_neighbors or get_facts I get a timeout error. The connection to the device remains active though.
Did you follow the steps from https://github.com/napalm-automation/napalm#faq
[x ] Yes [ ] No
Setup
napalm-iosxr version
(Paste verbatim output from
pip freeze | grep napalm-iosxr
between quotes below)IOS-XR version and platform details
(Paste the complete verbatim output from
show version brief
between quotes below)Steps to Reproduce the Issue
Error Traceback
(Paste the complete traceback of the exception between quotes below)