[SERVER-21305] Lock 'timeAcquiringMicros' value is much higher than the actual time spent Created: 05/Nov/15 Updated: 22/Apr/16 Resolved: 09/Nov/15 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Concurrency |
| Affects Version/s: | 3.0.7, 3.2.0-rc2 |
| Fix Version/s: | 3.0.8, 3.2.0-rc3 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Kaloian Manassiev | Assignee: | Geert Bosch |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Backport Completed: | |||||||||||||||||
| Sprint: | QuInt C (11/23/15) | ||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
This is present both in 3.0 and in 3.2 (master), but not in 2.6 or earlier. For each wait which is more than a second, MongoDB will report the sum of arithmetic progression of all 500 msec increments of the wait, so basically we report approximately a square of the actual wait time. It happens on this line. For lock waits, we wake up every 500 milliseconds to check for deadlock and to also update the wait time counters so that if a thread is blocked for a long time, the currentOp statistics will reflect that. The bug is in that we do not reset the last sample timestamp and so the time keeps accumulating. The workaround until we fix it would be to take the square root of the wait time reported in the lock info. |
| Comments |
| Comment by Githook User [ 09/Nov/15 ] |
|
Author: {u'username': u'GeertBosch', u'name': u'Geert Bosch', u'email': u'geert@mongodb.com'}Message: (cherry picked from commit ba231028314553f1495e6583d5a59c55919a764c) |
| Comment by Githook User [ 09/Nov/15 ] |
|
Author: {u'username': u'GeertBosch', u'name': u'Geert Bosch', u'email': u'geert@mongodb.com'}Message: |