All Products
Search
Document Center

ApsaraDB RDS:Add or remove a secondary instance

Last Updated:Nov 23, 2025

After creating a Global Active Database (GAD) instance group, you can add a newly-created or an existing RDS for PostgreSQL instance to the instance group as the secondary instance. You can also remove the secondary instance from the instance group based on your business requirements. The removed secondary instance is not deleted and still normally runs as an independent RDS for PostgreSQL instance.

Prerequisites

  • A GAD instance group has been created. For more information, see Create and delete a GAD instance group.

  • The GAD instance group is in the Running state.

  • The GAD instance group is located in one of the following supported regions: China (Hangzhou), China (Shanghai), China (Beijing), China (Zhangjiakou), China (Shenzhen), China (Hohhot), China (Heyuan), China (Chengdu).

Precautions

  • When you add a secondary instance to a GAD instance group, the primary instance restarts immediately and becomes temporarily unavailable. The restart process takes approximately 5 to 15 minutes and may result in temporary disconnection. Your business may be interrupted for 10 to 30 seconds.

  • A GAD instance group can only contain one primary instance and one secondary instance.

  • An RDS for PostgreSQL instance can be added to only one GAD instance group as either the primary or secondary instance.

  • An RDS for PostgreSQL instance cannot be released or unsubscribed from if it is still be added to a GAD instance group as the secondary instance. To release or unsubscribe from the secondary instance of a GAD instance group, you must first remove it from the GAD instance group first.

Billing

When you use GAD, you are charged for the RDS instance that you newly purchase to create the GAD instance group and the data synchronization capability provided by DTS. If you add an existing instance to a GAD instance group as the secondary instance, you are charged only for DTS. For more information, see Billing.

Add a secondary instance

Warning

When you add a secondary instance to a GAD instance group, the primary instance restarts immediately and becomes temporarily unavailable. The restart process takes approximately 5 to 15 minutes and may result in temporary disconnection. Your business may be interrupted for 10 to 30 seconds.

Method 1: Create a new instance and add it as the secondary instance

  1. Log on to the RDS console and go to the Global Active Instances page.

  2. Click Add Secondary Instance in the Actions column corresponding to the instance group to which you want to add the secondary instance.

    Note

    You can also click Add Secondary Instance on the details page of the GAD instance group.

  3. Configure parameters for the new RDS for PostgreSQL instance.

    The new RDS for PostgreSQL instance must meet the following requirements. For more information about how to configure other parameters, see Create an ApsaraDB RDS for PostgreSQL instance.

    • Billing method: The billing method of the instance must be subscription or pay-as-you-go.

    • Major engine version: The major engine version of the instance must be the same as that of the primary instance.

    • Instance type:

      • Dedicated: 4 cores and 8 GB of memory or higher.

      • General-purpose: 2 cores and 4 GB of memory or higher.

    • Storage capacity: The storage capacity of the instance must be greater than or equal to the total storage capacity of the primary instance.

      Note

      You can go to the Basic Information page of the primary instance and check its total storage capacity in the Instance Resources section.

  4. Configure the DTS data synchronization task. Keep the default values for the parameters.

    • Data Synchronization Type: Only One-way Synchronization is supported.

    • Data Synchronization Scope: Only Instance Synchronization is supported.

  5. Confirm the configurations and detailed fees of the secondary instance and DTS synchronization task. Then, click Pay Now. On the dialog box that appears, click OK.

    The system creates the RDS for PostgreSQL instance as the secondary instance and the DTS synchronization task between the primary and secondary instances.

  6. After the payment is complete, you are directed to details page of the GAD instance group. After the secondary instance is added to the instance group, you can view the instance and the DTS synchronization task on this page. For more information, see View the information about a GAD instance group.

Method 2: Add an existing instance as a secondary instance

The existing RDS for PostgreSQL instance that you want to add to the instance group must meet the following requirements:

  • Billing method: The billing method of the instance must be subscription or pay-as-you-go.

  • Major engine version: The major engine version of the instance must be the same as that of the primary instance.

  • Instance edition: The instance must run the same edition as the primary instance. Only Basic Edition and High-availability Edition are supported.

  • Instance type:

    • Dedicated: 4 cores and 8 GB of memory or higher.

    • General-purpose: 2 cores and 4 GB of memory or higher.

  • Storage capacity: The storage capacity of the instance must be greater than or equal to the total storage capacity of the primary instance.

Note

You can check the preceding information of the existing instance on its Basic Information page. If the instance type or storage capacity does not meet the requirements, you can change the instance specifications.

  1. Log on to the RDS console and go to the Instances page. Select the region of the existing instance from the top navigation bar and then click the ID of the existing instance.

  2. Click Add to GAD Cluster in the upper-right corner of the instance details page.

  3. In the dialog box that appears, configure the following parameters for the GAD instance group to which you want to add the existing instance.

    Parameter

    Description

    Region

    Select the region of the GAD instance group.

    GAD Cluster (Name/ID)

    Select the GAD instance group.

  4. Click OK. You are directed to details page of the GAD instance group. After the secondary instance is added to the instance group, you can view the instance and the DTS synchronization task on this page. For more information, see View the information about a GAD instance group.

Remove a secondary instance

Note

Removing a secondary instance does not release or unsubscribe from the secondary instance. The two operations are decoupled.

  • Remove a secondary instance: The removed secondary instance is not deleted and keeps running. The data in the instance is retained. You can view the instance on the Instances page.

  • Release or unsubscribe from the secondary instance: To release or unsubscribe from a secondary instance, you must first remove it from the instance group. After the secondary instance is released or unsubscribed from, it is moved to the recycle bin and is permanently deleted after the retention period expires.

  1. Log on to the RDS console and go to the Global Active Instances page.

  2. Click the ID of the instance group from which you want to remove the secondary instance.

  3. In the List of RDS instances section at the bottom of the page, click Remove in the Actions column corresponding to the secondary instance that you want to remove.

  4. On the message that appears, click Delete.

    Important
    • During the removal of the secondary instance, the connection to the the secondary instance and the databases on the instance is not interrupted. After being removed from the current GAD instance group, the instance can be added to another GAD instance group as the secondary instance if it meets the requirements.

    • After the secondary instance is removed from the GAD instance group, the DTS synchronization task between the primary and secondary instances is stopped. The removed secondary instance keeps running independently and is changed to the read/write state from the read-only state.

References