Saturday, April 23, 2022

[SOLVED] Linux nohup command not working correctly

Issue

So I have a startup script that's suppose to run this python script in the background using nohup. And I use nohup because I don't want it to be dependent on if I'm logged in or not. So, it's running from an SD card which I then turned into an image and burned onto another card.

The strange thing is that it works correctly in the first and not the second. I can look at nohub.out in the first and see the expected output but in the copy it's completely blank.

When I do ps aux | grep python I can see the script process running in both so I'm not sure why the copy doesn't seem to be doing what it's suppose to


Solution

I figured it out. Apparently they all had to be set to lock for some reason. When I did that they worked as expected



Answered By - Jared Joke
Answer Checked By - Mildred Charles (WPSolving Admin)