Some non-common Triggering Conditions of hbase in Split and major compact

Source: Internet
Author: User

in the major compact function of hbase, the parameter hbase. hregion. majorcompaction has been set to 0.
the log still shows that major compact is used.
there are three ways to trigger major compact
1) trigger by running the hbase shell command major_compact
2) compact when file <= sum (smaller_files) *
'hbase. hstore. compaction. ratio '
in this case, when the number of selected files is equal to the number of files in the store, minor compact will be upgraded to major compact
3) major compact expiration time interval: after (now-min (storefile. timestamp)>
"hbase. hregion. majorcompaction "+ rand () *
hbase. hregion. majorcompaction. jitter "

As for split, hbase. hregion. Max. filesize (10 Gb by default) is not set to a large value to ensure that the split is not performed.Algorithm, See
Increasingtoupperboundregionsplitpolicy is 0.94.0 default region split policy
Here, split has a judgment condition. Calculate the number of online region of the table on the tableregionscount (regionserver ),
Then, it cyclically calculates whether all the stores of this region are too large. This is a size calculated using the getsizetocheck method. If the total size of the current store is greater than this value, this region needs to be split.

The getsizetocheck calculation method first checks whether tableregionscount is equal to 0. If so, hbase. hregion. Max. filesize is returned. If not, math. Min (getdesiredmaxfilesize () is calculated (),

This. flushsize * (tableregionscount * tableregionscount ).

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.