robrechtme
robrechtme

Reputation: 98

Visual Studio Code Remote - SSH connection failure

So I've been able to connect over SSH to the server using a shell, and now I'm trying to use Visual Studio Code Remote - SSH. The SSH connection seems successful but then I get prompted with "Could not establish connection to ... . The VS Code Server failed to start."

Any ideas what the problem might be?

[14:39:44.369] > 
Server did not start successfully. Full server log >>>
/users/XXX/.vscode-server/bin/f359dd69833dd8800b54d458f6d37ab7c78df520/server.sh: line 12: 26789 
Aborted                 "$ROOT/node" ${INSPECT:-} "$ROOT/out/vs/server/main.js" "$@"
[14:26:33.056]
<<< End of server log
b65f23a8e10a##32##
[14:26:33.607] "install" terminal command done
[14:26:33.608] Install terminal quit with output: b65f23a8e10a##32##
[14:26:33.608] Received install output: b65f23a8e10a##32##
[14:26:33.611] Resolver error: The VS Code Server failed to start
[14:26:33.618] TELEMETRY: {"eventName":"resolver","properties":{"outcome":"failure","reason":"ExitCode","askedPw":"0","askedPassphrase":"0","asked2fa":"0","askedHostKey":"0","gotUnrecognizedPrompt":"0","remoteInConfigFile":"1"},"measures":{"resolveAttempts":1,"exitCode":32,"retries":1}}
[14:26:33.622] ------
{
  "eventName":"resolver",
  "properties": { 
    "outcome":"failure",
    "reason":"ExitCode",
    "askedPw":"0",
    "askedPassphrase":"0",
    "asked2fa":"0",
    "askedHostKey":"0",
    "gotUnrecognizedPrompt":"0",
    "remoteInConfigFile":"1"
  },
  "measures":{
    "resolveAttempts":1,
    "exitCode":32,
    "retries":1
  }
}

Thanks!

Upvotes: 3

Views: 6577

Answers (3)

Sha&#39;an
Sha&#39;an

Reputation: 1266

VS Code: File > Preferences > Settings > and search for @ext:ms-vscode-remote.remote-ssh,ms-vscode-remote.remote-ssh-edit config file then type the absolute file path of your ssh config file.

enter image description here

Upvotes: 1

Matus Hmelar
Matus Hmelar

Reputation: 448

I had similar issue, so I try running server.sh from your console that is inside of:

~/.vscode-server/bin/622**************************/server.sh

Mine showed missing libatomic1 library.

Once installed, everything works as it should.

Upvotes: 2

robrechtme
robrechtme

Reputation: 98

Turns out the SSH-server didn't support VS Code for some reason. I solved my problem by creating a ProxyCommand in ~/.ssh/config to another internal machine, which did support VS Code.

Upvotes: 0

Related Questions