安裝版本
Hbase版本 2.1.4
Hadoop版本 2.9
異常
java.lang.IllegalStateException: The procedure WAL relies on the ability to hsync for proper operation during component failures, but the underlying filesystem does not support doing so. Please check the config value of 'hbase.procedure.store.wal.use.hsync' to set the desired level of robustness and ensure the config value of 'hbase.wal.dir' points to a FileSystem mount that can provide it.
hbase-site.xml增加配置
<property>
<name>hbase.unsafe.stream.capability.enforce</name>
<value>false</value>
</property>
ERROR: KeeperErrorCode = NoNode for /hbase/meta-region-server
ERROR: KeeperErrorCode = NoNode for /hbase/master
檢查配置馁菜,檢查zookeeper是否正常
解決:刪除zookeeper下的/habse rmr /habse
刪除hbase.zookeeper.property.dataDir 默認(rèn)為/tmp/habse-{hostname}
刪除hdfs中的hbase hadoop dfs -rm -r /hbase
Java.lang.NoClassDefFoundError: Could not initialize class org.apache.hadoop.hbase.io.asyncfs.FanOutOneBlockAsyncDFSOutputHelper
hbase-site.xml增加配置
<property>
<name>hbase.wal.provider</name>
<value>filesystem</value>
</property>
java.lang.NoClassDefFoundError: org/apache/htrace/SamplerBuilder
添加舊版本的htrace-core-3.1.0-incubating.jar茴扁,可以從舊版本的hbase的lib中拷貝到當(dāng)前版本的hbase lib。
hbase-env.sh配置
export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
export HBASE_CLASSPATH=/usr/local/hadoop/etc/hadoop
export HBASE_MANAGES_ZK=false
hbase-site.xml配置
<configuration>
<property>
<name>hbase.rootdir</name>
<value>hdfs://localhost:9000/hbase</value>
</property>
<property>
<name>hbase.cluster.distributed</name>
<value>true</value>
</property>
<property>
<name>hbase.unsafe.stream.capability.enforce</name>
<value>false</value>
</property>
<property>
<name>hbase.wal.provider</name>
<value>filesystem</value>
</property>
<property>
<name>hbase.zookeeper.property.clientPort</name>
<value>2181</value>
</property>
<property>
<name>hbase.zookeeper.quorum</name>
<value>localhost:2181</value>
</property>
</configuration>