问题描述:
conf/hbase-env.sh增加如下配置:
export HBASE_MANAGES_ZK=false
启动hbase没有提示错误,但是在hbase日志文件却有如下错误:
Could not start ZK at requested port of 2181. ZK was started at port: 2182. Aborting as clients (e.g. shell) will not be able to find this ZK quorum.
解决办法:
conf/hbase-site.xml中修改hbase.cluster.distributed的值
<configuration> <property> <name>hbase.cluster.distributed</name> <value>true</value> </property> </configuration>
解释:
-
Hbase的运行模式。false是单机模式,true是分布式模式。若为false,Hbase和Zookeeper会运行在同一个JVM里面。
默认:
false
hbase.cluster.distributed