This is the second part of our tutorial series on configuring backups in Magento 2. Previously, we’ve discussed how to create backups in Magento 2.
Magento not only allows for backing up the store data manually, but you can also automate the process. Setting up a backup schedule will ensure you always have a backup to the nearest stable store configuration.
In this tutorial, you’ll learn how to schedule daily, monthly or yearly backups in Magento 2.
Follow these steps to set a backup schedule:
Step 1: Go to Stores => Configurations (under Settings) –
Step 2: Expand the Advanced section from left sidebar and click on System –
Step 3: Expand the Scheduled Backup Settings section under advanced system settings and set Enable Scheduled Backup to “Yes” –
Step 4: Set the settings for the backup schedule by specifying the following details:
- Backup Type: Set the type of backup you want to create a schedule for:
- Database and Media
- System (excluding Media)
- Start Time: Set when the backup process should start. Set this to the time of the day when you think you have least visitors on the store.
- Frequency: Set whether you want the backup to be taken daily, monthly or yearly.
- Maintenance Mode: Set this to “Yes” if you want to put the store in maintenance mode during the backup process.
Step 5: Click on the Save Config button to save the backup schedule.
Step 6: Magento will display a pop-up message to prompt you to refresh invalidated caches.
Follow these steps to flush cache in Magento 2.
This concludes our tutorial on how to schedule backups in Magento 2. To learn how to perform a rollback, follow last part of our series on configuring backups.