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
SSH ProxyCommand timing to Cisco devices #675
Comments
This totally fixed my same issue |
That is pretty bizarre, thanks for the details. My gut instinct is to make this optional/controllable somehow as a mandatory sleep/wait (even a small one) feels kinda bleh, especially since we don't (?) know why this makes things work in your situation. Also because it's a bit of a corner case - though I do wonder how many other oddball hang reports in this tracker might be due to this or similar things... Speaking of which, what exactly is "your same issue", @doddsie? I love details! Please give me details. |
Yeah, I never really liked my fix which is why I never submitted a PR on it. |
I am running my commands through a ssh tunnel for bastion servers and get ERROR:paramiko.transport:SSHException: Error reading SSH protocol banner My config file in ~/.ssh looks like the following: To start the tunnel I use the following: If there is a way for me to provide more information to you or any specific Certainly adding a delay to make this work is not ideal, but that is Cheers, On Sun, Apr 24, 2016 at 8:02 PM, Kirk Byers notifications@github.com
|
Also dealing with this issue, as it affects NetMiko. I attempted to apply @ktbyers fix, but must be missing something. simply inserting event.wait(0.2) does not work: try:
try:
event.wait(0.2) # MONKEY_PATCH: Added delay
self.packetizer.write_all(b(self.local_version + '\r\n'))
self._log(DEBUG, 'Local version/idstring: %s' % self.local_version) I added some additional details to the netmiko issue here, but there's nothing particularly new or interesting, and my problem looks exactly like what ktbyers describeds |
I am trying to use an SSH Proxy with Cisco IOS networking devices (and other networking vendors). I have verified that my SSH config parsing is working correctly. I have also verified that I can manually use the ProxyCommand from bash.
I am able to get this to work with Paramiko going from linux > to linux > to linux.
I am also able to get this to work going from linux > to linux > to Juniper
But if I try to do from linux > to linux > to Cisco, then I am receiving the following:
And in my log file I see:
The Cisco side indicates it has sent the banner:
If I add a short delay before the thread starts in transport.py, then the problem is fixed.
I was also able to fix it by adding a short delay right before the banner is output (line 1710 in transport.py). Right before the following line:
The text was updated successfully, but these errors were encountered: