gpt4 book ai didi

hadoop - Hadoop:HDFS群集空间不足,即使有可用空间

转载 作者:行者123 更新时间:2023-12-02 21:06:28 25 4
gpt4 key购买 nike

我们有4个datanode HDFS群集...每个数据节点上都有大量可用空间,大约98gb ...但是当我查看datanode信息时..它仅使用大约10gb的空间而已...

Data Node information

我们如何使其全部使用98gb而不耗尽图像中所示的空间

这是磁盘空间配置

Disk space distribution

这是名称节点上的hdfs-site.xml

<property>
<name>dfs.name.dir</name>
<value>/test/hadoop/hadoopinfra/hdfs/namenode</value>
</property>

这是数据节点下的hdfs-site.xml
<property>
<name>dfs.data.dir</name>
<value>/test/hadoop/hadoopinfra/hdfs/datanode</value>
</property>

即使/ test有98GB,并且hdfs配置为使用它,但未使用它

在进行配置更改时我是否缺少任何内容?我们如何确保使用了98GB?

最佳答案

根据this Hortonworks Community Portal link,修改数据节点目录的步骤如下:

  1. Stop the cluster.
  2. Go to the ambari HDFS configuration and edit the datanode directory configuration: Remove /hadoop/hdfs/data and /hadoop/hdfs/data1. Add [new directory location].
  3. Login into each datanode (via SSH) and copy the contents of /data and /data1 into the new directory.
  4. Change the ownership of the new directory and everything under it to “hdfs”.
  5. Start the cluster.


我假设您在技术上已经完成步骤2,因为您已经在原始问题中显示了正确配置的core-site.xml文件。确保已完成其他步骤,并且已停止所有Hadoop服务 。从那里,将所有权更改为运行Hadoop的用户(通常为hdfs,但我曾在root正在运行Hadoop进程的地方工作过),您应该会很好:)

关于hadoop - Hadoop:HDFS群集空间不足,即使有可用空间,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41722980/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com