A few Google search coupons later I got my answer: use start-stop-daemon to make it work. A donation however would always put a smile on my face though. Bramus is a Freelance Web Developer from Belgium. From the moment he discovered view-source at the age of 14 way back in , he fell in love with the web and has been tinkering with it ever since more … View more posts. Thank you very much! Both of them.
Join Stack Overflow to learn, share knowledge, and build your career. Connect and share knowledge within a single location that is structured and easy to search. I need to run a php script as daemon process wait for instructions and do stuff. I know PHP is not really the best option for daemon processes due to memory management issues, but due to various reasons I have to use PHP in this case. Any information will be really appreciated. Edit: Yes, there are some drawbacks, but not possible to control? That's just wrong.
Dear All, I have an application where I have to time to time keep checking the db if there is any update I got to run some function. So what is recommended cron job or php daemon. I would recommend a cron job.
PHP is a language primarily used by web developers, but even these have problems which have to be scheduled to background processes, like sending newsletters, analysing stats, or simply maintaining the database. The most common way to solve this, is abusing crond for almost everything. When things are getting more complicated, like running jobs every 10 seconds people get really creative like blocking the execution or whatever silly custom. I decided to do it a bit more the unix-way by writing a daemon process framework.