Hadoop 2.2.0 클러스터에서 wordcount 예제를 실행하려고합니다.Hadoop 맵이 ConnectException으로 인해 실패했습니다.
2014-01-07 05:07:12,544 WARN [main] org.apache.hadoop.mapred.YarnChild: Exception running child : java.net.ConnectException: Call From slave2-machine/127.0.1.1 to slave2-machine:49222 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
at org.apache.hadoop.net.NetUtils.wrapWithMessage(NetUtils.java:783)
at org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:730)
at org.apache.hadoop.ipc.Client.call(Client.java:1351)
at org.apache.hadoop.ipc.Client.call(Client.java:1300)
at org.apache.hadoop.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:231)
at com.sun.proxy.$Proxy6.getTask(Unknown Source)
at org.apache.hadoop.mapred.YarnChild.main(YarnChild.java:133)
Caused by: java.net.ConnectException: Connection refused
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:708)
at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)
at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:529)
at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:493)
at org.apache.hadoop.ipc.Client$Connection.setupConnection(Client.java:547)
at org.apache.hadoop.ipc.Client$Connection.setupIOstreams(Client.java:642)
at org.apache.hadoop.ipc.Client$Connection.access$2600(Client.java:314)
at org.apache.hadoop.ipc.Client.getConnection(Client.java:1399)
at org.apache.hadoop.ipc.Client.call(Client.java:1318)
... 4 more
작업을 실행할 때마다 문제가있는 포트가 변경되지만 맵 작업이 여전히 실패합니다. 나는 그 포트를 듣기로되어있는 프로세스를 모른다. 또한 실행 중에 netstat -ntlp
출력을 추적하려고 시도했지만 프로세스가 포트를 수신하지 않았습니다.
는 UPDATE :
127.0.0.1 localhost
127.0.1.1 master-machine
# 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
192.168.1.101 slave1 slave1-machine
192.168.1.102 slave2 slave2-machine
192.168.1.1 master
및 SLAVE1입니다 : 마스터 노드에 대한 /etc/hosts
의 내용이 있습니다이 작은 변화와 SLAVE1처럼 slave2에 대한
127.0.0.1 localhost
127.0.1.1 slave1-machine
# 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
192.168.1.1 master
192.168.1.101 slave1
192.168.1.102 slave2 slave2-machine
나는 당신이 추측 수 있다고 생각. 마지막으로, 마스터 yarn/hadoop/etc/hadoop/slaves
의 내용은 다음과 같습니다 하둡 노드가 서로 ssh를 할 수 있는지 여부
slave1
slave2
1- 마스터 노드는 각 슬레이브를 ssh 할 수 있습니다. 노예가 서로를 ssh 할 수 있어야한다는 것을 의미합니까?! 2 예, 동일합니다. 3 질문을'/ etc/hosts' 콘텐츠로 업데이트합니다. – Mehraban
답변을 업데이트했습니다. 아직 문제가 있는지 말해봐 – masoumeh
글쎄, 나는 그것을 발견했다 [여기] (http://mail-archives.apache.org/mod_mbox/hadoop-user/201208.mbox/%3CCAKEkMX-ca44-FnHaXip=DBbYHqgg9JW+GPc38Cq4Gvt8keigYQ @ mail.gmail.com % 3E) 그러나 나는 그것에 대해 연구 중이다. 그것은 기계의 이름과 관련이 있습니다. 'master'는 기계 이름이어야합니다. – Mehraban