SSH Connection Windows 11 Home

Carlos Spagnolo 21 Reputation points
2022-08-19T13:10:54.893+00:00

Hi, I am having a problem trying to connect to a server via SSH. I get the following error:

ssh: connect to host xx:xxx:xx:xx:x port 22: Connection timed out

The server is configured correctly, how can I fix it?

Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
9,799 questions
{count} votes

Accepted answer
  1. MotoX80 34,251 Reputation points
    2022-08-21T15:38:08.787+00:00

    I think my ISP uses cg-nat. Is there any solution in this case?

    Your best bet would be to contact your ISP.

    https://amoss.me/2017/05/port-forwarding-behind-a-carrier-grade-nat/

    The IP of my laptop is 192.168.1.4. It is connected to my WIFI router and DHCP on the router assigns the address. When I browse https://canyouseeme.org it reports that my IP address is 108.55.nnn.nnn. That is the external (internet) address of my Verizon router.

    When I want to expose some app to the internet I need to browse http://192.186.1.1 and log in to my router. From there I would define a forwarding rule that sends network traffic to port 80/443/22 to my 192.168.1.4 laptop.

    If you were able to "connect from another internet provider", and you did NOT configure any port forwarding rule, then I don't know how that is working. Does canyouseeme.org detect that port 22 is open? Does it report the IP address that you are trying to connect to?

    0 comments No comments

3 additional answers

Sort by: Most helpful
  1. MotoX80 34,251 Reputation points
    2022-08-19T15:22:36.583+00:00

    I'm trying to connect through the internet.

    Is the destination server directly connected to the internet, or does it sit behind a router?

    On the server, browse this site and enter 22 as the port number to check. Can it connect?

    https://canyouseeme.org/

    That site will also tell you the IP address of the server as it is visible on the internet. That is the address that the client would need to connect to. If that address does not match the address that ipconfig.exe reports, then the server is behind some router/firewall and you would need to enable port forwarding on the router to have external traffic on port 22 to be routed to the server's internal IP address.

    0 comments No comments

  2. Carlos Spagnolo 21 Reputation points
    2022-08-21T14:35:14.307+00:00

    I was able to connect from another internet provider. I think my ISP uses cg-nat. Is there any solution in this case?

    0 comments No comments

  3. Limitless Technology 39,661 Reputation points
    2022-08-22T07:30:09.38+00:00

    Hello

    Thank you for your question and reaching out. I can understand you are having issues related to SSH connection.

    It looks some Firewall policy blocking the connection.

    On Windows 11 Disable any Antivirus program or Windows firewall you may have for temporary purpose.

    Also please check SSHD service configuration file and you may need allow certain IP or subnet address so that It will allow to connect.

    ---------------------------------------------------------------------------------------------------------------------------------------------------

    --If the reply is helpful, please Upvote and Accept as answer--

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.