Join the community today
Register Now

Sysadmin Who uses Screen for linux ?

Discussion in 'System Administration' started by eva2000, Jun 19, 2014.

Tags:
  1. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Screen is useful for managing multiple SSH windows and also for maintaining an active SSH window even when your connection between you and your server is lost. This is useful is you run Centmin Mod install and/or upgrade commands and you have a flaky ISP connection to your server.

    To install linux screen and setup a dedicated screen for updates etc check out below tutorials

    Install is easy
    Code:
    yum -y install screen
    Screen tutorials
    I use screen alot of times with long term clients of mine, I setup a dedicated screen which I work in and survives when I log out of SSH, so when I return I can pick off where I left off on or check on processes or commands I may have left running for monitoring or analysis.


    Comes in handy :)
     
    Last edited: Nov 6, 2016
  2. Floren

    Floren Active Member

    148
    77
    28
    Jun 6, 2014
    Ratings:
    +77
    Local Time:
    8:42 AM
    I use it all the time, is an essential tool for my work.

    screen.jpg

    @eva2000, you should look also into autossh, is available in AXIVO repo.
    Yes, I also use Windows, not just Linux. :D
     
  3. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    ouch white background ! Looking at that for long periods of time must be killer on the eyes :)
     
  4. Floren

    Floren Active Member

    148
    77
    28
    Jun 6, 2014
    Ratings:
    +77
    Local Time:
    8:42 AM
    Actually the white background is default in RHEL6 distributions. :)
    For some reason, black hurts my eyes... probably because I'm to used dealing with text editors. :)
     
  5. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  6. Floren

    Floren Active Member

    148
    77
    28
    Jun 6, 2014
    Ratings:
    +77
    Local Time:
    8:42 AM
    @eva2000, default terminal in RHEL, I did not changed the color scheme:

    screen.jpg

    Check the OQGraph functionality I enabled in MariaDB 10.0.12. :D
     
  7. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Oh you meant terminal app itself.
     
  8. Floren

    Floren Active Member

    148
    77
    28
    Jun 6, 2014
    Ratings:
    +77
    Local Time:
    8:42 AM
    @eva2000, ya, in a Gnome environment.
     
  9. Sunka

    Sunka Well-Known Member

    1,150
    325
    83
    Oct 31, 2015
    Pula, Croatia
    Ratings:
    +525
    Local Time:
    2:42 PM
    Nginx 1.17.9
    MariaDB 10.3.22
    How to upgrade screen to newest version (4.4.0)?

    Code:
    [root@tvor-ocean ~]# screen -v
    Screen version 4.01.00devel (GNU) 2-May-06
    
    
    [root@tvor-ocean ~]# yum list screen -q
    Installed Packages
    screen.x86_64            4.1.0-0.23.20120314git3c2946.el7_2            @updates
    
    
    [root@tvor-ocean ~]# yum update screen
    Loaded plugins: fastestmirror, priorities
    Loading mirror speeds from cached hostfile
     * base: mirror.imt-systems.com
     * epel: mirror.de.leaseweb.net
     * extras: ftp.plusline.de
     * updates: ftp.plusline.de
    135 packages excluded due to repository priority protections
    No packages marked for update
     
  10. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  11. eva2000

    eva2000 Administrator Staff Member

    54,087
    12,177
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,735
    Local Time:
    11:42 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    Bringing this thread up for discussion again. Screen allows your SSH connection tasks (i.e. running Centmin Mod install etc) to survive SSH disconnections.

    For long tasks, I always use Screen session so I can return it after exiting SSH session.
     
  12. Jon Snow

    Jon Snow Active Member

    814
    163
    43
    Jun 30, 2017
    Ratings:
    +240
    Local Time:
    9:42 AM
    Nginx 1.13.9
    MariaDB 10.1.31
    The only time I randomly lost SSH connection was with Putty, but ever since switching to a new SSH client, I've never experienced it. I guess it'll only be beneficial to me if an SSH connection hangs probably from a networking issue.

    I remember starting a thread asking about multiple SSH connections for different servers and someone recommended Screen to me. I found that using Xshell's tabs worked as an alternative too.