MAPREDUCE作业设置由于连接异常而失败

时间:2018-08-06 08:30:11

标签: java docker hadoop mapreduce

通过IDEA远程调试运行mapreduce作业时,出现此错误:

  

15:08:04,822 |信息|主|工作机会org.apache.hadoop.mapreduce.Job 1431 |作业job_1533539222010_0001因状态失败而失败,原因是:作业设置失败:java.net.ConnectException:连接异常时从master / 172.17.0.5到192.168.0.28:8020调用失败:java.net.ConnectException:连接被拒绝;有关更多详细信息,请参见:http://wiki.apache.org/hadoop/ConnectionRefused       在sun.reflect.NativeConstructorAccessorImpl.newInstance0(本机方法)处       在sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)       在sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)       在java.lang.reflect.Constructor.newInstance(Constructor.java:423)       在org.apache.hadoop.net.NetUtils.wrapWithMessage(NetUtils.java:801)       在org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:732)       在org.apache.hadoop.ipc.Client.getRpcResponse(Client.java:1485)       在org.apache.hadoop.ipc.Client.call(Client.java:1427)       在org.apache.hadoop.ipc.Client.call(Client.java:1337)       在org.apache.hadoop.ipc.ProtobufRpcEngine $ Invoker.invoke(ProtobufRpcEngine.java:227)       在org.apache.hadoop.ipc.ProtobufRpcEngine $ Invoker.invoke(ProtobufRpcEngine.java:116)       在com.sun.proxy。$ Proxy10.mkdirs(未知来源)       在org.apache.hadoop.hdfs.protocolPB.ClientNamenodeProtocolTranslatorPB.mkdirs(ClientNamenodeProtocolTranslatorPB.java:574)       在sun.reflect.NativeMethodAccessorImpl.invoke0(本机方法)处       在sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)       在sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)       在java.lang.reflect.Method.invoke(Method.java:498)       在org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMethod(RetryInvocationHandler.java:398)       在org.apache.hadoop.io.retry.RetryInvocationHandler $ Call.invokeMethod(RetryInvocationHandler.java:163)       在org.apache.hadoop.io.retry.RetryInvocationHandler $ Call.invoke(RetryInvocationHandler.java:155)       在org.apache.hadoop.io.retry.RetryInvocationHandler $ Call.invokeOnce(RetryInvocationHandler.java:95)       在org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(RetryInvocationHandler.java:335)       在com.sun.proxy。$ Proxy11.mkdirs(未知来源)       在org.apache.hadoop.hdfs.DFSClient.primitiveMkdir(DFSClient.java:2525)       在org.apache.hadoop.hdfs.DFSClient.mkdirs(DFSClient.java:2500)       在org.apache.hadoop.hdfs.DistributedFileSystem $ 25.doCall(DistributedFileSystem.java:1155)       在org.apache.hadoop.hdfs.DistributedFileSystem $ 25.doCall(DistributedFileSystem.java:1152)       在org.apache.hadoop.fs.FileSystemLinkResolver.resolve(FileSystemLinkResolver.java:81)       在org.apache.hadoop.hdfs.DistributedFileSystem.mkdirsInternal(DistributedFileSystem.java:1152)       在org.apache.hadoop.hdfs.DistributedFileSystem.mkdirs(DistributedFileSystem.java:1144)       在org.apache.hadoop.fs.FileSystem.mkdirs(FileSystem.java:1913)       在org.apache.hadoop.mapreduce.lib.output.FileOutputCommitter.setupJob(FileOutputCommitter.java:343)       在org.apache.hadoop.mapreduce.v2.app.commit.CommitterEventHandler $ EventProcessor.handleJobSetup(CommitterEventHandler.java:254)       在org.apache.hadoop.mapreduce.v2.app.commit.CommitterEventHandler $ EventProcessor.run(CommitterEventHandler.java:234)处       在java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)       在java.util.concurrent.ThreadPoolExecutor $ Worker.run(ThreadPoolExecutor.java:617)       在java.lang.Thread.run(Thread.java:745)

我的hadoop在docker中,并且我已经完成了ip:port映射。

  

DNAT tcp-0.0.0.0/0 192.168.0.28 tcp dpts:1024:65535至:172.17.0.5:1024-65535

为什么连接失败? 我的hadoop是伪分发的。与此有关吗?

0 个答案:

没有答案