thenorm
Posts: 11
Joined: Mon Feb 24, 2014 2:05 am

login to running job?

Tue Feb 13, 2018 5:35 am

Can I start a program and log back in later to interact with it? This with SSH on command line, no desktop. I always seem to get a new session. I know the program is still running but I can't talk to it.

n67
Posts: 938
Joined: Mon Oct 30, 2017 4:55 pm

Re: login to running job?

Tue Feb 13, 2018 5:52 am

thenorm wrote:
Tue Feb 13, 2018 5:35 am
Can I start a program and log back in later to interact with it? This with SSH on command line, no desktop. I always seem to get a new session. I know the program is still running but I can't talk to it.
I believe the program you are looking for is "screen".

Note: I know many people these days recommend "tmux" over "screen". I am a long time user of "screen" and a recent uptaker of "tmux". I have to say that while "tmux" has some really nifty new features, it is far from "done". I've noticed a lot of weird quirks and cannot recommend it to the new user. "screen", OTOH, has been around a very long time, and is a really mature, stable product.

Therefore, I recommend "screen", unless you have a really good reason for wanting "tmux" and are willing to deal with its eccentricities.

Anyway, back to topic, OP should install screen and start playing around with it.
"L'enfer, c'est les autres"

G fytc hsqr rum umpbq rm qyw rm rfc kmbq md rfgq dmpsk:

Epmu Sn!

J lnacjrw njbruh-carppnanm vxm rb mnuncrwp vh yxbcb!

W. H. Heydt
Posts: 10891
Joined: Fri Mar 09, 2012 7:36 pm
Location: Vallejo, CA (US)

Re: login to running job?

Tue Feb 13, 2018 6:39 am

You can also put a job in the background and later bring it to the foreground. Run the command "man fg" to find out more.

Return to “General discussion”