This hangs on a windows 10 client, but I really do need to use windows 10 client lately:

ssh -4 -X -i my.pem ga@ -o ConnectTimeout=604800

Contrastingly, this worked good on a linux ubuntu client in the past:

ssh -X -o ConnectTimeout=604800 -i "my.pem" ga@

The microsoft docs link to the OpenBSD docs. However the problem seems to be windows 10 specific. I really need to stay connected a long time.

There was no effect by moving parameters around, nor by the -4 presence or absence, nor by removing the = character.

This interestingly worked good on a windows 10 client, but is missing the option that I require:

ssh -4 -X -i my.pem ga@
Welcome to Ubuntu 16.04.5 LTS (GNU/Linux 4.4.0-142-generic x86_64)

The big question is, what is the right format for the family of command line options "-o" here on windows 10 clients? And why isn't it identical to linux clients?

I understand there might be a file to contain these options (-o options are a long list of possible strings). However the OpenBSD docs do not and would not be able to describe where to put this file on windows 10. The file name and directory on windows 10 to use would be a mystery to me for now. I imagine the bsd docs might explain the format of this file though.

UPDATE: I tried making a config file with the setting in it, same format as command line, and then launched it 4 different ways and still hang:

ssh -F .config -4 -X -i my.pem ga@ -o ConnectTimeout=604800
ssh -F ".config" -4 -X -i my.pem ga@ -o "ConnectTimeout=604800"
ssh -F .config -4 -X -i my.pem ga@
ssh -F ".config" -4 -X -i my.pem ga@





Another ssh command I will be needing (below) also hangs. I need to do port forwarding, so I can run a browser process in my client computer, but use the server's web server to host my jupyter notebooks for machine learning projects. It's a different ssh command but it has the same hanging problem. Maybe the ssh isn't really supported on windows 10, and if that's true, I going to abandon windows 10 and go back to building myself a linux workstation for a client, because I know it works right. This makes me mad, as it's such a time waster.

ssh -i my.pem -N -f -L localhost:8889:localhost:8889 ga@

UPDATE: With -vvv parameter it shows to be hanging where port 22 is not sending something back to the client:

ssh -4 -X -i my.pem ga@ -o ConnectTimeout=604800 -vvv
OpenSSH_for_Windows_7.7p1, LibreSSL 2.6.5

debug3: Failed to open file:C:/Users/mrcod/.ssh/config error:2

debug3: Failed to open file:C:/ProgramData/ssh/ssh_config error:2

debug2: resolve_canonicalize: hostname is address

debug2: ssh_connect_direct: needpriv 0

debug1: Connecting to [] port 22.

debug2: fd 3 setting O_NONBLOCK

Has anyone been able to connect to a unix server from windows 10 yet via ssh? They must have. This isn't an unusual task in 2019, with AWS being the innovating flagship of cloud systems, and web sites using linux servers in the majority globally. I'm not sure why nobody appears to know anything. My english here isn't weak either.

I'm not seeing any real help from the LAST items coming out of the debug output.

For lack of any other ideas submitted here, a next step seems to be to experiment smore more with putting another config file in additional places (directories) that the debug output is saying it was looking for it and see if any settings look possible for fixing the hanging on port 22 problem here. I don't think there is much to go on here really, so I'm pessimistic unless someone chimes in that actually uses ssh on windows 10, since openbsd is what this software was compiled from on windows 10 according to microsoft links I've provided.

  • 1
    Can you clairify what client you are using on Windows 10? PuTTY/Windows 10 Open-SSH or Windows 10 Linux Subsystem? I would try PuTTY vs Windows 10 Open-SSH. – FreeSoftwareServers Feb 12 '19 at 19:39
  • 1
    Try running ssh with the -vvv option to print verbose debugging output. That will show exactly what ssh is doing when it hangs. If necessary, edit your question to add the debugging output. – Kenster Feb 12 '19 at 23:07
  • @FreeSoftwareServers I just opened a cmd terminal. – Geoffrey Anderson Feb 13 '19 at 3:08
  • @Kenster done -- what do you think about it – Geoffrey Anderson Feb 14 '19 at 14:47
  • Can you clarify your exact version of Windows just to be clear. (OS Type And Version Number Eg: Windows 10 Enterprise v1809) – FreeSoftwareServers Feb 15 '19 at 23:28

Windows OpenSSH is very new (beta) and only enabled by default on Windows 10 after April 2018 Update. (https://www.howtogeek.com/336775/how-to-enable-and-use-windows-10s-built-in-ssh-commands/). It has known issues such as only supporting ed25519 key.

I would use SuperPuTTY and PuTTY, which is the defacto SSH client for Windows for years (IMO). But, from reading this GitHub thread (https://github.com/PowerShell/Win32-OpenSSH/issues/973), it seems the GitHub version of Windows 10 OpenSSH has improvements/feature fixes that might not be available via default installation. Try using the GitHub version! --> https://github.com/PowerShell/openssh-portable/releases




| improve this answer | |
  • ">Windows does not support SSH on its CLI by default" It does as shown. – Geoffrey Anderson Feb 14 '19 at 14:49
  • Seems it is enabled by default now, used to be an optional feature. It is extremely new though, I updated with a new option to update via GitHub. – FreeSoftwareServers Feb 15 '19 at 23:19

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.