What are some tips for configuring HBase?

本文提供了HBase配置优化的关键步骤,包括系统级设置、HDFS参数调整、HBase默认配置修改等,旨在提升HBase集群的性能和稳定性。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

   
Much of this content is taken from the  HBase Overview [1] and the HBase Default Configuration [2] .

System
  • Increase the default per-process file handle limit [3] in 
    /etc/security/limits.conf
     
         

HDFS
  • Set dfs.datanode.max.xceivers to 2047 [4] in 
    $HADOOP_HOME/conf/hdfs-site.xml
     
         
  • Set dfs.datanode.socket.write.timeout to 0 [5]

HBase
  • First, note that the default configuration values are stored atsrc/main/resources/hbase-default.xml [6] in the source tree
  • For your site-specific configuration values, edit conf/hbase-site.xml
  • Set hbase.rootdir to point to the directory in HDFS where HBase will put its data; e.g. 
    hdfs://localhost:9000/hbase
     
         

Per-Cluster
  • hfile.block.cache.size controls the amount of region server heap space to devote to the block cache. Currently defaults to 20%.

Per-Table
  • Max File Size: for clusters with lots of data, can be tuned up to 1 GB to result in less regions on the cluster.
  • MemStore Flush Size

Per-Family
  • Compression
  • Bloom filters

Per-Region Server
  • hbase.regionserver.global.memstore.upperLimit is used to cap the amount of heap room in each region server to reserve for all MemStores [7] served by that region. It defaults to 40% of the heap. 
  • hbase.hregion.memstore.flush.size is the threshold for deciding when to flush a single MemStore to disk. It defaults to 64 MB.
  • hbase.hregion.memstore.block.multiplier controls when to start blocking writes to keep the MemStore size sane. It defaults to 2 (multiplied by the memstore.flush.size). For production clusters with lots of RAM that you monitor closely, you can up to something like 8.
  • hbase.hregion.max.filesize determines how big a StoreFile is allowed to grow before splitting a region. Defaults to 256 MB.

Per-Store
  • hbase.hstore.blockingStoreFiles determines the maximum number of StoreFiles per Store to allow before blocking writes and forcing a compaction. The default is 7, but in production clusters monitored closely, it may make sense to up to 15.

[1]  http://hbase.apache.org/docs/cur...
[2]  http://hbase.apache.org/docs/cur...
[3]  http://wiki.apache.org/hadoop/Hb...
[4]  http://wiki.apache.org/hadoop/Hb...
[5]  http://hbase.markmail.org/thread...
[6]  http://svn.apache.org/viewvc/hba...
[7]  http://hbase.apache.org/docs/cur...

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值