Everytime I sucessfully login to a remote server using ssh, the zsh terminal would stuck unless I do a Ctrl+C. There’s no problem with the ssh login, and I can even run python scripts in vscode. So not a problem with ssh login? It also requires three Ctrl+C after I type exit
for it to really exit the ssh connection everytime.
Things I’ve tried:
- The same happens when opening a new terminal in vscode. But
source ~/.zshrc
works just fine after I bring back the terminal by Ctrl+C. - I also tried to comment out all the contents in
zshrc
and try to re-connect in my local terminal or launch a new terminal in VS Code, and the problem persists (So not a problem withzshrc
?). - I tried uninstalling vscode from the server, removing the
~/.vscode-server
folder, and using my local machine’s terminal to connect. The problem persists (So not a problem with VS Code?) - I also tried this answer, but the
date
returns the correct time. - Tried to use
-vvv
option inssh
to see the verbose ssh login info, but there’s nothing else after “Last login” information where the terminal is stuck. - Tried to add
set -x
inzshrc
to see the verbose zshrc execution info, but there’s no output as I commented everything inzshrc
.
I’m in desperate need of any suggestions that might help solving this issue! Appreciate it!
New contributor
Interstellar Wanderer is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.