Closed chrmarti closed 2 months ago
Also on Windows (since that was my assignment):
[16:04:46.667] stderr> main: line 344: ps: command not found
I've removed all instance of ps
in the version v0.114.2024082715 (pre-release)
+ of the extension.
After upgrading to this version and attempting your repro steps, i'm hitting the same scp
snag as https://github.com/microsoft/vscode/issues/226753 but not seeing an ps
issues.
v0.114.2024082715 wasn't published yet when I was testing. It works now on macOS. Currently having issues with my devbox, can test there when it is back.
It hangs on Windows with Remote-SSH v0.114.2024082901 (pre-release)
:
Log:
[17:11:36.995] Log Level: 2
[17:11:37.003] SSH Resolver called for "ssh-remote+7b22686f73744e616d65223a226c6f63616c686f7374222c2275736572223a22726f6f74227d", attempt 1
[17:11:37.004] "remote.SSH.useLocalServer": false
[17:11:37.004] "remote.SSH.useExecServer": true
[17:11:37.004] "remote.SSH.showLoginTerminal": false
[17:11:37.004] "remote.SSH.remotePlatform": {"dev-server2":"linux","foobar":"windows","win11-server2":"windows"}
[17:11:37.004] "remote.SSH.path": undefined
[17:11:37.004] "remote.SSH.configFile": undefined
[17:11:37.004] "remote.SSH.useFlock": true
[17:11:37.004] "remote.SSH.lockfilesInTmp": false
[17:11:37.005] "remote.SSH.localServerDownload": auto
[17:11:37.005] "remote.SSH.remoteServerListenOnSocket": false
[17:11:37.005] "remote.SSH.showLoginTerminal": false
[17:11:37.005] "remote.SSH.defaultExtensions": []
[17:11:37.005] "remote.SSH.loglevel": 2
[17:11:37.005] "remote.SSH.enableDynamicForwarding": true
[17:11:37.005] "remote.SSH.enableRemoteCommand": false
[17:11:37.005] "remote.SSH.serverPickPortsFromRange": {}
[17:11:37.005] "remote.SSH.serverInstallPath": {}
[17:11:37.005] "remote.SSH.permitPtyAllocation": false
[17:11:37.006] "remote.SSH.preferredLocalPortRange: undefined
[17:11:37.006] "remote.SSH.useCurlAndWgetConfigurationFiles: false
[17:11:37.016] SSH Resolver called for host: root@localhost
[17:11:37.016] Setting up SSH remote "localhost"
[17:11:37.020] VS Code version: 1.93.0-insider
[17:11:37.020] Remote-SSH version: remote-ssh@0.114.2024082901
[17:11:37.020] win32 x64
[17:11:37.022] Using commit id "ff7a154d5e5e9034914f0466420f0f1407f0c95e" and quality "insider" for server
[17:11:37.030] Script variables:
{
"InstallExitCode.24": "AlreadyInProgress",
"InstallExitCode.25": "ServerDownloadFailed",
"InstallExitCode.26": "NoDownloaderAvailable",
"InstallExitCode.27": "UnsupportedArch",
"InstallExitCode.28": "StatusCheckFailed",
"InstallExitCode.29": "NeedInsidersArch",
"InstallExitCode.30": "NoDownloaderAvailableForStatusCheck",
"InstallExitCode.31": "ServerTransferFailed",
"InstallExitCode.32": "ServerFailedToStart",
"InstallExitCode.33": "NeedInsidersWindows",
"InstallExitCode.34": "CreateInstallDirFailed",
"InstallExitCode.35": "UnsupportedPlatform",
"InstallExitCode.36": "ServerTerminatedCVE20201416",
"InstallExitCode.37": "UnpackFailed",
"InstallExitCode.38": "ChangeDirFailed",
"InstallExitCode.AlreadyInProgress": "24",
"InstallExitCode.ServerDownloadFailed": "25",
"InstallExitCode.NoDownloaderAvailable": "26",
"InstallExitCode.NoDownloaderAvailableForStatusCheck": "30",
"InstallExitCode.UnsupportedArch": "27",
"InstallExitCode.StatusCheckFailed": "28",
"InstallExitCode.NeedInsidersArch": "29",
"InstallExitCode.ServerTransferFailed": "31",
"InstallExitCode.ServerFailedToStart": "32",
"InstallExitCode.NeedInsidersWindows": "33",
"InstallExitCode.CreateInstallDirFailed": "34",
"InstallExitCode.UnsupportedPlatform": "35",
"InstallExitCode.ServerTerminatedCVE20201416": "36",
"InstallExitCode.UnpackFailed": "37",
"InstallExitCode.ChangeDirFailed": "38",
"InstallUnpackCode.Success": "success",
"InstallUnpackCode.Error": "error",
"InstallUnpackCode.MissingFiles": "missingFiles",
"uuid": "510c378f2408",
"startMarker": "510c378f2408: running",
"commitId": "ff7a154d5e5e9034914f0466420f0f1407f0c95e",
"quality": "insider",
"token": "29c55acb-7a17-4a9a-9984-0ee4f611f420",
"vscodeAgentFolder": "$HOME/.vscode-server-insiders",
"allowClientDownload": "1",
"forceClientDownload": "0",
"cliNameInArchive": "code-insiders",
"ignoreWgetConfigFlag": " --no-config ",
"ignoreCurlConfigFlag": " --disable ",
"wgetTriesSegment": "--tries=1",
"listenArgs": "--on-host=127.0.0.1 --on-port",
"getDownloadServerStartTrigger": "510c378f2408:trigger_server_download",
"getDownloadServerEndTrigger": "510c378f2408:trigger_server_download_end",
"getProgressDownloading": "510c378f2408%%1%%",
"getProgressInstalling": "510c378f2408%%2%%"
}
[17:11:37.032] Install and start server if needed
[17:11:39.262] Checking ssh with "C:\Windows\system32\ssh.exe -V"
[17:11:39.265] Got error from ssh: spawn C:\Windows\system32\ssh.exe ENOENT
[17:11:39.265] Checking ssh with "C:\Windows\ssh.exe -V"
[17:11:39.267] Got error from ssh: spawn C:\Windows\ssh.exe ENOENT
[17:11:39.267] Checking ssh with "C:\Windows\System32\Wbem\ssh.exe -V"
[17:11:39.268] Got error from ssh: spawn C:\Windows\System32\Wbem\ssh.exe ENOENT
[17:11:39.268] Checking ssh with "C:\Windows\System32\WindowsPowerShell\v1.0\ssh.exe -V"
[17:11:39.269] Got error from ssh: spawn C:\Windows\System32\WindowsPowerShell\v1.0\ssh.exe ENOENT
[17:11:39.269] Checking ssh with "C:\Windows\System32\OpenSSH\ssh.exe -V"
[17:11:39.310] > OpenSSH_for_Windows_8.6p1, LibreSSL 3.4.3
[17:11:39.314] Running script with connection command: "C:\Windows\System32\OpenSSH\ssh.exe" -T -D 56552 "root@localhost" bash
[17:11:39.316] Terminal shell path: C:\Windows\System32\cmd.exe
[17:11:41.706] > The authenticity of host 'localhost (127.0.0.1)' can't be established.
> ED25519 key fingerprint is SHA256:Mhtu8Z6A+DCU2lnJDlvuoBgbHu4pkajyQ1y+ee2N140.
> This key is not known by any other names
> Are you sure you want to continue connecting (yes/no/[fingerprint])?]0;C:\Windows\System32\cmd.exe
[17:11:41.706] Got some output, clearing connection timeout
[17:11:41.706] Detected fingerprint confirmation message
[17:11:41.706] Showing fingerprint confirmation dialog
[17:11:43.767] Got fingerprint response: yes
[17:11:43.768] "install" wrote data to terminal: "yes"
[17:11:43.818] > yes
> Warning: Permanently added 'localhost' (ED25519) to the list of known hosts.
> root@localhost's password:
[17:11:43.818] Showing password prompt
[17:11:47.003] Got password response
[17:11:47.003] "install" wrote data to terminal: "******"
[17:11:47.046] >
[17:11:47.137] > 510c378f2408: running
> Script executing under PID: 1200
> Installing to /root/.vscode-server-insiders...
[17:11:47.153] > 510c378f2408%%1%%
> printenv:
> SHELL=/bin/bash
> DISTTAG=f40container
> PWD=/root/.vscode-server-insiders
> LOGNAME=root
> FBR=f40
> MOTD_SHOWN=pam
> HOME=/root
> LANG=C.UTF-8
> FGC=f40
> SSH_CONNECTION=172.17.0.1 39124 172.17.0.2 1234
> USER=root
> SHLVL=1
> SSH_CLIENT=172.17.0.1 39124 1234
> PATH=/root/.local/bin:/root/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
> OLDPWD=/root
> _=/usr/bin/printenv
> Neither wget nor curl is installed
> Trigger local server download
> 510c378f2408:trigger_server_download
> artifact==cli-alpine-x64==
> destFolder==/root/.vscode-server-insiders==
> destFolder2==/vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz==
> 510c378f2408:trigger_server_download_end
> Waiting for client to transfer server archive...
> Waiting for /root/.vscode-server-insiders/vscode-cli-ff7a154d5e5e9034914f0466420
> 0f0f1407f0c95e.tar.gz.done and vscode-server.tar.gz to exist
[17:11:47.154] Got request to download on client for {"artifact":"cli-alpine-x64","destPath":"/root/.vscode-server-insiders/vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz"}
[17:11:47.154] server download URL: https://update.code.visualstudio.com/commit:ff7a154d5e5e9034914f0466420f0f1407f0c95e/cli-alpine-x64/insider
[17:11:47.154] Downloading VS Code server locally...
[17:11:47.170] >
>
[17:11:47.809] Downloaded VS Code server to c:\Users\chrmarti\AppData\Local\Temp\8b31698e-5107-49c4-bfbf-e65655b2bcaf
[17:11:47.811] Renamed VS Code server to c:\Users\chrmarti\AppData\Local\Temp\vscode_server_1724944307809\vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz
[17:11:47.814] Checking ssh with "C:\Windows\system32\ssh.exe -V"
[17:11:47.815] Got error from ssh: spawn C:\Windows\system32\ssh.exe ENOENT
[17:11:47.816] Checking ssh with "C:\Windows\ssh.exe -V"
[17:11:47.817] Got error from ssh: spawn C:\Windows\ssh.exe ENOENT
[17:11:47.817] Checking ssh with "C:\Windows\System32\Wbem\ssh.exe -V"
[17:11:47.819] Got error from ssh: spawn C:\Windows\System32\Wbem\ssh.exe ENOENT
[17:11:47.819] Checking ssh with "C:\Windows\System32\WindowsPowerShell\v1.0\ssh.exe -V"
[17:11:47.820] Got error from ssh: spawn C:\Windows\System32\WindowsPowerShell\v1.0\ssh.exe ENOENT
[17:11:47.820] Checking ssh with "C:\Windows\System32\OpenSSH\ssh.exe -V"
[17:11:47.858] > OpenSSH_for_Windows_8.6p1, LibreSSL 3.4.3
[17:11:47.861] Expecting scp to be next to ssh at C:\Windows\System32\OpenSSH\scp.exe
[17:11:47.861] Testing scp with "C:\Windows\System32\OpenSSH\scp.exe"
[17:11:47.952] scp exited with code: 1
[17:11:47.952] Got stderr from scp: usage: scp [-346ABCpqrTv] [-c cipher] [-F ssh_config] [-i identity_file]
[-J destination] [-l limit] [-o ssh_option] [-P port]
[-S program] source ... target
[17:11:47.953] Copying file to remote with "C:\Windows\System32\OpenSSH\scp.exe" "vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz" "vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz.done" "root@localhost":"/root/.vscode-server-insiders"
[17:11:47.953] Using cwd: file:///c%3A/Users/chrmarti/AppData/Local/Temp/vscode_server_1724944307809
[17:11:47.953] Terminal shell path: C:\Windows\System32\cmd.exe
[17:11:50.315] > root@localhost's password:]0;C:\Windows\System32\cmd.exe
[17:11:50.315] Showing password prompt
[17:11:53.649] Got password response
[17:11:53.650] "Copy server to host" wrote data to terminal: "******"
[17:11:53.692] >
[17:11:53.801] > bash: line 1: scp: command not found
> lost connection
[17:11:55.060] "Copy server to host" terminal command done
Looks like two issues:
First is that curl
is not detected even though I see it installed in the repro
[root@127b10c12174 fedora-devcontainer]# curl --version
curl 8.6.0 (x86_64-redhat-linux-gnu) libcurl/8.6.0 OpenSSL/3.2.1 zlib/1.3.0.zlib-ng brotli/1.1.0 libidn2/2.3.7 libpsl/0.21.5 libssh/0.10.6/openssl/zlib nghttp2/1.59.0 OpenLDAP/2.6.7
Release-Date: 2024-01-31
Due to that its falling back to local download mode. It appears the command doesn't passthrough the non-standard port (edit: perhaps it does if localhost
is a config alias, which could explain the below comment?)
[17:11:47.953] Copying file to remote with
"C:\Windows\System32\OpenSSH\scp.exe" \
"vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz" "vscode-cli-ff7a154d5e5e9034914f0466420f0f1407f0c95e.tar.gz.done" \
"root@localhost":"/root/.vscode-server-insiders"
It also appears that scp
is also needed on the remote side (https://stackoverflow.com/a/20242139) and that's not the case for this barebones fedora image. That's where the
[17:11:53.801] > bash: line 1: scp: command not found
> lost connection
error is coming from.
Pre-release published that should resolve this (requires installing ssh locally on the remote host to get scp
)
https://github.com/user-attachments/assets/9697e68a-8049-47f5-b431-08dc77e1c1fa
Testing #226689
Remote - SSH v0.114.2024082315
Using one window to run a devcontainer:
Then connecting to the ssh server:
root@localhost:1234
Log: