Something you can use when performing long running processes on UNIX systems is GNU Screen.
Screen combined with SSH is to UNIX what Remote Desktop Connection is to Windows. Once you start screen, all processes you start under screen will remain running when you disconnect from a machine or are dropped by the server or network problems.
And like Remote Desktop Connection, you can start a process while connected from one machine and reconnect from another machine to resume your work.
To check whether you have existing screen sessions, type the following:
screen -ls
If the command outputs something starting with "There is a screen on ..." then you have one or more screen sessions. If the command outputs something starting with "No Sockets found in ...", then you do not have any screen sessions.
Generally you will only have one screen session. To "attach" to an existing screen session that is "detached"---if it is the only one---, type the following:
screen -r
To detach from a screen session you have open, type the following:
[CTRL]-a d (That is "Control" + "a" followed by "d")
After detaching, you can exit your terminal session.
To quit your screen session, type "exit" at your shell prompt and screen will quit.
If you do not have any screen sessions, type the following to start one:
screen
There are many more things you can do with screen but would take quite a bit to cover. If you want to learn more, please visit the "GNU screen" page at http://aperiodic.net/screen/ or read the fine manual ("man screen").
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment