This topic describes how to restore the data of an ApsaraDB RDS for SQL Server instance.

Background information

You can use one of the following methods to restore the data of an RDS instance:

Restore data to an existing RDS instance

You can restore some or all the databases on an RDS instance from a backup set or to a point in time. The destination RDS instance can be the original RDS instance or another existing RDS instance.

Note This function is supported for RDS instances that run SQL Server 2008 R2 with standard or enhanced SSDs, SQL Server 2012, SQL Server 2016, SQL Server 2017 SE, or SQL Server 2019 SE.

Procedure

  1. In the left-side navigation pane, click Backup and Restoration.
  2. In the upper-right corner of the page, click Restore.
  3. In the dialog box that appears, select Restore to Existing Instance and click OK.
  4. Configure the following parameters and click OK.
    Parameter Description
    Restore Method
    • By Time: allows you to restore data to a point in time within the specified log backup retention period. For more information about how to view or change the log backup retention period, see Back up an ApsaraDB RDS for SQL Server instance.
    • By Backup Set: allows you to restore data from a specified full or incremental backup set.
    Restore Time Select the point in time to which you want to restore data. This parameter appears only when you set the Restore Method parameter to By Time.
    Backup Set Select the backup set from which you want to restore data. This parameter appears only when you set the Restore Method parameter to By Backup Set.
    Instance Select the destination RDS instance to which you want to restore data.

    By default, ApsaraDB RDS displays the original RDS instance and all the RDS instances that are created by using the same Alibaba Cloud account, reside in the same region, and run the same database engine version as the original RDS instance.

    Note
    • If the original RDS instance belongs to the shared instance family, you cannot restore its data from a backup set to a general-purpose or dedicated RDS instance. Similarly, if the original RDS instance belongs to the general-purpose or dedicated instance family, you cannot restore its data from a backup set to a shared RDS instance.
    • If ApsaraDB RDS displays a large number of RDS instances, you can enter a keyword in the Instance field to search for the required destination RDS instance.
    Databases to Restore
    1. Select the databases that you want to restore. By default, all the databases on the original RDS instance are displayed and selected.
      • If you want to restore all data of the original RDS instance, select all the databases.
      • If you want to restore one or more databases, select only the required databases.
    2. Specify new names for the selected databases. By default, the original names of the selected databases are retained.
      Note The names of the selected databases on the original RDS instance cannot be the same as those of the existing databases on the destination RDS instance.
    Note
    • If a selected database on the original RDS instance has the same name as an existing database on the destination RDS instance, you must select New Name and specify a new name for the selected database.
    • The value of the New Name parameter can contain only lowercase letters, digits, underscores (_), and hyphens (-).

Restore data to a new RDS instance

You can restore the data of an RDS instance from a backup set or to a point in time. This process was known as instance cloning. If you restore data from a backup set, you can restore some or all the databases whose data is included in the backup set.

You must pay for the new RDS instance. If you no longer require the original RDS instance after the restoration, we recommend that you release or unsubscribe from the original RDS instance in a timely manner. For more information, see Release or unsubscribe from an ApsaraDB RDS for SQL Server instance.

Note This function is supported for RDS instances that run SQL Server 2008 R2 with standard or enhanced SSDs, SQL Server 2012, SQL Server 2016, or SQL Server 2017.

Procedure

  1. In the left-side navigation pane, click Backup and Restoration.
  2. In the upper-right corner of the page, click Restore.
  3. In the dialog box that appears, select Restore to New Instance and click OK.
  4. On the Restore Database (Previously Clone Instance) page, configure the following parameters.
    Parameter Description
    Billing Method
    • Subscription: A subscription instance is an instance that you can subscribe to for a specific period and pay for up front. Subscription billing is more cost-effective than pay-as-you-go billing. Therefore, we recommend that you select subscription billing with a longer commitment. You can receive larger discounts for longer subscription periods.
    • Pay-As-You-Go: A pay-as-you-go instance is charged per hour based on your actual resource usage. We recommend that you select pay-as-you-go billing for short-term use. If you no longer require your pay-as-you-go-billed instance, you can release it to reduce costs.
    Restore Mode
    • By Time: allows you to restore data to a point in time within the specified log backup retention period. For more information about how to view or change the log backup retention period, see Back up an ApsaraDB RDS for SQL Server instance.
    • By Backup Set: allows you to restore data from a specified backup set.
    Note
    • The By Time option appears only when the log backup function is enabled.
    • You can restore some or all the databases on the original RDS instance.
    Database Specify whether you want to restore some or all the databases on the original RDS instance. If you select Part, you must manually enter the names of the databases that you want to restore. In addition, you must separate the database names with commas (,).
    Edition
    • Basic: The database system consists of only one RDS instance. Computing is separated from storage to increase cost-effectiveness.
    • High-availability: The database system consists of one primary RDS instance and one secondary RDS instance. These RDS instances work in the high availability architecture.
    • AlwaysOn: The database system consists of one primary RDS instance, one secondary RDS instance, and up to seven read-only RDS instances. You can create read-only RDS instances to scale up the read capability of the database system.
    Note The available RDS editions vary based on the selected region and database engine version. For more information, see Overview of ApsaraDB RDS editions.
    Zone of Primary Node and Zone of Secondary Node

    The zone to which the RDS instance belongs. A zone is an independent physical location within a region. The Zone of Primary Node parameter specifies the zone to which the primary RDS instance belongs. The Zone of Secondary Node parameter specifies the zone to which the secondary RDS instance belongs.

    You can select the Single-zone Deployment or Multi-zone Development method.

    • Single-zone Deployment: The Zone of Primary Node and the Zone of Secondary Node are the same.
    • Multi-zone Deployment: The Zone of Primary Node and the Zone of Secondary Node are different. After you specify the Zone of Primary Node, the system automatically allocates the Zone of Secondary Node.

    The multi-zone deployment method provides zone-level disaster recovery. We recommend that you select the multi-zone deployment method.

    Note
    • After the RDS instance is created, you can view information about the RDS instance and its secondary RDS instance on the Service Availability page.
    • If you select the RDS Basic Edition, the database system consists of only one RDS instance and supports only the single-zone deployment method.
    Select zones
    Instance Type
    • Entry-level: belongs to the general-purpose instance family. A general-purpose instance exclusively occupies the allocated memory and I/O resources. However, it shares CPU and storage resources with the other general-purpose RDS instances that are deployed on the same server.
    • Enterprise-level: belongs to the dedicated instance family. A dedicated instance exclusively occupies the allocated CPU, memory, storage, and I/O resources. The top configuration of the dedicated instance family is the dedicated host instance family. A dedicated host instance exclusively occupies all the CPU, memory, storage, and I/O resources of the server where it is deployed.
    Note Each instance type supports a specific number of CPU cores, memory capacity, maximum number of connections, and maximum IOPS. For more information, see Primary instance types.
    Capacity The storage capacity that the RDS instance has available to store data files, system files, binary log files, and transaction files. The storage capacity increases in increments of 5 GB.
    Note The dedicated instance family supports exclusive allocations of resources. Therefore, the storage capacity of each instance type with local SSDs in this family is fixed. For more information, see Primary instance types.
  5. Click Next: Instance Configuration.
  6. Configure the following parameters.
    Parameter Description
    Network Type
    • Classic Network: the traditional type of network.
    • VPC: A virtual private cloud (VPC) is an isolated network that provides higher security and better performance than the classic network. If you select the VPC network type, you must also specify the VPC and the VSwitch of Primary Node.
    Note The RDS instance must have the same network type as the ECS instance that you want to connect. If the RDS and ECS instances both have the VPC network type, they must also reside in the same VPC. Otherwise, the RDS and ECS instances cannot communicate over an internal network.
    Resource Group The resource group to which the new RDS instance belongs.
  7. Click Next: Confirm Order.
  8. Confirm the settings in the Parameters section, specify the Purchase Plan and Duration parameters, read and select Terms of Service, and then click Pay Now. You must specify the Duration parameter only when the new RDS instance uses subscription billing.

Restore data to the original RDS instance by using a temporary RDS instance

This function is supported for the following SQL Server versions:
  • SQL Server 2012 EE Basic
  • SQL Server 2012 Web
  • SQL Server 2016 Web
  • SQL Server 2008 R2 (with local SSDs)

For more information, see Restore data of ApsaraDB RDS for SQL Server instances by using temporary instances.

Related operations

Operation Description
Restore databases Restores the data of an ApsaraDB RDS instance.