How Eternal Terminal Keeps Sessions Alive During Network Outages

Updated

Eternal Terminal (ET) is a remote shell that automatically reconnects without interrupting the session. The key mechanism is that the ET session itself survives a dead TCP connection, so when the network comes back — or your IP address changes — you resume the same session instead of starting a new one. This matters most if you run long-lived work inside tmux and don't want to lose it when your laptop switches networks or your connection drops.

The core idea: the session outlives the connection

With a normal remote shell, the TCP connection is the session. If that connection dies, the session dies with it, and anything running inside it is gone unless it was detached into a separate multiplexer.

ET separates the two. The session is maintained independently of the underlying TCP connection, so a network outage or IP roaming doesn't end it. When connectivity returns, ET resumes quickly rather than forcing you to kill and rebuild everything.

This is the difference ET's own documentation draws against plain ssh: with ssh, "one must kill the ssh session and reconnect after a network outage."

How it differs from autossh

autossh is a common workaround: it detects a dropped ssh connection and restarts it. But as ET's documentation notes, autossh "will start a new session each time."

That distinction has a practical cost. If you use tmux with control mode, an autossh reconnect means you have to wait for the old ssh connection to die and then re-attach. ET, by contrast, "saves valuable time by maintaining your tmux session even when the TCP connection dies and resuming quickly."

So the comparison is:

Behavior ssh autossh ET
Survives network outage No Reconnects, new session Yes, same session
Survives IP roaming No Reconnects, new session Yes
Keeps tmux session across the drop Only if detached Requires wait + re-attach Maintained directly
Native scrolling Yes Yes Yes
tmux control mode (tmux -CC) Yes Yes Yes

What ET does not change

ET is not a from-scratch replacement for ssh's connection layer — it uses ssh to initialize the connection. The improvement is specifically about what happens after that connection is established and then interrupted.

It's also worth being precise about the mosh comparison. mosh provides the same core reconnect functionality, but per ET's documentation it does not support native scrolling or tmux control mode (tmux -CC). If those two features matter to your workflow, that's the deciding factor between them.

When this actually helps

The scenario ET is built for: you're running something long-lived in tmux over a connection that isn't stable — a laptop moving between Wi-Fi and cellular, a flaky VPN, or a remote host whose address changes. Under ssh you'd lose the session or have to re-attach manually; under autossh you'd get a fresh session each time. Under ET the session persists and resumes.

If your connections are stable and your sessions are short, the reconnect behavior rarely comes into play, and plain ssh is simpler. The value shows up specifically when interruptions are frequent and your work lives inside a persistent tmux session.

For installation and usage steps, see ET's own Download and Tutorial pages at eternalterminal.dev.