All Products
Search
Document Center

ApsaraDB RDS:Restore the data of an ApsaraDB RDS for SQL Server instance

Last Updated:Aug 28, 2023

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

Feature description

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

Note

For more information about data restoration methods, see Methods to restore an ApsaraDB RDS for SQL Server instance.

Restore the data to an existing instance

You can restore the data of your RDS instance to the original RDS instance or to a different existing RDS instance from a data backup file or to a specific point in time. During this process, you can restore some or all of the databases that are created on your RDS instance.

Usage notes

You can restore the data of your RDS instance only to an existing RDS instance that runs the same database engine version and same RDS edition as your RDS instance. In addition, the instance types of your RDS instance and the existing RDS instance must belong to the same instance family.

For example, you can restore the data of a general-purpose RDS instance that runs SQL Server 2016 SE on RDS High-availability Edition only to another general-purpose RDS instance that runs SQL Server 2016 SE on RDS High-availability Edition.

Procedure

  1. Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the ID of the instance.
  2. In the left-side navigation pane, click Backup and Restoration.

  3. Click Restore.

  4. In the Select Restore Method dialog box, select Restore to Existing Instance and click OK.

    Note

    This method is not supported for RDS instances that run SQL Server 2008 R2 with local disks.

  5. Configure the following parameters and click OK.

    Parameter

    Description

    Restore Method

    • By Time: allows you to restore the data to a point in time within the specified log 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 the data from a backup set.

    Restoration Time

    This parameter appears only when you set the Restore Method parameter to By Time. Select the point in time to which you want to restore the data.

    Backup Set

    This parameter appears only when you set the Restore Method parameter to By Backup Set. Select the backup set from which you want to restore the data.

    More Backup Sets

    This parameter determines whether to display the most recent 1,000 backup sets. If you cannot find the required backup set from the Backup Set drop-down list, you can select this check box. Then, the system displays more backup sets for you to query.

    Destination Instance Name

    Select the destination RDS instance to which you want to restore the data.

    By default, the system displays all the RDS instances that are created within your Alibaba Cloud account and reside in the selected region. The displayed RDS instances include the original RDS instance whose data you want to restore.

    Note
    • If you use a snapshot backup file, you can restore the data only to an RDS instance on which the snapshot backup feature is enabled. For more information, see Enable snapshot backups for an ApsaraDB RDS for SQL Server instance.

    • The destination RDS instance can run a higher SQL Server version than the original RDS instance.

    • If the original RDS instance belongs to the shared instance family, you cannot restore the data of the instance 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 the data of the instance to a shared RDS instance.

    • If a large number of RDS instances are displayed, you can enter a keyword in the Destination Instance Name field to search for the required destination RDS instance.

    Databases to Restore

    1. Select the databases that you want to restore. By default, the system displays and selects all the databases that are created on the original RDS instance.

      • If you want to restore all the 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 the names that you want to use for the selected databases on the destination RDS instance. 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 specify New Database Name for the selected database.

    • The value of New Database Name can contain only lowercase letters, digits, underscores (_), and hyphens (-).

  6. Optional. View the progress of the restoration task.

    The system creates a restoration task. You can click the image.png icon in the upper-right corner. On the Tasks page, query the task whose Task Type is Clone Instance to view the progress of the restoration task.

    image.png

Restore data to a new RDS instance

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

Billing rules

You are charged for the new RDS instance. You can view the price of the new RDS instance when you create the instance.

Note
  • If you no longer require the original RDS instance after the restoration, we recommend that you release or unsubscribe from the instance at the earliest opportunity. For more information, see Release or unsubscribe from an ApsaraDB RDS for SQL Server instance.

  • You are immediately charged for the new RDS instance after the instance is created.

Procedure

  1. Go to the Instances page. In the top navigation bar, select the region in which the RDS instance resides. Then, find the RDS instance and click the ID of the instance.
  2. In the left-side navigation pane, click Backup and Restoration.

  3. Click Restore.

  4. In the Select Restore Method dialog box, select Restore to New Instance and click Ok.

    Note

    This method is not supported for RDS instances that run SQL Server 2008 R2 with local disks.

  5. On the Restore Database (Previously Clone Instance) page, configure the following parameters.

    Parameter

    Description

    Billing Method

    • Subscription: A subscription RDS instance is an instance for which you pay an upfront fee. For long-term usage, the subscription billing method is more cost-effective than the pay-as-you-go billing method. You are charged lower prices for longer subscription periods.

    • Pay-As-You-Go: A pay-as-you-go RDS instance is billed per hour based on your actual resource usage. We recommend that you select the pay-as-you-go billing method for short-term use. If you no longer need your pay-as-you-go RDS instance, you can release it to reduce costs.

    Restore Mode

    • By Time: allows you to restore the data to a point in time within the specified log 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: This mode allows you to restore data from a backup set.

    Note

    The By Time option is available only when the log backup feature is enabled.

    Database

    Specify whether to restore some or all of the databases that are created on the original RDS instance. If you select Snapshot backup does not support partial restoration, you must manually enter the names of the databases that you want to restore and separate the database names with commas (,).

    Note

    If you enable the snapshot backup feature for the RDS instance, you can select only All. For more information, see Enable the snapshot backup feature.

    Product Series

    • Basic: In RDS Basic Edition, the database system consists only of an RDS instance, and the computing is separated from storage. This RDS edition is cost-effective and suitable for learning or testing.

    • High-availability: In RDS High-availability Edition, the database system consists of a primary RDS instance and a secondary RDS instance. These instances work in the high availability architecture. RDS High-availability Edition is suitable for production environments and is suitable for more than 80% of business scenarios.

    • Cluster: In RDS Cluster Edition, the database system consists of a primary RDS instance, a secondary RDS instance, and up to seven read-only RDS instances. The read capability of the database system improves with the number of read-only RDS instances.

    Note

    The available RDS editions vary based on the region and database engine version that you select. For more information, see Overview.

    Zone of Primary Node

    Select a zone in which the RDS instance resides.

    Deployment Method

    • Multi-zone Deployment: The primary RDS instance and the secondary RDS instance reside in different zones to provide zone-disaster recovery. This is the recommended deployment method.

    • Single-zone Deployment: The RDS instance and the secondary RDS instance reside in the same zone.

    Note
    • No significant differences exist between the zones in the same region.

    • If the RDS instance resides in the same zone as the Elastic Compute Service (ECS) instance on which your application is deployed, these instances can deliver optimal performance. If the RDS instance and the ECS instance reside in different zones in the same region, the performance of the RDS instance and the ECS instance is slightly lower than the performance of the RDS instance and the ECS instance that reside in the same zone.

    • If you set the Product Series parameter to Basic, only the Single-zone Deployment method is available.

    • If Sold Out appears in the upper-right corner of a zone name, this zone does not have sufficient resources. In this case, you must switch to another zone.

    Zone of Secondary Node

    If you select Multi-zone Deployment for the Deployment Method parameter, you must select the zone in which the secondary RDS instance resides.

    Instance Type

    • General-purpose (Entry-level): A shared or general-purpose instance exclusively occupies the memory and I/O resources that are allocated. However, this type of instance shares CPU and storage resources with other general-purpose instances that are deployed on the same host.

    • Dedicated (Enterprise-level): You can select a dedicated instance type or a dedicated host instance type. A dedicated RDS instance exclusively occupies the CPU, memory, storage, and I/O resources that are allocated. The dedicated host instance family is the highest specifications of the dedicated instance family. A dedicated host instance occupies all the CPU, memory, storage, and I/O resources on the host on which the instance is deployed.

    Capacity

    Configure the storage capacity for your RDS instance. The storage capacity is provisioned to store data files, system files, log files, and transaction files in the RDS instance. You can adjust the storage capacity at a step size of 5 GB.

    Note

    A dedicated RDS instance that uses local disks exclusively occupies the allocated resources, and its storage capacity varies based on the instance type. For more information, see Primary ApsaraDB RDS instance types.

  6. Click Next: Instance Configuration.

  7. Configure the following parameters.

    Parameter

    Description

    Network Type

    • Classic Network: the traditional type of network.

    • VPC: A virtual private cloud (VPC) is an isolated virtual network that provides higher security and higher performance than the classic network. If you set the Network Type parameter to VPC, you must also specify the VPC and vSwitch of Primary Node parameters.

    Note

    Make sure that the RDS instance and the ECS instance to be connected are located in the same VPC or in the classic network. Otherwise, they cannot communicate over an internal network.

    Resource Group

    The resource group to which the new RDS instance belongs.

  8. Click Next: Confirm Order.

  9. Confirm the settings in the Parameters section, configure the Purchase Plan and Duration parameters, read and select Terms of Service, click Pay Now, and then complete the payment. You must configure the Duration parameter only when the new RDS instance uses the subscription billing method.

    You can go to the Instances page and find the created RDS instance based on the creation time. It requires 1 to 10 minutes to create an RDS instance. You can refresh the page to check whether the RDS instance is created. After the RDS instance is created, you can access the RDS instance to view the restored databases and tables.

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

This method is supported only for RDS instances that run SQL Server 2008 R2 with local disks. For more information, see Restore the data of an ApsaraDB RDS for SQL Server instance by using a temporary RDS instance.

Related operations

Operation

Description

RecoveryDBInstance

Restores one or more databases of an instance.