This topic describes the cross-region backup function of RDS for MySQL. This function automatically replicates local backup files to an OSS bucket that is located in a specified destination region other than the region where your RDS instance is located. The backup files in the destination region are used to manage and restore your RDS instance.

Note

Differences between cross-region backup and default backup

  • The cross-region backup function is disabled by default, and you must enable it manually. The default backup function is enabled by default.
  • The cross-region backup function stores data to a different region from your RDS instance. The default backup function stores data the region where the instance is located.
  • The cross-region backup function restores data to a new RDS instance in the source or destination region. The default backup function restores data to the source region where your RDS instance is located. For more information, see Restore the data of an RDS for MySQL instance.
  • The cross-region backup function is independent of your RDS instance. It retains the instance data based on the specified retention period even after you release the RDS instance. The default backup function retains the instance only for seven days after you release the RDS instance.

Prerequisites

The RDS instance version is one of the following:
  • MySQL 5.7 High-availability Edition (with local SSDs)
  • MySQL 5.6

Billing

The fees for the cross-region backup function include the following two parts:
  • Fees for remote storage in OSS: 0.0002 USD/GB/hour.
  • Traffic fees: For more information, see Database Backup pricing.
Note In the Beta testing phase, you are charged only the traffic fees.

Precautions

  • The cross-region backup function restores data to a new RDS instance in the source or destination region.
  • The cross-region backup function can only restore data to a new RDS instance but not to the original RDS instance.
  • The cross-region backup function does not affect the default backup function. This means that cross-region backup files and default backup files can co-exist.
  • With the cross-region backup function enabled, a backup is triggered when no valid backup set is generated within the last 24 hours.
  • With the cross-region log backup function enabled, the system checks whether a valid backup set generated within the last 24 hours is available:
    • If continuous binary logs are generated following a valid backup set, the system dumps these binary logs.
    • If no continuous binary logs are generated following a valid backup set, the system starts a backup.
  • The cross-region backup function is unavailable in some regions due to network resonances. The following table describes the destination regions available to each source region.
    Source region Available destination regions
    China (Hangzhou) China (Shanghai), China (Qingdao), China (Shenzhen)
    China (Shanghai) China (Hangzhou), China (Qingdao), China (Shenzhen)
    China (Qingdao) China (Hangzhou), China (Shanghai), China (Shenzhen)
    China (Beijing) China (Hangzhou), China (Shanghai), China (Qingdao), China (Shenzhen)
    China (Shenzhen) China (Hangzhou), China (Shanghai), China (Qingdao)
    China (Hong Kong) China (Hangzhou), China (Shanghai), China (Qingdao), China (Shenzhen)

Method 1: Enable cross-region backup

  1. Log on to the RDS console.
  2. In the upper-left corner, select the region where the target RDS instance is located.
    选择地域
  3. Find the target RDS instance and in the Actions column choose More > Cross-region Backup Settings.
  4. Set the following parameters.
    Parameter Description
    Cross-region Backup Status The status of the cross-region backup function. Select Enable.
    Backup Region The region where backup files are stored. Local backup files are automatically replicated to an OSS bucket in the region.
    Cross-region Retention Period The period in which cross-region backup files are retained. The retention period spans from 7 days to 1,825 days, which is five years at most.
    Note The system retains the cross-region backup files within the specified retention period even when the RDS instance expires or after you release the RDS instance. You can log on to the RDS console and go to the Cross-region Backup page to view the cross-region backup files that have not expired. For more information, see Back up data across regions.
    Cross-region Log Backup Status The status of the cross-region log backup function. If you enable this function, the system automatically replicates local log backup files to an OSS bucket in the specified destination region.


  5. Click OK.

Method 2: Enable cross-region backup

  1. Log on to the RDS console.
  2. In the upper-left corner, select the region where the target RDS instance is located.
  3. Find the target RDS instance and click its ID.
  4. In the left-side navigation pane, click Backup and Restoration.
  5. On the Cross-region Backup tab, clickEdit.
    Note If the Cross-region Backup tab is not displayed, check whether all the conditions specified in the Prerequisites section are met.
  6. Set the following parameters:
    Parameter Description
    Cross-region Log Backup Status The status of the cross-region backup function. Select Enable.
    Backup Region The region where backup files are stored. Local backup files are automatically replicated to an OSS bucket in the region.
    Cross-region Retention Period The period in which cross-region backup files are retained. The retention period spans from 7 days to 1,825 days, which is five years at most.
    Note The system retains the cross-region backup files within the specified retention period even when the RDS instance expires or after you release the RDS instance. You can log on to the RDS console and go to the Cross-region Backup page to view the cross-region backup files that have not expired. For more information, see Back up data across regions.
    Cross-region Log Backup Status The status of the cross-region log backup function. If you enable this function, the system automatically replicates local log backup files to an OSS bucket in the specified destination region.


  7. Click OK.

Modify cross-region backup settings

A menu item named Cross-region Backup is added to the left-side navigation pane on the RDS home page. With this menu item, you can modify cross-region backup settings even after your RDS instance is released.

  1. Log on to the RDS console.
  2. In the left-side navigation pane, click Cross-region Backup.
  3. Find the target RDS instance and in the Cross-region Backup Settings column click Edit. Then modify the cross-region backup settings and click OK.
    Note If the RDS instance has been released, then you can reconfigure only the Cross-region Retention Period parameter.

APIs

API Description
CheckCreateDdrDBInstance Used to check whether an RDS instance has a cross-region backup set that can be used for cross-region restoration.
CreateDdrInstance Used to restore data to a new RDS instance in the specified destination region.
ModifyInstanceCrossBackupPolicy Used to modify cross-region backup settings.
DescribeInstanceCrossBackupPolicy Used to query cross-region backup settings.
DescribeCrossRegionBackups Used to list cross-region data backup files.
DescribeCrossRegionLogBackupFiles Used to list cross-region log backup files.
DescribeAvailableCrossRegion Used to query the destination regions available to a specified region.
DescribeAvailableRecoveryTime Used to query the time period to which a selected backup file can restore an RDS instance.
DescribeCrossRegionBackupDBInstance Used to query the cross-region backup settings in a specified region.