I’ve searched, googled, sat in IRC for a week and even talked to a friend who is devoutly aligned with linux but I haven’t yet received a solid answer.
I have written a shell script that runs as soon as I log into my non-root user and runs basically just does “./myprogram &” without quotation. When I exit shh my program times out and I am unable to connect to it until I log back in. How can I keep my program running after I exit SSH of my non-root user?
I am curious if this has to be done on the program level or what? My apologizes if this does not belong here, I am not sure where it goes to be perfectly honest.
Beside using
nohup, you can run your program in terminal multiplexer likescreenortmux. With them, you can reattach to sessions, which is for example quite helpful if you need to run terminal-based interactive programs or long time running scripts over a unstable ssh connections.boybuis a nice enhancement ofscreen.