name节点和datanode没有启动

dced5bon  于 2021-06-02  发布在  Hadoop
关注(0)|答案(2)|浏览(273)

我在ubuntu中安装了hadoop,并为namenode和data node创建了dir。但是我不能看到namnode和data node没有运行。

hduser@sanjeebpanda:/usr/local/hadoop/etc/hadoop$ jps
9445 Jps
5311 JobHistoryServer
hduser@sanjeebpanda:/usr/local/hadoop/etc/hadoop$ start-all.sh
This script is Deprecated. Instead use start-dfs.sh and start-yarn.sh
14/11/09 21:14:34 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-2.4.0/logs/hadoop-hduser-namenode-sanjeebpanda.out
localhost: starting datanode, logging to /usr/local/hadoop-2.4.0/logs/hadoop-hduser-datanode-sanjeebpanda.out
Starting secondary namenodes [0.0.0.0]
0.0.0.0: starting secondarynamenode, logging to /usr/local/hadoop-2.4.0/logs/hadoop-hduser-secondarynamenode-sanjeebpanda.out
14/11/09 21:14:52 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
starting yarn daemons
starting resourcemanager, logging to /usr/local/hadoop/logs/yarn-hduser-resourcemanager-sanjeebpanda.out
localhost: starting nodemanager, logging to /usr/local/hadoop-2.4.0/logs/yarn-hduser-nodemanager-sanjeebpanda.out
hduser@sanjeebpanda:/usr/local/hadoop/etc/hadoop$ jps

**10134 NodeManager

10007 ResourceManager
10436 Jps
5311 JobHistoryServer**

但是我可以看到两个目录都被创建了。

hduser@sanjeebpanda:/usr/local/hadoop/yarn_data/hdfs$ ls -ltr
total 8
drwxr-xr-x 3 hduser hadoop 4096 Nov  9 21:13 namenode
drwx------ 2 hduser hadoop 4096 Nov  9 21:14 datanode
hduser@sanjeebpanda:/usr/local/hadoop/yarn_data/hdfs$
pbwdgjma

pbwdgjma1#

//关于列表文件
您正在使用 ls ,它列出本地目录中的文件
你必须使用 hadoop fs -ls 在hdfs中列出文件

cclgggtu

cclgggtu2#

按照这个链接,你的问题一定会解决
http://codesfusion.blogspot.in/2013/10/setup-hadoop-2x-220-on-ubuntu.html

相关问题