Screen is the best software used for full-screen window manager that multiplexes a physical terminal between several processes, typically interactive shells using only one SSH sesion or only one console.
Getting in
start a new screen session with session name
screen -S
list running sessions/screens
screen -ls
attach to a running session
screen -x
… to session with name
screen -r
the “ultimate attach”
screen -dRR (Attaches to a screen session. If the session is attached elsewhere, detaches that other display. If no session exists, creates one. If multiple sessions exist, uses the first one.)
All screen commands are prefixed by an escape key, by default C-a (that’s Control-a, sometimes written ^a). To send a literal C-a to the programs in screen, use C-a a. This is useful when when working with screen within screen. For example C-a a n will move screen to a new window on the screen within screen.