问题描述
- 求救啊!Hadoop 2.2.0 搭建集群 启动hdfs时候 namenode 启动后报空指针
-
日志如下:
2015-02-07 01:01:46,610 FATAL org.apache.hadoop.hdfs.server.namenode.NameNode: Error encountered requiring NN shutdown. Shutting down immediately.
java.lang.NullPointerException
at org.apache.hadoop.hdfs.DFSUtil.substituteForWildcardAddress(DFSUtil.java:942)
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyCheckpointer.getHttpAddress(StandbyCheckpointer.java:108)
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyCheckpointer.setNameNodeAddresses(StandbyCheckpointer.java:90)
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyCheckpointer.(StandbyCheckpointer.java:76)
at org.apache.hadoop.hdfs.server.namenode.FSNamesystem.startStandbyServices(FSNamesystem.java:994)
at org.apache.hadoop.hdfs.server.namenode.NameNode$NameNodeHAContext.startStandbyServices(NameNode.java:1456)
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyState.enterState(StandbyState.java:58)
at org.apache.hadoop.hdfs.server.namenode.NameNode.(NameNode.java:686)
at org.apache.hadoop.hdfs.server.namenode.NameNode.(NameNode.java:669)
at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1254)
at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1320)
2015-02-07 01:01:46,614 INFO org.apache.hadoop.util.ExitUtil: Exiting with status 1
2015-02-07 01:01:46,620 INFO org.apache.hadoop.hdfs.server.namenode.NameNode: SHUTDOWN_MSG:我就不明白了,为什么就一直报空指针,而且,远程调试的时候就不会报错,已经凌乱了。
解决方案
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyCheckpointer.getHttpAddress(StandbyCheckpointer.java:108)
at org.apache.hadoop.hdfs.server.namenode.ha.StandbyCheckpointer.setNameNodeAddresses(StandbyCheckpointer.java:90)
检查一下NameNode服务器地址的配置,和NameNode服务器通信是否正常。
时间: 2024-11-03 12:36:21