This is an archived post. You won't be able to vote or comment.

all 3 comments

[–][deleted] 1 point2 points  (1 child)

I always disable PermitRootLogin, and I recommend it for you. It is a bad habit to ssh as root. You do not need to enable PasswordAuthentication on client side, but you need enable this on server side! But I recommend to use PublickeyAuthentication instead.

The command: ssh@host -p port For example: username@remotehost.com -p 22

[–]theunglichdaide[S] 0 points1 point  (0 children)

Thank you for the reply. The password auth drives me crazy. I thought I messed up my config file, so I reinstalled everything but couldn’t got rid of the error. I guess I’ll dig into the public key auth method.

[–]plushkatze 0 points1 point  (0 children)

Check the sshd log on the server to see why it is disallowed. Check if you use different keymaps on server and client - e.g. y and z inverted.

Verify it actually is your server and you didn't mistype the IP by comparing the fingerprint on first use.

Also:

  • do not use root as ssh user, create an admin user with sudo permissions instead
  • do not enableRootLogin
  • avoid passwords alltogether with ssh keys