WiredTiger page size

I’m trying to run MongoDB on top of ZFS (I know about ext4 and XFS as the recommended solution), and I got stuck a bit with a recordsize ZFS option. To set it properly, I need to know if there is a fixed pagesize WiredTiger operates with. Something like an innodb_page_size for InnoDB MySQL.

I couldn’t find a word about it, only logrecord size param of a journal.

Thanks in advance.

The parameter I was looking for is referred to as the allocation_size It’s WiredTiger parameter. From the documentation

A component of WiredTiger called the Block Manager divides the on-disk pages into smaller chunks called blocks, which then get written to the disk. The size of these blocks is defined by a parameter called allocation_size, which is the underlying unit of allocation for the file the data gets stored in. An application might choose to have data compressed before it gets stored to disk by enabling block compression.

By default, for MongoDB it’s equal to 4KB

It could be changed with storage.wiredTiger.collectionConfig.configString , storage.wiredTiger.indexConfig.configString and while create collection.


1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.