继续昨天问题:今天已经解决,调通了(hadoop 1.0.0)
- 问题
2012-03-13 20:12:57,764 ERROR org.apache.hadoop.hdfs.server.namenode.FSNamesystem: FSNamesystem initialization failed.
原因是没有fomat namenode 执行如下命令
- bin/hadoop namenode -format
在这之前需要检查:是否有hadoop进程没有关闭
- ps -aux|grep "hadoop"
检查是否有hadoop运行
- bin/start-all.sh
运行结果
输入
-
查看NameNode结果
http://IP地址:50070/ 或者http://localhost:50070/
NameNode 'localhost:9000'
| Started: | Wed Mar 14 18:48:41 CST 2012 |
| Version: | 1.0.1-SNAPSHOT, r |
| Compiled: | Wed Dec 28 11:13:26 CST 2011 by somo |
| Upgrades: | There are no upgrades in progress. |
Browse the filesystem
Namenode Logs
Cluster Summary
Safe mode is ON. The ratio of reported blocks 0.0000 has not reached the threshold 0.9990. Safe mode will be turned off automatically.
6 files and directories, 1 blocks = 7 total. Heap Size is 240.69 MB / 888.94 MB (27%)
| Configured Capacity | : | 0 KB |
| DFS Used | : | 0 KB |
| Non DFS Used | : | 0 KB |
| DFS Remaining | : | 0 KB |
| DFS Used% | : | 100 % |
| DFS Remaining% | : | 0 % |
| Live Nodes | : | 0 |
| Dead Nodes | : | 0 |
| Decommissioning Nodes | : | 0 |
| Number of Under-Replicated Blocks | : | 0 |
There are no datanodes in the cluster
NameNode Storage:
| Storage Directory | Type | State |
| /tmp/hadoop-somo/dfs/name | IMAGE_AND_EDITS | Active |
This is Apache Hadoop release 1.0.1-SNAPSHOT
查看JobTracker
上面页面显示,成功,不过集群没有Data Node
本文解决了Hadoop集群搭建过程中的NameNode初始化失败问题。通过格式化NameNode、检查并关闭未结束的Hadoop进程,最终成功启动了Hadoop集群,并验证了NameNode和JobTracker的状态。
1135

被折叠的 条评论
为什么被折叠?



