Stop Losing Your SSH Sessions Forever
You know the pain. You're deep in a remote terminal, running a long build or a data transfer, and suddenly your SSH connection drops. Your work is gone, your session is dead. It's frustrating, and screen or tmux don't always solve the problem when the agent disconnects. Enter rmux.
What It Does
rmux is a lightweight, Rust-based tool that wraps your SSH connections with tmux. When you SSH into a remote machine via rmux, it automatically attaches to (or creates) a persistent tmux session. If your SSH connection drops — for whatever reason — your session keeps running on the remote machine. You can simply reconnect and pick up exactly where you left off.
The key difference? rmux doesn't try to be a full terminal multiplexer. It's a thin, opinionated layer that ensures your work survives network hiccups, laptop sleep, or accidental disconnects.
Why It's Cool
- Zero config, zero friction. Just run
rmux serverinstead ofssh server. It handles tmux automatically. - Rust-native speed. No node, no Python dependencies. It's a single binary.
- Smart reconnection. If you reconnect to the same server, it finds your existing tmux session. No duplicate sessions, no manual cleanup.
- Works with your existing SSH config.
rmuxrespects~/.ssh/configand agent forwarding. You don't have to change your workflow. - Lightweight. No background daemons. No overhead when you're not using it.
The clever part: rmux automatically wraps your ssh command with tmux new-session -A -D -s rmux. That -A flag means "attach to an existing session with that name, or create one". This single line of tmux-fu is all it takes to never lose a session again.
How to Try It
You need Rust installed, but it's a quick cargo install:
cargo install rmux
Or grab a prebuilt binary from the releases page.
Then simply:
rmux [email protected]