sumitagrawl commented on code in PR #9973:
URL: https://github.com/apache/ozone/pull/9973#discussion_r3000136492


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/utils/DiskCheckUtil.java:
##########
@@ -173,9 +182,19 @@ public boolean checkReadWrite(File storageDir,
             "for volume check.", testFile.getAbsolutePath()), notFoundEx);
         return false;
       } catch (IOException ioEx) {
+        String ioem = ioEx.getMessage();
+        String causeMsg = ioEx.getCause() != null ? 
ioEx.getCause().getMessage() : null;
+        causeMsg = causeMsg != null ? causeMsg : "";
+        if ((ioem != null && ioem.contains(TOO_MANY_OPEN_FILES)) || 
causeMsg.contains(TOO_MANY_OPEN_FILES)) {
+          LOG.warn("Could not read file {} for volume check.", 
testFile.getAbsolutePath(), ioEx);

Review Comment:
   Do we need any specific notification? as this will make read operation also 
failure.



##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/utils/DiskCheckUtil.java:
##########
@@ -42,6 +42,7 @@
  * where the disk is mounted.
  */
 public final class DiskCheckUtil {
+  public static final String TOO_MANY_OPEN_FILES = "Too many open files";

Review Comment:
   message used to check the failure is **OS** dependent. We need check if 
message is same in all supported OS variant or not, docker, mac



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to