ANALYZE TABLE should remove its table from background stat processing queue

Bug #1626441 reported by Laurynas Biveinis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Server
Unknown
Unknown
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.5
Invalid
Undecided
Unassigned
5.6
Fix Released
Medium
Laurynas Biveinis
5.7
Fix Released
Medium
Laurynas Biveinis

Bug Description

Copy of http://bugs.mysql.com/bug.php?id=71761:

[18 Feb 2014 15:03] Laurynas Biveinis
Description:
1. An InnoDB table receives many updates and is added to the background stats processing queue.
2. Updates stop, an ANALYZE TABLE request comes, and the table stats are recalculated.
3. Some time later, the background stats thread picks up this table and recalculates its stats even though they are already up to date.

How to repeat:
Run write workload on a table, stop it, ANALYZE TABLE, observe the background stats thread recalculating its stats again.

Suggested fix:
One way to fix it is to add dict_stats_recalc_pool_del(ib_table), guarded by dict_mutex_enter/exit_for_mysql(), to ha_innobase::info_low if(is_analyze || innobase_stats_on_metadata).

tags: added: innodb upstream
Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :
Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-1749

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.