I'm using ssh and Microsoft VS Code on my Mac (up to date Ventura) to connect to my Ubuntu VM (up to date 22.04). However, I keep getting inactivity timeouts (I believe this is from the macOS side):
client_loop: send disconnect: Broken pipe
My Ubuntu sshd_config contains:
TCPKeepAlive yes
ClientAliveInterval 30
ClientAliveCountMax 5
And my macOS ~/.ssh/config contains:
TCPKeepAlive no
ServerAliveInterval 30
ServerAliveCountMax 5
But that doesn't seem to help.
There are a million posts about setting the values above, and I believe I've tried all reasonable permutations to no avail.
How can I keep the connections up permanently?