Host domain.com
HostName domain.com
User USERNAME
ForwardAgent yes
Does this issue occur when you try this locally?: Yes
Does this issue occur when you try this locally and all extensions are disabled?: All other extensions disabled except "Remote - SSH"
Currently I cannot provide /etc/ssh/sshd_config because it is readable by root only. If needed, I can get it by contacting the system admin.
I have attempted to remove ~/.vscode-server on the remote machine and retry. But it does not solve the problem.
Remote OS bash version: 4.2.46(1)-release
Remote OS glibc version: 2.17-157.el7_3.1
Local OS and Remote OS have NO access to the internet. Extension installed by vsix
Home folder is on NFS. Read the issue #885. Enabled remote.SSH.lockfilesInTmp, but does not solve the problem
Remote host Login shell is /bin/bash. Remove ~/.bashrc and ~/.bash_profile does not help
Install wget from http://gnuwin32.sourceforge.net/packages/wget.htm, on the Host Windows OS. Not work
Remove ~/.vscode, ~/.vscode-server and /run/user/$(id -u)/vscode*. Does not help
The problem is related to no internet access. However, the error message is too confusing for me. I didn't realize that "Could not establish connection. XHR failed" is because downloading vscode-server from internet failed.
Find the solution on https://stackoverflow.com/questions/56718453/using-remote-ssh-in-vscode-on-a-target-machine-that-only-allows-inbound-ssh-co/56781109#56781109
This works for me.
Is this the same as #1242?
This is the same as #1242, but the error message is too confusing, so it takes me a while to realize the root cause of the issue. I suggest to fix the broken error message first.
just encountered this as well on an air-gapped machine.
very confusing error message!
thank you Safetee for the fix! the stack overflow link worked perfectly
You can try this approach https://medium.com/@debugger24/installing-vscode-server-on-remote-machine-in-private-network-offline-installation-16e51847e275
I had this exact issue after upgrading to 1.50.0. Deleting /.vscode-server via SSH did it for me though.
As mentioned above, duplicate of #1242, but considering keeping open to address feedback about improved error message:
The problem is related to no internet access. However, the error message is too confusing for me. I didn't realize that "Could not establish connection. XHR failed" is because downloading vscode-server from internet failed.
Most helpful comment
The problem is related to no internet access. However, the error message is too confusing for me. I didn't realize that "Could not establish connection. XHR failed" is because downloading vscode-server from internet failed.
Find the solution on https://stackoverflow.com/questions/56718453/using-remote-ssh-in-vscode-on-a-target-machine-that-only-allows-inbound-ssh-co/56781109#56781109
This works for me.