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

Failed to connect over SSH #20854

Open
1 task done
rmGFW opened this issue Nov 19, 2024 · 6 comments
Open
1 task done

Failed to connect over SSH #20854

rmGFW opened this issue Nov 19, 2024 · 6 comments
Labels
bug [core label] needs info / awaiting response Issue that needs more information from the user remote dev Feedback for remote development servers

Comments

@rmGFW
Copy link

rmGFW commented Nov 19, 2024

Check for existing issues

  • Completed

Describe the bug / provide steps to reproduce it

zed ssh://xxx-configured-in-ssh-conf-with-ProxyCommand:/path/to/repo

Environment

Zed: v0.161.2 (Zed)
OS: macOS 14.5.0
Memory: 16 GiB
Architecture: aarch64

If applicable, add mockups / screenshots to help explain present your vision of the feature

image image

If applicable, attach your Zed.log file to this issue.

Zed.log

@rmGFW rmGFW added admin read Pending admin review bug [core label] triage Maintainer needs to classify the issue labels Nov 19, 2024
@SomeoneToIgnore
Copy link
Contributor

Any server and client logs you can provide?

@SomeoneToIgnore SomeoneToIgnore added the needs info / awaiting response Issue that needs more information from the user label Nov 19, 2024
@rmGFW
Copy link
Author

rmGFW commented Nov 19, 2024

this is the client side log

2024-11-19T16:35:19.18318+08:00 [INFO] Initializing default prettier with plugins {}
2024-11-19T16:35:24.905971+08:00 [ERROR] failed to establish connection: Timeout detected
2024-11-19T16:35:24.911234+08:00 [ERROR] Failed to open project: Timeout detected
2024-11-19T16:35:26.308558+08:00 [INFO] language server 1: unregistered workspace/DidChangeWatchedFiles capability with id de6d8e03-ea29-486e-ae07-5622e9a65162

@notpeter
Copy link
Member

zed ssh://xxx-configured-in-ssh-conf-with-ProxyCommand:/path/to/repo

I want to see if I can trigger the same behavior.

  1. Can you provide your ssh version: ssh -V
  2. Are there multiple jumps? e.g. Local->B->C->Remote or just one: Local->B->Remote
  3. Do any of the hosts require keyboard input? (password prompt, 2FA code, etc)
  4. Are you using AgentForwarding?
  5. Are you using short-lived SSH keys / certificates or related solution (e.g. Teleport)?
  6. Can you provide the ssh config including the ProxyCommand (e.g. ProxyCommand ssh machineA nc %h %p and the configuration for all host in the chain (e.g. Match, Host *, Jump host, host blocks, etc).

Feel free to redact, but the more information you can provide the more likely we are to be able to reproduce your setup and trigger the issue you're having.

@notpeter notpeter added remote dev Feedback for remote development servers and removed triage Maintainer needs to classify the issue admin read Pending admin review labels Nov 19, 2024
@mlsvrts
Copy link

mlsvrts commented Nov 19, 2024

I have seen this behavior -- does your .bashrc on the remote host do something like

exec $(which zsh)

?

If so, can you try updating it to look like this?

if test -t 1; then
  exec $(which zsh)
fi

(alternatively, move exec [some-other-shell] to your .bash_profile)

@rmGFW
Copy link
Author

rmGFW commented Nov 20, 2024

I have seen this behavior -- does your .bashrc on the remote host do something like

exec $(which zsh)

?

If so, can you try updating it to look like this?

if test -t 1; then
  exec $(which zsh)
fi

(alternatively, move exec [some-other-shell] to your .bash_profile)

you are right , i did , but after remove exec which zsh , timeout error still came out

@rmGFW
Copy link
Author

rmGFW commented Nov 20, 2024

r

zed ssh://xxx-configured-in-ssh-conf-with-ProxyCommand:/path/to/repo

I want to see if I can trigger the same behavior.

  1. Can you provide your ssh version: ssh -V
  2. Are there multiple jumps? e.g. Local->B->C->Remote or just one: Local->B->Remote
  3. Do any of the hosts require keyboard input? (password prompt, 2FA code, etc)
  4. Are you using AgentForwarding?
  5. Are you using short-lived SSH keys / certificates or related solution (e.g. Teleport)?
  6. Can you provide the ssh config including the ProxyCommand (e.g. ProxyCommand ssh machineA nc %h %p and the configuration for all host in the chain (e.g. Match, Host *, Jump host, host blocks, etc).

Feel free to redact, but the more information you can provide the more likely we are to be able to reproduce your setup and trigger the issue you're having.

  1. ssh -V output
    ssh -V
    OpenSSH_9.6p1, LibreSSL 3.3.6

image
  1. no

4 and 5 , i don't known

6 . see the picture i have provided in the question 2

thanks!

by the way , (the vscode remote ssh works well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug [core label] needs info / awaiting response Issue that needs more information from the user remote dev Feedback for remote development servers
Projects
None yet
Development

No branches or pull requests

4 participants