All Products
Search
Document Center

Cloud Backup:Restore Tablestore tables

Last Updated:Feb 29, 2024

If a system failure or error occurs on a Tablestore instance, you can restore the table data in the backup vault to the source Tablestore instance or another specified Tablestore instance. You can restore only one table at a time. This topic describes how to create a restore job for a Tablestore instance.

Prerequisites

  • A backup plan is created for a Tablestore instance and the backup plan is completed. For more information, see Back up Tablestore tables.

  • If you restore data to a new Tablestore table, you must create a table in the same region. For more information, see Create buckets.

  • You have learned about the billing rules of the Tablestore backup feature. For more information, see the "Billing" section in Overview.

Billing

  • If you restore data to a Tablestore instance, you are charged for the data write throughput. The fees are included into your Tablestore bills. For more information, see Billing overview.

  • You are not charged for Cloud Backup within 30 days after you use the Tablestore backup feature for the first time. After the free trial period ends, you are charged for Tablestore backup based on backup and restore scenarios:

    • Backup: You are charged for Cloud Backup based on the storage usage of backup vaults. You are not charged for the read traffic of Tablestore.

    • Restoration: You are not charged for Cloud Backup. The restoration fees are included into your Tablestore bills.

Usage notes

  • When you restore a table that contains auto-increment columns, you can only rebuild auto-increment columns and restore only the putRow operation. In incremental backup, the updateRow and deleteRow operations performed on the table are ignored. For example, if the putRow operation is performed on a row multiple times in a source table, after the table is restored, the row becomes multiple rows. This is because that a new row of data is created each time the value of an auto-increment column is regenerated.

  • A restore job overwrites the rows with the same primary key in the destination table. Other rows are not affected.

  • If you specify a destination table name that does not exist, the restore job creates a table based on the table that was backed up.

  • If you restore data across Tablestore instances, make sure that the name of the restored table is not the same as the name of an existing table. If you restore a table to an existing table, make sure that the schema of the destination table is the same as that of the source table. In addition, you must set a valid max version offset and data lifecycle for the destination table to prevent write failures during restoration or data expiration shortly after restoration. If the schema of the destination table is different from that of the source table, the restoration may fail.

Procedure

Note

After you create a backup plan, the first backup job performs a full backup and subsequent backup jobs perform incremental backups.

  1. Log on to the Cloud Backup console.

  2. In the left-side navigation pane, choose Backup > Tablestore Backup.

  3. In the top navigation bar, select a region.

  4. Find the Tablestore instance that you want to restore, and click Restore in the Actions column.

  5. In the Create Restore Job panel, configure the parameters and click OK.

    1. Specify a name for the backup plan, select the objects that you want to restore, and then click Next.

      Parameter

      Description

      Recoverable Tables

      Select a table from the Recoverable Tables drop-down list. The drop-down list shows only the tables that you selected when you created the backup plan.

      Important

      You can restore only one table at a time.

      Recoverable Time Point

      Select a time range from the Recoverable Time Point drop-down list. The drop-down list shows time ranges based on the scheduled execution time that you specified for the backup plan.

      Choose Recovery Point

      Select a point in time at which you want to run the restore job.

    2. Configure the Destination Instance.

      image.png

      Parameter

      Description

      Restore to Database

      Select a destination database from the Restore to Database drop-down list. The drop-down list shows all the Tablestore resources that belong to your Alibaba Cloud account. If you specify another Tablestore instance, the source Tablestore instance is restored to the specified instance.

      Restore to New Table

      Enter the name of the destination table.

      Important
      • If you restore data to the source table, select the name of the source table.

      • If you restore data across Tablestore instances, make sure that the name of the restored table is not the same as the name of an existing table.

      • If you restore a table to an existing table, make sure that the schema of the destination table is the same as that of the source table. In addition, you must set a valid max version offset and data lifecycle for the destination table to prevent write failures during restoration or data expiration shortly after restoration. If the schema of the destination table is different from that of the source table, the restoration may fail.

    After the restore job is created, you can view the progress of the restore job in the Status column on the Restore Jobs tab. After the specified table is restored, you can log on to the Tablestore console to verify the details about the table.恢复任务

References