Command line script run in background goes in stopped state
问题 I have a short php utility script, I run it from cli simply with: php myscript.php The script is always running, periodically performing some tasks (not relevant for the question). It doesn't need any input from the user. After running it, I usually press CTRL + z and then run bg to put the process in background, and everything is fine. If I run it as: php myscript.php & the script is put on background on start, but it is also put in a stopped state. Example: [1] 11513 [1]+ Stopped php