Search code examples
linuxsshvisual-studio-codevscode-remote

After Establishing a Remote-ssh connection to the server, it appears the vscode-server does not finish the installation


I am using the Remote-ssh extension with VS Code (Insiders) to connect to an AWS Linux server. This connection is authenticated with a SSH key stored on my local machine. After I connect, a terminal titled "install" is opened and the following is the output:

685ad2d6d150: running
Acquiring lock on /home/ubuntu/.vscode-server-insiders/bin/45aafeb326d0d3d56cbc9e2932f87e368dbf652d/vscode-remote-lock.ubuntu.45aafeb326d0d3d56cbc9e2932f87e368dbf652d
Found existing installation at /home/ubuntu/.vscode-server-insiders/bin/45aafeb326d0d3d56cbc9e2932f87e368dbf652d...
Checking /home/ubuntu/.vscode-server-insiders/.45aafeb326d0d3d56cbc9e2932f87e368dbf652d.log and /home/ubuntu/.vscode-server-insiders/.45aafeb326d0d3d56cbc9e2932f87e368dbf652d.pid for a running server
Looking for server with pid: 79962
Found running server...

*
* Reminder: You may only use this software with Visual Studio family products,
* as described in the license (https://go.microsoft.com/fwlink/?linkid=2077057)
*

Checking server status on port 45093 with wget
685ad2d6d150: start
SSH_AUTH_SOCK====
DISPLAY====
webUiAccessToken====
listeningOn==45093==
osReleaseId==ubuntu==
arch==x86_64==
tmpDir==/run/user/1000==
platform==linux==
unpackResult====
didLocalDownload==0==
downloadTime====
installTime====
extInstallTime====
serverStartTime====
connectionToken==86be68cd-ee77-49dc-ae26-5c1521022c2c==
685ad2d6d150: end

(this print is after the initial install and reconnecting to the server, but the output is about the same)

Afterwards the "install" terminal remains open. If I close it, then it seems my connection is interrupted and trying to open a file, or another Bash terminal reopens the install terminal.

If I open a direct connection to the user directory, I get the following warning:

Screenshot of warning icon

Extentions want to make the following changes to the terminal's environment

If I open a connection from within a git repository directory I don't get that warning.

My question is, is the vscode-server-insiders "install" finished? Is the "install" terminal supposed to remain open the entire time? If I close the "install" terminal, is it supposed to break the connection and reopen? Is the warning that shows up because I am not in a git repository directory? Should I be getting that warning? Or is this all the normal process of remotely connecting via ssh with VS Code?

Sorry, I have Googled, but have not seen anything referencing that this is the regular behavior of using the Remote-ssh extension. I feel like if the vscode-server-insiders installation was completed that the "install" output in the terminal should go away. But it seems to hang after the connectionToken==86be68cd-ee77-49dc-ae26-5c1521022c2c==4134564d6c5d: end output. Just trying to figure out if this is indeed what is supposed to happen.

UPDATE 1: As mentioned by @VonC, it appears that the install process is indeed hanging. I had already looked at the Troubleshooting hanging or failing connections documentation and added "remote.SSH.showLoginTerminal": true, "remote.SSH.useLocalServer": false to my settings file, but it doesn't seem to make a difference. Nothing shows up in the output log for the Remote-ssh extension. There are a lot of pty errors in the developer's console, but nothing else that looks like it could be making the install process hang. So, does anyone have any clues as to why the install process is hanging?

UPDATE 2: Setting remote.SSH.showLoginTerminal to false doesn't show the "install" terminal at all. But is this hiding the terminal and the issue, or is this actually solving the issue? It appears that the "Checking server status..." step was what was hanging in the process, but I could still use a bash terminal and open files. I can also still do all that with remote.SSH.showLoginTerminal set to false. I am using a ssh key and I am not using a password to login. I guess now I am more curious as to what is really going on here and making sure that there are no problems that are just being hidden by this setting.


Solution

  • The "Extensions want to make changes" part does not seem linked to microsoft/vscode-remote-release, but is more a VSCode warning, as shown in microsoft/vscode issue 108940, still opened in issue 96699.

    Closing the install terminal does not terminate the session, but check settings, as seen in the "Troubleshooting hanging or failing connections": something like "remote.SSH.showLoginTerminal" could have bearing on what you see.

    The OP Charles Williams confirms having set "remote.SSH.showLoginTerminal" to false, which seems to resolve (or hide?) the issue.