All Products
Search
Document Center

ApsaraDB for MongoDB:Batch-change configurations for components and nodes

Last Updated:Jun 23, 2026

You can change the specifications and storage of Mongos, shard, and ConfigServer components in an ApsaraDB for MongoDB sharded cluster instance to meet different performance requirements.

Batch configuration changes are supported for the following components and nodes in ApsaraDB for MongoDB sharded cluster instances:

  • Specifications and storage space of one or more shards.

  • Specifications of one or more Mongos nodes.

  • Specifications and storage space of the ConfigServer.

You can mix general-purpose and dedicated specifications when changing configurations. Instances that use cloud disks also support one-click conversion of specification categories, allowing you to quickly switch the category (general-purpose or dedicated) for all selected components.

Billing rules

For more information, see Configuration change fees.

Precautions

  • The new storage space must be greater than or equal to the storage space currently used by the component.

  • For instances that use local disks, you cannot change the configuration of the ConfigServer.

  • You cannot change the number of read-only nodes for a shard in a batch operation. To change read-only node counts, go to the configuration page for the individual shard. For more information, see Change shard configurations.

  • During the configuration change, one or two transient disconnections of about 30 seconds each may occur. You can set the switchover time to avoid business impact.

    Important

    When you change only the storage space, the system performs different operations depending on the available storage resources on the local host:

    • Sufficient: The system expands the storage on the local host, which does not require cross-host migration or a switchover. No transient disconnection occurs, and the change takes effect immediately without waiting for the maintenance window.

    • Insufficient: Cross-host migration and switchover are required. A transient disconnection occurs during the change, and the change takes effect at the switchover time that you specify.

  • The time required to complete the configuration change depends on multiple factors, such as network conditions, the task queue, and data volume. We recommend that you perform this operation during off-peak hours and ensure that your application has an automatic reconnection mechanism.

  • If your database's minor version is expired or no longer maintained, the system upgrades it to the latest minor version by default to ensure optimal performance and stability.

Procedure

  1. Go to the ApsaraDB for MongoDB Sharded Cluster Instances page. In the top navigation bar, select a resource group and a region. Then, click the ID of the target instance.

  2. On the Basic Information page, in the Mongos List, Shard List, and Configserver List sections, perform the following operations.

    • For subscription instances: Select the target component or node, and then click Batch Upgrade or Batch Downgrade at the bottom of the page.

    • For pay-as-you-go instances: Select the target component or node, and then click Batch Change configurations at the bottom of the page.

  3. Configure the following parameters.

    Parameter

    Description

    Category

    Select a specification category to filter the specifications available for Mongos, shard, and ConfigServer nodes.

    • Dedicated: Shows only dedicated specifications.

    • General-purpose: Shows only general-purpose specifications.

    • Mixed Deployment: Shows both dedicated and general-purpose specifications.

    Note
    • This parameter is available only for an instance that uses cloud disks.

    • You cannot select a category if it is not supported in the current zone.

    • For information about the categories and specifications of sharded cluster instances, see Sharded cluster instance specifications.

    Instances

    • Mongos List: Select the new Specifications.

    • Shard List: Select the new Specifications and Storage Space.

    • Configserver List: Select the new Specifications and Storage Space.

    To simplify configuring many nodes, use the Synchronize Node Settings feature in the Mongos List and Shard List. This lets you configure a single node and apply its settings to other nodes of the same type:

    1. Configure the Specifications and Storage Space for one node, and then click Synchronize Node Settings to the right of the node.

    2. For a shard component, you must Select Settings to be Synchronized. Select Specifications or Storage, and then click Next.

    3. Select the nodes to which you want to synchronize the settings, and then click Next.

    4. Confirm that the synchronization result is correct, and then click Confirm.

    Note

    The new storage space must be greater than or equal to the node's current storage space. To reduce the storage space, you must create a new instance and migrate your data. For more information, see Other configuration change scenarios and solutions.

    Switching Time

    Select when the change takes effect:

    • Switch Immediately After Task Completion: The change takes effect immediately after the configuration is complete.

    • Switch during the maintenance window after the task is complete: The switch takes effect during the maintenance window. You can select the current maintenance window or set a new one based on your business requirements. For more information about maintenance windows, see Set a maintenance window.

  4. Read the Service Agreement.

  5. Complete the purchase based on your billing method.

    • For pay-as-you-go instances: Click Pay. The system automatically deducts the fee within the next hour.

    • For subscription instances: Click Pay, and then follow the instructions on the Pay page to complete the payment.

    During the configuration change, the instance status is In the process of matching. The change is complete when the instance status changes to Running.

Related APIs

API

Description

ModifyNodeSpecBatch

Changes the specifications of multiple nodes in an ApsaraDB for MongoDB sharded cluster instance at a time.