LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Crontab & PHP help (https://www.linuxquestions.org/questions/linux-newbie-8/crontab-and-php-help-760383/)

CapnStank 10-07-2009 02:36 PM

Crontab & PHP help
 
I'm receiving the following error from my crontab and have a pretty good idea what is causing it; I just don't know what to do about it.

The error:
Code:

/bin/sh: php: command not found
The entry in crontab file
Code:

*/10 * * * *      php /path/to/external.php
Now my assumption is that it cannot find the php location and is defaulting to /bin/sh. How do I locate my PHP install directory? After I find it I assume I just modify the section of code above where php is?

Tux-Slack 10-07-2009 02:38 PM

Issue:
whereis php
It will give you the full path to executable, then in crontab instead of php /script replace the php with the fullpath


All times are GMT -5. The time now is 02:00 AM.