PolarDB-X supports automatic backup and manual backup. This helps you restore historical data from backups. This topic describes the features that are used to back up data.
Features
Backup typePolarDB-X provides data backup and log backup.
- Data backup: The system backs up data and creates a backup set. Physical backup is used for data backup.
- Log backup: This feature is also known as incremental backup. This feature backs up binary logs that record data changes. After log backup is enabled, you can restore data to a specific point in time within the backup window. The data is restored based on data backup and log backup. The point in time that you specify to restore data is accurate to seconds. For example, if a data backup set is created for an instance at 00:00:01 on January 1, 2021 and log backup is enabled for the instance, you can restore data to a specific point in time elapsed from 00:00:01 on January 1, 2021. The point in time is accurate to seconds.
PolarDB-X supports automatic backup and manual backup.
- Automatic backup: The system automatically triggers data backup at specific intervals.
- By default, automatic backup is enabled. The system automatically enables data backup and log backup.
- By default, data backup is performed once per day. Logs are continuously backed up. You do not need to configure the frequency for log backup. You can configure the backup window and backup interval for automatic backup. For more information, see Configure automatic backup.
- Manual backup: You can trigger a data backup task in the console. For more information, see Manually create a backup. Manual backup is supported only for data backup. Logs are continuously backed up. You do not need to manually trigger a log backup task.
- To prevent data loss, we recommend that automatic backup is performed at least twice a week.
- Before you start a manual backup task, make sure that the previous manual backup task is completed.
- Data backup: Data backup files are stored in the storage systems that are provided by Alibaba Cloud. Data backup files do not consume the storage of your database instance. By default, data backup files are retained for 30 days.
- Log backup: Log backup files are temporarily stored in your database instance. After the log
backup files are stored for a specific period of time or the storage usage of your
database instance is equal to a specific percentage of the total storage, the log
backup files are uploaded to the storage systems that are provided by Alibaba Cloud.
By default, if the log backup files are stored in your database instance for 7 hours
or the storage usage of your database instance is equal to 30 percent of the total
storage, the log backup files are uploaded. This way, log backup files are retained
for seven days in the storage systems provided by Alibaba Cloud.
You can configure the retention policy for log backup files in local storage. This can help you reduce the storage usage of log backup files. For more information, see Configure log backup for local storage.
The tasks for data backup and log backup run on the secondary nodes of data nodes in PolarDB-X. PolarDB-X does not distribute business traffic to the secondary nodes. This way, data backup and log backup do not affect the instance performance.
Billing method
- Data backup: You are not charged when you use this feature.
- Log backup: You are charged only for the used storage of your database instance. The billing method and pricing of log backup are the same as the billing method and pricing of the storage usage in PolarDB-X.
Note
- During the backup process, we recommend that you do not scale out, scale up, or scale down your PolarDB-X instance. This can help you prevent backup failures.
- During the backup process, we recommend that you do not execute DDL statements. These statements can trigger locks on tables. The locks on tables may cause the backup task to fail.
- You cannot download data backup files or log backup files.
Configure automatic backup
Configure log backup for local storage
Manually create a backup
- Log on to the PolarDB-X console.
- In the top navigation bar, select the region where the target instance is located.
- On the Instance List page, click the PolarDB-X 2.0 tab.
- Find the target instance and click its ID.
- In the left-side navigation pane, choose .
- Click Create backup.
- In the dialog box that appears, click OK.