vscode-remote-release icon indicating copy to clipboard operation
vscode-remote-release copied to clipboard

[Remote-SSH Bug]: Port forwarding stops working after reconnection using execServer

Open jeanp413 opened this issue 1 year ago • 2 comments

Is there an existing issue for this bug?

  • [X] I have searched the existing issues

Required Troubleshooting Steps

  • [X] I have followed these troubleshooting steps
  • [X] I have tried both values of the remote.SSH.useLocalServer setting

Connect Locally

It connects successfully

->

After a reconnection port forwarding is broken, need to remove the forwarded port from the ports view and add it again so it starts working again

Expected Behavior

Port forwarding should work after reconnection

Steps To Reproduce

  1. Set "remote.SSH.useExecServer": true in your vscode settings
  2. Connect to a remote machine using SSH and run some command that starts an http server
  3. Forward the remote port locally
  4. Run curl on the forwarded port , check it works
  5. Run the following in a local terminal ps -ejw | grep ssh and kill the ssh -v -T ... process. to force to reconnect
  6. Wait vscode reconnects
  7. Run curl on the forwarded port again, check it hangs forever 🐛

Remote-SSH Log

Remote-SSH Log

[PASTE LOG HERE]

Anything else?

No response

jeanp413 avatar May 24 '24 06:05 jeanp413

cc @connor4312

jeanp413 avatar May 24 '24 06:05 jeanp413

I am also experiencing this issue when VSCode disconnects.

torsteinmeyer avatar Jun 20 '24 11:06 torsteinmeyer

This should be fixed in the latest Remote - SSH prerelease

connor4312 avatar Jul 17 '24 15:07 connor4312