ApsaraDB RDS allows you to read data from secondary RDS instances of their primary ApsaraDB RDS for SQL Server instances that run RDS Cluster Edition. This topic describes how to configure the read attribute for a secondary RDS instance of a primary RDS instance. By default, after you create a primary RDS instance that runs RDS Cluster Edition, you can read data from the secondary RDS instance of the primary RDS instance. The secondary RDS instance serves as a read-only RDS instance, which reduces the cost of cloud migration.

Prerequisites

  • Your RDS instance is a primary RDS instance and meets the following requirements:
    • The RDS instance runs SQL Server 2017 on RDS Cluster Edition or SQL Server 2019 on RDS Cluster Edition.
    • The RDS instance runs RDS Cluster Edition.
    • The RDS instance uses the enhanced SSD (ESSD) storage type.
    Note You can go to the Basic Information page of the RDS instance to view the preceding information.
  • The read/write splitting feature is enabled for the primary RDS instance. For more information, see Enable the read/write splitting endpoint for an ApsaraDB RDS for SQL Server instance.

Functionality

  • After you create an RDS instance that runs RDS Cluster Edition, a primary RDS instance and a secondary RDS instance are provisioned. By default, the secondary RDS instance is read-only. Therefore, the secondary RDS instance can serve as a read-only instance.
  • After the read/write splitting feature is enabled for the primary RDS instance, you can configure read weights for the primary, secondary, and read-only RDS instances. For more information, see Procedure.
  • If an existing primary RDS instance runs RDS Cluster Edition and the read/write splitting feature is enabled for the primary RDS instance, you can directly read data from the secondary RDS instance of the primary RDS instance. If the read/write splitting feature is disabled, you must enable the feature and configure a read-only routing endpoint. For more information, see Procedure.

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 Cluster Management.
  3. On the page that appears, click Configure Readonly Splitting Address in the Basic Information section to configure read weights.
  4. Click OK.

Related operations

OperationDescription
AllocateReadWriteSplittingConnectionApplies for a read-only routing endpoint for a primary ApsaraDB RDS instance.