Hadoop作业跟踪器只能从本地主机访问 [英] Hadoop job tracker only accessible from localhost

查看:98
本文介绍了Hadoop作业跟踪器只能从本地主机访问的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在设置Hadoop(0.20.2)。对于初学者来说,我只是希望它能够在单台机器上运行 - 我可能需要某个集群,但当我到达时,我会担心这一点。我知道我的客户端代码可以连接到作业跟踪器并启动作业,但有一个问题:作业跟踪器只能从运行它的同一台机器访问。我实际上用nmap进行了端口扫描,它显示了从Hadoop机器扫描时打开的端口9001,并在从其他地方扫描时关闭。



我在三机器(一台Mac,一台Ubuntu和一台运行在VirtualBox中的Ubuntu VM),这是一样的。他们都没有设置任何防火墙,所以我很确定这是一个Hadoop问题。任何建议?

解决方案

在你的hadoop配置文件中, fs.default.name mapred.job.tracker 引用localhost?

如果是这样,那么Hadoop将仅在回环接口上监听端口9000和9001,而其他主机无法访问该端口。确保 fs.default.name mapred.job.tracker 引用您计算机可从外部访问的主机名。


I'm setting up Hadoop (0.20.2). For starters, I just want it to run on a single machine - I'll probably need a cluster at some point, but I'll worry about that when I get there. I got it to the point where my client code can connect to the job tracker and start jobs, but there's one problem: the job tracker is only accessible from the same machine that it's running on. I actually did a port scan with nmap, and it shows port 9001 open when scanning from the Hadoop machine, and closed when it's from somewhere else.

I tried this on three machines (one Mac, one Ubuntu, and an Ubuntu VM running in VirtualBox), it's the same. None of them have any firewalls set up, so I'm pretty sure it's a Hadoop problem. Any suggestions?

解决方案

In your hadoop configuration files, does fs.default.name and mapred.job.tracker refer to localhost?

If so, then Hadoop will only listen to port 9000 and 9001 on the loopback interface, which is inaccessible from any other host. Make sure fs.default.name and mapred.job.tracker refer to your machine's externally accessible host name.

这篇关于Hadoop作业跟踪器只能从本地主机访问的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆