But I am getting the following error:

ssh_exchange_identification: read: Connection reset by peer

I executing the following command:

sudo ssh root@example.net

Can this be due to somekind of firewall settings or because the server is overlaoded?

link|improve this question
You don't need to sudo to ssh to another box as root, just ssh root@where-ever from your current id. You only need sudo if you're using key exchange as the root user. Also, never ssh into a box as root. Having said all that - try ssh -v -v -v root@whatever and see if you get any meaningful output (-v makes it more verbose). – EightBitTony Jun 29 '11 at 19:14
Have you specifically enabled root logins over SSH? I know they're disabled in Ubuntu, and you really shouldn't be logging in as root via SSH anyways. – Darth Android Jun 29 '11 at 19:21
feedback

migrated from stackoverflow.com Jun 29 '11 at 19:08

This question came from our site for professional and enthusiast programmers.

2 Answers

It's likely a firewall issue, I can connect fine from here (it asks me for a password).

Please do not use sudo ssh, just ssh is fine. Also, disable passwordbased authentication and use keybased auth if possible.

To diagnose problems, run ssh with the -v option (-vvv for maximum verbosity):

ssh -vvv user@host
link|improve this answer
feedback
  • try ssh -vvv
  • (re)moving your .ssh/config to let's say /tmp and try ssh again
  • try regenerating your keys (client then server)
  • try to ssh from same box to same box just for test
  • temporary disable your firewall
link|improve this answer
feedback

Your Answer

 
or
required, but never shown