Re: Paramiko SSHClient.connect() problem

2015-10-27 Thread Chris Angelico
On Wed, Oct 28, 2015 at 6:56 AM, Skip Montanaro wrote: > On Tue, Oct 27, 2015 at 1:40 PM, Chris Angelico wrote: >> >> If you hack your hosts file to have only one localhost, >> does the problem disappear? > > > Yes, that appears to solve the problem. Thanks. I hadn't even thought there > would be

Re: Paramiko SSHClient.connect() problem

2015-10-27 Thread Skip Montanaro
On Tue, Oct 27, 2015 at 1:40 PM, Chris Angelico wrote: > If you hack your hosts file to have only one localhost, > does the problem disappear? > Yes, that appears to solve the problem. Thanks. I hadn't even thought there would be IPv4/IPv6 distinctions here. Interestingly enough, the box does s

Re: Paramiko SSHClient.connect() problem

2015-10-27 Thread Chris Angelico
On Wed, Oct 28, 2015 at 12:23 AM, Skip Montanaro wrote: > Finally, there is also a "localhost" record in known_hosts. Connecting to > that fails with a different exception: > ssh = paramiko.SSHClient() conn = ssh.connect("localhost") > error getsockaddrarg: bad family > [||1] [paramiko/c

Re: Paramiko SSHClient.connect() problem

2015-10-27 Thread Skip Montanaro
On Tue, Oct 27, 2015 at 8:23 AM, Skip Montanaro wrote: > >>> ssh = paramiko.SSHClient() > >>> conn = ssh.connect("firefly") > SSHException Server 'firefly' not found in known_hosts > [||1] [paramiko/client.py|connect|288] > [paramiko/client.py|missing_host_key|570] > I figured out that I needed

Paramiko SSHClient.connect() problem

2015-10-27 Thread Skip Montanaro
I'm trying to use paramiko (for the first time) to connect to both the localhost and a remote host as I read along in Jesse Noller's blog post . That host is listed in ~/.ssh/known_hosts three different ways: