Question

Experiencing this error - ssh: connect to host xxx.xx.xxx.xx port 22: Operation timed out

Posted October 8, 2021 138 views
FedoraDigitalOcean Droplets

I’m not able to access my droplet via ssh with the command ssh user@xxx.xx.xxx.xx
It returns a port 22: Operation timed out error.

I used to be able to access it without any problems but haven’t access it in several weeks.

I’m using a custom fedora image if that helps.

I’ve tried to access the droplet console so I can do some resets as pointed out in some community posts but I never set up a password because I used sssh. The droplet doesn’t allow me to reset root password because:
This Droplet’s root password is managed internally and cannot be changed from the control panel. Please SSH into the Droplet to manage it.

Is there any way to access the droplet console?

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.

×
Submit an Answer
3 answers

The issue turned out to be related to the firewall setup. My local public IP was missing from the firewall setting.

I’ve tried rebooting the with Power Cycle on the droplet but still not able to access it via ssh.

What firewall are you using? Is port 22 allowed in the firewall rules? With UFW, something like ufw allow 'OpenSSH' should open port 22 (which SSH runs on)

  • Here’s how the firewall is set up on the droplet:

    Type: SSH
    Protocol: TCP
    Port Range: 22
    Sources: xxx.xx.xxx.xx/32 xx.xx.xxx.xx/32

    To run a ufw command wouldn’t I need to log into the web-based console?