To meet data reading performance requirements in various business scenarios, the number of nodes can be changed in ApsaraDB for MongoDB. . Data can be read from added secondary nodes. This method improves the overall read performance of replica set instances.

Background information

To meet the high availability of ApsaraDB for MongoDB, the number of nodes in replica set instances can be changed to 3, 5, and 7. .
Note The nodes of standalone instances cannot be changed.

You can add or remove nodes for a replica set instance, which must have at least three nodes. Changing the number of nodes for a replica set instance results in a change to its bill. For more information, see billing items and pricing.


  1. Log on to the ApsaraDB for MongoDB console.
  2. In the upper-left corner of the page, select the region where your instance resides.
  3. In the left-side navigation pane, click Replica Set Instances.
  4. Find the target RDS instance and click its ID.
  5. On the Basic Informationpage, perform the following steps based on the billing method of the instance:
    1. For a subscription instance, click upgrade configuration or downgrade in the Basic Information section.
    2. For a pay-as-you-go instance, click Change Configuration in the Basic Information section.
  6. On the Change Configuration page, specify Replication Factor for the instance.
    Select the number of nodes
    Note For more information about how to change specifications and the storage space, see Configuration change overview.
  7. Select the check box under terms of service to complete the payment process as prompted.

What to do next

After you add the nodes for the replica set instances, the connection strings of new nodes (all displayed as Secondary but with different role IDs) appear in the console. The connection string URI for a high availability connection is also updated. You can modify the connection string in an application to achieve high availability and read/write splitting connection and improve the overall performance. For more information, see Connect to a replica set instance through the mongo shell.