@LimitedPrivate({"HDFS","MapReduce"})
@Evolving
public class DF
extends Shell
Shell.CommandExecutor, Shell.ExitCodeException, Shell.OSType, Shell.ShellCommandExecutorENV_DEBUG_OPTS, ENV_HADOOP_HOME, ENV_HADOOP_OPTS, ENV_MAPR_JMX_OPTS, ENV_NAME_REGEX, FREEBSD, inheritParentEnv, isSetsidAvailable, LINK_COMMAND, LINUX, LOG, MAC, osType, OTHER, PPC_64, READ_LINK_COMMAND, SET_GROUP_COMMAND, SET_OWNER_COMMAND, SET_PERMISSION_COMMAND, SOLARIS, SYSPROP_HADOOP_HOME_DIR, timeOutInterval, TOKEN_SEPARATOR_REGEX, USER_NAME_COMMAND, WINDOWS, WINDOWS_MAX_SHELL_LENGHT, WINDOWS_MAX_SHELL_LENGTH, WindowsProcessLaunchLock, WINUTILS| Constructor | Description |
|---|---|
DF(java.io.File path,
long dfInterval) |
|
DF(java.io.File path,
Configuration conf) |
| Modifier and Type | Method | Description |
|---|---|---|
long |
getAvailable() |
|
long |
getCapacity() |
|
java.lang.String |
getDirPath() |
|
protected java.lang.String[] |
getExecString() |
return an array containing the command name and its parameters.
|
java.lang.String |
getFilesystem() |
|
java.lang.String |
getMount() |
|
int |
getPercentUsed() |
|
long |
getUsed() |
|
static void |
main(java.lang.String[] args) |
|
protected void |
parseExecResult(java.io.BufferedReader lines) |
Parse the execution result.
|
protected void |
parseOutput() |
|
java.lang.String |
toString() |
appendScriptExtension, appendScriptExtension, bashQuote, checkIsBashSupported, checkUserExists, checkWindowsCommandLineLength, destroyAllShellProcesses, execCommand, execCommand, execCommand, getAllShells, getCheckProcessIsAliveCommand, getEnvironment, getEnvironmentVariableRegex, getExitCode, getGetPermissionCommand, getGroupsCommand, getGroupsForUserCommand, getGroupsIDForUserCommand, getHadoopHome, getMemlockLimit, getProcess, getQualifiedBin, getQualifiedBinPath, getReadlinkCommand, getRunScriptCommand, getSetOwnerCommand, getSetPermissionCommand, getSetPermissionCommand, getSignalKillCommand, getSymlinkCommand, getUsersForNetgroupCommand, getWaitingThread, getWinUtilsFile, getWinUtilsPath, hasWinutilsPath, isJava7OrAbove, isJavaVersionAtLeast, isTimedOut, run, setEnvironment, setWorkingDirectorypublic DF(java.io.File path,
Configuration conf)
throws java.io.IOException
java.io.IOExceptionpublic DF(java.io.File path,
long dfInterval)
throws java.io.IOException
java.io.IOExceptionpublic java.lang.String getDirPath()
public java.lang.String getFilesystem()
throws java.io.IOException
java.io.IOException - raised on errors performing I/O.public long getCapacity()
public long getUsed()
public long getAvailable()
public int getPercentUsed()
public java.lang.String getMount()
throws java.io.IOException
java.io.IOException - raised on errors performing I/O.public java.lang.String toString()
toString in class java.lang.Objectprotected java.lang.String[] getExecString()
ShellgetExecString in class Shellprotected void parseExecResult(java.io.BufferedReader lines)
throws java.io.IOException
ShellparseExecResult in class Shelllines - lines.java.io.IOException - raised on errors performing I/O.@VisibleForTesting
protected void parseOutput()
throws java.io.IOException
java.io.IOExceptionpublic static void main(java.lang.String[] args)
throws java.lang.Exception
java.lang.ExceptionCopyright © 2008–2025 Apache Software Foundation. All rights reserved.