安装HBase后,HMaster进程无法在hadoop多节点集群上运行。

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了安装HBase后,HMaster进程无法在hadoop多节点集群上运行。相关的知识,希望对你有一定的参考价值。

我在两个ubuntu虚拟机上安装了一个hadoop多节点集群,下一步我试图在这个虚拟集群上安装HBase。

在下一步,我试图在这个虚拟集群上安装HBase。但是,当我在这个虚拟集群上运行HBase时 start-hbase.sh, HMaster 主站不运行 HRegionServer 已在主、从机上正确运行。

hbase-env.sh 文件内容。

export JAVA_HOME=/usr/lib/jvm/java-8-openjdk-amd64
export HBASE_OPTS="$HBASE_OPTS -XX:+UseConcMarkSweepGC"
export HBASE_MANAGES_ZK=false

hbase-site.xml 文件内容: 文件内容:

<configuration>
    <property>
            <name>hbase.rootdir</name>
            <value>hdfs://machine-a:54310/hbase</value>
    </property>
    <property>
            <name>hbase.zookeeper.property.dataDir</name>
            <value>/usr/local/zookeeper</value>
    </property>
    <property>
            <name>hbase.cluster.distributed</name>
            <value>true</value>
    </property>
    <property>
            <name>hbase.zookeeper.property.clientPort</name>
            <value>2181</value>
    </property>
    <property>
            <name>hbase.zookeeper.quorum</name>
            <value>machine-a</value>
    </property>
</configuration>

zoo.cfg 文件内容:

tickTime=2000
initLimit=10
syncLimit=5
dataDir=/usr/local/zookeeper
clientPort=2181

运行zookeeper。

ZooKeeper JMX enabled by default 
Using config: /usr/local/zookeeper 3.4.13/bin/../conf/zoo.cfg
Starting zookeeper ... /usr/local/zookeeper 3.4.13/bin/zkServer.sh: line 140: ./zookeeper.out: Permission denied
STARTED

运行HBase

/usr/local/hadoop-3.1.2/libexec/hadoop-functions.sh: line 2358: HADOOP_ORG.APACHE.HADOOP.HBASE.UTIL.GETJAVAPROPERTY_USER: bad substitution
/usr/local/hadoop-3.1.2/libexec/hadoop-functions.sh: line 2453: HADOOP_ORG.APACHE.HADOOP.HBASE.UTIL.GETJAVAPROPERTY_OPTS: bad substitution
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/local/hadoop-3.1.2/share/hadoop/common/lib/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/local/hbase-2.1.2/lib/client-facing-thirdparty/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
running master, logging to /usr/local/hbase-2.1.2/logs/hbase-saeed-master-machine-a.out
/usr/local/hadoop-3.1.2/libexec/hadoop-functions.sh: line 2358: HADOOP_ORG.APACHE.HADOOP.HBASE.UTIL.GETJAVAPROPERTY_USER: bad substitution
/usr/local/hadoop-3.1.2/libexec/hadoop-functions.sh: line 2453: HADOOP_ORG.APACHE.HADOOP.HBASE.UTIL.GETJAVAPROPERTY_OPTS: bad substitution
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/usr/local/hadoop-3.1.2/share/hadoop/common/lib/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/usr/local/hbase-2.1.2/lib/client-facing-thirdparty/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
saeed@machine-b: running regionserver, logging to /usr/local/hbase-2.1.2/bin/../logs/hbase-saeed-regionserver-machine-b.out
saeed@machine-a: running regionserver, logging to /usr/local/hbase-2.1.2/bin/../logs/hbase-saeed-regionserver-machine-a.out
答案

当我试图启动HBase时,也出现了类似的日志,当我查看主日志时,可以看到以下内容。

2020-05-25 16:18:20,529 ERROR [masterVB-hbase:16000:becomeActiveMaster] master.HMaster: ***** ABORTING master vb-hbase,16000,1590403688901: 未处理的异常。开始关机。***** java.lang.IllegalStateException: 存储过程WAL依赖于在组件故障时进行正常操作的hsync能力,但底层文件系统不支持这样做。请检查 'hbase.procedure.store.wal.use.hsyn'。c'来设置所需的健壮程度,并确保'hbase.wal.dir'的配置值指向能够提供它的FileSystem mount。

然后我按照 这里的步骤

很显然,我们在启动和主站不上来的过程中看到的无效变量记录的错误可能没有直接的联系,因为我还是可以看到这个错误,但是到现在为止似乎一切正常。

以上是关于安装HBase后,HMaster进程无法在hadoop多节点集群上运行。的主要内容,如果未能解决你的问题,请参考以下文章

HBase 启动后HMaster进程自动消失

hbase启动后HMaster进程自动关闭

hbase启动后HMaster进程自动关闭

Hbase的Hmaster进程没有启动

Hbase无法正常启动,hbase网页打不开,HMaster启动后自动关闭

hbase启动后HMaster几秒后死掉