I am a Front-End Developer whose duties have been expanded to cover our entire Magento installation. We have catalog price rules that drop off at night. Are there cron job tests we can run to verify functionality? Other than the cron items that are in the root should I be checking elsewhere?

  • you can test via Mage::log('u rmessage') and check into var/log folder
    – Keyul Shah
    Apr 2 '14 at 15:38
  • May I ask for more specificity? I'm a front-ender. I apologize.
    – mcmattgr
    Apr 2 '14 at 15:48

If you open app\code\core\Mage\CatalogRule\etc\config.xml, youll see that the catalogrule_apply_all job defines a function called dailyCatalogUpdate in Mage_CatalogRule_Model_Observer. So you could add


somewhere inside that function and see if "whatever" is written to your logfile in /var/log/logfilename.log. You have to enable the logs in the backend however. You know how to do that?

Furthermore you can check what the table cron_schedule says, like that:

 select * from cron_schedule where job_code like '%apply_all%' order by schedule_id;

This will give you the latest price rule job on top. Its status should be success, if it isnt, see if it was executed at all.



There is an interesting tip here regarding being notified when the cron runs: http://www.magentocommerce.com/boards/viewthread/73390/

And also a nice script here: http://blog.nexcess.net/2010/10/03/finding-the-status-of-magento-cron-jobs-tasks/ to view cron job tasks in a nicer table format.

We've had issues with price rules previously (I believe the cron runs around midnight), but the issues were actually caused by another cron (for a plugin) failing around the same time.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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