Maintaining Connections

Screen

To start screen, type screen at the command prompt. Your original session will be detached and you will be brought to a new window.

This shows details such as screen geometry and character set. The important part is that 2(bash) at the end. The 2 is the number of the currently displayed terminal window, and bash is the shell. Users can press crtl+A, then the number of the screen to which they wish to attach, or press Ctrl+A followed by a D to get a list of terminal windows available.

Each screen can run any program contained on the cluster.

To detach a screen and come back to it later...use the system above to start a window with Matlab or another program. Then issue the key Ctrl+A followed by a D. This will drop the user back to the bash prompt after detaching any session. The user may logout at this point.


To reattach an existing session, login to the command prompt and type screen -ls. This will list all detached sessions.

[dpane@psych-o ~]$ screen -ls
There is a screen on:
    8673.pts-6.psych-o    (Detached)
1 Socket in /var/run/screen/S-dpane.

To reattach to that one session, I would type this at the bash prompt:

[dpane@psych-o ~]$ screen -r 8673.pts-6.psych-o    


From there, it will return the session to the current login.

-- David Pane - 2015-04-30

Comments

Topic revision: r1 - 2015-04-30 - dpane
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback