Reduced by 1% when order is placed
Hurry up to get the best offer!
Rating 5 stars - 1 votes

Schedule automated cron tasks not overloading your server

Have you ever came up with the need to periodically do the same job? Would you like these recurring tasks to be running automatically? It is possible setting up cron job in Magento 2 (Magento Open Source 2, Adobe Commerce).

What is Magento 2 (Magento Open Source 2, Adobe Commerce) cron?

Cron jobs are automated events run on a regular basis. They allow to avoid manual tasks accomplishing, as you just need to set correct settings and actions will be accomplished for you after a certain interval. For example, without a cron job set-up, you will have to manually update inventory and catalog indexes several times a day. If you have a large website this can take long time and forgetting to do it can cause loss of information and money, as a result!

What can be cron tasks?

As was already mentioned, these are the tasks that are repeated from time to time and are important for maintaining stability of your store. You can set up cron tasks to run Magento 2 (Magento Open Source 2, Adobe Commerce) cron import or export, scheduled backup/restore, reports generating, inventory update, price changes etc.

How to avoid server overload during cron tasks executing?

Very often cron tasks cause heavy load on your server, especially if the procedures are performed within short intervals. To avoid overload of your server you can set up data-related updates using Store Manager for Magento application. One of database connection type it uses is bridge and using it it is easier to manage your database, as changes are made locally and then posted to web. Thus, less requests to server are made and this keeps it from overload.

Setting up scheduled tasks via the application is possible with the help of import configurations or SQL queries. They should be saved to file locally at your PC to further be added to scheduler.

Please note, SQL statements require special technical skills and should be created beforehand.

How to set up cron job in Store Manager for Magento?

In case you need to update your store details via regular Magento 2 (Magento Open Source 2, Adobe Commerce) cron import, using Store Manager for Magento it is possible to set up import configuration and update your database using the information you receive from your supplier. For this you just need to have information from your supplier in file (or HTTP or FTP link to it) and make all the necessary settings for scheduling regular updates.

It does not require from you special technical skills and will be equally easy for online shop possessor as well as for specialist.

In case you need to make some special content updates, it is possible to create SQL query in Custom SQL section of Store Manager and save it locally at some directory at your computer.

In case you already have .sql file, you can make it work on schedule. For that in Store Manager for Magento, open tab Addons tab under the Left-side menu and there you will see option “Automated Backup”. There select the Script Executions tab and create a new configuration. You can also find the all created regular tasks under the 'Show Scheduled tasks' tab.

Automated Script Execution

In the new window appearing, you will be able to indicate the task name and its type. For execution of SQL query, you need to select type “Automated BackUp and Script Execution: Automated script execution”.

Then select or create task configuration, loading the file with SQL query and making additional settings.

Select the SQL Query

Further you also need to indicate when the task will automatically start and with what frequency repeated.

Add Task to Scheduler

Moreover, with Bridge type of connection you can make additional settings to automatically do “Get data from web” before the changes and “Post changes to web” after them.

That is pretty much all you need to do to get your cron job in Magento 2 (Magento Open Source 2, Adobe Commerce) up and running without heavy lifting on your server.

Try FREE Store Manager yourself! Get it Now!

Related Articles:

automated magento backups running on schedule tutorial

Automated Magento BackUps Running on Schedule

Schedule automatic Magento database backup on daily, weekly or monthly basis or set it up to be performed every few hours. Read More...

how to perform automated product import

How to Perform Automated Product Import

Schedule Magento import to be accomplished on hourly, daily or weekly basis using the saved configuration. Read More...

magento 2 speed up

Magento 2 Speed Up

Effective tips on how to speed up Magento 2 and boost SEO. Read More...

Store Diagnostics Troubleshoot Magento Website Problems

Store Diagnostics – Troubleshoot Magento Website Problems

The list of Magento store diagnostics types and their explanation. Read More...

Be the first to comment.
Live Chat