I just moved to a hosting that "supports" both SSH and cron job. However, the following are the limitations:
1. I can not use crontab -u in SSH 2. The official cron job runs at my root which is 3 levels up from ADMIN directory. Anyway out? Charter, could this be another enhancement to the new version of PHPDIG script? |
Because my cron job has to run in my root. I try the following:
1. I make another copy of spider.php and place it in my root. 2. I try "php spider.php cronlist >> spider.log" I got "path not found" types of errors in spider.log 3. I change $relative_script_path from ".." to "public_html/phpdid" (line 31, that is my path). I got nothing (0 byte) in spider.log file. Anything I did wrong? Did anyone try to run shell mode spider in directories other than admin? Please help!!! |
Finally, I get some output in spider.log:
<br /> <b>Warning</b>: main(../includes/config.php): failed to open stream: No such file or directory in <b>/home/takpoli/public_html/spider.php</b> on line <b>91</b><br /> <br /> <b>Warning</b>: main(): Failed opening '../includes/config.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/home/takpoli/public_html/spider.php</b> on line <b>91</b><br /> <br /> <b>Warning</b>: main(../libs/auth.php): failed to open stream: No such file or directory in <b>/home/takpoli/public_html/spider.php</b> on line <b>92</b><br /> <br /> <b>Warning</b>: main(): Failed opening '../libs/auth.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/home/takpoli/public_html/spider.php</b> on line <b>92</b><br /> <br /> <b>Warning</b>: main(../admin/robot_functions.php): failed to open stream: No such file or directory in <b>/home/takpoli/public_html/spider.php</b> on line <b>96</b><br /> <br /> <b>Warning</b>: main(): Failed opening '../admin/robot_functions.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/home/takpoli/public_html/spider.php</b> on line <b>96</b><br /> <br /> <b>Warning</b>: main(../libs/htmlheader.php): failed to open stream: No such file or directory in <b>/home/takpoli/public_html/spider.php</b> on line <b>102</b><br /> <br /> <b>Warning</b>: main(): Failed opening '../libs/htmlheader.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/home/takpoli/public_html/spider.php</b> on line <b>102</b><br /> <head> <br /> <b>Warning</b>: main(../libs/htmlmetas.php): failed to open stream: No such file or directory in <b>/home/takpoli/public_html/spider.php</b> on line <b>104</b><br /> <br /> <b>Warning</b>: main(): Failed opening '../libs/htmlmetas.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in <b>/home/takpoli/public_html/spider.php</b> on line <b>104</b><br /> </head> <body bgcolor="white"> <img src="../phpdig_logo_2.png" width="200" height="114" alt="PhpDig PHPDIG_VERSION" /><br /> <h3><br /> <b>Fatal error</b>: Call to undefined function: phpdigprnmsg() in <b>/home/takpoli/public_html/spider.php</b> on line <b>108</b><br /> 500 Can't connect to cronlist.txt:80 (Bad hostname 'cronlist.txt') It seems some other places need to be change. Could anyone help? Thanks. |
Try using absolute paths (e.g. /usr/bin/php -f /path/to/spider.php)
Don't forget the -f part |
All times are GMT -8. The time now is 02:06 PM. |
Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright © 2001 - 2005, ThinkDing LLC. All Rights Reserved.