|
Post by soundwave on Apr 26, 2019 20:19:23 GMT -8
I've noticed that after starting the SGS python script it works for 4-5 hours then stops. Is there a log I can look at to get info on what is happening?
|
|
jared
New Member
Posts: 5
|
Post by jared on Apr 28, 2019 16:07:36 GMT -8
I found that the script would halt if i did not start the script via a persistent login. So basically, SSH to the raspberry pi and then running the script only lasted as long as I was connected to that SSH session. Are you looking at the Desktop of the Raspberry Pi? or an SSH session?
|
|
|
Post by SDL on Apr 28, 2019 17:50:38 GMT -8
AHA! I know exactly what is going on!
If your terminal window terminates for any reason then any tasks started from that window will also die.
Here is how you can avoid that. The magic is "nohup"
Do this:
nohup sudo python SGS.py & and it will run until the Raspberry is rebooted. It also creates a nohup.out file that you can check for output. Use this command
tail -f nohup.out and after a bit (it outputs hunks of text), you will see your normal output.
Best regards, BP
|
|