Hbase優化之Region分割設定的問題

2021-07-15 06:58:47 字數 730 閱讀 7760

hbase優化之region分割設定的問題

hbase一張表可以分別儲存在幾個region上,乙個region又分成了好多store,乙個store又分成了memstore和storefile,當memstore滿64mb後,會把資料flush到disk上而成為storefile,當storefile數量超過3(設定)時,會啟動compaction過程將它們合併為乙個storefile。這個過程中會刪除一些timestamp過期的資料,比如update的資料。而當合併後的storefile大小大於hfile預設最大值時,會觸發split動作,也就是說,當乙個region內的所有儲存檔案中最大的那個hfile大於hbase.hregion.max.filesize所設定的大小,則將乙個region切分成兩個region。

調整hbase-site.xml中的 hbase.hregion.max.filesize屬性.舊版本預設為256mb,可以自行配置。

hbase.hregion.max.filesize

1073741824

maximum hstorefile size. if any one of a column families' hstorefiles has

grown to exceed this value, the hosting hregion is split in two.

default: 1g.

property>

HBase之Region上Spilt流程分析

我們知道在memstore達到閥值以後,會進行flushregion操作.那麼在操作完成之後,會對hregion進行檢查,看是否hregion是否已經達到閥值,如果已經達到閥值,則需要對hregion進行split操作。一 檢測hregion是否需要進行split的流程分析 boolean shou...

Hbase均衡Region和許可權管理

查詢namespace為amrcloud中名為powerdata的表的資料 scan amrcloud powerdata 查詢某一條資料 get t1 r1 t1為表名,r1為rowkey,c1為column family 列出所有表 list 列出所有namespace list namespa...

HBase之效能優化

3.讀表操作 3.1 多htable併發讀 建立多個htable客戶端用於讀操作,提高讀資料的吞吐量,乙個例子 static final configuration conf hbaseconfiguration.create static final string table log name u...