[SERVER-8136] allow db.currentOp() from mongos to show the query jobs performed on secondaries Created: 10/Jan/13 Updated: 06/Dec/22 Resolved: 17/Apr/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Replication |
| Affects Version/s: | 2.2.2 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | stronglee | Assignee: | Backlog - Replication Team |
| Resolution: | Duplicate | Votes: | 4 |
| Labels: | MongosOperationManagement | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Debian 6.0 kernel: Linux 2.6.38-2-amd64 |
||
| Issue Links: |
|
||||||||||||||||||||
| Assigned Teams: |
Replication
|
||||||||||||||||||||
| Operating System: | Linux | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Description |
|
I wanted to use db.killOp() to kill some long time queries which were performed on secondaries by using read preference "Secondary". |
| Comments |
| Comment by Bernard Gorman [ 17/Apr/18 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
spencer: this behaviour has already been implemented as part of the $currentOp aggregation stage; a $currentOp pipeline accepts and will honour a read preference, if one is provided. See the abridged sample output below, with secondaries for each of three shards running on ports 27019, 27022, 27025. I'm going to close this as a dupe of
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Ofer Cohen [ 12/Aug/15 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
This feature is a must-to-have, because it's the only way to monitor easily large cluster queries (and other operations). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by stronglee [ 11/Jan/13 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
I connected to a mongos and I did the query on this mongos. Please consider my case: | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Eliot Horowitz (Inactive) [ 10/Jan/13 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Which node were you connected to? |