ssh root@server Permission denied (publickey).
Why find .ssh/iddsa file. there is no such a file. just idrsa.
So the issue is that I can login to my server just fine using:
But when I try to login with a user I created from root:
Permission denied (publickey).
The steps I went through before this.
SSH generated a key
Created an Ubuntu 16.04 droplet with given SSH key.
SSH into server with root
$ adduser username
usermod -aG sudo username
OpenSSH7.6p1, LibreSSL 2.6.2
debug1: Reading configuration data /etc/ssh/sshconfig
debug1: /etc/ssh/sshconfig line 48: Applying options for *
debug2: sshconnectdirect: needpriv 0
debug1: Connecting to cleanproject port 22.
debug1: Connection established.
debug1: identity file /Users/happy/.ssh/idrsa type 0
debug1: Authentications that can continue: publickey
debug1: Trying private key: /Users/happy/.ssh/iddsa
debug3: no such identity: /Users/happy/.ssh/iddsa: No such file or directory
debug1: Trying private key: /Users/happy/.ssh/idecdsa
debug3: no such identity: /Users/happy/.ssh/idecdsa: No such file or directory
debug1: Trying private key: /Users/happy/.ssh/ided25519
debug3: no such identity: /Users/happy/.ssh/ided25519: No such file or directory
debug2: we did not send a packet, disable method
debug1: No more authentication methods to try.
root@cleanproject: Permission denied (publickey).
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.×