Back up Tablestore data tables

Updated at:

To prevent data loss or corruption caused by accidental deletion, modification, or overwriting, we recommend that you use Cloud Backup to back up data tables in Tablestore instances on a regular basis. Cloud Backup allows you to configure flexible backup policies and back up data to the cloud, where you can view and restore data tables at any time. This topic describes how to use Cloud Backup to back up data tables in Tablestore instances.

Prerequisites

  • Cloud Backup is activated. Activating Cloud Backup is free of charge. If you use the Tablestore backup feature of Cloud Backup, you are charged Cloud Backup for the storage capacity. The billing details are as follows:

    • Storage capacity fee

      Billed by the storage capacity that backup data consumes in the backup vault. View vault details on the Overview page of the Cloud Backup console. Cloud Backup supports two storage types: locally redundant storage (LRS) and zone-redundant storage (ZRS). For more information, see Pricing.

    • Restoration fee

      Restoring data to a Tablestore instance incurs a data write throughput fee charged by Tablestore. For more information, see Tablestore billing.

  • A Tablestore instance is created. For more information, see Create a Tablestore instance.

Considerations

  • When you use this feature for the first time, Cloud Backup automatically creates the service-linked role AliyunServiceRoleForHbrOtsBackup to obtain access to your Tablestore instance resources. Follow the wizard to complete the operation. For more information, see Service-linked roles for Cloud Backup.

  • Cloud Backup automatically reads and loads Tablestore instances in the corresponding region, including instances of the current account and backed up cross-account instances.

Create a backup plan to periodically back up Tablestore instance data tables

Note

After you create a backup plan, the first backup job is a full backup. Subsequent backup jobs are incremental backups by default.

You can perform the following steps to create a Tablestore backup plan.

  1. Log on to the Cloud Backup console.

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

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

  4. In the Actions column of the target Tablestore instance, click Back Up.

    Note

    To back up a Tablestore instance of another added account, switch the specified account above the Tablestore instance list to the account that owns the instance.

  5. In the Create Backup Plan panel, configure the parameters as described below and click OK.

    1. Configure the backup content and click Next.

      Parameter

      Description

      Plan Name

      The name of the backup plan.

      Database Instance

      The backup objects. You can select one or more tables at the table level.

    2. Configure the backup plan and click Next.

      Backup type

      Parameter

      Description

      Full Backup

      Full Backup

      Turn on Full Backup to perform a full backup.

      Backup Frequency

      This parameter is required only when Full Backup is turned on. The backup interval. Valid values: Daily, Weekly, and Monthly.

      Run At

      This parameter is required only when Full Backup is turned on. The time when the backup starts. The value is accurate to the second.

      Time Interval

      This parameter is required only when Backup Frequency is set to Daily. The interval between backups, in days.

      Backup Week

      This parameter is required only when Backup Frequency is set to Weekly. The day of the week on which the backup is performed.

      Backup Month

      This parameter is required when Backup Frequency is set to Monthly. The month in which the backup is performed.

      Backup Day

      This parameter is required when Backup Frequency is set to Monthly. The day of the month on which the backup is performed.

      Incremental Backup

      Incremental Backup

      Turn on Incremental Backup to perform an incremental backup. Compared with a full backup, an incremental backup backs up only the data that has changed since the last backup. The data volume is smaller and the backup is faster.

      Backup Frequency

      This parameter is required only when Incremental Backup is turned on. The backup interval. Valid values: Minutes, Hours, and Days.

      Run At

      This parameter is required only when Incremental Backup is turned on and Backup Frequency is set to Days. The time when the backup starts. The value is accurate to the second.

      Time Interval

      This parameter is required only when Incremental Backup is turned on. The backup interval. You can specify an interval of 30 minutes, a number of hours, or a number of days.

    3. Configure the backup options.

      Parameter

      Description

      Backup Vault

      The backup vault in which the backup data is stored.

      • Create Vault: The name of the new backup vault. If you leave this parameter empty, a random name is assigned by default.

      • Select Vault: Select an existing backup vault from the drop-down list.

      To maximize backup data redundancy, the system automatically selects a Vault types based on the region support. In regions that support zone-redundant storage, a zone-redundant backup vault is created by default. In other regions, a locally redundant backup vault is created by default.

      Vault Name

      The name of the backup vault.

      Vault Resource Group

      This parameter is required only when Backup Vault is set to Create Vault. The resource group to which the backup vault belongs.

      A resource group is a mechanism for grouping and managing resources within an Alibaba Cloud account. Resource groups help you manage resource grouping and authorization for a single cloud account in a more efficient manner. For more information, see Create a resource group.

      Vault Encryption Method

      This parameter is required only when Backup Vault is set to Create Vault. The encryption method of the backup vault.

      • Managed by Cloud Backup (default): Uses the default encryption method of the backup service.

      • KMS: Uses a custom key from Alibaba Cloud KMS for encryption. You must specify the KMS Key ID parameter.

      Important
      • After KMS encryption is enabled, you cannot change the KMS encryption key.

      • If the KMS key is disabled or deleted, the backup data in the backup vault cannot be restored.

      • To use a KMS key to encrypt a backup vault, you must create a KMS encryption key ID in Alibaba Cloud KMS in advance. For more information, see Create a CMK.

      Retention Period

      The retention period of the backup data. The default value is 2 years. Valid time units: Days, Weeks, Months, and Years.

      Enable Bandwidth Throttling

      Traffic throttling helps you control the traffic of backup jobs during peak hours to prevent impacts on your regular business. If you use traffic throttling, select the Time Range (Hour), enter the Maximum Traffic (MB) that can be used during the throttling period, and then click Add.

    After the backup plan is created, Cloud Backup performs Tablestore backup jobs based on the specified backup start time and backup interval. You can view the created backup plan on the Backup Plan tab.

Backup successful

When the backup execution time is reached, Cloud Backup starts the backup job. The backup is successful when the backup job Status is Completed.

Note

The job list displays only the backup job records from the last six months. To export more data, see Backup audit reports.

Backup vault replication

To prevent regional disasters or account management risks from affecting business continuity, Cloud Backup allows you to configure Cross-region backup or Cross-account backup vault replication for a backup vault whose Storage Vault Type is General Backup. After the configuration is complete, data in the source backup vault is automatically synchronized to the destination backup vault, ensuring data consistency between the two locations. You can also perform cross-region data restoration from the destination backup vault as needed.

For a general-purpose backup vault that stores Tablestore table data, you can configure backup vault replication for cross-region or cross-account disaster recovery. Tablestore backup also supports the following enterprise-level features: Cross-account backup, KMS encryption, Immutable backup, and Tag-based automatic resource association and backup.

Error handling

When a backup plan or backup job has an abnormal Status, use the following recommendations to resolve the issue.

  • The Status of a backup job is Failed:

    Follow the on-screen prompts to verify and correct the configuration.

  • The Tablestore Instance Status is Released:

    The Tablestore instance has been deleted.

    • If you deleted the Tablestore instance intentionally, you can ignore the backup job status. To avoid additional backup storage capacity charges, we recommend that you click Storage Vaults in the left-side navigation pane, find the corresponding backup vault, and delete it.

    • If you deleted the Tablestore instance by mistake, you can restore it. Create a Tablestore instance in the corresponding region and use it as the restore destination to complete the restore. For more information, see Restore a Tablestore table. In the Create Restore Job dialog box, on the Target Instance step, configure the Restore to Database parameter (only running instances are available) and the Restore to New Table Name parameter (required, up to 255 characters).

  • The Plan Status of a backup plan is Disabled:

    The backup plan has been suspended. After the plan is suspended, Cloud Backup no longer protects the Tablestore instance. We recommend that you enable the backup plan as soon as possible.

Related operations

After you create a backup plan, you can also perform the following operations.

Operation

Description

Plan Status

The switch of the backup plan. The switch is turned on by default after you create the backup plan. To suspend the plan, turn off the Plan Status switch.

Edit

If the created Tablestore backup job does not meet your expectations, you can modify the backup plan.

Perform Full Backup Now

Immediately start a full backup job.

Perform Incremental Backup Now

Immediately start an incremental backup job.

Alert Settings

Configure alerting for backup jobs.

  • Disabled: No alert notifications are sent.

  • Same as Backup Vault: Uses the same alerting method as the backup vault.

  • Send to Alibaba Cloud Account: Sends an alert to the Alibaba Cloud account by email.

  • Custom: Sends the alert to one or more selected contacts or contact groups. After you complete the configuration, the client sends backup alerts to the selected contacts or contact groups.

To add an alert contact, see Manage alert contacts.

Delete

Delete a backup plan. After the backup plan is deleted, it no longer runs, but the backed-up data is retained.

What to do next

Restore a Tablestore table

Related documentation