I can't connect to my Smart VPS over SSH. How do I get back in?

If SSH won't let you in, the console will; it doesn't use the network at all.

Steps

Check that the VPS shows as running in the portal at https://noc.versaweb.com. If it's stopped, start it first. You'll need a valid login for the VPS, which is the root password or a password reset from the portal.

  1. Open the Serial console from your VPS page in the portal (see our console article) and log in.
  2. Check that SSH is running. On Debian and Ubuntu the service is ssh: systemctl status ssh, and if it isn't running, systemctl enable --now ssh. On AlmaLinux it's sshd: systemctl status sshd, then systemctl enable --now sshd. Debian also starts SSH through ssh.socket, so systemctl status ssh.socket is worth a look.
  3. Confirm which port it listens on: ss -tlnp | grep ssh.
  4. Check your firewall. If a command says "command not found", that tool isn't installed, so skip it:

    • ufw: ufw status. Fix it with ufw allow 22/tcp.
    • firewalld: firewall-cmd --list-all. Fix it with firewall-cmd --permanent --add-service=ssh then firewall-cmd --reload.
  5. Check whether a ban tool blocked your own address (skip this if fail2ban-client isn't installed): fail2ban-client status sshd. To free an address, run fail2ban-client set sshd unbanip YOUR.HOME.IP.
  6. Check the SSH settings in /etc/ssh/sshd_config and any files in /etc/ssh/sshd_config.d/, which can override it. sshd -T prints the settings actually in effect. If you turned off password login but your key isn't installed, set PasswordAuthentication yes, then restart SSH with systemctl restart ssh (Debian and Ubuntu) or systemctl restart sshd (AlmaLinux).
  7. Test from a second terminal on your computer: ssh -l root YOUR.IP.ADDRESS. Leave the console open until it works.

If it didn't work

  • Run journalctl -u sshd -n 50 (or -u ssh) in the console and read the last lines for the reason.
  • If the console itself won't connect, see How do I open the Serial console or VNC Console for my Smart VPS?.
  • Still stuck? Open a ticket under Technical Support with your IP address, what you changed last, and the log lines above.


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 1