0

我正在尝试创建一个新的 DFSLocation 但我无法连接

下面是错误信息。请有人建议我。

“无法连接到 Map/Reduce 位置:localhost 调用 localhost/127.0.0.1:50020 连接异常失败:java.net.ConnectException:连接被拒绝:没有更多信息”

4

1 回答 1

-1

嗨,这里的朋友 Rahul Tyagi,我遇到了同样的问题。

$ vim /usr/local/hadoop/etc/hadoop/core-site.xml

打开终端并粘贴给定的地址。属性文件夹将打开,然后添加:

<property>
    <name>hadoop.tmp.dir</name>
    <value>/app/hadoop/tmp</value>
    <description>A base for other temporary directories.</description>
</property>

<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>

现在第二步:

$ vim /usr/local/hadoop/etc/hadoop/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>

就这样。

于 2016-07-09T12:08:45.277 回答