Question

I have port 22: Operation timed out on my droplets

Tomorrow I made a droplet and this morning I have the error

ssh -vvvv root@165.232.147.254
OpenSSH_8.6p1, LibreSSL 2.8.3
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 21: include /etc/ssh/ssh_config.d/* matched no files
debug1: /etc/ssh/ssh_config line 54: Applying options for *
debug2: resolve_canonicalize: hostname 165.232.147.254 is address
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts' -> '/Users/vsshnayder/.ssh/known_hosts'
debug3: expanded UserKnownHostsFile '~/.ssh/known_hosts2' -> '/Users/vsshnayder/.ssh/known_hosts2'
debug1: Authenticator provider $SSH_SK_PROVIDER did not resolve; disabling
debug3: ssh_connect_direct: entering
debug1: Connecting to 165.232.147.254 [165.232.147.254] port 22.
debug3: set_sock_tos: set socket 3 IP_TOS 0x48
debug1: connect to address 165.232.147.254 port 22: Operation timed out
ssh: connect to host 165.232.147.254 port 22: Operation timed out

I haven’t server passowrd and using ssh key to connect to server

Please help me to connect


Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

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.

KFSys
Site Moderator
Site Moderator badge
January 15, 2022
Accepted Answer

Hi @volodyaschneider,

It seems to me like your IP address is not allowed to reach port 22 or the method you are using to authenticate is not turned on by the droplet.

Having said that, most probably the issue is with port 22. In such cases, you’ll need to use the DigitalOcean’s Recovery Console to get access to your Droplet back and allow SSH connections.

Check the following documentation about the matter:

https://docs.digitalocean.com/products/droplets/resources/recovery-console/

Following the steps, there will allow you to gain access to your Droplet and allow connections for your IP on port 22.

alexdo
Site Moderator
Site Moderator badge
January 15, 2022

Hello, @volodyaschneider

If you filter any traffic to your droplet via a Cloud Firewall you can temporary disable all rules in order to regain access to your server.

https://docs.digitalocean.com/products/networking/firewalls/

On the other hand if you filter traffic on port 22 via UFW you can then use the DigitalOcean console as per KFSys’s suggestion in order to restore the normal access to your droplet.

https://docs.digitalocean.com/products/droplets/resources/recovery-console/

https://www.digitalocean.com/community/tutorials/how-to-set-up-a-firewall-with-ufw-on-ubuntu-20-04

Hope that this helps! Regards, Alex

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Become a contributor for community

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

DigitalOcean Documentation

Full documentation for every DigitalOcean product.

Resources for startups and SMBs

The Wave has everything you need to know about building a business, from raising funding to marketing your product.

Get our newsletter

Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.

New accounts only. By submitting your email you agree to our Privacy Policy

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.