networking - How to fix permission denied when I try to connect via SSH to my ubuntu server? - Ask Ubuntu
when try connect ubuntu server hosted on aws "permission denied".
ssh -v ...
gets me this:
openssh_7.2p2, libressl 2.4.1 debug1: reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 20: applying options * debug1: connecting 52.22.60.11 [52.22.60.11] port 22. debug1: connection established. debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_rsa type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_rsa-cert type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_dsa type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_dsa-cert type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_ecdsa type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_ecdsa-cert type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_ed25519 type -1 debug1: key_load_public: no such file or directory debug1: identity file /users/rubenberkhout/.ssh/id_ed25519-cert type -1 debug1: enabling compatibility mode protocol 2.0 debug1: local version string ssh-2.0-openssh_7.2 debug1: remote protocol version 2.0, remote software version openssh_6.6.1p1 ubuntu-2ubuntu2.4 debug1: match: openssh_6.6.1p1 ubuntu-2ubuntu2.4 pat openssh_6.6.1* compat 0x04000000 debug1: authenticating 52.22.60.11:22 'admin' debug1: ssh2_msg_kexinit sent debug1: ssh2_msg_kexinit received debug1: kex: algorithm: curve25519-sha256@libssh.org debug1: kex: host key algorithm: ecdsa-sha2-nistp256 debug1: kex: server->client cipher: chacha20-poly1305@openssh.com mac: <implicit> compression: none debug1: kex: client->server cipher: chacha20-poly1305@openssh.com mac: <implicit> compression: none debug1: expecting ssh2_msg_kex_ecdh_reply debug1: server host key: ecdsa-sha2-nistp256 sha256:bkkfdekrz+v2q7d8kr+wutsr8asoqnayvqpjylubaui debug1: host '52.22.60.11' known , matches ecdsa host key. debug1: found key in /users/rubenberkhout/.ssh/known_hosts:8 debug1: rekey after 134217728 blocks debug1: ssh2_msg_newkeys sent debug1: expecting ssh2_msg_newkeys debug1: rekey after 134217728 blocks debug1: ssh2_msg_newkeys received debug1: ssh2_msg_service_accept received debug1: authentications can continue: publickey debug1: next authentication method: publickey debug1: trying private key: /users/rubenberkhout/.ssh/id_rsa debug1: trying private key: /users/rubenberkhout/.ssh/id_dsa debug1: trying private key: /users/rubenberkhout/.ssh/id_ecdsa debug1: trying private key: /users/rubenberkhout/.ssh/id_ed25519 debug1: no more authentication methods try. permission denied (publickey).
aws forces private-key authentication. don't allow user/pass auth.
you have do:
ssh -i private-key.pem user@server-ip
substituting in information, obviously.
if don't have .pem
file, can download aws control panel.
Comments
Post a Comment