Your best friend for file transfer.

SSH Exhange Identification Read : Connection Reset By Peer (20 posts)
- Started 10 years ago by Todd
- Latest reply 9 years ago from Kjeld Flarup
-
Todd Member
-
Jim Matthews Administrator
I would open Terminal (found in the Utilities folder) and type:
ssh -v username@hostname
where username is your account on the SFTP server, and hostname is the hostname or IP address of the SFTP server. What do you see?
Thanks,
Jim Matthews
Fetch Softworks -
Todd Member
Todd--MacBook-Pro:~ todd$ ssh -v HeathPlus@198.101.142.69
OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for *
debug1: Connecting to 198.101.142.69 [198.101.142.69] port 22.
debug1: Connection established.
Could not create directory '/Users/toddcoggins/.ssh'.
debug1: identity file /Users/todd/.ssh/id_rsa type -1
debug1: identity file /Users/todd/.ssh/id_rsa-cert type -1
debug1: identity file /Users/todd/.ssh/id_dsa type -1
debug1: identity file /Users/todd/.ssh/id_dsa-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.2
ssh_exchange_identification: read: Connection reset by peer
Todd--MacBook-Pro:~ todd$ -
Jim Matthews Administrator
That's odd -- when I try to connect to that address I get a bit further (far enough to be prompted to enter a password).
Are you able to connect to any other SFTP servers?
Thanks,
Jim Matthews
Fetch Softworks -
Todd Member
I have not tried to connect to any other SFTP servers.
-
Jim Matthews Administrator
Try typing
ssh -v fake@getfetch.com
What is the output then?
Thanks,
Jim Matthews
Fetch Softworks -
Todd Member
Last login: Thu Nov 21 14:50:23 on ttys005
Todd-MacBook-Pro:~ todd$ ssh -v fake@getfetch.com
OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for *
debug1: Connecting to getfetch.com [68.178.150.1] port 22.
debug1: Connection established.
Could not create directory '/Users/todd/.ssh'.
debug1: identity file /Users/todd/.ssh/id_rsa type -1
debug1: identity file /Users/todd/.ssh/id_rsa-cert type -1
debug1: identity file /Users/todd/.ssh/id_dsa type -1
debug1: identity file /Users/todd/.ssh/id_dsa-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_6.2
debug1: Remote protocol version 2.0, remote software version OpenSSH_3.5p1
debug1: match: OpenSSH_3.5p1 pat OpenSSH_3.*
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Server host key: RSA de:18:88:be:a9:19:f0:98:12:aa:bc:a1:ff:47:cc:e7
The authenticity of host 'getfetch.com (68.178.150.1)' can't be established.
RSA key fingerprint is de:18:88:be:a9:19:f0:98:12:aa:bc:a1:ff:47:cc:e7.
Are you sure you want to continue connecting (yes/no)? y
Please type 'yes' or 'no': yes
Failed to add the host to the list of known hosts (/Users/todd/.ssh/known_hosts).
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: Roaming not allowed by server
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: publickey
debug1: Trying private key: /Users/todd/.ssh/id_rsa
debug1: Trying private key: /Users/todd/.ssh/id_dsa
debug1: Next authentication method: keyboard-interactive
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug1: Next authentication method: password
fake@getfetch.com's password: -
Jim Matthews Administrator
So:
* You can get to the password prompt on my server but not yours
* I can get to the password prompt on your server and mineIt is as if the problem is specific to the combination of your Mac and your server.
I do see a message about ssh not being able to create a ".ssh" directory in your home directory. Do you know why that is? What happens if you type:
mkdir /Users/todd/.ssh
in Terminal?
Thanks,
Jim Matthews
Fetch Softworks -
Todd Member
mkdir /Users/todd/.ssh
mkdir: /Users/todd/.ssh: Permission denied -
Jim Matthews Administrator
It's very strange that you don't have permission to create a folder in your own home folder. I would run Disk Utility (in the Utilities folder) and Repair Disk Permissions -- does that help?
Thanks,
Jim Matthews
Fetch Softworks -
Todd Member
Very strange, after repairing making a directory still hasn't worked.
BTW thanks so much for your help.
-
Jim Matthews Administrator
Can you create .ssh now?
-
ken Member
I had this problem and it turned out to be that sshd (?) was doing a reverse lookup on my client IP and DNS was not working at the time. The key to finding this was that /var/log/messages on the server was reporting issues with hosts.allow.
-
Kjeld Flarup Member
I experienced the same.
When looking into the logs I saw that someone was hammering and trying to guess the root password.
After blocking that IP, the problem disappeared within a few minutes.Coincidence or ?
-
Harold Member
Hi, I have the same problem. I need to access our windows file server from QNAP in putty.
When I try to ssh the windows file server with this command in putty:
ssh -p139 -v sisc-elohimI get this error:
debug1: Connecting to sisc-elohim [143.229.0.3] port 139.
debug1: Connection established.
debug1: permanently_set_uid: 0/0
debug1: identity file /root/ .ssh/ identity type -1
debug1: identity file /root/ .ssh/ id_rsa type 1
debug1: identity file /root/ .ssh/ id_dsa type -1
ssh_exchange_identification: read: Connection reset by peerPlease help.
Thank you so much in advance. -
Jim Matthews Administrator
Hi,
I'd recommend contacting the server administrator or the creators of putty for assistance.
Thanks,
Jim Matthews
Fetch Softworks -
Harold Member
Thank you.
-
Linov Suresh Member
Look like you have enabled TCP Wrappers in your system. Please verify hosts.deny file
-
bmike1 Member
I am trying to build a linux from scratch system. Here is my setup. I have two computers: the host just sits there. I am ssh(ing)from my main computer to the host and am building it from the main computer. Now I got through building the temporary tool chain and am in section 6.6 where I am supposed to change the host name to something other than "I have no name!" To do so another terminal is opened and text is entered. Now I am a little confused on how I get to the '... no name!' user. I think I've realized how to do it (redo section 6.4?). What I am concerned with at the moment is after I open the other terminal and ssh to the LFS computer I get the error:
SSH Exhange Identification Read : Connection Reset By Peer
I just got a suggestion to:
root@debian:/home/mike# rm /etc/ssh/*key*
root@debian:/home/mike# ssh-keygen -A
ssh-keygen: generating new host keys: RSA1 RSA DSA ECDSAbut none of those suggestions worked.
I read in the replies about someone whom blocked a crackers IP address and that caused it to work but I don't know how to see if someone is attempting to guess my password norhow to get the crackers ip address.Never mind---- upon a reboot ssh worked. nOw..... If only I could figure out why this happened.
-
Kjeld Flarup Member
bmike1, look in /var/log/secure
- Page 1
I am attempting to connect SFTP over port 22. My port forwarding is on and port 22 is open. What can be the problem?
Posted 10 years ago #