About Linux GNU Screen command
Screen
is a terminal multiplexer. It means that you can start a screen session and
then open any number of windows (virtual terminals) inside that session.
Processes running in Screen will continue to run when their window is not
visible even if you get disconnected.
It
supports a scrolback history buffer for each virtual terminal and it is
possible to move text regions between windows.
Linux
screen command offers you to open several separate terminal instances
inside a one single terminal window manager.
The
screen application is very useful, if you are dealing with multiple programs
from a command line interface.
Screen is started from the command line just like
any other command:
$ screen
Screen
functions just like a normal shell except for a few special characters.
Control Command
Screen
uses the command “Ctrl-a” as a signal to send
commands to screen instead of the shell.
Key
bindings are the commands the screen uses after you press “Ctrl-a”. You can reconfigure these keys to your
liking using a .screenrc file.
Features
ü Create
multiple windows inside a Screen session
ü Use
multiple shell windows from just one SSH session
ü Keep
a shell session active even when there are network disturbances
ü Manage
connections to shell from multiple locations
ü Keep
a long running session alive even after exiting a shell session
ü You
can detach from the screen session at any time
ü You
can reattach or reconnect to a Linux Screen
ü You
can list screens
ü Switch
between windows
ü Log
your screen output
ü Lock
screen session
Alerts about activity or inactivity
Screen
can monitor a window for activity or inactivity. This is great for long
operations and computations, when you wait long for output.
You
can use “Ctrl-a” “M” to look for activity.
Screen will then flash an alert at the bottom of the page when output is
registered on that screen.
You
can also monitor for inactivity.
If
you’re waiting for some long operation to complete, you can be notified when
there is no more output. This is a signal for that job is done. To monitor for
silence or no output use “Ctrl-a” “_”.
Terminating screen session
Once we are done with the screen
sessions, we can terminate it (and start it again later to attach to previous
sessions) with the combination of “Ctrl-a” key followed by “k”.
If you frequently remote into your Linux servers, and you
want to make sure to not lose your command line work due to a questionable
network connection, screen is a must-use program. To learn more about what this
can do, issue the command man screen and read through the manual page.
For more info:- check ubuntu version

Comments
Post a Comment