Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Remote-SSH Bug]: The VS Code Server failed to start #8342

Closed
3 tasks done
Zecyl opened this issue Apr 8, 2023 · 4 comments
Closed
3 tasks done

[Remote-SSH Bug]: The VS Code Server failed to start #8342

Zecyl opened this issue Apr 8, 2023 · 4 comments
Assignees
Labels
ssh Issue in vscode-remote SSH

Comments

@Zecyl
Copy link

Zecyl commented Apr 8, 2023

Is there an existing issue for this bug?

  • I have searched the existing issues

Required Troubleshooting Steps

  • I have followed these troubleshooting steps
  • I have tried both values of the remote.SSH.useLocalServer setting

Connect Locally

It connects successfully

->

No response

Expected Behavior

The VS Code Server should start and I should be able to use VS Code like normal.

Steps To Reproduce

Using a PC running Windows 11 with VS Code 1.77.1, trying to connect to a Raspberry Pi running Raspberry Pi OS.

  1. Kill the VS Code Server on the Raspberry Pi
  2. Connect using the menu on the left and by clicking on the arrow to the right of the remote SSH
  3. Enter password in prompt

Remote-SSH Log

Remote-SSH Log

[12:19:41.687] > Server did not start successfully. Full server log at /home/ulysses/.vscode-serv
> ver/.b7886d7461186a5eac768481578c1d7ca80e2d21.log >>>
> /home/ulysses/.vscode-server/bin/b7886d7461186a5eac768481578c1d7ca80e2d21/bin/co
> ode-server: 12: /home/ulysses/.vscode-server/bin/b7886d7461186a5eac768481578c1d7c
> ca80e2d21/node: not found
> <<< End of server log
[12:19:41.705] > 
[12:19:41.855] > 4e1fa1f9fd54: start
> exitCode==32==
> listeningOn====
> osReleaseId==raspbian==
> arch==aarch64==
> tmpDir==/run/user/1000==
> platform==linux==
> unpackResult====
> didLocalDownload==0==
> downloadTime====
> installTime====
> extInstallTime====
> serverStartTime==14645==
> 4e1fa1f9fd54: end
[12:19:41.855] Received install output: 
exitCode==32==
listeningOn====
osReleaseId==raspbian==
arch==aarch64==
tmpDir==/run/user/1000==
platform==linux==
unpackResult====
didLocalDownload==0==
downloadTime====
installTime====
extInstallTime====
serverStartTime==14645==

[12:19:41.857] Resolver error: Error: The VS Code Server failed to start
	at m.ServerInstallError (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:584322)
	at f (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:578379)
	at t.handleInstallOutput (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:581404)
	at t.tryInstall (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:681793)
	at async c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:644041
	at async t.withShowDetailsEvent (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:647359)
	at async t.resolve (c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:645091)
	at async c:\Users\ulyss\.vscode\extensions\ms-vscode-remote.remote-ssh-0.98.0\out\extension.js:1:720839
[12:19:41.863] ------

Anything else?

Connecting worked fine until I updated my VS Code to version 1.77.1, then it stopped working.

I already tried killing the server on the Raspberry Pi both through VS Code and by deleting the files manually through local SSH connection.
I also saw #8341 (comment) which seems very similar to me.

@Zecyl Zecyl added the ssh Issue in vscode-remote SSH label Apr 8, 2023
@cdavi014
Copy link

cdavi014 commented Apr 9, 2023

Having the same issue since the update. Any work around? I have a RPi 4 - d03114 8GB.

After re-installing the server, this is what the directory looks like:

drwxr-xr-x   6 pi pi     4096 Apr  9 19:09 .
drwxr-xr-x   3 pi pi     4096 Apr  9 19:08 ..
drwxr-xr-x   4 pi pi     4096 Apr  5 00:21 bin
drwxr-xr-x  33 pi pi     4096 Apr  5 00:21 extensions
-rw-r--r--   1 pi pi    13380 Apr  5 00:19 LICENSE
-rwxr-xr-x   1 pi pi 79252272 Apr  5 00:21 node
drwxr-xr-x 166 pi pi     4096 Apr  5 00:21 node_modules
drwxr-xr-x   3 pi pi     4096 Apr  5 00:21 out
-rw-r--r--   1 pi pi       62 Apr  5 00:19 package.json
-rw-r--r--   1 pi pi    43030 Apr  5 00:20 product.json
-rwxr-xr-x   1 pi pi      240 Apr  5 00:18 server.sh

I believe that it's not supposed to be the server.sh script anymore? Also, when trying to run the node executable:
-bash: ./node: No such file or directory

@cdavi014
Copy link

cdavi014 commented Apr 9, 2023

Ok so it seems I was able to find a workaround provided here.

"I think you're having the same issue as me, but it's actually caused by an update to the pi. VScode is reading the uname -m value, the machine hardware name, which is returning aarch64, and so it is trying to run the 64 bit version of the remote server. In reality, your pi is likely using a armv7l (32 bit) user space. Remove the vscode remote server currently on the pi, then add arm_64bit=0 to /boot/config.txt and restart. If uname -m returns armv7l, then vscode should work again."

  1. Remove vscode server from RPi: rm -rf ~/.vscode-server on the RPi.
  2. Add the arm_64bit=0 to /boot/config.txt and restart as stated above on the RPi.
  3. Start your vscode again from the host and start your remote connection. This will download the correct server.

@daniporr
Copy link

I have exactly the same problem, but in my case the architecture is i686, so the workaround suggested by @cdavi014 does not work:

[...] > Unsupported architecture: i686
[...]
osReleaseId==debian==
arch==i686==
platform==linux==

It is worth noting that until a few days ago VS Code on this machine was working perfectly.

P.S. I know about the problems with 32-bit (i686) systems (for instance, #4026 #1529 #4453), but as I wrote above, it was working until a few days ago (maybe due to #4453?).

@roblourens
Copy link
Member

This is #2947 (comment), although @daniporr I'm not sure whether yours is the same. I'm not aware of anything that would have changed about that configuration- could something have changed with your system configuration?

@github-actions github-actions bot locked and limited conversation to collaborators May 25, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
ssh Issue in vscode-remote SSH
Projects
None yet
Development

No branches or pull requests

4 participants