[SERVER-26705] Need a command that lists all connections to/from a given mongos or mongod Created: 19/Oct/16  Updated: 20/Jun/23

Status: Backlog
Project: Core Server
Component/s: Networking
Affects Version/s: None
Fix Version/s: None

Type: New Feature Priority: Major - P3
Reporter: Andrew Young Assignee: Backlog - Service Architecture
Resolution: Unresolved Votes: 11
Labels: service_architecture
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Related
related to SERVER-18470 Give some indication of age of inacti... Backlog
related to SERVER-5261 Include authentication information in... Closed
Assigned Teams:
Service Arch
Participants:
Case:

 Description   

The currentOp(true) command does not always return a list of all open connections to and from a given mongos or mongod. This is especially true on a mongos where the command instead calls currentOp() on the primary nodes of each shard and merges the results together.

I need a reliable way to determine what connections are currently open to and from a given mongos or mongod server. This list should correspond to the connection count from db.serverStatus().connections.



 Comments   
Comment by Kyle Mertz [ 28/Dec/18 ]

Couldn't you add a new call (totalOps or connectionInfo or creativeNameHere) instead of changing currentOp?  I assume that's the biggest delay in delivering this...the impact to existing users.  My need is slightly different than the requestor, but I definitely see his point.  My need is to be able to show the total connections from a specific client host.  So a group by on clients with the connection counts.  This is very helpful when you have a single client spamming connections into your mongod.  This is pretty trivial with other database platforms, I'm actually quite shocked there isn't already a solution for this outside of parsing log messages.

Comment by Gregory McKeon (Inactive) [ 16/Aug/18 ]

Since investigating, we've determined that this ticket is more than a change to the existing behavior of currentOp and will have user facing changes. Removing from Quick Wins and moving to track this as an epic for scheduling at our next quarterly planning.

Generated at Thu Feb 08 04:12:57 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.