Screen Linux: The Screen is an utility which is available in Linux mainly used to resume the sessions. Let you consider a scenario, You are transferring a big file from your desktop to any server and it will take a long time to complete. If the data connection is lost means and then your connection between the desktop & server will be terminated and so the transferring process will be terminated. To overcome this issue, Linux has the special utility named as Screen, Which resumes the session and once the data connection is back, The file transferring to your server will resume.
- What is Screen Utility
- How to install Screen Utility in Linux
- How to start Screen Utility
- Screen Utility basic commands
- Detach Session from Screen Utility
- Reattach Session in Screen Utility
- Screen Utility Basic Usage
- Uninstall Screen Utility From Ubuntu Linux
What is Screen Utility in Linux?
Screen Utility is a terminal multiplexer. The Screen Utility is otherwise called as the GNU Screen. The Screen utility will allow you to start Screen Session & you can able to open any number of Virtual screen inside the Terminal. This screen utility will help you run the session even though the connection between the host is terminated. Once the connection is back you may able to resume the session using the screen utility from the terminal.
How to install Screen Utility in Linux:
The Screen Utility coming as the pre-installed package in the recent version of Ubuntu Linux. (Greater than 16.04 version). If your Ubuntu version doesn’t have any, use the following command to install the Screen Utility in Ubuntu Command:
The above command will help you install the “Screen Utility” in your Ubuntu PC. To view the version of Screen Utility:
The output of the above command will be like this:
To install Screen Utlity in Cent OS Linux:
It is easy to install the Screen Utility in your Cent OS, use the following command:
How to start Screen Utility in Ubuntu Linux:
You can start the Screen Utility using the following command, screen, copy this command & paste in the terminal. This command will open a screen session inside the Terminal.
Screen Utility basic commands:
You must need to learn some essential basic Screen Utility commands. When you start the new session in screen utility which creates the new windows inside the terminal itself. This Screen Utility allows you to create a multiple screen session inside the terminals. Below, we mentioned some important and basic Screen Utility commands will help you work with Screen.
- Ctrl+a c Create a new session or window inside the Terminal
- Ctrl+a “ Shows all the available windows
- Ctrl+a 0 Switch to the 0th window
- Ctrl+a A Allows you to rename the current Window
- Ctrl+a S Split your screen into two (Horizantally)
- Ctrl+a | Split your screen into two (Vertically)
- Ctrl+a tab Switch to the next available window or session
- Ctrl+a Ctrl+a Allows you toggle between two region
- Ctrl+a Q Close all the session except the currently active one
- Ctrl+a X Close the currently active region
If you have any other essential Screen commands, kindly mention those in our comment!
How to Detach Session from Screen Utility:
It is very easy to detach from Screen Session, to do this use the following command:
How To Reattach Session in Screen Utility:
To reattach or resume the Screen Session, use the following command:
To view the currently running session in your pc, enter the following command in the terminal:
If you want to reattach session to the 10377.pts-0, use the following command:
The above command will reattach or resume the screen session to 10377.pts.0 window.
How To Use Screen Session Utility:
- Open Terminal & type Screen
- Run any program inside the terminal.
- You can use the Ctrl-a + Ctrl-d to detach from the screen session.
- You can resume or reattach to the current session using Ctrl+a r
This is how you can use the Screen Utility in Ubuntu Linux.
Uninstalling Screen Utility From Ubuntu Linux:
You can uninstall the Screen Utility from the Ubuntu Linux, Use the below command to uninstall:The above command will initiate the uninstallation process, If it asks you confirmation about the uninstallation process & Enter “Y” & hit the Enter button to continue the uninstallation process.
That’s it, Here comes the conclusion of this article. You can use the Screen Basic Commands in Debian & non-Debian based distros. If you have any queries related to this article kindly mention those in our comment section.
- Content Explanation
- Commands Explanation
- Commands Working
- Attach & Detach Commands
For more articles, kindly visit our HomePage