0

Our HBase cluster (version 2.1.10) is generating excessively small HFiles, often below 10 MB and sometimes as low as 2 KB.

This occurs despite configuring hbase.hregion.memstore.flush.size to a 256M and tuning parameters like hbase.hregion.percolumnfamilyflush.size.lower.bound.min to match the flush size. Additionally, we've enabled BASIC in-memory compaction.

The root cause appears to be the global nature of MemStoreSizing . This variable, shared across all column families within a region,triggers a region-wide flush when the total memstore size exceeds the threshold.

Consequently, even if only one column family is actively accumulating data, the entire region is flushed, potentially leading to the creation of small HFiles.

We seek guidance on strategies to prevent the generation of small HFiles and to enable per-column-family flushing in multi-column-family HBase tables.

Olaf Kock
48.3k9 gold badges63 silver badges91 bronze badges
asked Nov 17, 2024 at 7:28

1 Answer 1

0

To avoid creating small files in HBase, increase the MemStore flush size

(hbase.regionserver.memstore.flush.size)

and write buffer size

(hbase.regionserver.write.buffer.size)

to delay flushing. Adjust compaction settings, like storefile compaction threshold

(hbase.regionserver.storefile.compaction.threshold)

to reduce frequent minor compactions. Increase blockingStoreFileSize

(hbase.hstore.blockingStoreFileSize)

to control HFile sizes. Consider using bulk loading for large data imports. Also, optimize region sizes by adjusting region split size

(hbase.regionserver.region.split.size)

Regularly monitor HBase metrics and adjust configurations for efficient flushing and file management.

answered Nov 17, 2024 at 7:32
Sign up to request clarification or add additional context in comments.

1 Comment

Increasing the flush size can reduce the number of regions per region server compaction is after Hfile create, I perfer to have bigger Hfile before compaction

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.