Multiple hash index partitions causes overly large hash index
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Percona Server moved to https://jira.percona.com/projects/PS |
Fix Released
|
High
|
George Ormond Lorch III | ||
5.1 |
Invalid
|
High
|
Unassigned | ||
5.5 |
Fix Released
|
High
|
George Ormond Lorch III |
Bug Description
Normally, adaptive hash index is initialized to 1/64 th of the buffer pool size.
in buf_pool_init:
btr_search_
However, innodb_
This leads to each partition being created with size of 1/64 of the buffer pool instead of 1/(64*number_
For instance, for a buffer pool of size 192G, without partitions it will be 3 GB but if the number of partitions is say, 8, it will be 24 G and will scale with that.
What is expected:
The size of each partition should be decided after taking into account the number of buffer pool instances, ie.
in btr_search_
..otherwise each partition will be created with size of an otherwise single partition.
Related branches
- Stewart Smith (community): Approve
-
Diff: 19 lines (+9/-0)1 file modifiedPercona-Server/storage/innobase/btr/btr0sea.c (+9/-0)
On a second thought, instead of
hash_size /= btr_search_ index_num may be better since that is more directly related to the adaptive hash index.