Useful Screen commands

Start screen

(^ means CTRL)

^a ? - help

^a ^c - Create a new window with a shell and switch to that window

^a " - list of windows
^a N - show details of current window

^a <n> - switch to given window, where 0 <= n <= 9

^-a space \
^-a n     | - next window ^a^n
^-a ^-n   /

^-a backspace \
^-a h         | - prev window ^a^p
^-a p         |
^-a ^-p       /

^a^k - kill current window

^a ESC - temporarily leave screen to enable __scrolling__

SSH and screen

ssh-copy-id - use locally available keys to authorise logins on a remote machine
https://www.youtube.com/watch?v=HsPnsE1IEN0

http://www.cyberciti.biz/tips/linux-screen-command-howto.html

1. ssh
2. screen
3. ^A c - new window


screen disconnect and reconnect:

^a ^d  to disconnect from screen

screen -r    --> to reconnect
  or
screen -D -r    --> to reconnect or create if no existing session found