I was having an issue with Magento 2 cron jobs.

They seemed to be configured correctly, but every morning I got the CMS admin alert that they need to be run. The client also reported that new products didn’t appear in the frontend after saving. A sign that the database wasn’t reindexing.

/bin/sureserver-cron.sh was trying to run every 15minutes, but further investigation showed the cron script wasn’t completing.


Check the cron logs




Magento 2 cron error

[2017-09-25 09:28:10] setup-cron.ERROR: Your current PHP memory limit is 400M. Magento 2 requires it to be set to 756M or more. As a user with root privileges, edit your php.ini file to increase memory_limit. (The command php –ini tells you where it is located.) After that, restart your web server and try again. [] []


Cron Fix

Raising the memory limit to 800 MB in the global php.ini solved the issue and allowed the cron script to complete.

Leave a comment