The instance monitoring feature of ApsaraDB for MongoDB lets you monitor the resource status of each node in an instance. You can select different combinations of dimensions, such as instance components and node roles, to view the status of common resources, such as CPU utilization and memory usage, for multiple combined nodes.
Instance monitoring provides two ways to query combined monitoring data:
Multi-node Monitoring: The system calculates the average of the monitoring values for the selected nodes and displays the aggregated result. This lets you view the overall operational status for each dimension.
Per-node Monitoring: The monitoring values for each selected node are displayed independently. This lets you compare the operational status of individual nodes.
Usage notes
You cannot view the input/output operations per second (IOPS) usage and IOPS utilization for standalone instances. For these instance architectures, the IOPS Usage and IOPS Utilization metrics on the Monitoring Information page always display 0, which does not reflect the actual IOPS monitoring data.
Collection granularity
ApsaraDB for MongoDB lets you choose the collection granularity, which is the time interval between data points. Supported granularities are: 1 minute, 10 minutes, 30 minutes, 1 hour, and 1 day.
The available range for collection granularity depends on the time range of the monitoring query, as shown below:
Monitoring time range | Minimum collection granularity | Maximum collection granularity |
≥ 1 minute and ≤ 10 minutes | 1 minute | 1 minute |
> 10 minutes and ≤ 20 minutes | 1 minute | 10 minutes |
> 20 minutes and ≤ 1 hour | 1 minute | 30 minutes |
> 1 hour and ≤ 1 day | 1 minute | 1 hour |
> 1 day and ≤ 30 days | 30 minutes | 1 day |
For example, if you view monitoring information for a 1-day time range with a collection granularity of 1 minute, the monitoring curve consists of 1,440 data points.
Choose a suitable time range and collection granularity. If the time range is shorter than two collection intervals, the monitoring graph displays only a single data point instead of a curve.
Procedure
Go to the MongoDB Replica Set Instances or MongoDB Sharded Cluster Instances page, select the resource group and region at the top, and then click the ID of the target instance.
In the navigation pane on the left, click Monitoring Data.
In the upper-left corner of the Instance Monitoring tab, select Multi-node Monitoring or Per-node Monitoring.
In the metrics pane on the right, select the metrics to display and drag them to change their order, as needed.
Based on the instance type, select the desired monitoring scope.
Multi-node Monitoring
Replica set

Item
Description
Role
Select one or all of the Primary, Secondary, or Readonly roles to view the aggregated monitoring information for the corresponding roles.
The monitoring graph shows the aggregated result, which is the average of the metric values for all nodes in the selected roles.
Time Range
Click the time range above the monitoring graph to change the time range for the monitoring information.
Monitoring data is retained for 30 days. You cannot view monitoring information that is more than 30 days old.
A single query can return monitoring data for a maximum of 7 days.
NoteIf you select a long time range, the request may time out due to excessive data. If this happens, shorten the time range for the query.
Instance Sampling Interval
Click the collection granularity in the upper-left corner of the monitoring graph to change the collection granularity for the current monitoring information.
Sharded cluster

Item
Description
Shard type
Select the Mongos, Shard, or Configserver component.
You can combine options in different ways to view monitoring information for the corresponding nodes. Examples:
Example 1: To view the monitoring data of all node roles among all shards, you can select the following combination:
Example 1: To view monitoring information for all roles in all shards, select the following combination. Set Shard Type to Shard, Instance ID to All, and Role to All.
Example 2: To view the monitoring data of the Primary role in a specified shard, you can select the following combination:
Example 2: To view monitoring information for the Primary role in a specific shard, select the following combination. Set Shard Type to Shard, select the desired shard for Instance ID, and set Role to Primary.
The monitoring graph shows the aggregated result, which is the average of the metric values for all nodes within the selected scope.
Instance ID (Shard ID)
Select one or all instance IDs (shard IDs).
Role
Select one or all roles.
Time Range
Click the time range above the monitoring graph to change the time range for the monitoring information.
NoteIf you select a long time range, the request may time out due to excessive data. If this happens, shorten the time range for the query.
Instance Sampling Interval
Click the collection granularity in the upper-left corner of the monitoring graph to change the collection granularity for the current monitoring information.
Per-node Monitoring
NoteYou can select a maximum of five nodes.
Replica set

Item
Description
Node
Select one or more nodes to view or compare.
The monitoring graph shows a comparison of the monitoring information for the selected nodes.
Time Range
Click the time range above the monitoring graph to change the time range for the monitoring information.
Monitoring data is retained for 30 days. You cannot view monitoring information that is more than 30 days old.
A single query can return monitoring data for a maximum of 7 days.
NoteIf you select a long time range, the request may time out due to excessive data. If this happens, shorten the time range for the query.
Instance Sampling Interval
Click the collection granularity in the upper-left corner of the monitoring graph to change the collection granularity for the current monitoring information.
Sharded cluster

Item
Description
Shard type
Select the Mongos, Shard, or Configserver that you want to view.
Node
Select one or more nodes to view or compare. The monitoring graph shows a comparison of the monitoring information for the selected nodes.
Time Range
Click the time range above the monitoring graph to change the time range for the monitoring information.
NoteIf you select a long time range, the request may time out due to excessive data. If this happens, shorten the time range for the query.
Instance Sampling Interval
Click the collection granularity in the upper-left corner of the monitoring graph to change the collection granularity for the current monitoring information.
View the monitoring information.
Hover over a point on the x-axis of a metric trend graph to view detailed information for that point in time.
Click the
icon in the upper-left corner of the monitoring graph to view metric descriptions. For more information, see Monitoring items and metrics.Click the
icon in the upper-right corner of the monitoring graph to view the graph in full screen.