- 我正在尝试使用这个 page 为 Hadoop 设置我的 Eclipse
- 我正在使用来自 here 的 hadoop eclipse 插件 jar
- 我的 core-site.xml 看起来有以下内容:
<property> <name>fs.default.name</name> <value>hdfs://localhost:54310</value> <description>The name of the default file system. A URI whose scheme and authority determine the FileSystem implementation. The uri's scheme determines the config property (fs.SCHEME.impl) naming the FileSystem implementation class. The uri's authority is used to determine the host, port, etc. for a filesystem.</description> </property> </configuration>
- 我的 mapred-site.xml 有以下内容
<property> <name>mapred.job.tracker</name> <value>localhost:54311</value> <description>The host and port that the MapReduce job tracker runs at. If "local", then jobs are run in-process as a single map and reduce task. </description> </property>
我在 Eclipse 中的 mapreduce 透视图下设置 hadoop 位置为
Location Name: local Map Reduce Master
- Host: localhost
- port: 54310
DFS Master
- Host: localhost
- port: 54311
当我尝试连接时出现错误提示:
Error: Call to localhost/127.0.0.1:54311 failed on local exception: java.io.EOFException
- 有人可以帮我解决这个问题吗?
谢谢
最佳答案
我没有遇到太大问题。谷歌搜索会给你https://issues.apache.org/jira/browse/MAPREDUCE-1280 在你的eclipse中使用jar文件
$ cat mapred-site.xml
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="configuration.xsl"?>
<!-- Put site-specific property overrides in this file. -->
<configuration>
<property>
<name>mapred.job.tracker</name>
<value>localhost:8021</value>
</property>
</configuration>
我将 master 设置为 8021,将 DFS master 设置为 8020。
我认为你犯了和我一样的错误。在您的 eclipse 配置中交换您的端口号,它应该可以工作
关于java - Eclipse Hadoop 插件在尝试连接时显示 "java.io.EOFException",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/9136859/