AnalyticDB for MySQL provides the data restoration capability. When you create an AnalyticDB for MySQL cluster, the data backup and log backup features are automatically enabled for the cluster. If data of the cluster is accidentally deleted, you can restore the data by using a full data backup set and several log backup sets within the most recent seven days. You can view data backup sets and modify data backup cycles and data backup retention periods in the AnalyticDB for MySQL console.
Usage notes
You cannot execute DDL statements on an AnalyticDB for MySQL cluster within about 10 minutes after a data backup of the cluster starts.
By default, the log backup feature is enabled, and log backup sets are retained for seven days free of charge.
After you release an AnalyticDB for MySQL cluster, the backup data of the cluster is deleted. If you want to retain specific data of the cluster, you can export the data to Object Storage Service (OSS) for backup before you release the cluster. For more information, see Export data to OSS.
Billing rules
The most recent data backup set of an AnalyticDB for MySQL cluster is retained free of charge. If a cluster contains multiple data backup sets, you are charged for the data backup sets other than the most recent one based on the pay-as-you-go billing method. For more information, see Pricing.
View backup sets
Log on to the AnalyticDB for MySQL console. In the upper-left corner of the console, select a region. In the left-side navigation pane, click Clusters. On the Clusters page, click an edition tab. Find the cluster that you want to manage and click the cluster ID.
In the left-side navigation pane, click Backup and Restoration.
On the Data Backup tab of the Backup and Restoration page, view information about the backup sets of the cluster, such as the backup start time, backup end time, free backup set size, and backup type.
NoteThe values of the Backup Size parameter that are displayed in the AnalyticDB for MySQL console vary based on the edition and the mode of the cluster.
Data Warehouse Edition in elastic mode or Data Lakehouse Edition: The values of the Backup Size parameter are the actual sizes of the backup sets in the cluster.
Data Warehouse Edition in reserved mode: The values of the Backup Size parameter are larger than the actual sizes of the backup sets in the cluster because the backup storage is equal to the disk storage that you select when you purchase the cluster.
For example, the preceding figure shows a screenshot of a backup set in an AnalyticDB for MySQL Data Lakehouse Edition cluster.
21.18 MB
indicates the actual size of the backup set generated by the cluster between 00:00 to 00:01 on December 1, 2024.
Modify backup settings
On the Backup and Restoration page, click the Backup Settings tab.
Click Modify Backup Settings. In the Backup Settings panel, configure the parameters that are described in the following table.
Parameter
Description
Data Backup Cycle
The days of the week on which you want to perform automatic data backups.
ImportantTo prevent unnecessary charges caused by more than one data backup set in your AnalyticDB for MySQL cluster, we recommend that you set the data backup cycle to once a week and the data backup retention period to seven days.
Backup Start Time
The start time of automatic data backups.
ImportantThe amount of time that is required to back up data varies based on the amount of data to back up. We recommend that you set the backup start time to a period of time during off-peak hours.
Data Backup Retention Period
The number of days for which you want to retain the data backup sets. Default value: 7.
If you want to restore you AnalyticDB for MySQL cluster to a point in time, make sure that a complete data backup set generated before the point in time exists. We recommend that you specify the data backup retention period based on your business requirements.
Delete a backup set
On the Backup and Restoration page, click the Data Backup tab.
Find the backup set that you want to delete and click Delete in the Actions column.
In the message that appears, click OK.
Disable the data backup feature
On the Backup and Restoration page, click the Backup Settings tab.
Click Modify Backup Settings. In the Backup Settings panel, clear the Data Backup Cycle field.
Click OK.
What to do next
You can clone an AnalyticDB for MySQL cluster to create a new one by using backup sets. For more information, see Clone a cluster.