I’m using coolify. I just installed the Anysphere Dev Containers extension and uninstalled VSCode’s Dev Containers extension, reloaded the window and reconnected using SSH. No luck; the same problem with the same apparent frequency: “Remote Extension host terminated unexpectedly 3 times within the last 5 minutes”
The “Remote Extension host terminated unexpectedly 3 times within the last 5 minutes” indicates a problem with an extension, not with the SSH or dev containers connection. Could you try cmd/ctrl-shift-p then “Start Extension Bisect” command to find the problematic one?
Bisecting disables four extensions: anysphere remote SSH, anysphere dev containers, and then two other innocuous ones (jupyter and stan). The warning appears anyway: “Remote Extension host terminated unexpectedly 3 times within the last 5 minutes”. However, in looking at the dev tools console, it seems to be an extension related to git. I think you’re right that the remote extension host stuff probably isn’t related to the issue of the SSH connection cutting out (contrary to what I assumed) .
However, I’m still getting my SSH cutting out frequently. Could you take a look at these logs from the latest disconnection?
output.txt (1.1 KB)
Hi @peterphalen – I don’t see anything suspicious in these logs. However, we recently fixed a few issues with the Anysphere Remote SSH extension that, when using Dev Containers over SSH, would cause the connection to terminate every 5 minutes. These are fixed in version 1.0.7 of the Anysphere Remote SSH extension. Could you try upgrading and let me know whether that fixes the flakiness?
Update: I think the (remaining) problem was that I was giving the model a context that was too large. I had the entire server open, whereas opening only /var (for example) seems to function.
Hello @ravirahman , I could not quite find the specific settings, but did some changes under “Preferences: Open User Settings (JSON)”. Below is a snippet of the current JSON I’m using
// Prevent overload from automatic port forwarding
"remote.autoForwardPorts": false,
// No longer needed since auto forwarding is disabled
// "remote.autoForwardPortsSource": "hybrid",
// SSH connection tweaks
"remote.SSH.connectTimeout": 15,
"remote.SSH.enableX11Forwarding": false,
"remote.SSH.lockfilesInTmp": true,
"remote.SSH.remoteServerListenOnSocket": true,
// Helps keep SSH tunnel alive (prevents idle timeout)
"remote.SSH.serverAliveInterval": 30,
"remote.SSH.serverAliveCountMax": 10
Basically turned autoForwardPorts to false, commented autoForwardPortsSource (GPT suggestion), as well as adding the serverAlive parameters (also GPT suggestion). The problem seems fixed, it happens once a day now. Will keep tracking it for a few more days, before marking your answer as “Solution”. Thanks for all the support!
Attached a log after today’s reload (happened 1x)
redacted_cursor_log.txt (210.7 KB)