Reputation: 728
If a do screen in linux, and then ssh into some other machine, run a job there, detach from screen and disconnect the terminal. If i open the terminal again i can go that session and job is still running. I just want to know how internally this screen is working?
Upvotes: 1
Views: 3030
Reputation: 436
After ssh and successful login use screen -S screen_name to generate screen, then new tab will open. Run your program and you may close it. To see your program running use: screen -r screen_name.
Upvotes: 0
Reputation: 1638
Detach does exactly what literally means. It detaches the screen process from it's parent. It means that his parent (your ssh session) will not inform his dependent/child process about its termination.
For more info this links could be useful:
https://en.wikipedia.org/wiki/Nohup
https://unix.stackexchange.com/questions/3886/difference-between-nohup-disown-and
Upvotes: 2