Instance and table restoration is a process of restoring only a specified instance or table of a cluster. For example, if you are a games company, you can use the instance and table restoration feature to restore the data of a player or a group of players. Instance and table restoration supports two methods: restore from a backup set and restore data to a previous point in time. This topic describes how to restore the data of an instance or table to a previous point in time.
- You can restore only specified tables, so you must confirm that you have selected all the tables that you want to restore.
Note If you cannot determine which tables to restore, we recommend that you restore all the data of your cluster to a new cluster and then migrate the data back to the original cluster. For more information, see Method 1 for cluster restoration: Restore from a backup set and Method 2 for cluster restoration: Restore data to a previous point in time.
- If the specified tables are deleted during the time period between the generation of the last backup set and the specified time, you cannot restore the data by Backup Timepoint.
- You can restore up to 100 tables at a time. If you choose to restore an instance, all tables in the instance can be restored.
Note To restore a large number of tables, we recommend that you restore all data of your cluster to a new cluster. For more information, see Method 1 for cluster restoration: Restore from a backup set and Method 2 for cluster restoration: Restore data to a previous point in time.
- The instance and table restoration feature only applies to clusters that have no more than 50,000 tables.
- The instance and table restoration feature does not restore triggers. If the original table has a trigger, the trigger will not be restored.
- The instance and table restoration feature does not restores foreign keys. If the original table has a foreign key, the foreign key will not be restored.
- Log on to the PolarDB console.
- In the upper-left corner of the console, select the region where the cluster is deployed.
- Find the cluster and click the cluster ID.
- In the left-side navigation pane, choose .
- On the Backup and Restore page, click Restore Databases/Tables.
- In the dialog box that appears, select Backup Timepoint in the Restore Type section and select a particular time in the Restoration Time section.
Note The time selected in the Restoration Time section must be within the time period specified in the Restore To section. Only the data generated over the past 7 days can be restored.
- In the left section of the Databases and Tables to Restore page, select the instance that you want to restore, and select the table that you want to restore on the right side.
- If you select an instance but do not specify tables, all data in the instance is restored.
- After you select an instance or table, the system automatically generates the name of the new instance or table by adding the
_backupsuffix to the name of the original instance or table. For example, if the name of a table is
test, then the new table is named
test_backup. You can also customize the names of new instances and tables.
- Click OK.
Related API operations
|DescribeMetaList||You can call the DescribeMetaList operation to query the metadata of the instance or table that you want to restore.|
|RestoreTable||You can call the RestoreTable operation to restore the instances or tables of a PolarDB cluster.|