software:cli:screen
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| software:cli:screen [2024/11/01 14:33] – warnaud | software:cli:screen [2025/07/07 07:11] (current) – warnaud | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | - Share a screen session: \\ in one terminal <code bash> screen -S SharedSession </ | ||
| + | - Logging: \\ To save everything that is in your screen session, at the beginning: < | ||
| + | - Detach a screen inside a screen:< | ||
| + | - Serial console: <code bash> screen /dev/ttyS0 19200</ | ||
| + | ==== Upgrading system ==== | ||
| + | Network might goes down while full system upgrade | ||
| + | <code bash>ssh -t machine.to.update screen -d -R -S Upgrade</ | ||
| + | If it goes down, same command reconnects to the screen session " | ||
| + | |||
| + | ====== CheatSheet ====== | ||
| + | Here's a quick cheatsheet for GNU Screen with start/ | ||
| + | |||
| + | ===== Starting and Reconnecting ===== | ||
| + | |||
| + | |||
| + | ==== Start a new screen session: ==== | ||
| + | |||
| + | < | ||
| + | |||
| + | |||
| + | ==== Start a named screen session: ==== | ||
| + | |||
| + | |||
| + | < | ||
| + | |||
| + | |||
| + | ==== Reconnect to a detached session: ==== | ||
| + | |||
| + | |||
| + | < | ||
| + | |||
| + | |||
| + | ==== List running sessions: ==== | ||
| + | |||
| + | |||
| + | < | ||
| + | |||
| + | |||
| + | ==== Reconnect to a specific session: ==== | ||
| + | |||
| + | |||
| + | < | ||
| + | |||
| + | |||
| + | ===== Main Key Bindings (defaults) ===== | ||
| + | |||
| + | |||
| + | All commands are prefixed with `Ctrl+a` (denoted as `C-a` below) | ||
| + | |||
| + | ==== Window Management: ==== | ||
| + | |||
| + | * `C-a c`: Create a new window | ||
| + | * `C-a n`: Switch to next window | ||
| + | * `C-a p`: Switch to previous window | ||
| + | * `C-a 0-9`: Switch to window 0-9 | ||
| + | * `C-a "`: List all windows | ||
| + | * `C-a A`: Rename current window | ||
| + | |||
| + | ==== Session Management: ==== | ||
| + | |||
| + | * - `C-a d`: Detach from current session | ||
| + | * - `C-a x`: Lock the screen session | ||
| + | |||
| + | Split Screen: | ||
| + | * `C-a S`: Split display horizontally | ||
| + | * `C-a |`: Split display vertically | ||
| + | * `C-a tab`: Switch between regions | ||
| + | |||
| + | Copy Mode: | ||
| + | * `C-a [`: Enter copy mode | ||
| + | * `C-a ]`: Paste from copy buffer | ||
| + | |||
| + | Other Useful Commands: | ||
| + | * `C-a ?`: Show help | ||
| + | * `C-a a`: Send `Ctrl+a` to the current window | ||
| + | * `C-a k`: Kill current window | ||
| + | * `C-a \`: Kill all windows and terminate screen | ||
| + | |||
| + | Remember that you can customize these bindings in your `~.screenrc` file to suit your preferences. | ||
| + | |||
| + | |||
| + | |||
| + | |||
| + | References: | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * http:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
| + | * https:// | ||
