PhpDig.net

Go Back   PhpDig.net > PhpDig Forums > Troubleshooting

Reply
 
Thread Tools
Old 04-06-2004, 09:21 PM   #1
jerrywin5
Orange Mole
 
Join Date: Mar 2004
Posts: 48
Problem running cron job

I am able to run the spider from the shell and index URLs in a file using
Code:
php -f spider.php newurls.txt >> spider.log
However, when I setup a cron job using
Code:
0 1 * * * php -f spider.php newurls.txt >> spider.log
it does not work. I get the following error:
Code:
/bin/sh: php: command not found
and do not know why. Which command is the error referring to? What do I need to change?

Any help would be appreciated.
jerrywin5 is offline   Reply With Quote
Old 04-10-2004, 04:07 PM   #2
Charter
Head Mole
 
Charter's Avatar
 
Join Date: May 2003
Posts: 2,539
>> Which command is the error referring to?

Hi. Looks like it refers to PHP as not found. Perhaps try the following instead:

Code:
0 1 * * * /full/path/to/php -f /full/path/to/spider.php /full/path/to/newurls.txt >> /full/path/to/spider.log
__________________
Responses are offered on a voluntary if/as time is available basis, no guarantees. Double posting or bumping threads will not get your question answered any faster. No support via PM or email, responses not guaranteed. Thank you for your comprehension.
Charter is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Baffled by Cron Job Slider How-to Forum 2 12-15-2004 11:34 PM
Reindex without cron job? ark2424 How-to Forum 8 12-09-2004 05:54 AM
cron job problems takpoli How-to Forum 3 05-12-2004 01:26 PM
Alternative to Cron job? jirving Troubleshooting 1 09-29-2003 05:07 PM
cron job David J Harmon How-to Forum 1 09-27-2003 07:20 AM


All times are GMT -8. The time now is 12:38 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright © 2001 - 2005, ThinkDing LLC. All Rights Reserved.