2
votes

crontab: run cron.php every 5 minutes;

config.xml

<crontab>
    <jobs>
            <newsletter_send_all>
                <schedule><cron_expr>20 2 * * *</cron_expr></schedule>
                    <run><model>psteal/observer_psteal::updatefrommagento</model></run>
            </newsletter_send_all> 
    </jobs>
</crontab>

The generated data in DB ,TABLE is cron_schedule:

job_code status messages created_at scheduled_at

newsletter_send_all pending NULL 2013-01-25 02:18:46 2013-01-25 02:20:00

newsletter_send_all pending NULL 2013-01-25 02:18:46 2013-01-25 02:27:00

I don't know why magento generates two same cron jobs?It should be only one job(at 2013-01-25 02:20:00) ,Any ideas?

1

1 Answers

-1
votes

Try changing the cron task name from newsletter_send_all to psteal_newsletter_send_all for example, since newsletter_send_all is already defined in app/code/core/Mage/Newsletter/etc/config.xml