[NCLUG] Switching IPs & Maintaining Connections

Stephen Warren swarren at wwwdotorg.org
Sun Jan 30 16:06:10 MST 2005

jeff wrote:
> I kinda doubt there is a way to disconnect an ssh session then 
> reconnect to it from another IP...

Look into a utility called screen. It's basically a proxy for a shell 
connection - kinda like VNC, but for text!

Basically, on your target machine, you run screen, which then spawns a 
shell and connects you to it, so that you pretty much can't tell the 
difference between it and direct use of the shell.

Then, you can 'detach' from the session, but screen continues to run, 
and the shell stays around.

To reconnect, simply ssh back to the host running screen, run screen and 
it'll attach to the existing instance, and you have your shell session back.

Of course, this won't work for anything like tunneled X applications, or 
forwarded ports, but if all you want is persistent shell state, it's 

Stephen Warren, Software Engineer, NVIDIA, Fort Collins, CO
swarren at wwwdotorg.org     http://www.wwwdotorg.org/pgp.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 256 bytes
Desc: OpenPGP digital signature
URL: <http://lists.nclug.org/pipermail/nclug/attachments/20050130/846453db/attachment.pgp>

More information about the NCLUG mailing list