首页 > 代码库 > There are 0 datanode(s) running and no node(s) are excluded in this operation.

There are 0 datanode(s) running and no node(s) are excluded in this operation.

向hadoop导入文件,报错

....

There are 0 datanode(s) running and no node(s) are excluded in this operation.

....

查看配置 

$hadoop_home/hadoop/etc/hdfs-site.xml

<property>
<name>dfs.namenode.name.dir</name>
<value>file:/home/sparkuser/myspark/hadoop/hdfs/name</value>
</property>
<property>

对应目录下生成in_use.lock文件

解决

删除目录下的 current 

There are 0 datanode(s) running and no node(s) are excluded in this operation.