我有一個CDH4.3所有功能於一身的VM啓動並運行,我試圖遠程安裝一個hadoop客戶端。我注意到,在不更改任何默認設置的情況下,我的hadoop羣集正在偵聽127.0.0.1:8020
。fs.defaultFS只聽本地端口8020
[[email protected] ~]$ netstat -lent | grep 8020
tcp 0 0 127.0.0.1:8020 0.0.0.0:* LISTEN 492 100202
[[email protected] ~]$ telnet ${all-in-one vm external IP} 8020
Trying ${all-in-one vm external IP}...
telnet: connect to address ${all-in-one vm external IP} Connection refused
[[email protected] ~]$ telnet 127.0.0.1 8020
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'
我的遠程機具有指向${all-in-one vm external IP}
所有配置(core-site.xml, hdfs-site.xml
)。當我運行從遠程客戶端的東西,我得到這個:
└ $ ./bin/hdfs --config /home/${myself}/hadoop-2.0.0-cdh4.3.0/etc/hadoop dfs -ls
13/10/27 05:27:53 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
ls: Call From ubuntu/127.0.1.1 to ${all-in-one vm external IP}:8020 failed on connection exception: java.net.ConnectException: Connection refused; For more details see: http://wiki.apache.org/hadoop/ConnectionRefused
我改變了我的hadoop的所有功能於一身的VM: core-site.xml and hdfs-site.xml
/etc/hadoop/conf
受到來自:localhost.localdomain
- >${all-in-one vm external IP},
但在重新啓動HDFS之後,它仍然監聽本地主機8020.任何想法?我如何在8020而不是本地主機上監聽$ {external IP}。
嗯......這看起來很舊,但我看到使用hadoop 2.7.3的相同問題。更改端口core-site.xml不會執行任何操作,如果值不是8020,則會導致連接從'hdfs:// myserver /'中被拒絕。 – monkut