Skip to main content

Linux Screen for session management

Need multiple shell sessions?

You are logged into your remote server via SSH and happily plucking along at your keyboard and then it happens. Suddenly, the characters stop moving and then you get the dreaded “Connection Closed” message. You have just lost your session. You were halfway through some task and now you have to start over. Ugh. Well you can prevent this from happening by using screen.

Lost your shell connection?

The Linux screen tool can not only save you from disconnection disasters, but it also can increase your productivity by using multiple windows within one SSHsession. 

What is Screen for Linux?

As the man page states, “Screen is a full-screen window manager that multiplexes a physical terminal between several processes (typically interactive shells).” This can be a life saver when working on your dedicated server. Screen has a several great features for helping you administer your server more productively and safely.

Installing Screen on Linux

Chances are that you already have screen on your system. On most Red Hat distributions you can find it in /usr/bin/screen. 
[root@arun01-I84076 /]# which screen
/usr/bin/screen

If you do not have screen, then you can install it easily from an RPM or the package file for your system. On Cobalt Raq servers, you can safely use the RedHat RPMS appropriate for your system.
Screen RPMs: rpmfind
Screen Web site: GNU Screen
Using screen Command in Putty
[root@arun01-I84076 /]# man screen
       
1.To enter into screen type screen command in putty window
[root@arun01-I84076 /]# screen


Screen shell
2.To view the screen help press ctrl+A then ?
Enter q to exit from help window
3.To create a new screen press ctrl+A and hit "c" to create new screen.
4.Now you can perform what ever installation you need and press ctrl+A and hit "d" to detach from screen.
5.You can toggle to several windows by ctrl+A
6.To know what are the screens available
sh-3.2# screen -list
There are screens on:
        17457.pts-1.arun01-I84076      (Attached)
        17894.pts-3.arun01-I84076      (Attached)
        4 Sockets in /var/run/screen/S-root.
7.To get back from screen press ctrl+D
8.If you login as new session then you can attach your screen by 
[root@arun01-I84076 ~]# screen -r 18454.pts-7.navve01-I84076




Comments

  1. Thanks for giving the tips. You can also try Go4hosting to experience best hosting services.

    ReplyDelete

Post a Comment

Popular posts from this blog

How to make the email Address Dummy in Oracle Database?

How to make the email Address Dummy in Oracle Database? Query to make the email Address as dummy, update <tablename> set <Columnname> = '@' || <Columnname> where <Columnname>  is not null; Query to Remove the email Address as dummy, update <tablename> set <Columnname>= substr(<Columnname>,2,length(<Columnname>)) where <Columnname> is not null;

What is (Computer) Networking?

In the world of computers, networking is the practice of linking two or more computing devices together for the purpose of sharing data. Networks are built with a mix of computer hardware and computer software. Area Networks Networks can be categorized in several different ways. One approach defines the type of network according to the geographic area it spans.Local area networks (LAN), for example, typically span a single home, school, or small office building, whereas wide area networks (WAN), reach across cities, states, or even across the world. The Internet is the world's largest public WAN. One way to categorize the different types of computer network designs is by their scope or scale. For historical reasons, the networking industry refers to nearly every type of design as some kind of area network. Common examples of area network types are: LAN - Local Area Network WLAN - Wireless Local Area Network WAN - Wide Area Network MAN - Metropolitan Area Network SAN - ...

List of FTP commands for the Microsoft command-line FTP client

Command-line options As you're starting the program from a DOS prompt: ftp [-v] [-d] [-i] [-n] [-g] [-s:filename] [-a] [-w:windowsize] [computer] -v  - Suppresses  verbose  display of remote server responses. -n  - Suppresses auto-login upon initial connection. -i  - Turns off interactive  prompting  during multiple file transfers. -d  - Enables  debugging , displaying all ftp commands passed between the client and server. -g  - Disables filename  globbing , which permits the use of wildcard chracters in local file and path names. -s:filename  - Specifies a text file containing ftp commands; the commands will automatically run after ftp starts. No spaces are allowed in this parameter. Use this switch instead of redirection (>). -a  - Use any local interface when binding data connection. -w:windowsize  - Overrides the default transfer buffer size of 4096. computer  - Specifies the computer name o...