Every launch to twiddle (which is typically twice during every publish) or ANY remote shell command in the current tools, never cleans up its host shell connections.
According to API this is platform dependent. IHostShell may or may not close its connection after executing a command. There is no guarantee, but on some platforms it may not close them. It seems in linux (and possibly other platforms) the host shell is NOT closed.
Eventually, there are too many connections to the remote system, and further attempts to connect OR transfer files become failures, leading to a complete paralysis of the tooling.
Workaround is to go to the Remote System view and disconnect and reconnect to your remote system, however, 4 publishes later, the same action will be needed.