| Bug #30331 | Table_locks_waited shows inaccurate values | ||
|---|---|---|---|
| Submitted: | 9 Aug 2007 16:17 | Modified: | 11 Feb 21:15 |
| Reporter: | Victoria Reznichenko | ||
| Status: | Closed | ||
| Category: | Server | Severity: | S3 (Non-critical) |
| Version: | any | OS: | Any |
| Assigned to: | Davi Arnaut | Target Version: | 5.1 |
| Triage: | D4 (Minor) | ||
[9 Aug 2007 16:17]
Victoria Reznichenko
[21 Dec 2007 13:49]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/40336 ChangeSet@1.2583, 2007-12-21 10:49:21-02:00, davi@mysql.com +3 -0 Bug#30331 Table_locks_waited shows inaccurate values The problem is that the Table_locks_waited was incremented only when the lock request succeed. If a thread waiting for the lock gets killed or the lock request is aborted, the variable would not be incremented, leading to inaccurate values in the variable. The solution is to increment the Table_locks_waited whenever the lock request is queued. This reflects better the intended behavior of the variable -- show how many times a lock was waited.
[22 Jan 15:58]
Dmitri Lenev
I think it is OK to push this patch into 5.1 after adjusting test case to use new and nice facilities instead of wait_show_pattern.
[28 Jan 13:52]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/41298 ChangeSet@1.2661, 2008-01-28 10:52:41-02:00, davi@mysql.com +3 -0 Bug#30331 Table_locks_waited shows inaccurate values The problem is that the Table_locks_waited was incremented only when the lock request succeed. If a thread waiting for the lock gets killed or the lock request is aborted, the variable would not be incremented, leading to inaccurate values in the variable. The solution is to increment the Table_locks_waited whenever the lock request is queued. This reflects better the intended behavior of the variable -- show how many times a lock was waited.
[11 Feb 17:23]
Bugs System
Pushed into 5.1.24-rc
[11 Feb 17:26]
Bugs System
Pushed into 6.0.5-alpha
[11 Feb 21:15]
Paul DuBois
Noted in 5.1.24, 6.0.5 changelogs. The Table_locks_waited waited variable was not incremented in the cases that a lock had to be waited for but the waiting thread was killed or the request was aborted.
[6 Mar 10:03]
Jon Stephens
Also documented for 5.1.23-ndb-6.2.14.
[30 Mar 20:56]
Jon Stephens
Also documented for 5.1.23-ndb-6.3.11.
