Search code examples
phpbashnohupphp-resque

PHP nohup process randomly stops


I have a php-redis process which is running in the background and 99% of the time it works perfectly and continues to run. However, every so often the process just dies without any reason. There is nothing in any of the logs, the server does not run out of processing power, ram, etc.

It is being started with a bash script and is run with nohup.

Anyone have any ideas? I have been debugging this for days and am out of ideas. I can provide more information if you need it.


Solution

  • For this, I would certainly recommend using supervisor to manage the process. It will ensure the process is always running/waiting, and will automatically restart it on failure.