PITR: Restoring a DB Instance to a Point in Time
Scenarios
You can restore from automated backups to a specified point in time.
During PITR restoration, RDS downloads the most recent full backup file from OBS to the target DB instance for full restoration and then replays the incremental backups to the specified point in time. Data is restored at an average speed of 80 MB/s.
Function Description
| Item | Description |
|---|---|
| Restoration scope | The entire instance |
| Instance data after restoration | The instance data after restoration is consistent with that in the full backup plus the incremental backup used for the restoration.
|
| Restorable time point | Any time point within the retention period after the earliest full backup is generated |
| Scenario |
|
| Configurations for restoring to a new instance |
|
| Time required | The time required depends on how much data there is in the instance. The average restoration speed is 80 MB/s. |
Constraints
- Do not run the reset master command on RDS for MySQL DB instances within their lifecycle. Otherwise, an exception may occur when restoring an RDS for MySQL DB instance to a specified point in time.
- When you restore data to a new DB instance, large transactions in the original DB instance backup may cause a restoration failure. If the restoration fails, contact customer service.
- Constraints on restoring data to the original DB instance:
- If the DB instance for which the backup is created has been deleted, data cannot be restored to the original DB instance.
- Restoring to the original DB instance will overwrite all existing data and passwords, and the DB instance will be unavailable during the restoration.
- Backups of MySQL 8.0 can be restored only to instances with the same kernel minor version. If an instance has already been upgraded to a higher minor version, backups created before the upgrade cannot be restored to the current instance.
- Constraints on restoring data to an existing DB instance:
- Restoring to an existing DB instance will overwrite data and passwords on it and cause the existing DB instance to be unavailable.
- For MySQL 5.6 and 5.7, select an instance that uses the same engine and the same major version, with an equal or higher minor kernel version than the original instance.
- For MySQL 8.0, select an instance that uses the same engine and the same major version, with an equal minor kernel version as the original instance.
- Ensure that the storage space of the selected instance is no less than that of the original instance. Otherwise, the restoration task cannot be delivered.
Restoring a DB Instance
- Log in to the management console.
- Click
in the upper left corner and select a region and a project. - Click
in the upper left corner of the page and choose Database > Relational Database Service. - On the Instances page, click the target instance name.
- In the navigation pane on the left, choose Backups & Restorations. On the displayed page, choose Restore to Point in Time > Restore Instance.
- Select the restoration date and time range, a time point within the selected time range, and a restoration method. Then, click OK.
- Create New Instance
The Create New Instance page is displayed.
- The DB engine and version of the new DB instance are the same as those of the original DB instance and cannot be changed.
- Other settings are the same as those of the original DB instance by default and can be modified. For details, see Buying an RDS for MySQL Instance.
- Restore to Original
- Select the confirmation check box and click Next.
- Confirm the information and click OK.
- Restore to Existing
- Select the confirmation check box.
- Choose an existing instance and click Next.
- Confirm the information and click OK.
- Create New Instance
- View the restoration result. The result depends on which restoration method was selected:
- Create New Instance
A new DB instance is created using the backup data. The status of the DB instance changes from Creating to Available.
The new DB instance is independent of the original one. If you need read replicas to offload read pressure, create one or more for the new DB instance.
After the new DB instance is created, a full backup will be automatically triggered.
- Restore to Original
On the Instances page, the status of the instance changes from Restoring to Available.
A new restoration time range is available. There will be a difference between the new and original time ranges. This difference reflects the duration of the restoration.
After the restoration is complete, a full backup will be automatically triggered.
- Restore to Existing
On the Instances page, the status of the instance changes from Restoring to Available.
After the restoration is complete, a full backup will be automatically triggered.
- Create New Instance
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot