我试图安装hadoop,在格式化name node时遇到了这个错误
Re-format filesystem in Storage Directory root= C:\hadoop\data\namenode; location= null ? (Y or N) Y
2021-01-03 11:30:36,360 INFO namenode.FSImage: Allocated new BlockPoolId: BP-801639091-192.168.218.1-1609655436323
2021-01-03 11:30:36,362 INFO common.Storage: Will remove files: []
2021-01-03 11:30:36,453 WARN namenode.NameNode: Encountered exception during format
ExitCodeException exitCode=-1073741515:
at org.apache.hadoop.util.Shell.runCommand(Shell.java:1008) at org.apache.hadoop.util.Shell.run(Shell.java:901)
at org.apache.hadoop.util.Shell$ShellCommandExecutor.execute(Shell.java:1213)
at org.apache.hadoop.util.Shell.execCommand(Shell.java:1307)
at org.apache.hadoop.util.Shell.execCommand(Shell.java:1289)
at org.apache.hadoop.fs.FileUtil.execCommand(FileUtil.java:1341)
at org.apache.hadoop.fs.FileUtil.execSetPermission(FileUtil.java:1332)
at org.apache.hadoop.fs.FileUtil.setPermission(FileUtil.java:1285)
at org.apache.hadoop.hdfs.server.common.Storage$StorageDirectory.clearDirectory(Storage.java:456)
at org.apache.hadoop.hdfs.server.namenode.NNStorage.format(NNStorage.java:591)
at org.apache.hadoop.hdfs.server.namenode.NNStorage.format(NNStorage.java:613)
at org.apache.hadoop.hdfs.server.namenode.FSImage.format(FSImage.java:188)
at org.apache.hadoop.hdfs.server.namenode.NameNode.format(NameNode.java:1271)
at org.apache.hadoop.hdfs.server.namenode.NameNode.createNameNode(NameNode.java:1713)
at org.apache.hadoop.hdfs.server.namenode.NameNode.main(NameNode.java:1821)
2021-01-03 11:30:36,459 ERROR namenode.NameNode: Failed to start namenode.
我参考了许多不同的文章,但没有结果,我试图使用另一个版本的hadoop,但问题仍然存在,因为我刚刚开始,我不能完全理解这个问题,因此我需要帮助
这些是我的配置
-For core-site.xml
<configuration>
<property>
<name>fs.defaultFS</name>
<value>hdfs://localhost:9000</value>
</property>
</configuration>
- For mapred-site.xml
<configuration>
<property>
<name>mapreduce.framework.name</name>
<value>yarn</value>
</property>
</configuration>
-For yarn-site.xml
<configuration>
<property>
<name>yarn.nodemanager.aux-services</name>
<value>mapreduce_shuffle</value>
</property>
<property>
<name>yarn.nodemanager.auxservices.mapreduce.shuffle.class</name>
<value>org.apache.hadoop.mapred.ShuffleHandler</value>
</property>
</configuration>
-For hdfs-site.xml
<configuration>
<property>
<name>dfs.replication</name>
<value>1</value>
</property>
<property>
<name>dfs.namenode.name.dir</name>
<value>C:\hadoop\data\namenode</value>
</property>
<property>
<name>dfs.datanode.data.dir</name>
<value>C:\hadoop\data\datanode</value>
</property>
</configuration>
请引导我
1条答案
按热度按时间ulmd4ohb1#
将我的bin目录替换为这个bin。
我知道你需要在安装后更换它,但以前的箱子,我取代了我的安装箱不工作。