多卷&使用 Hadoop 限制磁盘使用

发布于 2024-12-01 02:10:34 字数 530 浏览 3 评论 0原文

我正在使用 Hadoop 来处理大量数据。我设置了一个hadoop节点来使用多个卷:其中一个卷是具有10To磁盘的NAS,另一个是存储容量为400 GB的服务器本地磁盘。
问题是,如果我理解的话,数据节点将尝试在每个卷中放置等量的数据。因此,当我在大量数据上运行作业时,400 GB 的磁盘很快就满了,而 10 To 磁盘则有足够的剩余空间。然后我的 Map-Reduce 程序由 Hive 冻结,因为我的集群打开了安全模式...
我尝试设置限制数据节点磁盘使用的属性,但它什么也没做:我仍然有同样的问题。 希望有人能帮助我。

看来我的 mapreduce 程序打开了安全模式,因为:

The ratio of reported blocks 0.0000 has not reached the threshold 0.9990.

我在 namenode Web 界面上看到了该错误。我想使用属性 dfs.safemode.threshold.pct 禁用此选项,但我不知道这是否是解决该问题的好方法?

I am using Hadoop to processing on large set of data. I set up a hadoop node to use multiple volumes : one of these volume is a NAS with 10To disk, and the other one is the local disk from server with a storage capacity of 400 GB.
The problem is, if I understood, that data-nodes will attempt to place equal amount of data in each volumes. Thus when I run a job on a large set of data the disk with 400 GB is quickly full, while the 10 To disk got enough space remained. Then my map-reduce program produce by Hive freeze because my cluster turn on the safe mode...
I tried to set the property for limit Data node's disk usage, but it does nothing : I have still the same problem.
Hope that someone could help me.

Well it seems that my mapreduce program turn on safe mode because :

The ratio of reported blocks 0.0000 has not reached the threshold 0.9990.

I saw that error on the namenode web interface. I want to disable this option with the property dfs.safemode.threshold.pct but I do not know if it is a good way to solve it?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

女中豪杰 2024-12-08 02:10:34

我认为您可以向 dfs.datanode.fsdataset.volume.choosing.policy 寻求帮助。

<property><name>dfs.datanode.fsdataset.volume.choosing.policy</name><value>org.apache.hadoop.hdfs.server.datanode.fsdataset.AvailableSpaceVolumeChoosingPolicy</value>

I think you can turn to dfs.datanode.fsdataset.volume.choosing.policy for help.

<property><name>dfs.datanode.fsdataset.volume.choosing.policy</name><value>org.apache.hadoop.hdfs.server.datanode.fsdataset.AvailableSpaceVolumeChoosingPolicy</value>

微暖i 2024-12-08 02:10:34

使用 $HADOOP_HOME/conf/hdfs-site.xml 中的 dfs.datanode.du.reserved 配置设置来限制磁盘使用。

参考

<property> 
    <name>dfs.datanode.du.reserved</name> 
    <!-- cluster variant --> 
    <value>182400</value> 
    <description>Reserved space in bytes per volume. Always leave this much space free for non dfs use. 
  </description> 
  </property> 

Use the dfs.datanode.du.reserved configuration setting in $HADOOP_HOME/conf/hdfs-site.xml for limiting disk usage.

Reference

<property> 
    <name>dfs.datanode.du.reserved</name> 
    <!-- cluster variant --> 
    <value>182400</value> 
    <description>Reserved space in bytes per volume. Always leave this much space free for non dfs use. 
  </description> 
  </property> 
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文