back       next

screen

ways to continue run command after shell exit

  1. screen:
    screen -dmS <screen_name> <command>
    exit

  2. nohup:
    nohup <command> &
    exit

  3. at:
    echo "<command>" | at now
    exit

  4. disown:
    <command> &
    disown -h
    exit

Share screen session

  1. Start screen using the command:

    $ screen -S <SessionName>

    The -S switch gives the session a name, which makes multiple screen sessions easier to manage.

  2. Allow multiuser access in the screen session:

    CTRL-A
    :multiuser on

  3. Grant permission to the guest user to access the screen session:

    CTRL-A
    :acladd <guest_user>

  4. The guest user can now connect via:

    $ screen -x <host_user>/<SessionName>

Syndicate content