amazonec2上hadoop中的bindexception

wooyq4lh  于 2021-06-03  发布在  Hadoop
关注(0)|答案(1)|浏览(352)

我正在尝试在ec2示例上设置hadoop集群(cdh4)。当我试图格式化namenode时,它一直崩溃。这就是我得到的错误。

2013-04-12 05:37:16,995 FATAL org.apache.hadoop.hdfs.server.namenode.NameNode: Exception in namenode join
java.net.BindException: Problem binding to [head.node.iec.project:8020] java.net.BindException: Cannot assign requested address; For more details see:  http://wiki.apache.org/hadoop/BindException
    at org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:715)
    at org.apache.hadoop.ipc.Server.bind(Server.java:356)
    at org.apache.hadoop.ipc.Server$Listener.<init>(Server.java:454)
    at org.apache.hadoop.ipc.Server.<init>(Server.java:1835)
    at org.apache.hadoop.ipc.RPC$Server.<init>(RPC.java:970)
    at org.apache.hadoop.ipc.ProtobufRpcEngine$Server.<init>(ProtobufRpcEngine.java:375)
    at org.apache.hadoop.ipc.ProtobufRpcEngine.getServer(ProtobufRpcEngine.java:350)
    at org.apache.hadoop.ipc.RPC.getServer(RPC.java:695)
    at org.apache.hadoop.ipc.RPC.getServer(RPC.java:684)
    at org.apache.hadoop.hdfs.server.namenode.NameNodeRpcServer.<init>(NameNodeRpcServer.java:239)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.createRpcServer(NameNode.java:453)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.initialize(NameNode.java:435)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:609)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.<init>(NameNode.java:590)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1141)
    at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1205)
2013-04-12 05:37:16,998 INFO org.apache.hadoop.util.ExitUtil: Exiting with status 1
2013-04-12 05:37:17,024 INFO org.apache.hadoop.hdfs.server.namenode.NameNode: SHUTDOWN_MSG:

hosts文件如下所示

127.0.0.1 localhost
184.73.62.190  head.node.iec.project head
54.244.75.141  node1.node.iec.project node1

# The following lines are desirable for IPv6 capable hosts

::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

有人能帮我吗?

93ze6v8z

93ze6v8z1#

我犯的错误是使用示例的公共ip,而不是amazon分配的本地ip(10.x.x.x)。解决了这个问题。

相关问题