0

I hope someone can help because I'm really struggling. My Magento cron is throwing an error:

#0 /app/code/core/Mage/Cron/Model/Schedule.php(68): Mage::exception('Mage_Cron', 'Invalid cron ex...')
#1 app/code/community/Aoe/Scheduler/Model/Schedule.php(858): Mage_Cron_Model_Schedule->setCronExpr('0 0 3 1/1 * ? *')
#2 app/code/community/Aoe/Scheduler/Model/Schedule.php(128): Aoe_Scheduler_Model_Schedule->setCronExpr('0 0 3 1/1 * ? *')
#3 app/code/community/Aoe/Scheduler/Model/ScheduleManager.php(254): Aoe_Scheduler_Model_Schedule->initializeFromJob(Object(Aoe_Scheduler_Model_Job))
#4 app/code/community/Aoe/Scheduler/Model/ScheduleManager.php(165): Aoe_Scheduler_Model_ScheduleManager->generateSchedulesForJob(Object(Aoe_Scheduler_Model_Job))
#5 app/code/community/Aoe/Scheduler/Model/Observer.php(43): Aoe_Scheduler_Model_ScheduleManager->generateSchedules()
#6 app/code/local/Mage/Core/Model/App.php(1300): Aoe_Scheduler_Model_Observer->dispatch(Object(Varien_Event_Observer))
#7 app/code/local/Mage/Core/Model/App.php(1281): Mage_Core_Model_App->_callObserverMethod(Object(Aoe_Scheduler_Model_Observer), 'dispatch', Object(Varien_Event_Observer))
app/Mage.php(448): Mage_Core_Model_App->dispatchEvent('default', Array)
cron.php(77): Mage::dispatchEvent('default')
#10 {main}

The problem I have is I just can't find the job that's got that cron expression! I've tried grep in my Magento directory for the expression but all I get is the error reports/logs.

Can anyone help?

1 Answer 1

0

What you can find when you 'grep' through the filesystem is basically the default setting for a cron job.

Many extensions allow you to define the execution expression separately for example from System -> Configuration. Also, Aoe_Schedule allows you to modify the execution expression (from System -> Scheduler -> Job Configuration). These settings then should be stored in core_config_data table with a path like crontab/jobs/CRON_CODE/schedule/cron_expr.

So, to find the faulty cron expression you can try to select * from core_config_data where value = "0 0 3 1/1 * ? *" for example from within PHPMyAdmin.

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.