Hbase启动失败,因为regionserver的主机名无法设置为localhost

时间:2015-04-06 04:35:58

标签: hbase

我有三个节点来启动Hbase集群,但它无法启动HMenter和Regionservers,例外情况如下:

FATAL [main] regionserver.RSRpcServices: The hostname of regionserver cannot be set to localhost in a fully-distributed setup because it won't be reachable. See "Getting Started" for more information.
2015-04-05 09:11:58,160 ERROR [main] master.HMasterCommandLine: Master exiting
java.lang.RuntimeException: Failed construction of Master: class org.apache.hadoop.hbase.master.HMaster
    at org.apache.hadoop.hbase.master.HMaster.constructMaster(HMaster.java:1982)
    at org.apache.hadoop.hbase.master.HMasterCommandLine.startMaster(HMasterCommandLine.java:198)
    at org.apache.hadoop.hbase.master.HMasterCommandLine.run(HMasterCommandLine.java:139)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:70)
    at org.apache.hadoop.hbase.util.ServerCommandLine.doMain(ServerCommandLine.java:126)
    at org.apache.hadoop.hbase.master.HMaster.main(HMaster.java:1996)
#127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
Caused by: java.io.IOException: The hostname of regionserver cannot be set to localhost in a fully-distributed setup because it won't be reachable.

有人说区域服务器的主机名是Localhost。但事实并非如此,我的两个regionservers的主机名分别是dev1.test.local和dev2.test.local。 我还在配置文件RegionServers中指定了IP。 我很好奇为什么HMaster认为RegionServer的主机名是localhost? 提前致谢!

1 个答案:

答案 0 :(得分:0)

在hbase 1.0中,您无法将master添加为区域服务器。