microsoft / vscode-remote-release

Visual Studio Code Remote Development: Open any folder in WSL, in a Docker container, or on a remote machine using SSH and take advantage of VS Code's full feature set.
https://aka.ms/vscode-remote
Other
3.63k stars 282 forks source link

Connection error: Unauthorized client refused: auth mismatch #7008

Closed MH-Leon closed 1 year ago

MH-Leon commented 2 years ago

Issue Type: Bug

I encountered an occasional but serious problem when using the "Remote-ssh" extension: The extension connected to my Ubuntu server, but it said "Unable to get remote environment" and reported an error "(Error: Connection error: Unauthorized client refused: auth mismatch)"(I am connecting to my server entity that is not a container).But I was able to connect to the server using xshell via ssh without any problems.

One of the server-side error logs. [2022-08-01 11:00:12.410] [remoteagent] [error] [127.0.0.1][c872948c] Unauthorized client refused: auth mismatch. [2022-08-01 11:00:12.904] [remoteagent] [error] [127.0.0.1][154cb3a7] Unauthorized client refused: auth mismatch.

This problem was encountered after I updated my vscode version from 1.57.0 to 1.69.2. I tried connecting to my two servers, one Ubuntu 18.0 and the other Ubuntu 20.0, and both had the same problem and reported the exact same error, and both used the commit_id "3b889b090b5ad5793f524b5d1d39fda662b96a2a " vscode-server, this commit_id is exactly the same as my local vscode running on windows 11. Also tried using "kill vscode server on host..." and then reinstalling, then uninstalling and reinstalling the plugin, restarting the local device, restarting the server, and connecting again, but that didn't solve the problem.

Please tell me how to solve this problem.

Extension version: 0.84.0 VS Code version: Code 1.69.2 (3b889b090b5ad5793f524b5d1d39fda662b96a2a, 2022-07-18T16:12:52.460Z) OS version: Windows_NT x64 10.0.22000 Restricted Mode: No

System Info |Item|Value| |---|---| |CPUs|11th Gen Intel(R) Core(TM) i5-1155G7 @ 2.50GHz (8 x 2496)| |GPU Status|2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_renderer: enabled_on
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled| |Load (avg)|undefined| |Memory (System)|15.79GB (7.03GB free)| |Process Argv|--crash-reporter-id 0f58ba56-3937-4ee0-b289-c149ea127c45| |Screen Reader|no| |VM|67%|
A/B Experiments ``` vsliv368cf:30146710 vsreu685:30147344 python383:30185418 vspor879:30202332 vspor708:30202333 vspor363:30204092 vswsl492:30256859 vslsvsres303:30308271 pythonvspyl392:30443607 vserr242cf:30382550 pythontb:30283811 vsjup518:30340749 pythonvspyt551cf:30345471 pythonptprofiler:30281270 vsdfh931:30280409 vshan820:30294714 vstes263:30335439 pythondataviewer:30285071 vscod805:30301674 binariesv615:30325510 bridge0708:30335490 bridge0723:30353136 cmake_vspar411cf:30525689 vsaa593cf:30376535 vsc1dst:30438360 pythonvs932:30410667 wslgetstarted:30449410 vscscmwlcmt:30465135 cppdebug:30492333 pylanb8912cf:30529770 vsclangdf:30486550 c4g48928:30535728 ```
jfpaccini commented 2 years ago

I have had the same problems since .. ages now. There is a long thread here with no satisfactory solution.

https://github.com/microsoft/vscode-remote-release/issues/5290

I still have a windows 10 box from which there is no such problem

MH-Leon commented 2 years ago

I have had the same problems since .. ages now. There is a long thread here with no satisfactory solution.

5290

I still have a windows 10 box from which there is no such problem

I installed vscode and ssh extension on a win10 device today, and also deliberately turned off Settings Sync, and still had the problem after the first few normal links. And yesterday on a win11 device that could not connect, today there is completely back to normal. They are both still in the same LAN. I also tried to lower the version of Remote-Containers to v0.224.3, but it didn't work in my environment (´Д` )

xingzhis commented 2 years ago

I had the same problem on macOS Catalina. Downgrading to VS code 1.68.1 solved it.

PLCreed commented 2 years ago

I have had the same problems since .. ages now. There is a long thread here with no satisfactory solution.

5290

I still have a windows 10 box from which there is no such problem

I installed vscode and ssh extension on a win10 device today, and also deliberately turned off Settings Sync, and still had the problem after the first few normal links. And yesterday on a win11 device that could not connect, today there is completely back to normal. They are both still in the same LAN. I also tried to lower the version of Remote-Containers to v0.224.3, but it didn't work in my environment (´Д` )

I had the same problem, but I found a MAJIC way to connnet to the remote successfully. https://github.com/microsoft/vscode-remote-release/issues/5290#issuecomment-1216336424

tanhakabir commented 2 years ago

Sorry about this. Could you share your Remote SSH logs? Yes this could be a duplicate of #5290

MH-Leon commented 2 years ago

自从.. 年龄以来,我也遇到了同样的问题。 这里有一个长线程,没有令人满意的解决方案。
#5290 我还有一个没有此类问题的 Windows 10 盒子

今天在win10设备上安装了vscode和ssh扩展,还特意关闭了Settings Sync,前几个正常链接后还是有问题。 而昨天在win11设备上无法连接,今天就完全恢复正常了。 他们仍然在同一个局域网中。 我还尝试将 Remote-Containers 的版本降低到 v0.224.3,但它在我的环境中不起作用(´Д`)

我遇到了同样的问题,但我找到了一种成功连接到远程的 MAJIC 方法。 第5290章(评论)

Amazing, but it really works(゜ロ゜)

MH-Leon commented 2 years ago

Sorry about this. Could you share your Remote SSH logs? Yes this could be a duplicate of #5290

It looks like the same issue, discussed in #5290 results in downgrading the Remote-Containers extension, but I don't use it.

the Remote SSH logs `[11:30:47.007] Log Level: 2 [11:30:47.008] remote-ssh@0.84.0 [11:30:47.008] win32 x64 [11:30:47.020] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d", attempt 1 [11:30:47.021] "remote.SSH.useLocalServer": false [11:30:47.021] "remote.SSH.showLoginTerminal": true [11:30:47.021] "remote.SSH.remotePlatform": {"Leon_ubuntu20":"linux","SW-lunwenkang":"linux","SW_chenyvtong":"linux"} [11:30:47.021] "remote.SSH.path": C:\Windows\System32\OpenSSH\ssh.exe [11:30:47.021] "remote.SSH.configFile": C:\Users\SW.ssh\config [11:30:47.021] "remote.SSH.useFlock": true [11:30:47.021] "remote.SSH.lockfilesInTmp": false [11:30:47.021] "remote.SSH.localServerDownload": auto [11:30:47.021] "remote.SSH.remoteServerListenOnSocket": false [11:30:47.021] "remote.SSH.showLoginTerminal": true [11:30:47.021] "remote.SSH.defaultExtensions": [] [11:30:47.022] "remote.SSH.loglevel": 2 [11:30:47.022] "remote.SSH.enableDynamicForwarding": true [11:30:47.022] "remote.SSH.enableRemoteCommand": false [11:30:47.022] "remote.SSH.serverPickPortsFromRange": {} [11:30:47.022] "remote.SSH.serverInstallPath": {} [11:30:47.024] SSH Resolver called for host: Leon_ubuntu20 [11:30:47.024] Setting up SSH remote "Leon_ubuntu20" [11:30:47.028] Using commit id "6d9b74a70ca9c7733b29f0456fd8195364076dda" and quality "stable" for server [11:30:47.030] Install and start server if needed [11:30:47.031] Checking ssh with "C:\Windows\System32\OpenSSH\ssh.exe -V" [11:30:47.060] > OpenSSH_for_W [11:30:47.060] > indows_8.1p1, LibreSSL 3.0.2

[11:30:47.065] Using SSH config file "C:\Users\SW.ssh\config" [11:30:47.065] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 9547 -F "C:\Users\SW.ssh\config" "Leon_ubuntu20" bash [11:30:47.067] Terminal shell path: C:\Windows\System32\cmd.exe [11:30:49.289] > 45ff52973018: running

]0;C:\Windows\System32\cmd.exe [11:30:49.289] Got some output, clearing connection timeout [11:30:49.309] > 45ff52973018: running

[11:30:49.338] > Acquiring lock on /root/.vscode-serve er/bin/6d9b74a70ca9c7733b29f0456fd8195 5364076dda/vscode-remote-lock.root.6d9 9b74a70ca9c7733b29f0456fd8195364076dda [11:30:49.348] > Found existing installation at /root/ /.vscode-server/bin/6d9b74a70ca9c7733b b29f0456fd8195364076dda... Checking /root/.vscode-server/.6d9b74 4a70ca9c7733b29f0456fd8195364076dda.lo og and /root/.vscode-server/.6d9b74a70 0ca9c7733b29f0456fd8195364076dda.pid f for a running server Looking for server with pid: 1098107 [11:30:49.355] > [11:30:49.368] > Starting server with command... /root t/.vscode-server/bin/6d9b74a70ca9c7733 3b29f0456fd8195364076dda/bin/code-serv ver --start-server --host=127.0.0.1 -- -accept-server-license-terms --enable- -remote-auto-shutdown --port=0 --telem metry-level all &> "/root/.vscode-se erver/.6d9b74a70ca9c7733b29f0456fd8195 5364076dda.log" < /dev/null printenv: SHELL=/bin/bash LANGUAGE=zh_CN:zh PWD=/root LOGNAME=root XDG_SESSION_TYPE=tty MOTD_SHOWN=pam HOME=/root LANG=zh_CN.UTF-8 VSCODE_AGENT_FOLDER=/root/.vscode e-server SSH_CONNECTION=113.99.130.163 218 87 172.21.89.29 22 XDG_SESSION_CLASS=user USER=root SHLVL=0 XDG_SESSION_ID=32339 XDG_RUNTIME_DIR=/run/user/0
SSH_CLIENT=113.99.130.163 2187 22 PATH=/usr/local/sbin:/usr/local/b bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr r/games:/usr/local/games:/snap/bin
DBUS_SESSION_BUSADDRESS=unix:pat th=/run/user/0/bus =/usr/bin/printenv [11:30:49.380] > Removing old logfile at /root/.vscode e-server/.6d9b74a70ca9c7733b29f0456fd8 8195364076dda.log Spawned remote server: 1101736
[11:30:49.388] > [11:30:49.396] > Waiting for server log... [11:30:49.404] > [11:30:49.440] > Waiting for server log... [11:30:49.515] >
*

  • Reminder: You may only use this sof ftware with Visual Studio family produ ucts,
  • as described in the license (https: ://go.microsoft.com/fwlink/?linkid=207 77057)

[11:30:49.530] > [11:30:49.547] > 45ff52973018: start SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== [11:30:49.552] > downloadTime==== installTime==== extInstallTime==== serverStartTime==139== connectionToken==039832a1-a9c9-48ed-8 8872-928a1d807d21== 45ff52973018: end [11:30:49.552] Received install output: SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==139== connectionToken==039832a1-a9c9-48ed-8 8872-928a1d807d21==

[11:30:49.553] Remote server is listening on 33829 [11:30:49.553] Parsed server configuration: {"serverConfiguration":{"remoteListeningOn":{"port":33829},"osReleaseId":"ubuntu","arch":"x86_64","webUiAccessToken":"","sshAuthSock":"","display":"","tmpDir":"/run/user/0","platform":"linux","connectionToken":"111111a1-a1a1-11aa-11111-111a1a111a11"},"serverStartTime":139,"installUnpackCode":""} [11:30:49.554] Starting forwarding server. localPort 9562 -> socksPort 9547 -> remotePort 33829 [11:30:49.555] Forwarding server listening on 9562 [11:30:49.555] Waiting for ssh tunnel to be ready [11:30:49.556] [Forwarding server 9562] Got connection 0 [11:30:49.557] Tunneled 33829 to local port 9562 [11:30:49.558] Resolved "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d" to "127.0.0.1:9562" [11:30:49.564] ------

[11:30:49.578] > [11:30:49.589] [Forwarding server 9562] Got connection 1 [11:30:49.856] [Forwarding server 9562] Got connection 2 [11:30:50.194] ------

[11:30:50.194] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d", attempt 2, (Reconnection) [11:30:50.195] SSH Resolver called for host: Leon_ubuntu20 [11:30:50.195] Setting up SSH remote "Leon_ubuntu20" [11:30:50.196] Using commit id "6d9b74a70ca9c7733b29f0456fd8195364076dda" and quality "stable" for server [11:30:50.197] Install and start server if needed [11:30:50.198] Using SSH config file "C:\Users\SW.ssh\config" [11:30:50.198] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 9569 -F "C:\Users\SW.ssh\config" "Leon_ubuntu20" bash [11:30:50.199] Terminal shell path: C:\Windows\System32\cmd.exe [11:30:50.303] > 45ff52973018: end

[11:30:50.804] > 505e98214eb5: running ]0;C:\Windows\System32\cmd.exe [11:30:50.804] Got some output, clearing connection timeout [11:30:50.822] > 505e98214eb5: running

[11:30:50.966] > Acquiring lock on /root/.vscod de-server/bin/6d9b74a70ca9c7733 3b29f0456fd8195364076dda/vscode e-remote-lock.root.6d9b74a70ca9 9c7733b29f0456fd8195364076dda
[11:30:51.001] > Found existing installation at t /root/.vscode-server/bin/6d9b b74a70ca9c7733b29f0456fd8195364 4076dda... Checking /root/.vscode-server/ /.6d9b74a70ca9c7733b29f0456fd81 195364076dda.log and /root/.vsc code-server/.6d9b74a70ca9c7733b b29f0456fd8195364076dda.pid for r a running server [11:30:51.010] > Looking for server with pid: 1 1101736 [11:30:51.100] > Found running server...

*

  • Reminder: You may only use t this software with Visual Studi io family products,
  • as described in the license (https://go.microsoft.com/fwli ink/?linkid=2077057)

[11:30:51.122] > [11:30:51.178] > Checking server status on port t 33829 with wget [11:30:51.244] > 505e98214eb5: start SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==
505e98214eb5: end [11:30:51.244] Received install output: SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==

[11:30:51.244] Remote server is listening on 33829 [11:30:51.244] Parsed server configuration: {"serverConfiguration":{"remoteListeningOn":{"port":33829},"osReleaseId":"ubuntu","arch":"x86_64","webUiAccessToken":"","sshAuthSock":"","display":"","tmpDir":"/run/user/0","platform":"linux","connectionToken":"111111a1-a1a11-11aa-1111-111a1a111a11"},"installUnpackCode":""} [11:30:51.246] Starting forwarding server. localPort 9573 -> socksPort 9569 -> remotePort 33829 [11:30:51.246] Forwarding server listening on 9573 [11:30:51.246] Waiting for ssh tunnel to be ready [11:30:51.247] [Forwarding server 9573] Got connection 0 [11:30:51.247] Tunneled 33829 to local port 9573 [11:30:51.247] Resolved "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d" to "127.0.0.1:9573" [11:30:51.249] ------

[11:30:51.266] [Forwarding server 9573] Got connection 1 [11:30:51.408] [Forwarding server 9573] Got connection 2 [11:30:51.416] ------

[11:30:51.416] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d", attempt 3, (Reconnection) [11:30:51.417] SSH Resolver called for host: Leon_ubuntu20 [11:30:51.417] Setting up SSH remote "Leon_ubuntu20" [11:30:51.418] Using commit id "6d9b74a70ca9c7733b29f0456fd8195364076dda" and quality "stable" for server [11:30:51.419] Install and start server if needed [11:30:51.421] Using SSH config file "C:\Users\SW.ssh\config" [11:30:51.421] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 9589 -F "C:\Users\SW.ssh\config" "Leon_ubuntu20" bash [11:30:51.422] Terminal shell path: C:\Windows\System32\cmd.exe [11:30:51.565] > 505e98214eb5: end

[11:30:51.970] > 6b87a0b81fe9: running ]0;C:\Windows\System32\cmd.exe [11:30:51.970] Got some output, clearing connection timeout [11:30:51.994] > 6b87a0b81fe9: running

[11:30:52.004] > Acquiring lock on /root/.vscod de-server/bin/6d9b74a70ca9c7733 3b29f0456fd8195364076dda/vscode e-remote-lock.root.6d9b74a70ca9 9c7733b29f0456fd8195364076dda
[11:30:52.014] > Found existing installation at t /root/.vscode-server/bin/6d9b b74a70ca9c7733b29f0456fd8195364 4076dda... Checking /root/.vscode-server/ [11:30:52.021] > /.6d9b74a70ca9c7733b29f0456fd81 195364076dda.log and /root/.vsc code-server/.6d9b74a70ca9c7733b b29f0456fd8195364076dda.pid for r a running server Looking for server with pid: 1 1101736 [11:30:52.065] > Found running server...

*

  • Reminder: You may only use t this software with Visual Studi io family products,
  • as described in the license (https://go.microsoft.com/fwli ink/?linkid=2077057)

Checking server status on port t 33829 with wget 6b87a0b81fe9: start SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==
6b87a0b81fe9: end [11:30:52.065] Received install output: SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==

[11:30:52.066] Remote server is listening on 33829 [11:30:52.066] Parsed server configuration: {"serverConfiguration":{"remoteListeningOn":{"port":33829},"osReleaseId":"ubuntu","arch":"x86_64","webUiAccessToken":"","sshAuthSock":"","display":"","tmpDir":"/run/user/0","platform":"linux","connectionToken":"111111a1-a1a11-11aa-1111-111a1a111a11"},"installUnpackCode":""} [11:30:52.067] Starting forwarding server. localPort 9594 -> socksPort 9589 -> remotePort 33829 [11:30:52.068] Forwarding server listening on 9594 [11:30:52.068] Waiting for ssh tunnel to be ready [11:30:52.069] [Forwarding server 9594] Got connection 0 [11:30:52.069] Tunneled 33829 to local port 9594 [11:30:52.070] Resolved "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d" to "127.0.0.1:9594" [11:30:52.072] ------

[11:30:52.095] [Forwarding server 9594] Got connection 1 [11:30:52.100] > [11:30:52.123] [Forwarding server 9594] Got connection 2 [11:30:52.138] ------

[11:30:52.138] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d", attempt 4, (Reconnection) [11:30:52.139] SSH Resolver called for host: Leon_ubuntu20 [11:30:52.139] Setting up SSH remote "Leon_ubuntu20" [11:30:52.141] Using commit id "6d9b74a70ca9c7733b29f0456fd8195364076dda" and quality "stable" for server [11:30:52.142] Install and start server if needed [11:30:52.144] Using SSH config file "C:\Users\SW.ssh\config" [11:30:52.144] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 9601 -F "C:\Users\SW.ssh\config" "Leon_ubuntu20" bash [11:30:52.146] Terminal shell path: C:\Windows\System32\cmd.exe [11:30:52.256] > 6b87a0b81fe9: end

[11:30:52.675] > c9bafb97abf5: running ]0;C:\Windows\System32\cmd.exe [11:30:52.675] Got some output, clearing connection timeout [11:30:52.693] > c9bafb97abf5: running

[11:30:52.711] > Acquiring lock on /root/.vscod de-server/bin/6d9b74a70ca9c7733 3b29f0456fd8195364076dda/vscode e-remote-lock.root.6d9b74a70ca9 9c7733b29f0456fd8195364076dda
[11:30:52.718] > Found existing installation at t /root/.vscode-server/bin/6d9b b74a70ca9c7733b29f0456fd8195364 4076dda... Checking /root/.vscode-server/ /.6d9b74a70ca9c7733b29f0456fd81 195364076dda.log and /root/.vsc code-server/.6d9b74a70ca9c7733b b29f0456fd8195364076dda.pid for r a running server Looking for server with pid: 1 1101736 [11:30:52.727] > [11:30:52.742] > Found running server...

*

  • Reminder: You may only use t this software with Visual Studi io family products,
  • as described in the license (https://go.microsoft.com/fwli ink/?linkid=2077057)

[11:30:52.751] > Checking server status on port t 33829 with wget [11:30:52.761] > c9bafb97abf5: start SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 [11:30:52.767] > 9-48ed-8872-928a1d807d21==
c9bafb97abf5: end [11:30:52.767] Received install output: SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==

[11:30:52.767] Remote server is listening on 33829 [11:30:52.767] Parsed server configuration: {"serverConfiguration":{"remoteListeningOn":{"port":33829},"osReleaseId":"ubuntu","arch":"x86_64","webUiAccessToken":"","sshAuthSock":"","display":"","tmpDir":"/run/user/0","platform":"linux","connectionToken":"111111a1-a1a11-11aa-1111-111a1a111a11"},"installUnpackCode":""} [11:30:52.770] Starting forwarding server. localPort 9625 -> socksPort 9601 -> remotePort 33829 [11:30:52.770] Forwarding server listening on 9625 [11:30:52.771] Waiting for ssh tunnel to be ready [11:30:52.772] [Forwarding server 9625] Got connection 0 [11:30:52.773] Tunneled 33829 to local port 9625 [11:30:52.774] Resolved "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d" to "127.0.0.1:9625" [11:30:52.775] ------

[11:30:52.776] > [11:30:52.791] [Forwarding server 9625] Got connection 1 [11:30:53.039] [Forwarding server 9625] Got connection 2 [11:30:53.045] ------

[11:30:53.045] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d", attempt 5, (Reconnection) [11:30:53.046] SSH Resolver called for host: Leon_ubuntu20 [11:30:53.046] Setting up SSH remote "Leon_ubuntu20" [11:30:53.047] Using commit id "6d9b74a70ca9c7733b29f0456fd8195364076dda" and quality "stable" for server [11:30:53.048] Install and start server if needed [11:30:53.051] Using SSH config file "C:\Users\SW.ssh\config" [11:30:53.051] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 9632 -F "C:\Users\SW.ssh\config" "Leon_ubuntu20" bash [11:30:53.052] Terminal shell path: C:\Windows\System32\cmd.exe [11:30:53.186] > c9bafb97abf5: end

[11:30:53.603] > c88d5f4656df: running ]0;C:\Windows\System32\cmd.exe [11:30:53.603] Got some output, clearing connection timeout [11:30:53.623] > c88d5f4656df: running

[11:30:53.641] > Acquiring lock on /root/.vscod de-server/bin/6d9b74a70ca9c7733 3b29f0456fd8195364076dda/vscode e-remote-lock.root.6d9b74a70ca9 9c7733b29f0456fd8195364076dda
[11:30:53.643] > Found existing installation at t /root/.vscode-server/bin/6d9b b74a70ca9c7733b29f0456fd8195364 4076dda... Checking /root/.vscode-server/ /.6d9b74a70ca9c7733b29f0456fd81 195364076dda.log and /root/.vsc code-server/.6d9b74a70ca9c7733b b29f0456fd8195364076dda.pid for r a running server Looking for server with pid: 1 1101736 [11:30:53.653] > [11:30:53.661] > Found running server...

*

  • Reminder: You may only use t this software with Visual Studi io family products, [11:30:53.667] >
  • as described in the license (https://go.microsoft.com/fwli ink/?linkid=2077057)

Checking server status on port t 33829 with wget [11:30:53.693] > [11:30:53.703] > c88d5f4656df: start SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==
c88d5f4656df: end [11:30:53.704] Received install output: SSH_AUTH_SOCK==== DISPLAY==== webUiAccessToken==== listeningOn==33829== osReleaseId==ubuntu== arch==x86_64== tmpDir==/run/user/0== platform==linux== unpackResult==== didLocalDownload==0== downloadTime==== installTime==== extInstallTime==== serverStartTime==== connectionToken==039832a1-a9c9 9-48ed-8872-928a1d807d21==

[11:30:53.704] Remote server is listening on 33829 [11:30:53.704] Parsed server configuration: {"serverConfiguration":{"remoteListeningOn":{"port":33829},"osReleaseId":"ubuntu","arch":"x86_64","webUiAccessToken":"","sshAuthSock":"","display":"","tmpDir":"/run/user/0","platform":"linux","connectionToken":"111111a1-a1a11-11aa-1111-111a1a111a11"},"installUnpackCode":""} [11:30:53.709] Starting forwarding server. localPort 9636 -> socksPort 9632 -> remotePort 33829 [11:30:53.710] Forwarding server listening on 9636 [11:30:53.710] Waiting for ssh tunnel to be ready [11:30:53.711] [Forwarding server 9636] Got connection 0 [11:30:53.712] Tunneled 33829 to local port 9636 [11:30:53.712] Resolved "ssh-remote+7b22686f73744e616d65223a224c656f6e5f7562756e74753230227d" to "127.0.0.1:9636" [11:30:53.714] ------

[11:30:53.735] [Forwarding server 9636] Got connection 1 [11:30:53.736] > [11:30:53.766] [Forwarding server 9636] Got connection 2 [11:30:56.992] > 45ff52973018: end

[11:30:56.992] > 505e98214eb5: end

[11:30:56.993] > 6b87a0b81fe9: end

[11:30:56.993] > c9bafb97abf5: end

[11:30:56.993] > c88d5f4656df: end

`

roblourens commented 1 year ago

Is anyone still seeing the "auth mismatch" message with all latest versions?

jfpaccini commented 1 year ago

unfortunately, yes.. image

version 1.74.0

roblourens commented 1 year ago

I'm wondering whether this is related to the background connection terminal apparently being narrow so the install result wrapped and put newlines in the connection token. Does setting "remote.SSH.useLocalServer": true (must be in your settings.json) help?

And I wonder whether your window is narrow, or whether opening the terminal pane as the connection process starts helps it.

jfpaccini commented 1 year ago

Got it !

Indeed, opening the terminal pane large enough to avoid line break fixes the issue. Narrow terminal pane triggers the problem.

At least this is an explanation and a workaround. Thanks 😉

roblourens commented 1 year ago

Great! We have this issue for that: https://github.com/microsoft/vscode-remote-release/issues/5818

I will close this against that one since it is a little more specific. I assume that's the core issue for everyone here. If someone has a lot showing this error without connectionToken wrapping in the log, we can investigate that.