ssh_exchange_identification: Connection closed by remote host

  • Posted on September 1, 2013
  • crowdtodAsked by crowdtod

I did few steps for the gunicorn and nginx. Everything was fine, but, then i again tried to login into vps by ssh then i get following errors.

ssh_exchange_identification: Connection closed by remote host

Now, i can’t login into digitalocean vpn to change /etc/hosts.deny

Further, i tried from the browser based terminal access then its wired that i can’t type “/” as my keyboard is not in english format.

Help is appreciated!

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

Log in to your droplet via the console and run these commands: <br> <br><pre>ssh-keygen -t dsa -N “” -f /etc/ssh/ssh_host_dsa_key <br>ssh-keygen -t rsa -N “” -f /etc/ssh/ssh_host_rsa_key <br>ssh-keygen -t ecdsa -N “” -f /etc/ssh/ssh_host_ecdsa_key</pre> <br>if that doesn’t work (i.e. you still can’t type /), try running this command instead: <br> <br><pre>dpkg-reconfigure openssh-server</pre>

After creating self signed cert, using this tutorial : . i have tried all the solutions presented and i still get same error ‘ssh_exchange_identification: read: Connection reset by peer’

@kamal thank you it is fixed i can connect to ssh <br> <br>thank you soo much