An ApsaraDB for MongoDB sharded cluster instance consists of mongos components, shards, and a ConfigServer component. You can change the configurations of each component to meet the performance requirements of your sharded cluster instance.
You can start a configuration change task for multiple mongos, shard, and ConfigServer nodes in an ApsaraDB for MongoDB sharded cluster instance at a time. The task involves the following operations:
Change the specifications and storage capacity of one or more shards.
Change the specifications of one or more mongos nodes.
Change the specifications and storage capacity of a ConfigServer node.
When you change the configurations of the sharded cluster instance, you can deploy both the general-purpose and dedicated categories. You can change the category of a sharded cluster instance that uses cloud disks. This way, the category of each node in the instance is changed.
Billing rules
For more information, see Configuration change fees.
Usage notes
The new storage capacity that you specify is greater than or equal to the existing storage capacity of the sharded cluster instance.
The configurations of ConfigServer nodes in a sharded cluster instance that uses local disks cannot be changed.
The number of read-only nodes in a shard cannot be changed. To change the number of read-only nodes in a shard, go to the configuration change page of the shard. For more information, see Change the configurations of one or more shards.
During a configuration change, one or two transient disconnections may occur. Each transient disconnection lasts about 30 seconds. To prevent a configuration change from interrupting your workloads, we recommend that you change configurations at a time that has minimal impact on your business.
ImportantIf you only change the storage capacity of the ConfigServer component, ApsaraDB for MongoDB performs different operations based on whether your host has sufficient storage resources:
If your host has sufficient storage resources, ApsaraDB for MongoDB scales up the storage capacity of your host without the need for cross-host migrations or failovers. Transient disconnections do not occur during the scale-up process. The scale-up task is immediately executed to completion. You do not need to wait for the maintenance window.
If your host does not have sufficient storage resources, cross-host migrations and failovers are required. Transient disconnections may occur during the scale-up process. The scale-up task is executed during the specified maintenance window.
Time required to complete a configuration change depends on various factors, such as network, task queue, and the number of nodes. We recommend that you perform a configuration change during off-peak hours and make sure that your applications can automatically reconnect to the instance.
If the minor version of the sharded cluster instance expires or is not maintained, ApsaraDB for MongoDB automatically updates the minor version of the instance to the latest version during a configuration change. This ensures that the sharded cluster instance can provide high performance and stability.
Procedure
Go to the Sharded Cluster Instances page. In the top navigation bar, select the region in which the desired instance resides. Then, find the instance that you want to manage and click its instance ID.
In the Mongos List, Shard List, or Configserver List section of the Basic Information page, perform one of the following operations:
For a subscription instance, find the nodes whose configurations you want to change, click Batch Upgrade or Batch Downgrade in the lower part of the Basic Information page.
For a pay-as-you-go instance, find the nodes whose configurations you want to change, click Batch Reconfigure.
Configure the parameters described in the following table.
Parameter
Description
Category
The new instance category. Valid values:
Dedicated: Only dedicated mongos, shard, and ConfigServer nodes are displayed.
General-purpose: Only general-purpose mongos, shard, and ConfigServer nodes are displayed.
Hybrid deployment: Dedicated and general-purpose mongos, shard, and ConfigServer nodes are displayed.
NoteThis parameter is required only for ApsaraDB for MongoDB sharded cluster instances that use cloud disks.
If a category is not available for selection, it is not supported in the current zone.
For more information about the categories and specifications of ApsaraDB for MongoDB sharded cluster instances, see Sharded cluster instance types.
Instances
Mongos List: Select the new instance specification.
Shard List: Select the new instance specification and storage capacity.
Configserver List: Select the new instance specification and storage capacity.
The node configuration synchronization feature is available in Mongos List and Shard List. If your instance contains a large number of nodes, you can configure only one node and synchronize the configurations of the node to other nodes of the same type. Steps:
Specify the specifications and storage capacity for one node based on your business requirements and then click Synchronize Node Settings in the Actions column.
For a node in a shard, select Settings to be Synchronized. This way, Specifications and Storage are selected. Then, click Next.
Select the node whose configurations you want to synchronize and then click Next.
Confirm the settings and click OK.
NoteThe new storage capacity must be equal to or greater than the storage capacity used by the current node. To reduce storage capacity, you can create an instance and then migrate data to the instance. For more information, see Other configuration change scenarios and methods.
Switching Time
The time at which you want to apply the configuration change. Valid values:
Switch Immediately after Migration: ApsaraDB for MongoDB immediately applies the configuration change after you complete the payment.
Switch within Maintenance Window: ApsaraDB for MongoDB applies the configuration change within the maintenance window that you specify. You can select the current maintenance window or customize a maintenance window based on your business requirements. For more information about a maintenance window, see Specify a maintenance window.
Read and select the Terms of Service that is displayed.
Perform the corresponding operations based on the selected billing method.
Pay-as-you-go: Click Pay Now. Then, the system automatically collects the amount in the next hour.
Subscription: Click Pay Now. On the Purchase page, complete the payment process.
When the configuration change is being applied, the instance status is Changing Configuration. If the instance status changes to running, the configuration change is complete.
Related API operations
Operation | Description |
Changes the configurations of multiple mongos, shard, and ConfigServer nodes in an ApsaraDB for MongoDB sharded cluster instance in batch. |