iFUEL INTERACTIVE

A NY Interactive Agency and a Division of Agency212

See you on Flickr See you on Twitter See you on FaceBook Subscribe

Archive for February, 2011

Reindexing Magento Data via a Cron Job
February 11th, 2011  |  3 COMMENTS  |  Development, Magento, PHP
Tags: , , ,

I like to have all Magento data re-indexed every night via a cron job. That way I KNOW the indexes are up to date.

To create the cron job, add the following to your cron file to reindex every day at 4am

0 4 * * * php -f /shell/indexer.php reindexall

Note: If you get an error telling you you’re out of memory similar to:

PHP Fatal error: Allowed memory size of 262144 bytes exhausted (tried to allocate 7680 bytes) in …/app/code/core/Mage/Index/Model/Indexer.php on line 163

Try commenting out php_value memory_limit and php_value max_execution_time in your .htaccess file.

Copyright iFuel Interactive © 2010. All Rights Reserved.
Going up? Click here.A NY INTERACTIVE AGENCY