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]: Remote-SSH 0.106.1 gets stuck downloading the server #8926

Closed
3 tasks done
Tracked by #9044
0x0L opened this issue Sep 7, 2023 · 34 comments
Closed
3 tasks done
Tracked by #9044

[Remote-SSH Bug]: Remote-SSH 0.106.1 gets stuck downloading the server #8926

0x0L opened this issue Sep 7, 2023 · 34 comments
Assignees
Labels
bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority ssh Issue in vscode-remote SSH verified Verification succeeded

Comments

@0x0L
Copy link

0x0L commented Sep 7, 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

->

Everything works ok with 1.81 and previous versions
In 1.82 it gets stuck at (with v0.106.1)

[server] Installing and setting up Visual Studio Code Server...

Expected Behavior

No response

Steps To Reproduce

No response

Remote-SSH Log

Remote-SSH Log

...
[server] checking .../log.txt and .../pid.txt for a running server ...
[server] Installing and setting up Visual Studio Code Server ...

Anything else?

In .vscode-server/.cli.xxx.log I see:

[...] info Disposed of connection to running server.
looking for token xxxx, got Some("xxxxx")
[...] info checking .../log.txt and .../pid.txt for a running server ...
@0x0L 0x0L added the ssh Issue in vscode-remote SSH label Sep 7, 2023
@amirhosseindavoody
Copy link

Same thing happened to me a few minutes ago.

@hugohdz89
Copy link

Same for me

@roblourens
Copy link
Member

Please share the full log from the Remote-SSH output channel.

You should be able to work around it by setting "remote.SSH.useExecServer": false as well

@roblourens roblourens added the info-needed Issue requires more information from poster label Sep 8, 2023
@xubuntutux
Copy link

xubuntutux commented Sep 8, 2023

The "remote.SSH.useExecServer": false workaround did work, as well as downgrading to v.0.102.0.

I've attached the log from my Remote-SSH output channel when using v.0.106.1 of the extension.
remote-ssh-output.txt

Version: 1.82.0 (user setup)
Commit: 8b617bd08fd9e3fc94d14adb8d358b56e3f72314
Date: 2023-09-06T22:07:07.438Z
Electron: 25.8.0
ElectronBuildId: 23503258
Chromium: 114.0.5735.289
Node.js: 18.15.0
V8: 11.4.183.29-electron.0
OS: Windows_NT x64 10.0.19045

@karlhorton
Copy link

I'm seeing the same issue and note that after multiple tries I'm seeing some rogue vscode install processes which need to be manually cleaned, with kill -9.

/home/khorton/.vscode-server/code-8b617bd08fd9e3fc94d14adb8d358b56e3f72314 command-shell --cli-data-dir /home/khorton/.vscode-server/cli --on-port --require-token 7394a9ff424d

@fmg-pete
Copy link

fmg-pete commented Sep 8, 2023

Same issue as above, stuck on "Downloading VS Code Server" after latest update. Windows 10.

@Chaotic-chaos
Copy link

Same issue here, I've turned on the 'Remote.SSH.Local Server Download' into 'always'. But it seems that the code still download *.tar.gz on my remote machine. Waiting for a solution.

@NoReasonKen
Copy link

The "remote.SSH.useExecServer": false work for me.

My situation is, my server uses an old version of tar as default, so the installation of vscode is always failed. My workaround is connected to server and tar the archive file manually with newer tar binary. After that, reconnect vscode.

To be able to use the newer "ExecServer" installation method and set it as default, a document which can explain how to manually install it is needed.

@Brainor
Copy link

Brainor commented Sep 8, 2023

This instruction below is for those who don't have Internet connection on both remote and local machines.

  • set "remote.SSH.useExecServer": false as roblourens suggests. This uses the old .vscode-server/bin/{commit-ID} structure.

or

  • leave remote.SSH.useExecServer as default (true), and here are the steps that need to be done:
  1. download vscode-server-linux-x64.tar.gz from https://update.code.visualstudio.com/commit:{commit_ID}/server-linux-x64/stable as usual.
    1. extract vscode-server-linux-x64.tar.gz to .vscode-server/cli/servers/Stable-{commit_ID}/server so that the bin folder is directly under server folder.
  2. download vscode_cli_alpine_x64_cli.tar.gz from https://update.code.visualstudio.com/commit:{commit_ID}/cli-alpine-x64/stable.
    1. rename the file inside vscode_cli_alpine_x64_cli.tar.gz to code-{commit_ID} and put it (the code-{commit_ID} file) in .vscode-server.

@LsYueh
Copy link

LsYueh commented Sep 8, 2023

Downgrading Remote-SSH to v.0.102.0 for now.

@xhwang-China
Copy link

set "remote.SSH.useExecServer": false can solve my problem

@ladyrick
Copy link

ladyrick commented Sep 8, 2023

Please share the full log from the Remote-SSH output channel.

You should be able to work around it by setting "remote.SSH.useExecServer": false as well

I think this issue happens when the remote server has no access to the internet. Previously, vscode use scp to copy vscode-server to the remote host. Now maybe you are trying to download something on the remote host?
I hope this info will help.
hang

@moritzwilksch
Copy link

remote.SSH.useExecServer": false also solves the problem for me. It seems like the new bootstrapping mode which uses the code cli at ~/.vscode-server/code-COMMIT/ does not honor the "Local Server Download" setting and still tries to fetch from the internet (which times out in my firewalled setup). The old version of scp-ing a tar to ~/.vscode-server/bin/COMMIT/ and unpacking still works.

@EJLearner
Copy link

You should be able to work around it by setting "remote.SSH.useExecServer": false as well

How can I set "remote.SSH.useExecServer" to false?

@xubuntutux
Copy link

I think this issue happens when the remote server has no access to the internet.

Yes, my remote also has no internet access.

@moritzwilksch
Copy link

How can I set "remote.SSH.useExecServer" to false?

Either paste the snippet you mentioned into settings.json or search for "Use Exec Server" in settings and toggle the checkbox

@ThePickledGherkin
Copy link

Setting remote.SSH.useExecServer to False did not work for me.

@ddedov-intel
Copy link

Didn't work for me too. Downgraded my VSCode to 1.81

@jbleahy
Copy link

jbleahy commented Sep 8, 2023

Adding a data point... I also had this same issue, and using the WAR for setting "remote.SSH.useExecServer": false worked for me.

I am using vscode 1.82.0 with remote-ssh v0.106.1. My remote server that I am trying to connect to is also behind a firewall with no access to the outside world. These are the settings I have changed from default for the remote-ssh extension

Setting Value settings.json Equivalent
Remote.SSH: Local Server Download always "remote.SSH.localServerDownload": "always"
Remote.SSH: Use Exec Server disabled "remote.SSH.useExecServer": false

@Zilong-Yuan
Copy link

Add another datapoint. Stucking at Downloading part...... really bad experience after updating

@Zilong-Yuan
Copy link

I think this issue happens when the remote server has no access to the internet.

Yes, my remote also has no internet access.

it should work fine before this update:) , but after this whether it is connected or not, it remains stuck at downloading

@coderpiaobozhe
Copy link

This instruction below is for those who don't have Internet connection on both remote and local machines.

* set "remote.SSH.useExecServer": false as [roblourens](https://github.com/roblourens) [suggests](https://github.com/microsoft/vscode-remote-release/issues/8926#issuecomment-1710915484). This uses the old `.vscode-server/bin/{commit-ID}` structure.

or

* leave `remote.SSH.useExecServer` as default (true), and here are the steps that need to be done:


1. download `vscode-server-linux-x64.tar.gz` from `https://update.code.visualstudio.com/commit:{commit_ID}/server-linux-x64/stable` as usual.
   
   1. extract `vscode-server-linux-x64.tar.gz` to `.vscode-server/cli/servers/Stable-{commit_ID}/server` so that the `bin` folder is directly under `server` folder.

2. download `vscode_cli_alpine_x64_cli.tar.gz` from `https://update.code.visualstudio.com/commit:{commit_ID}/cli-alpine-x64/stable`.
   
   1. rename the file inside `vscode_cli_alpine_x64_cli.tar.gz` to `code-{commit_ID}` and put it (the `code-{commit_ID}` file) in `.vscode-server`.

On my ubuntu desktop, this solution does not work.

I tried it but failed. The codeserver actually found existing installations and did not install new packages anymore. However, after that it continue waiting for server log and finally exited.

Here is the error information:

[00:32:40.853] > Spawned remote CLI: 613700
[00:32:40.857] > Waiting for server log...
......
[00:32:55.292] > Waiting for server log...
[00:32:55.327] > c84ca06a1cee: start
> SSH_AUTH_SOCK====
> DISPLAY====
> listeningOn====
> osReleaseId==ubuntu==
> arch==x86_64==
> vscodeArch==x64==
> bitness==64==
> tmpDir==/run/user/1003==
> platform==linux==
> unpackResult====
> didLocalDownload==0==
> downloadTime====
> installTime====
> serverStartTime==14473==
> c84ca06a1cee: end
[00:32:55.327] Received install output: 
SSH_AUTH_SOCK====
DISPLAY====
listeningOn====
osReleaseId==ubuntu==
arch==x86_64==
vscodeArch==x64==
bitness==64==
tmpDir==/run/user/1003==
platform==linux==
unpackResult====
didLocalDownload==0==
downloadTime====
installTime====
serverStartTime==14473==

[00:32:55.328] Failed to parse remote port from server output
[00:32:55.328] Terminating local server
[00:32:55.330] Resolver error: Error: 
	at g.Create (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:619763)
	at t.handleInstallOutput (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:617166)
	at e (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:677163)
	at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
	at async /home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:699001
	at async t.withShowDetailsEvent (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:702607)
	at async /home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:675584
	at async C (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:672054)
	at async t.resolveWithLocalServer (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:675175)
	at async C (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:696129)
	at async t.resolve (/home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:700003)
	at async /home/coderw/.vscode/extensions/ms-vscode-remote.remote-ssh-0.106.1/out/extension.js:2:883340
[00:32:55.332] ------




[00:32:55.335] Local server exit: 15

@sjaganathan
Copy link

Setting "remote.SSH.useExecServer": false worked for me.

@starball5
Copy link

@roblourens roblourens changed the title [Remote-SSH Bug]: vscode 1.82 update broke remote-ssh [Remote-SSH Bug]: Remote-SSH 0.106.1 doesn't download the server on offline remotes Sep 9, 2023
@roblourens roblourens changed the title [Remote-SSH Bug]: Remote-SSH 0.106.1 doesn't download the server on offline remotes [Remote-SSH Bug]: Remote-SSH 0.106.1 gets stuck downloading the server Sep 9, 2023
@roblourens roblourens added bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority and removed info-needed Issue requires more information from poster labels Sep 9, 2023
@roblourens roblourens added this to the September 2023 milestone Sep 9, 2023
@roblourens
Copy link
Member

That setting is now disabled by default in 0.106.2. On vscode insiders, it is still enabled for testing, but you can disable it manually. Sorry for the churn. Share the log if you have more issues.

@danielfaust
Copy link

That setting is now disabled by default in 0.106.2.

Since downgrading to 1.81.1 will require disabling automatic updates, how can we get notified when this issue is fixed? Will we have to check https://code.visualstudio.com/updates/v1_82 or is there some automated mechanism?

@moritzwilksch
Copy link

Nice, thank you for addressing it this quickly @roblourens, much appreciated! Will this be re-enabled in a future version when the underlying issue has been fixed? I assume y'all want to move everyone to the new bootstrapping mode at some point?

@Fasteroid

This comment was marked as off-topic.

@connor4312
Copy link
Member

Will this be re-enabled in a future version when the underlying issue has been fixed?

Yes, but that's probably not going to happen until the next stable VS Code release

@qumqum22
Copy link

Hello, I had same issue but it's gone after I uninstalled extention that name was "[DEPRECATED] Pair bracket colorizer" on remote server. Maybe it is connected somehow.

@jaroslawhartman
Copy link

jaroslawhartman commented Sep 11, 2023

Thank you for the fix.

But I'm sorry - I couldn't figure it out from the thread - is there a working workaround until getting next stable VSCode release?


Update: similarly to others, "remote.SSH.useExecServer": false not working for me.

Eventually, downgraded as described in Stack Overflow.

@0x0L
Copy link
Author

0x0L commented Sep 11, 2023

@jaroslawhartman

"remote.SSH.useExecServer": false

At least that worked for me

@wmorellato
Copy link

Stopped having the issue with version v0.106.3. Setting remote.SSH.useExecServer is still disabled.

@Joshua0128
Copy link

setting remote.SSH.useExecServer works for me. Finally can start my work.

@amunger amunger added the verified Verification succeeded label Sep 28, 2023
@protection6 protection6 mentioned this issue Sep 29, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Oct 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug important Issue identified as high-priority ssh Issue in vscode-remote SSH verified Verification succeeded
Projects
None yet
Development

No branches or pull requests