I have a php script that I'm runnign via cron. Sometimes it exits when finished and sometimes it hangs.. I have no idea why, it runs and exits via a sheel and runs then exits thru Zend Studio using my server as to debug.
The script goes out and index's anythign new on youtube in certain categories. How can I insure the php script die's before the next cron job starts? Is there a way to do this in a php or a shell script? I have 3 php files that run, one per hour.. all three have the eextension _auto.php
I'd like to search running processes and if _auto.php is found, killl the process.. I don't know enough about shell scripts to do that and my googl searches have come up empty. Or is it better to let the php script first check for another copy running and kill it if it is?