In innodb, the page size is known as default 16kb. How do I set the page size to 8kb? Is there an option to set in the source compilation step?
You don't need to specify page size in the source compilation step. MySQL 5.6 and later support different page sizes without recompiling.
You must, however, set the page size before the InnoDB tablespace is initialized. All tablespaces (including per-table tablespaces, general tablespaces, undo tablespaces, temp tablespaces, etc.) must use the same page size.
You set the page size to 8KB by putting this line in your /etc/my.cnf
file, in the [mysqld]
section:
innodb_page_size=8K
You need to do this before the InnoDB tablespaces are initialized. If you want to change the page size later:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With