Show Menu
Cheatography

Screen Quick Reference Cheat Sheet by

GNU screen quick reference

Getting In

screen -S <na­me>
start a new screen session with session name
screen -ls
list running sessio­ns/­screens
screen -x
attach to a running session
screen -r <na­me>
attach to session name
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.

Getting Out

C-a d
detach
C-a D D
detach and logout (quick exit)
C-a \
Exit all of the programs in screen. (not recomm­ended)
C-a C-\
force-exit screen (not recomm­ended)
exit
getting out of the screen session

Escape key

 
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 working with screen within screen. For example C-a a n will move screen to a new window on the screen within screen.

GNU Screen Link

 

Window Management

create new window
C-a c
change to last-v­isited active window
C-a C-a
change to window by number
C-a <nu­mbe­r>
change to window by number or name
C-a ' <number or title>
change to next window in list
C-a n or C-a <sp­ace>
change to window by number or name
C-a ' <number or title>
change to next window in list
C-a n or C-a <sp­ace>
change to previous window in list
C-a p or C-a <ba­cks­pac­e>
see window list
C-a " (allows you to select a window to change to)
show window bar
C-a w (if you don't have window bar)
close current window
Close all applic­ations in the current window (including shell)
kill current window
C-a k (not recomm­ended)
kill all windows
*C-a * (not recomm­ended)
rename current window
C-a A
 

Split screen

split display horizo­ntally
C-a S
split display vertically
C-a | or C-a V (for the vanilla vertical screen patch)
jump to next display region
C-a tab
remove current region
C-a X
remove all regions but the current one
C-a Q

Clipboard and Navigation

freely navigate buffer
C-a [ or C-a <es­c>
toggle selection to copy
space
paste
C-a ]

Misc

redraw window
C-a C-l
monitor window for activity
C-a M
monitor window for silence
C-a _
enter digraph (for producing non-ASCII charac­ters)
C-a C-v
lock (password protect) session
C-a x
enter screen command
C-a :
enable logging in the screen session
C-a H

Scroll­bac­k-b­uffer

half page up
C-u
half page down
C-d
back
C-b
forward
C-f
cursor left/d­own­/up­/right
/h/j/k/l
In copy mode, one can navigate the scrollback buffer in various ways:
 

Comments

No comments yet. Add yours below!

Add a Comment

Your Comment

Please enter your name.

    Please enter your email address

      Please enter your Comment.

          Related Cheat Sheets

          Closed-source Debugging with GDB Cheat Sheet
          First Aid Kit Cheat Sheet