TMux

TMUX terminal multiplexer

  1. ssh into the remote machine
  2. start tmux by typing tmux into the shell
  3. start the process you want inside the started tmux session
  4. leave/detach the tmux session by typing Ctrl-b :detach

You can now safely logoff from the remote machine, your process will keep running inside tmux. When you come back again and want to check the status of your process you can use tmux attach to attach to your tmux session.

If you want to have multiple session running side-by-side you should name each session using Ctrl-B and $. You can get a list of the currently running sessions using tmux list-sessions.

Ctrl-b c          Create new window
Ctrl-b d          Detach current client
Ctrl-b l          Move to previously selected window
Ctrl-b n          Move to the next window
Ctrl-b p          Move to the previous window
Ctrl-b $num       Move to window $num
 
Ctrl-b w          list windows
Ctrl-b &          Kill the current window
Ctrl-b !          close other panes except the current one
Ctrl-b ,          Rename the current window
 
Ctrl-b %          Split the current window into two panes
Ctrl-b "          split pane horizontally
Ctrl+b arrow      key - switch pane.
Hold Ctrl+b,      don't release it and hold one of the arrow keys - resize pane.
 
Ctrl-b q          Show pane numbers (used to switch between panes)
Ctrl-b o          Switch to the next pane
Ctrl-b ?          List all keybindings
Ctrl-b x          exit
 
Ctrl-b s          list sessions
tmux new-session  start a new session
tmux attach       re-attach a detached session
Ctrl-b :detach    detach from currently attached session