Mini-guide: tmux
Tip jar 🫙 expatriotic@walletofsatoshi.com
Donations
Bitcoin paynym = +expatriotic
Monero QR

88D6SZFBA6fFhYGdnY4c57dTAJD6jyqRTfCKwHjZrfdnhd8phAMYnDQWSJrqyAmgVHV7mDU6soaHogZvno1AUXp79DwtWvK
Tmux (Terminal Multiplexer) allows you to run persistent, multi-window terminal sessions. You can detach from a session, log out, and your programs (like a node sync) will continue to run. You can then re-attach later.
The default Prefix key is Ctrl+B. To send a command, you press the Prefix, release it, and then press the command key (e.g., d to detach).
Session Basics
Start a new, named session:
tmux new -s <session_name>
Example:
tmux new -s monerodList all running sessions:
tmux lsDetach from your current session: Press
Ctrl+B, release, then pressd.Re-attach to a specific session:
tmux attach -t <session_name>
Example:
tmux attach -t monerod
Killing Sessions
You can terminate sessions from inside tmux (using the prefix) or from your main terminal.
From Inside a Session
Kill the current session you are in:
Method one:
exit+ [enter]Method two:
Ctrl+B:(colon)kill-session+ [Enter]
Kill all other sessions (except the one you are in):
tmux kill-session -a
(This can also be run from the
Ctrl+B,:command prompt).
From Outside (Main Terminal)
Kill a specific session by name: First, list them:
tmux lsThen, kill the target:tmux kill-session -t <session_name>
Example:
tmux kill-session -t monerodKill all sessions and the tmux server (Cleanly): This is the recommended way to shut down all tmux activity.
tmux kill-serverKill all tmux processes (Forcefully): If
kill-serverfails, this is the "gross" or unclean method.pkill -f tmux