Instance sessions allow you to view the information about sessions between an ApsaraDB for MongoDB instance and a client in real time, which includes the client information, commands that are run, and connection duration. You can also terminate abnormal sessions based on your business requirements.
The instance is a standalone, replica set, or sharded cluster instance.
- Log on to the ApsaraDB for MongoDB console.
- In the upper-left corner of the page, select the resource group and region to which the instance belongs.
- In the left-side navigation pane, click Replica set instances or Sharded cluster instance based on the instance type.
- On the page that appears, find the instance that you want to manage and click its ID.
- In the left-side navigation pane, choose .
- In the Current Node drop-down list, select the node that you want to view. Note
- If you turn on Auto Refresh, the system updates session data on the page every 5 seconds. By default, the system displays the active sessions. You can turn on the Display All switch to view both active and inactive sessions.
- In the Session Statistics section, you can view information about sessions in the Overview, Statistics by Client, and Statistics by Namespace charts.
Terminate instance sessions
- In the Instance Sessions section, select the sessions that you want to terminate, and click Kill Selected.
- In the Terminate Session message, click Kill.