php - Unix Cron Not Executing -
I am executing a shell script every time such as a cron job:
* * * * * / Bin / bash /var/www/html/stream.sh The script contains the following code:
#! / Bin / sh if ps -ef | Grep -v grep | Grep get_tweets.php; Then exit 0 and nowhupp php /var/www/html/streaming/db/get_tweets.php> / Dev / null & amp; As a cron, I am also running another shell script, the only difference between the two "get_tweets" has been replaced by "parse_tweets_keyword" and the cron is executed like this: << code / P>
* * * * * / bin / bash /var/www/html/process-check.sh The problem is, while the subsequent cron is full Works fine, it does not seem to run successfully before, but when I run the command:
newhope php / var / www / html / streaming / db / get_tweets .php & gt; / Dev / null & amp; The script runs completely, so I'm not completely sure that the permissions for all the files are correct and executable and I run crons as root under crontab. And the PHP script I'm running is running as background processes. If someone can help or know this issue, it would be greatly appreciated, I tried to run PHP scripts through crop, instead of running shell scripts in PHP as a line in the crossbab Also open for better ways of running
Comments
Post a Comment