This is a read-only copy of the MariaDB Knowledgebase generated on 2024-11-16. For the latest, interactive version please visit https://mariadb.com/kb/.

How Innodb chunk size is influenced in Innodb buffer pool after eliminating buffer pool instances

After the removal of InnoDB buffer pool instances in MariaDB 10.5.1 (JIRA ticket). I would like to understand how the Chunk sizes should be calculated?

Is it still valid to have following criteria?

1.Buffer pool size must always be equal to or a multiple of innodb_buffer_pool_chunk_size * innodb_buffer_pool_instances.

2.If innodb_buffer_pool_chunk_size * innodb_buffer_pool_instances is larger than the current buffer pool size when the buffer pool is initialized, innodb_buffer_pool_chunk_size is truncated to innodb_buffer_pool_size / innodb_buffer_pool_instances?

OR

Are we advised to set the innodb_buffer_pool_chunk_size to zero(0) where innodb storage engine calculates as innodb_buffer_pool_size/64 and determines the value at startup.

My first question, how we can determine the ideal chunk size in mariadb 10.11 with pool instance always being 1.

Next question, does chunk size impacts performance in anyway? My understanding on the Impacts of performance for tweaking chunk size is that smaller chunk size can be efficient for random access, as it allows for better utilization of the buffer pool for frequent accessed smaller units of data. On the other side for larger chunk size more data is read/written in each I/O operation, potentially reducing the frequency of I/O requests and it would work better with sequential access patterns than random access patterns.

Thanks in advance.

Answer Answered by Daniel Black in this comment.

buffer pool = innodb_buffer_pool_chunk_size * innodb_buffer_pool_instances.

This was never true.

The chunk size represents the minium increment in which InnoDB buffer pool can resize up or down. That's it. Previous defaults where too small meaning to took a long time to initialize on large memory systems, and who was really going to downsize by 0.0001%. The buffer_pool_size/64 puts in the the reasonable number percentage for a quick resize if needed. So provided the buffer_pool_size intially is in the order of magnitude of the current buffer pool size, the default is sufficient

Also chunks are being removed - MDEV-29445.

InnoDB pages are always the fixed size, default 16k but can be down to 4k or up to 64k (configurable installation time only).

Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.