deech123 Posted November 1, 2010 Share Posted November 1, 2010 Hi guys,on my server I can set cron jobs like : /ramdisk/bin/php5 -q /home1/mysite/public_html/adminfolder/searchcron?full=1&token=fApvuyFp If I do this I get an error like :No input file specified.then I thought well let's do this (I add .php to the searchcron): /ramdisk/bin/php5 -q /home1/mysite/public_html/adminfolder/searchcron.php?full=1&token=fApvuyFp no luck either.If I do this I get an error like :No input file specified.and with this, it's also not working /ramdisk/bin/php5 -q http://www.myserver.com/adminfolder/searchcron.php?full=1&token=fApvuyFp I get the error :/bin/sh: http://www.myserver.com/adminfolder/searchcron?full=1: No such file or directoryI'm having over 5 cronjobs working fine with files on the server.only the last I want to add was the build search index.no luck.any idea what I can do to make it work? Link to comment Share on other sites More sharing options...
deech123 Posted November 1, 2010 Author Share Posted November 1, 2010 Did some extra testing.found out that there must be an error in the searchindex page cron stuff :-)if I have this : /ramdisk/bin/php5 -q /home1/mysite/public_html/adminfolder/searchcron.php?full=1&token=fApvuyFp this is correct, but gives me an error like : no input file specified.when I try the direct url : http://www.mysite.com/adminfolder/searchcron.php?full=1&token=fApvuyFp then the page is loading and loading and then after 2 minuts I get an error page like : this page does not longer excist.and the url becomes : http://www.mysite.com/adminfolder/&conf=4so really hope anybody can give me the clue to make it work.I managed to cronjob my hugh import everynight as well as other jobs, but the search index is the last I want to run....thx Link to comment Share on other sites More sharing options...
nzrobert Posted February 23, 2011 Share Posted February 23, 2011 did you find a solution to this?I'm looking to re-build an index every 2 days or so and would like a cron job to do this, any help is appreciated.Thanks!Robert Link to comment Share on other sites More sharing options...
deech123 Posted February 23, 2011 Author Share Posted February 23, 2011 Hi just add this in a new file or in you cronjob file you are making. echo "\n\n*******************************\nSTART INDEX\n*******************************\n"; if (substr(_COOKIE_KEY_, 34, 8) != 'fApv0mFp') echo ("ERRORS: SEARCH INDEX NOT SUCCESFUL"); ini_set('max_execution_time', 7200); Search::indexation('1'); /* Tools::redirectAdmin($_SERVER['HTTP_REFERER'].'&conf=4'); */ echo ("SEARCH INDEX SUCCESFUL!"); die(); works like a charm. Link to comment Share on other sites More sharing options...
nzrobert Posted February 23, 2011 Share Posted February 23, 2011 Hi,Thanks for that, what is the code i enter into CRON to get it to run correctly?CheersRobert Link to comment Share on other sites More sharing options...
deech123 Posted February 23, 2011 Author Share Posted February 23, 2011 robert,that depens on the cron you use, i have a cron shedule in cpanel..so they are sometimes different.you must ask your hosting firm what to use or look at their site what they offer as faq. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now