From 11f750e6a77b905b20541f9ec510b1875ad91357 Mon Sep 17 00:00:00 2001 From: Ayush Saxena Date: Thu, 8 Aug 2019 00:49:58 +0530 Subject: [PATCH] HDFS-14616. Add the warn log when the volume available space isn't enough. Contributed by liying. --- .../datanode/fsdataset/RoundRobinVolumeChoosingPolicy.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/RoundRobinVolumeChoosingPolicy.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/RoundRobinVolumeChoosingPolicy.java index 2d924c0236..0f23e47096 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/RoundRobinVolumeChoosingPolicy.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/fsdataset/RoundRobinVolumeChoosingPolicy.java @@ -96,6 +96,10 @@ public class RoundRobinVolumeChoosingPolicy throw new DiskOutOfSpaceException("Out of space: " + "The volume with the most available space (=" + maxAvailable + " B) is less than the block size (=" + blockSize + " B)."); + } else { + LOG.warn("The volume[{}] with the available space (={} B) is " + + "less than the block size (={} B).", volume.getBaseURI(), + availableVolumeSize, blockSize); } } }