1

Hi I'm trying to run the indexer for a website using the cron. I have the timing set correctly but the command is not working, probably something simple but any ideas people?

/opt/plesk/php/5.5/php -f /var/www/vhosts/aropec.co.uk/shell/indexer.php reindexall

9
  • what happen if you execute this line in your Terminal?
    – Pawel
    Aug 19, 2016 at 13:35
  • No such file or directory Aug 19, 2016 at 13:39
  • did you execute the whole line? I meant /opt/plesk/php/5.5/php -f /var/www/vhosts/aropec.co.uk/shell/indexer.php reindexall
    – Pawel
    Aug 19, 2016 at 13:48
  • /opt/plesk/php/5.5/php: No such file or directory Aug 19, 2016 at 13:54
  • you use the a wrong php path. To finde the correct path execute in your Terminal which php
    – Pawel
    Aug 19, 2016 at 14:15

1 Answer 1

1

either you can do it by below script in your php file

$indexingProcesses = Mage::getSingleton('index/indexer')->getProcessesCollection(); 

foreach ($indexingProcesses as $process) {

      $process->reindexEverything();

}
1
  • So I need to call up a php file I can't just do it directly? Aug 19, 2016 at 13:40

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.