microsoft / microsoft/vscode-remote-release

SSH via terminal working, but not in VSCode

Open
#10,951 4 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

ssh
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.useLocalServer setting
  • 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 did not try step 2 of the troubleshooting steps

Remote-SSH Log
Remote-SSH Log

[13:45:30.471] Log Level: 2
[13:45:30.499] SSH Resolver called for "ssh-remote+zllambda-gpu1.csez.zohocorpin.com", attempt 1
[13:45:30.502] remote.SSH.useLocalServer = true
[13:45:30.502] remote.SSH.useExecServer = true
[13:45:30.503] remote.SSH.bindHost = {}
[13:45:30.503] remote.SSH.path = undefined
[13:45:30.503] remote.SSH.configFile = undefined
[13:45:30.503] remote.SSH.useFlock = true
[13:45:30.503] remote.SSH.lockfilesInTmp = false
[13:45:30.503] remote.SSH.localServerDownload = auto
[13:45:30.503] remote.SSH.remoteServerListenOnSocket = false
[13:45:30.503] remote.SSH.defaultExtensions = []
[13:45:30.504] remote.SSH.defaultExtensionsIfInstalledLocally = []
[13:45:30.504] remote.SSH.loglevel = 2
[13:45:30.504] remote.SSH.enableDynamicForwarding = true
[13:45:30.504] remote.SSH.enableRemoteCommand = false
[13:45:30.504] remote.SSH.serverPickPortsFromRange = {}
[13:45:30.504] remote.SSH.serverInstallPath = {}
[13:45:30.504] remote.SSH.permitPtyAllocation = false
[13:45:30.506] remote.SSH.preferredLocalPortRange = undefined
[13:45:30.506] remote.SSH.useCurlAndWgetConfigurationFiles = false
[13:45:30.506] remote.SSH.experimental.chat = false
[13:45:30.506] remote.SSH.experimental.enhancedSessionLogs = false
[13:45:30.506] remote.SSH.httpProxy = {}
[13:45:30.507] remote.SSH.httpsProxy = {}
[13:45:30.516] VS Code version: 1.100.1
[13:45:30.516] Remote-SSH version: remote-ssh@0.120.0
[13:45:30.516] linux x64
[13:45:30.520] SSH Resolver called for host: zllambda-gpu1.csez.zohocorpin.com
[13:45:30.520] Setting up SSH remote "zllambda-gpu1.csez.zohocorpin.com"
[13:45:30.526] Acquiring local install lock: /tmp/vscode-remote-ssh-5d0992b3-install.lock
[13:45:30.530] Looking for existing server data file at /home/veera-14082/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-5d0992b3-91fa95bccb027ece6a968589bb1d662fa9c8e170-0.120.0-es/data.json
[13:45:30.530] No existing data file
[13:45:30.531] Using commit id "91fa95bccb027ece6a968589bb1d662fa9c8e170" and quality "stable" for server
[13:45:30.531] Extensions to install: 
[13:45:30.537] Install and start server if needed
[13:45:30.543] PATH: /home/veera-14082/.poetry/bin:/home/veera-14082/anaconda3/envs/zenv/bin:/home/veera-14082/anaconda3/condabin:/home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/veera-14082/.poetry/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin
[13:45:30.543] Checking ssh with "ssh -V"
[13:45:30.553] > OpenSSH_8.9p1 Ubuntu-3ubuntu0.13, OpenSSL 3.0.2 15 Mar 2022

[13:45:30.556] askpass server listening on /run/user/1001/vscode-ssh-askpass-8bb165b5e679a68eefe0f18d1bb98c6fb5413fb9.sock
[13:45:30.557] Spawning local server with {"serverId":1,"ipcHandlePath":"/run/user/1001/vscode-ssh-askpass-a05e04d7c4e91ea27b69c9742e984dfa37ca6fd4.sock","sshCommand":"ssh","sshArgs":["-v","-T","-D","36657","-o","ConnectTimeout=15","zllambda-gpu1.csez.zohocorpin.com"],"serverDataFolderName":".vscode-server","dataFilePath":"/home/veera-14082/.config/Code/User/globalStorage/ms-vscode-remote.remote-ssh/vscode-ssh-host-5d0992b3-91fa95bccb027ece6a968589bb1d662fa9c8e170-0.120.0-es/data.json"}
[13:45:30.557] Local server env: {"SSH_AUTH_SOCK":"/run/user/1001/keyring/ssh","SHELL":"/bin/bash","DISPLAY":":0","ELECTRON_RUN_AS_NODE":"1","SSH_ASKPASS":"/home/veera-14082/.vscode/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/local-server/askpass.sh","VSCODE_SSH_ASKPASS_NODE":"/usr/share/code/code","VSCODE_SSH_ASKPASS_EXTRA_ARGS":"","VSCODE_SSH_ASKPASS_MAIN":"/home/veera-14082/.vscode/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/askpass-main.js","VSCODE_SSH_ASKPASS_HANDLE":"/run/user/1001/vscode-ssh-askpass-8bb165b5e679a68eefe0f18d1bb98c6fb5413fb9.sock"}
[13:45:30.561] Spawned 2520020
[13:45:30.562] Using connect timeout of 17 seconds
[13:45:30.646] > local-server-1> Running ssh connection command: ssh -v -T -D 36657 -o ConnectTimeout=15 zllambda-gpu1.csez.zohocorpin.com
[13:45:30.649] > local-server-1> Spawned ssh, pid=2520028
[13:45:30.652] stderr> OpenSSH_8.9p1 Ubuntu-3ubuntu0.13, OpenSSL 3.0.2 15 Mar 2022
[13:45:42.220] stderr> debug1: Server host key: ssh-ed25519 SHA256:Ai52npm2jasAdUxRV0zshg0SJvxeQB8ObaQaSVxkK0E
[13:45:47.564] Terminating local server
[13:45:47.566] Resolver error: Error: Connecting with SSH timed out
	at y.Timeout (/home/veera-14082/.vscode/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/extension.js:2:744895)
	at Timeout._onTimeout (/home/veera-14082/.vscode/extensions/ms-vscode-remote.remote-ssh-0.120.0/out/extension.js:2:805797)
	at listOnTimeout (node:internal/timers:581:17)
	at process.processTimers (node:internal/timers:519:7)
[13:45:47.571] ------




[13:45:47.571]  ---------- [Session Summary] ----------- 
[13:45:47.571] [Timeout]: Error: Timeout (Connecting with SSH timed out)
[13:45:47.571]  ---------------------------------------- 
[13:45:47.574] Local server exit: 15

Expected Behavior

Connection

Actual Behavior

Not connected

Steps To Reproduce

Connection

Anything else?

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the connection through VS Code and compare it with the generated SSH command from the troubleshooting wiki. Inspect the Remote-SSH: Show Log output around the SSH timeout and verify the expected result is a successful connection to the remote host.

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.