2014-06-06 99 views
1

我今天早上有Hadoop 2.4(請參閱我以前的2個問題)。現在我刪除它,並安裝2.2,因爲我有問題與2.4,也因爲我認爲2.2是最新的穩定版本。現在,我也跟着教程這裏:hadoop 2.2 - datanode不啓動

http://codesfusion.blogspot.com/2013/10/setup-hadoop-2x-220-on-ubuntu.html?m=1

我敢肯定我做的一切都是正確的,但我又面臨着類似的問題。

當我運行jps時,顯然數據節點沒有啓動。

我又在做什麼錯了?

任何幫助將不勝感激。

[email protected]:~$ start-dfs.sh 
14/06/06 18:12:45 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable 
Incorrect configuration: namenode address dfs.namenode.servicerpc-address or dfs.namenode.rpc-address is not configured. 
Starting namenodes on [] 
localhost: starting namenode, logging to /usr/local/hadoop/logs/hadoop-hduser-namenode-test02.out 
localhost: starting datanode, logging to /usr/local/hadoop/logs/hadoop-hduser-datanode-test02.out 
localhost: Java HotSpot(TM) 64-Bit Server VM warning: You have loaded library /usr/local/hadoop/lib/native/libhadoop.so.1.0.0 which might have disabled stack guard. The VM will try to fix the stack guard now. 
localhost: It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'. 
Starting secondary namenodes [0.0.0.0] 
0.0.0.0: starting secondarynamenode, logging to /usr/local/hadoop/logs/hadoop-hduser-secondarynamenode-test02.out 
0.0.0.0: Java HotSpot(TM) 64-Bit Server VM warning: You have loaded library /usr/local/hadoop/lib/native/libhadoop.so.1.0.0 which might have disabled stack guard. The VM will try to fix the stack guard now. 
0.0.0.0: It's highly recommended that you fix the library with 'execstack -c <libfile>', or link it with '-z noexecstack'. 
14/06/06 18:13:01 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable 
[email protected]:~$ jps 
2201 Jps 
[email protected]:~$ jps 
2213 Jps 
[email protected]:~$ start-yarn 
start-yarn: command not found 
[email protected]:~$ start-yarn.sh 
starting yarn daemons 
starting resourcemanager, logging to /usr/local/hadoop/logs/yarn-hduser-resourcemanager-test02.out 
localhost: starting nodemanager, logging to /usr/local/hadoop/logs/yarn-hduser-nodemanager-test02.out 
[email protected]:~$ jps 
2498 NodeManager 
2264 ResourceManager 
2766 Jps 
[email protected]:~$ jps 
2784 Jps 
2498 NodeManager 
2264 ResourceManager 
[email protected]:~$ jps 
2498 NodeManager 
2264 ResourceManager 
2796 Jps 
[email protected]:~$ 

回答

1

我的問題是我從字面上理解了這些教程。

粘貼以下HDFS <configuration>之間
fs.default.name
://本地主機:9000

我懷疑這是錯誤的,而這樣做,但我還是做到了。
由於core-site.xml文件採用XML格式,因此看起來不正確。
所以實際上,它需要看起來像這樣。

<property> 
<name>fs.default.name</name> 
<value>hdfs://localhost:9000</value> 
</property> 

改變它到這個固定我的問題。

0

我有類似的問題DataNode沒有啓動。我所做的是重新設置namenode的格式,然後重新啓動集羣。然後,運行jps確認數據節點已啓動。

這可能是由於將HDFS目錄放置在您的「home」目錄(在Linux機器上)引起的,因爲啓動和關閉操作系統會影響這些文件夾(不完全確定如何,但爲了防止此問題出現將來,將HDFS目錄移出主目錄)。

請讓我知道這是否工作。

+0

HDFS文件夾不在我的主目錄中。我以某種方式解決了這個問題(不太清楚如何進行2次更改),但現在我遇到了另一個問題:Web監視顯示0個活動節點。我提交了一個任務,但沒有人正在處理它,看來。 –

+0

安裝這個Hadoop怪獸並不容易,即使最簡單的配置充滿驚喜,看起來...... –

+0

所以現在... NodeManager沒有啓動!大! –

相關問題