Re:My ISP Is Killing My Idle SSH Sessions
by gregmac on Monday January 11, 2021 @07:50PM
(#25740720)
I also changed to using client keepalives after something in our office network changed: they installed new switches and access points and suddenly my ssh sessions wouldn't stay open. After getting nowhere with IT (mainly just a low priority issue to them) it was just less frustrating to enable keepalives and the problem disappeared, so that's my default config everywhere ever since.
Re:My ISP Is Killing My Idle SSH Sessions
by GekkePrutser on Monday January 11, 2021 @08:23PM
(#25741045)
I think TCP keepalives are conceptually the best though. As your problem occurs at the transport level, not the application layer.
This way you solve it where the issue occurs, and with the added benefit that it works for all TCP connections, not just SSH.
However I haven't had this issue. My isp is pretty ok in this regard and I supply my own router. So I don't know if there's issues with this in real life.
I usually just do client keepalives as they are easiest to set up. Server keepalives are good if you are worried about “forgotten” clients. TCP keepalives are usually not worth it IMHO.