APLawrence.com -  Resources for Unix and Linux Systems, Bloggers and the self-employed

Unix, Xenix and ODT General FAQ


Some material is very old and may be incorrect today

© December 2003 (various)

How can I reconnect to a disconnected session?

Whether it's a modem a vpn that drops, or just accidentally closing a Windows emulator, sometimes you lose your connection. Users get kicked out, and that screws up their software.

The usual answer to that is to install "screen" because it will let you reconnect.

Unfortunately "screen" is a Swiss army knife, and it does way too much, including terminal emulation that you apparently can't avoid - it wants to be a vt100 terminal and that's all there is to it: the darn thing even watches your function keys and oh so helpfully translates them to vt100 sequences! Lousy idea if your software doesn't like vt100.

If it DOES like vt100, screen may be just what you want.

I found that "dislocate" is part of the "expect" package and it does just what I want: allows you to reconnect to a session. It doesn't do anything else, and that's good.

Of course if you DO want multiple windows and everything else screen offers, it's a great tool.

To use screen, or dislocate, you need to run them BEFORE you get disconnected.

 screen yourprog
 dislocate yourprog
 

Then, when you want to reconnect:

 screen -D -R
 dislocate -l
 

Binaries of both screen and expect are available from Skunkware for SCO and of course easily available for Linux..


If you found something useful today, please consider a small donation.



Got something to add? Send me email.





(OLDER)    <- More Stuff -> (NEWER)    (NEWEST)   

Printer Friendly Version

->
-> (SCO Unix) How can I reconnect to a disconnected session?


Inexpensive and informative Apple related e-books:

Take Control of the Mac Command Line with Terminal, Second Edition

Take Control of OS X Server

iOS 8: A Take Control Crash Course

iOS 10: A Take Control Crash Course

Are Your Bits Flipped?






Printer Friendly Version

Have you tried Searching this site?

This is a Unix/Linux resource website. It contains technical articles about Unix, Linux and general computing related subjects, opinion, news, help files, how-to's, tutorials and more.

Contact us


Printer Friendly Version





Some people, when confronted with a problem, think "I know, I'll use sed." Now they have two problems. (Jamie Zawinski)




Linux posts

Troubleshooting posts


This post tagged:

FAQ



Unix/Linux Consultants

Skills Tests

Unix/Linux Book Reviews

My Unix/Linux Troubleshooting Book

This site runs on Linode