Class NameNodeResourceChecker
java.lang.Object
org.apache.hadoop.hdfs.server.namenode.NameNodeResourceChecker
NameNodeResourceChecker provides a method -
hasAvailableDiskSpace - which will return true if and only if
the NameNode has disk space available on all required volumes, and any volume
which is configured to be redundant. Volumes containing file system edits dirs
are added by default, and arbitrary extra volumes may be configured as well.-
Constructor Summary
ConstructorsConstructorDescriptionNameNodeResourceChecker(org.apache.hadoop.conf.Configuration conf) Create a NameNodeResourceChecker, which will check the edits dirs and any additional dirs to check set inconf. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturn true if disk space is available on at least one of the configured redundant volumes, and all of the configured required volumes.
-
Constructor Details
-
NameNodeResourceChecker
Create a NameNodeResourceChecker, which will check the edits dirs and any additional dirs to check set inconf.- Throws:
IOException
-
-
Method Details
-
hasAvailableDiskSpace
public boolean hasAvailableDiskSpace()Return true if disk space is available on at least one of the configured redundant volumes, and all of the configured required volumes.- Returns:
- True if the configured amount of disk space is available on at least one redundant volume and all of the required volumes, false otherwise.
-