Screen is a neat way to keep your processes running when you need to disconnect from the machine or have a dodgy connection which gets reset (my case!).
You run screen on a *nix machine that is always on and it keeps your processes running even if the connection dies or if you want to disconnect.
My setup:
~/.screenrc
startup_message off# hardstatuslinehardstatus onhardstatus alwayslastline#hardstatus string '%{= kG}%-Lw%{= kW}%50> %n%f* %t%{= kG}%+Lw%< %{= kG}%-=%c:%s%{-}'hardstatus string '%{= kG}%-Lw%{= kW}%50> %n%f* %t%{= kG}%+Lw%<'screen -t ubuntu3 0screen -t ubuntu3 1screen -t ubuntu2 ssh ubuntu2
Usage:
to start:
screento reconnect to an existing screen session
screen -xto switch screens (n is the screen number)
Ctrl+a nto close a screen
Ctrl+dNote: if the machine hosting screen reboots then the screen session is lost
More info here:
http://www.askbjoernhansen.com/2006/02/07/happy_unix_screen.html
http://www.rackaid.com/resources/linux-tutorials/general-tutorials/using-screen/
http://nigel.mcnie.name/blog/how-i-use-screen
On Mac OS X, probably need to make an adjustment so your backspace key works:
http://www.pyrosoft.co.uk/blog/2008/04/28/fixing-the-backspace-key-with-os-x-and-linux-screen/