Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have 64-bit RHEL 2.6.18-238.el5 running. I access the machine through vpn. I started an application via terminal and while application was running there was disconnection in vpn which closed my terminal. Upon reconnecting to vpn when I opened the terminal I could see that my application is still running ,checked using ps -ef command. Now how can I continue using my application in the terminal. Is there any way to access that running application in the terminal? Please help.Thanks

share|improve this question
up vote 3 down vote accepted

You should make a habit of starting screen as soon as you login in a remote box.

You might want to give retty a try, but keep in mind that your chances to regain control of your application are minimal.

share|improve this answer

You can use screen tool for situations like this.

First install the screen tool. Then type screen and run the application. If the VPN is disconnected, Log in to the server again and type server -ls.

It will list available screen sessions. To connect to a screen session type screen -r <session_name>. From there you can continue from the last disconnected position.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.