tmux new -s mysession run commands inside tmux detach Ctrl+B then D safely close SSH/Putty Later, reconnect and reattach: tmux ls Make sure use sudo to verify for root tmux attach -t mysession
tmux attach -t