错误1:

running matser, logging to /opt/hbase-1.6.0/bin/../logs/hbase-jamjar-matser-master.out
Error: Could not find or load main class matser

原因&解决:hbase-env.sh 中需要export你的Java路径

 

错误2:

running master, logging to /opt/hbase-1.6.0/bin/../logs/hbase-jamjar-master-master.out
[Fatal Error] core-site.xml:1:1: Content is not allowed in prolog.
 

原因&解决:软连接hadoop的xml 地址写错了,我这里软连接了整个文件夹

注意只软连接core_site.xml文件

ln -s XX.XX.XX.core_site.xml core_site.xml

 

错误3:

running master, logging to /opt/hbase-1.6.0/bin/../logs/hbase-jamjar-master-master.out
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [jar:file:/opt/hbase-1.6.0/lib/slf4j-log4j12-1.7.25.jar!/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [jar:file:/home/jamjar/hadoop-2.7.5/share/hadoop/common/lib/slf4j-log4j12-1.7.10.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]

原因:找到了两个jar包对应的StaticLoggerBinder.class,分别在我的/opt/hbase-1.6.0/lib/slf4j-log4j12-1.7.25.jar和/hadoop-2.7.5/share/hadoop/common/lib/slf4j-log4j12-1.7.10.jar

解决:移除一个jar包,我移除了hbase的

 

 

错误4:

我用./bin/hbase-daemon.sh start master 启动之后没有报错,然后进入浏览器master:16010 时候报的错误

HTTP ERROR 500

Problem accessing /master-status. Reason:

    Master is initializing

Caused by:

org.apache.hadoop.hbase.PleaseHoldException: Master is initializing
    at org.apache.hadoop.hbase.master.HMaster.isInMaintenanceMode(HMaster.java:2789)
    at org.apache.hadoop.hbase.tmpl.master.MasterStatusTmplImpl.renderNoFlush(MasterStatusTmplImpl.java:249)
    at org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl.renderNoFlush(MasterStatusTmpl.java:395)
    at org.apache.hadoop.hbase.tmpl.master.MasterStatusTmpl.render(MasterStatusTmpl.java:386)
    at org.apache.hadoop.hbase.master.MasterStatusServlet.doGet(MasterStatusServlet.java:81)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1221)
    at org.apache.hadoop.hbase.http.lib.StaticUserWebFilter$StaticUserFilter.doFilter(StaticUserWebFilter.java:113)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.apache.hadoop.hbase.http.ClickjackingPreventionFilter.doFilter(ClickjackingPreventionFilter.java:48)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.apache.hadoop.hbase.http.HttpServer$QuotingInputFilter.doFilter(HttpServer.java:1453)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.apache.hadoop.hbase.http.NoCacheFilter.doFilter(NoCacheFilter.java:49)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.apache.hadoop.hbase.http.NoCacheFilter.doFilter(NoCacheFilter.java:49)
    at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
    at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
    at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
    at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
    at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:766)
    at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
    at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
    at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
    at org.mortbay.jetty.Server.handle(Server.java:326)
    at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
    at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:928)
    at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:549)
    at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
    at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
    at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
    at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)

原因&解决:

先启动regionserver,在启动HMaster。

  在regionServer上./hbase-daemon.sh start regionserver

  在master上执行:./bin/hbase-daemon.sh start master

致谢:https://blog.csdn.net/liuxiao723846/article/details/53146304

http://mail-archives.apache.org/mod_mbox/hadoop-user/201211.mbox/%3C1352628661.70639.YahooMailNeo@web15807.mail.cnb.yahoo.com%3E

 

错误5:

./bin/stop-hbase.sh 关闭hbase的出错:

 

stopping hbasecat: /tmp/hbase-jamjar-master.pid: No such file or directory

原因:主要还是因为你没启动成功,所以没有pid

 

错误6:

2021-04-15 07:04:32,844 WARN  [master:16000.activeMasterManager] ipc.Client: Failed to connect to server: master/192.168.110.129:9000: try once and fail.
java.net.ConnectException: Connection refused
    at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
    at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:716)
    at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)
    at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:531)
    at org.apache.hadoop.ipc.Client$Connection.setupConnection(Client.java:685)
    at org.apache.hadoop.ipc.Client$Connection.setupIOstreams(Client.java:788)
    at org.apache.hadoop.ipc.Client$Connection.access$3500(Client.java:410)
    at org.apache.hadoop.ipc.Client.getConnection(Client.java:1550)
    at org.apache.hadoop.ipc.Client.call(Client.java:1381)
    at org.apache.hadoop.ipc.Client.call(Client.java:1345)
    at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:227)
    at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:116)
    at com.sun.proxy.$Proxy16.setSafeMode(Unknown Source)
    at org.apache.hadoop.hdfs.protocolPB.ClientNamenodeProtocolTranslatorPB.setSafeMode(ClientNamenodeProtocolTranslatorPB.java:691)

注意hdfs里面的默认服务端口,我这里写的是8020,所以hbase里面也要写8020!!! 9000自然连接不上!

  <property>
     <name>fs.default.name</name>
     <value>hdfs://master:8020</value>
  </property>

注意你的hbase和hadoop版本是否兼容:

HBASE和HADOOP版本不兼容!

HBASE和HADOOP版本不兼容!

HBASE和HADOOP版本不兼容!

HBASE和HADOOP版本不兼容!

HBASE和HADOOP版本不兼容!

HBASE和HADOOP版本不兼容!

 

Logo

华为开发者空间,是为全球开发者打造的专属开发空间,汇聚了华为优质开发资源及工具,致力于让每一位开发者拥有一台云主机,基于华为根生态开发、创新。

更多推荐