zoukankan      html  css  js  c++  java
  • windows下eclipse远程连接hadoop错误“Exception in thread"main"java.io.IOException: Call to Master.Hadoop/172.20.145.22:9000 failed ”

    在VMware虚拟机下搭建了hadoop集群,ubuntu-12.04,一台master,三台slave。hadoop-0.20.2版本。在 master机器上利用eclipse-3.3连接hadoop并运行mapreduce实例可以成功。但是当在windows下eclipse-3.3 远程连接hadoop,DFS locations可以连接上,但运行mapreduce实例时报错,如下:

    13/07/02 13:37:04 WARN conf.Configuration: DEPRECATED: hadoop-site.xml found in the classpath.
    Usage of hadoop-site.xml is deprecated. Instead use core-site.xml, mapred-site.xml and hdfs-site.xml to override properties of core-default.xml, mapred-default.xml and hdfs-default.xml respectively Exception in thread "main" java.io.IOException: Call to Master.Hadoop/172.20.145.22:9000 failed on local exception: java.io.EOFException at org.apache.hadoop.ipc.Client.wrapException(Client.java:1107) at org.apache.hadoop.ipc.Client.call(Client.java:1075) at org.apache.hadoop.ipc.RPC$Invoker.invoke(RPC.java:225) at $Proxy1.getProtocolVersion(Unknown Source) at org.apache.hadoop.ipc.RPC.getProxy(RPC.java:396) at org.apache.hadoop.ipc.RPC.getProxy(RPC.java:379) at org.apache.hadoop.hdfs.DFSClient.createRPCNamenode(DFSClient.java:119) at org.apache.hadoop.hdfs.DFSClient.<init>(DFSClient.java:238) at org.apache.hadoop.hdfs.DFSClient.<init>(DFSClient.java:203) at org.apache.hadoop.hdfs.DistributedFileSystem.initialize(DistributedFileSystem.java:89) at org.apache.hadoop.fs.FileSystem.createFileSystem(FileSystem.java:1386) at org.apache.hadoop.fs.FileSystem.access$200(FileSystem.java:66) at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:1404) at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:254) at org.apache.hadoop.fs.Path.getFileSystem(Path.java:187) at org.apache.hadoop.mapreduce.lib.input.FileInputFormat.addInputPath(FileInputFormat.java:372) at org.apache.hadoop.examples.WordCount.main(WordCount.java:68) Caused by: java.io.EOFException at java.io.DataInputStream.readInt(Unknown Source) at org.apache.hadoop.ipc.Client$Connection.receiveResponse(Client.java:804) at org.apache.hadoop.ipc.Client$Connection.run(Client.java:749)

    分析原因和解决方案:

    导致这个问题的原因是由于eclipse上面引入的hadoop版本和linux虚拟机上面安装的hadoop版本不一致导致,把两边环境的版本换成一致就可以了。

  • 相关阅读:
    Flutter TextField 文本输入框的基本属性
    Flutter 之网络请求Dio, FormData, 表单网络请求, x-www-form-urlencoded
    操作DataTable数据,修改某列的值
    获取DataTable某一列所有值
    ajax将数据遍历给select的option选项
    Flutter 获取网络数据及渲染列表
    Flutter实现APP版本更新
    Flutter 一些常用库插件
    flutter_screenutil屏幕適配
    前端组件学习
  • 原文地址:https://www.cnblogs.com/longshiyVip/p/4803895.html
Copyright © 2011-2022 走看看