Hi, i just tried to setup my first cronjob and I failed miserably.
My Goal: To run a php script every 30 minutes.
My attempt was as folows.
- vi foo
*/30 * * * * php /home/myusername/mydomain.com/script.php
- crontab foo
Now I get an email stating this.
I used this cron on my previous shared server without a problem. I also tried running it as a shell script whatever by putting #!/usr/local/bin/php -q on top of my php script, chmodding it to 755 and then just doing */30 * * * * /fullpath/script.php, but that doesn’t work either.
- How can I get this working?
- If i didn’t put MAILTO on the cron, what email does the system to use and how do I change or modify that?
Oh, and running php script.php from the shell runs perfect…Must have something to do with this server clustering which confuses the hell out of me.