Cron job: Permission Denied error
I can edit a crontab file using:
crontab -e
I can create a job which runs every ten minutes:
*/10 * * * * /srv/www/mysite.com/public_html/myfolder/cron.php
But the email output (every ten minutes) is:
/bin/sh: /srv/www/mysite.com/public_html/myfolder/cron.php: Permission denied
What am I missing?
Using Ubuntu 10.04 LTS stackscript; a test wordpress install seems to be working normally
6 Replies
*/10 * * * * /usr/bin/php srv/www/mysite.com/public_html/myfolder/cron.php
or
*/10 * * * * cd /srv/www/mysite.com/public_html/myfolder/ && /usr/bin/php cron.php
/bin/sh: /usr/bin/php: not found
Apparently the LAMP StackScript I was using didn't have this step in it.