You are viewing an old revision of this post, from September 24, 2014 @ 17:18:06. See below for differences between this version and the current revision.

Setup cronjob for Magento’s server

Here is some popular command when you set a cronjob up for Magento by SSH.

1. Setup cronjob run every 5 minutes:

*/5 * * * * wget -O /dev/null -q http://www.example.com/cron.php > /dev/null    

or

*/5 * * * * /bin/sh /[magento_path]/cron.sh

2. Setup running reindex data every 60 minutes:

*/60 * * * * php /directory_to_magento/shell/indexer.php reindexall

 

Revisions

Revision Differences

September 24, 2014 @ 17:18:06Current Revision
Content
Unchanged: <p>Unchanged: <p>
Unchanged: Here is some popular command when you set a cronjob up for Magento by SSH.Unchanged: Here is some popular command when you set a cronjob up for Magento by SSH.
Unchanged: </p>Unchanged: </p>
Unchanged: <p>Unchanged: <p>
Unchanged: 1. Setup cronjob run every 5 minutes:Unchanged: 1. Setup cronjob run every 5 minutes:
Unchanged: </p>Unchanged: </p>
Unchanged: <p>Unchanged: <p>
Unchanged: */5 * * * * wget -O /dev/null -q http://www.example.com/cron.php &gt; /dev/null &nbsp; &nbsp;Unchanged: */5 * * * * wget -O /dev/null -q http://www.example.com/cron.php &gt; /dev/null &nbsp; &nbsp;
Unchanged: </p>Unchanged: </p>
 Added: <p>
 Added: or
 Added: </p>
 Added: <pre style="margin-top: 0px; margin-bottom: 0px; padding: 6px 10px; border: 1px solid rgb(204, 204, 204); font-size: 12px; line-height: 19px; overflow: auto; border-radius: 3px; background-color: rgb(248, 248, 248);">
 Added: */5 * * * * /bin/sh /[magento_path]/ cron.sh</pre>
Unchanged: <p>Unchanged: <p>
Unchanged: 2. Setup running reindex data every 60 minutes:Unchanged: 2. Setup running reindex data every 60 minutes:
Unchanged: </p>Unchanged: </p>
Unchanged: <p>Unchanged: <p>
Unchanged: */60 * * * * php /directory_to_ magento/shell/indexer.php reindexallUnchanged: */60 * * * * php /directory_to_ magento/shell/indexer.php reindexall
Unchanged: </p>Unchanged: </p>
Unchanged: <p>Unchanged: <p>
Unchanged: &nbsp;Unchanged: &nbsp;
Unchanged: </p>Unchanged: </p>

Note: Spaces may be added to comparison text to allow better line wrapping.

No comments yet.

Leave a Reply