Guide
SSH into your VPS
Create a key, connect once with the panel password, install the key and move to an unprivileged account.
1. Generate a key if you have none
ssh-keygen -t ed25519 -a 100 -C you@laptop writes the private key and the .pub file to ~/.ssh. Ed25519 is shorter and faster than RSA at the same strength.
2. Connect once with the panel password
ssh root@203.0.113.10 accepts the password shown in the panel. The session closes after the first login on images that force a password change.
3. Install the key
ssh-copy-id -i ~/.ssh/id_ed25519.pub root@203.0.113.10 appends the key to authorized_keys with the right permissions. A hand-copied key with mode 0644 is silently refused.
4. Verify the host key
The first connection prints a fingerprint. Compare it with the value under Console, Host keys before typing yes.
5. Create an unprivileged account
adduser deploy && usermod -aG sudo deploy, then ssh-copy-id to that account. Only after it authenticates should root login be disabled.
6. Add a client alias
In ~/.ssh/config: Host node1, HostName 203.0.113.10, User deploy, IdentityFile ~/.ssh/id_ed25519. Plain ssh node1 then works from any directory.
7. Debug a hanging connection
ssh -vvv node1 prints where the handshake stops. A timeout at banner exchange is a firewall or an sshd that is not listening, not a key problem.
FAQ
Questions we get on this page
Why does the host key change after a rebuild?+
Can I use a passphrase-protected key?+
Ready when you are
Tell us what you need. A human answers.
Pilot stage: one facility in Reykjavík, plans confirmed by hand, payment in crypto. Write to the desk and you get a real person, not a queue.