与FS的连接不良

时间:2012-09-16 15:48:33

标签: hadoop

我正在使用Cloudera Hadoop(cdh3u1),我遇到以下错误消息:

[root@paul conf.class]# sudo -u hdfs hadoop fs -mkdir /user/training 
12/09/16 07:40:26 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 0 time(s).
12/09/16 07:40:27 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 1 time(s).
12/09/16 07:40:28 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 2 time(s).
12/09/16 07:40:29 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 3 time(s).
12/09/16 07:40:30 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 4 time(s).
12/09/16 07:40:31 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 5 time(s).
12/09/16 07:40:32 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 6 time(s).
12/09/16 07:40:33 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 7 time(s).
12/09/16 07:40:34 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 8 time(s).
12/09/16 07:40:35 INFO ipc.Client: Retrying connect to server: peter/192.168.1.100:8020. Already tried 9 time(s).
Bad connection to FS. command aborted. exception: Call to peter/192.168.1.100:8020 failed on local exception: java.net.NoRouteToHostException: No route to host

我在名为Paul的从属节点上运行此命令并尝试连接到名为Peter的主节点。请帮忙!

1 个答案:

答案 0 :(得分:1)

堆栈跟踪只是说在paul上运行的客户端无法连接到端口8020上运行在192.168.1.100上的Namenode。

检查:

1)namenode在peter / 192.168.1.100:8020上运行。您可以在peter中执行jps以检查Namenode进程是否正在运行,或者尝试从浏览器中的paul或localhost:50070浏览192.168.1.100:50070以查看namenode的web ui是否即将启动。

2)core-site.xml中的“fs.default.name”,即“192.168.1.100:8020”是正在运行namenode的服务器的正确地址和端口。