microsoft / microsoft/vscode-remote-release
Various SSH timeout usability issues
Nobody has claimed this yet.
- Dominant language
- Dockerfile
- Stars
- 4.2k
- Forks
- 469
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 1
Description
Is there an existing issue for this bug?
- I have searched the existing open issues and found none that apply.
- If I find any issue of interest that is related or closed, I will included a link to it in this issue.
Required Troubleshooting Steps
- I have read and performed the troubleshooting steps
- I have tried both values of the
remote.SSH.useLocalServersetting - My issue was not covered in the Tips and Tricks linked from the Troubleshooting Wiki.
- I will include a complete copy of my Remote - SSH logs by running Remote-SSH: Show Log in the command palette or from View > Output in the menu bar
[Optional] Diagnose with Copilot
I did not ask the @remote-ssh participant for help
In step 2 of the troubleshooting wiki, what was the result of running the generated SSH command verbatim outside of VS Code?
I COULD successfully SSH to the remote machine with the generated SSH command
Remote-SSH Log
Remote-SSH Log
[16:47:01.664] Log Level: 2
[16:47:01.674] SSH Resolver called for "ssh-remote+demeter6", attempt 1
[16:47:01.677] remote.SSH.useLocalServer = true
[16:47:01.677] remote.SSH.useExecServer = true
[16:47:01.677] remote.SSH.bindHost = {}
[16:47:01.677] remote.SSH.path =
[16:47:01.677] remote.SSH.configFile =
[16:47:01.677] remote.SSH.useFlock = true
[16:47:01.677] remote.SSH.lockfilesInTmp = false
[16:47:01.677] remote.SSH.localServerDownload = auto
[16:47:01.678] remote.SSH.remoteServerListenOnSocket = false
[16:47:01.678] remote.SSH.defaultExtensions = []
[16:47:01.678] remote.SSH.defaultExtensionsIfInstalledLocally = []
[16:47:01.678] remote.SSH.loglevel = 2
[16:47:01.678] remote.SSH.enableDynamicForwarding = true
[16:47:01.678] remote.SSH.enableRemoteCommand = false
[16:47:01.678] remote.SSH.serverPickPortsFromRange = {}
[16:47:01.678] remote.SSH.serverInstallPath = {}
[16:47:01.678] remote.SSH.permitPtyAllocation = false
[16:47:01.678] remote.SSH.preferredLocalPortRange = undefined
[16:47:01.678] remote.SSH.useCurlAndWgetConfigurationFiles = false
[16:47:01.678] remote.SSH.experimental.chat = true
[16:47:01.679] remote.SSH.experimental.enhancedSessionLogs = true
[16:47:01.679] remote.SSH.httpProxy = {"*":""}
[16:47:01.679] remote.SSH.httpsProxy = {"*":""}
[16:47:01.684] VS Code version: 1.105.0-insider
[16:47:01.684] Remote-SSH version: remote-ssh@0.120.0
[16:47:01.684] darwin arm64
[16:47:01.691] SSH Resolver called for host: demeter6
[16:47:01.691] Setting up SSH remote "demeter6"
[16:47:01.695] Acquiring local install lock: /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-remote-ssh-52011aef-install.lock
[16:47:01.696] Looking for existing server data file at /Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json
[16:47:01.696] No existing data file
[16:47:01.696] Using commit id "72f7c60cfcc01d4e8a437f4a1704b8bbd3229411" and quality "insider" for server
[16:47:01.696] Extensions to install:
[16:47:01.699] Install and start server if needed
[16:47:01.701] PATH: /Users/keno/.juliaup/bin:/Users/keno/.opam/default/bin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Library/Apple/usr/bin:/Users/keno/.cargo/bin
[16:47:01.701] Checking ssh with "ssh -V"
[16:47:01.706] > OpenSSH_9.9p2, LibreSSL 3.3.6
[16:47:01.709] askpass server listening on /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-030e714a00959e78499f8a441cc1c6a9bc8bc5d3.sock
[16:47:01.709] Spawning local server with {"serverId":1,"ipcHandlePath":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-b875cdbb2c54e4c2a828a3f0ed8788e9286633b3.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","50176","-o","ConnectTimeout=15","demeter6"],"serverDataFolderName":".vscode-server-insiders","dataFilePath":"/Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json"}
[16:47:01.709] Local server env: {"SSH_AUTH_SOCK":"/private/tmp/com.apple.launchd.BRM0B9lxgg/Listeners","SHELL":"/bin/zsh","DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/Applications/Visual Studio Code - Insiders.app/Contents/Frameworks/Code - Insiders Helper (Plugin).app/Contents/MacOS/Code - Insiders Helper (Plugin)","VSCODE_SSH_ASKPASS_EXTRA_ARGS":"","VSCODE_SSH_ASKPASS_MAIN":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-030e714a00959e78499f8a441cc1c6a9bc8bc5d3.sock"}
[16:47:01.709] Spawned 51064
[16:47:01.710] Using connect timeout of 17 seconds
[16:47:01.794] > local-server-1> Running ssh connection command: ssh -v -T -D 50176 -o ConnectTimeout=15 demeter6
[16:47:01.795] > local-server-1> Spawned ssh, pid=51071
[16:47:01.799] stderr> OpenSSH_9.9p2, LibreSSL 3.3.6
[16:47:18.716] Terminating local server
[16:47:18.720] Resolver error: Error: Connecting with SSH timed out
at y.Timeout (/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/extension.js:2:744895)
at Timeout._onTimeout (/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/extension.js:2:805797)
at listOnTimeout (node:internal/timers:588:17)
at process.processTimers (node:internal/timers:523:7)
[16:47:18.728] ------
[16:47:18.729] ---------- [Session Summary] -----------
[16:47:18.729] [Timeout]: Error: Timeout (Connecting with SSH timed out)
[16:47:18.729] ----------------------------------------
[16:47:18.731] Local server exit: 15
[16:47:19.081] Opening exec server for ssh-remote+demeter6
[16:47:19.114] Opening exec server for ssh-remote+demeter6
[16:47:19.147] Initizing new exec server for ssh-remote+demeter6
[16:47:19.148] Acquiring local install lock: /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-remote-ssh-52011aef-install.lock
[16:47:19.148] Looking for existing server data file at /Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json
[16:47:19.148] No existing data file
[16:47:19.148] Using commit id "72f7c60cfcc01d4e8a437f4a1704b8bbd3229411" and quality "insider" for server
[16:47:19.148] Extensions to install:
[16:47:19.150] Install and start server if needed
[16:47:19.152] askpass server listening on /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-160f20a541700d9a0b577bd09a92a651164d038f.sock
[16:47:19.153] Spawning local server with {"serverId":2,"ipcHandlePath":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-c5a065c0d71e27c48b8030402af1123a3eabf8f8.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","50176","-o","ConnectTimeout=15","demeter6"],"serverDataFolderName":".vscode-server-insiders","dataFilePath":"/Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json"}
[16:47:19.153] Local server env: {"SSH_AUTH_SOCK":"/private/tmp/com.apple.launchd.BRM0B9lxgg/Listeners","SHELL":"/bin/zsh","DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/Applications/Visual Studio Code - Insiders.app/Contents/Frameworks/Code - Insiders Helper (Plugin).app/Contents/MacOS/Code - Insiders Helper (Plugin)","VSCODE_SSH_ASKPASS_EXTRA_ARGS":"","VSCODE_SSH_ASKPASS_MAIN":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-160f20a541700d9a0b577bd09a92a651164d038f.sock"}
[16:47:19.153] Spawned 51073
[16:47:19.153] Using connect timeout of 17 seconds
[16:47:19.235] > local-server-2> Running ssh connection command: ssh -v -T -D 50176 -o ConnectTimeout=15 demeter6
[16:47:19.237] > local-server-2> Spawned ssh, pid=51080
[16:47:19.240] stderr> OpenSSH_9.9p2, LibreSSL 3.3.6
[16:47:35.392] stderr> debug1: Server host key: ssh-ed25519 SHA256:/Dgy2jbOl3X2F1lC5TFQsu2UW2obu+A9ObXMLQlNiGw
[16:47:36.156] Terminating local server
[16:47:36.156] Exec server for ssh-remote+demeter6 failed: Error: Connecting with SSH timed out
[16:47:36.156] Existing exec server for ssh-remote+demeter6 errored (Error: Connecting with SSH timed out)
[16:47:36.157] Initizing new exec server for ssh-remote+demeter6
[16:47:36.157] Acquiring local install lock: /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-remote-ssh-52011aef-install.lock
[16:47:36.157] Error opening exec server for ssh-remote+demeter6: Error: Connecting with SSH timed out
[16:47:36.158] ---------- [Session Summary] -----------
[16:47:36.158] [Timeout]: Error: Timeout (Connecting with SSH timed out)
[16:47:36.158] ----------------------------------------
[16:47:36.159] Looking for existing server data file at /Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json
[16:47:36.159] No existing data file
[16:47:36.160] Using commit id "72f7c60cfcc01d4e8a437f4a1704b8bbd3229411" and quality "insider" for server
[16:47:36.160] Extensions to install:
[16:47:36.163] Install and start server if needed
[16:47:36.163] Local server exit: 15
[16:47:36.167] askpass server listening on /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-1be5dfaa7b95379c22ffcc4edc7fc1fc4a6c53bb.sock
[16:47:36.168] Spawning local server with {"serverId":3,"ipcHandlePath":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-b09176ea9c4c7ff8909010617491ab640263d44b.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","50176","-o","ConnectTimeout=15","demeter6"],"serverDataFolderName":".vscode-server-insiders","dataFilePath":"/Users/keno/Library/Application Support/Code - Insiders/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-52011aef-72f7c60cfcc01d4e8a437f4a1704b8bbd3229411-0.120.0-es/data.json"}
[16:47:36.168] Local server env: {"SSH_AUTH_SOCK":"/private/tmp/com.apple.launchd.BRM0B9lxgg/Listeners","SHELL":"/bin/zsh","DISPLAY":"1","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/Applications/Visual Studio Code - Insiders.app/Contents/Frameworks/Code - Insiders Helper (Plugin).app/Contents/MacOS/Code - Insiders Helper (Plugin)","VSCODE_SSH_ASKPASS_EXTRA_ARGS":"","VSCODE_SSH_ASKPASS_MAIN":"/Users/keno/.vscode-insiders/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-1be5dfaa7b95379c22ffcc4edc7fc1fc4a6c53bb.sock"}
[16:47:36.168] Spawned 51084
[16:47:36.169] Using connect timeout of 17 seconds
[16:47:36.677] Server delay-shutdown request failed: connect ENOENT /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-b09176ea9c4c7ff8909010617491ab640263d44b.sock
[16:47:38.683] Server delay-shutdown request failed: connect ENOENT /var/folders/y3/hn1qlpx91fzc_0qnrjtg2cbw0000gn/T/vscode-ssh-askpass-b09176ea9c4c7ff8909010617491ab640263d44b.sock
[16:47:39.296] > local-server-3> Running ssh connection command: ssh -v -T -D 50176 -o ConnectTimeout=15 demeter6
[16:47:39.297] > local-server-3> Spawned ssh, pid=51091
[16:47:39.301] stderr> OpenSSH_9.9p2, LibreSSL 3.3.6
[16:47:53.171] Terminating local server
[16:47:53.172] Exec server for ssh-remote+demeter6 failed: Error: Connecting with SSH timed out
[16:47:53.172] Error opening exec server for ssh-remote+demeter6: Error: Connecting with SSH timed out
[16:47:53.172] ---------- [Session Summary] -----------
[16:47:53.172] [Timeout]: Error: Timeout (Connecting with SSH timed out)
[16:47:53.173] ----------------------------------------
[16:47:53.178] Local server exit: 15
Expected Behavior
I am currently on a high-latency connection (GEO sat -> US -> EU -> US and back). The 15 second default timeout is insufficient to establish an ssh connection, so I get a timeout warning. This by itself is fine, but I would have expected some easy way to recover from this and retry with a higher timeout. Perhaps the Retry option itself should bump the timeout temporarily or there could be a separate Retry with higher timeout option.
Actual Behavior
I get the options Retry, Close Remote and More Actions. Retry is gets me back to the same place. Under More Actions, I get Open Settings which sounds promising to adjust the timeout, except that it doesn't actually let me touch the settings while in the SSH timeout failed state:
In order to change the settings value, I first need to close the remote connection, then open settings and then re-open the remote connection. This seems way too cumbersome.
Steps To Reproduce
Fly to Europe, try to use VS Code Remote in-flight.
Anything else?
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no source file or test. Start by reproducing the timeout from the Remote-SSH log using the generated SSH command and compare behavior with remote.SSH.useLocalServer enabled and disabled. Done would require a clearly defined resolution for the reported timeout usability issues, but the issue does not specify one.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- vscode
- Domain
- devtools, networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100