How to correctly configure Magento 2 cronjob under cPanel

Login via ssh as the account user (or login via cPanel -> Cronjobs)

# crontab -e
MAILTO=""
* * * * * /usr/local/bin/php -d memory_limit=-1 /home/demoshop/public_html/bin/magento cron:run > /home/demoshop/public_html/var/log/magento.cron.log
* * * * * /usr/local/bin/php -d memory_limit=-1 /home/demoshop/public_html/update/cron.php > /home/demoshop/public_html/var/log/update.cron.log
* * * * * /usr/local/bin/php -d memory_limit=-1 /home/demoshop/public_html/bin/magento setup:cron:run > /home/demoshop/public_html/var/log/setup.cron.log

(Replace demoshop by your own account name)


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 89268