|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.dfs.DFSck
public class DFSck
This class provides rudimentary checking of DFS volumes for errors and sub-optimal conditions.
The tool scans all files and directories, starting from an indicated root path. The following abnormal conditions are detected and handled:
FIXING_NONE
)FIXING_MOVE
). Remaining data blocks are saved as a
block chains, representing longest consecutive series of valid blocks.FIXING_DELETE
)
Nested Class Summary | |
---|---|
static class |
DFSck.Result
Result of checking, plus overall DFS statistics. |
Field Summary | |
---|---|
static int |
FIXING_DELETE
Delete corrupted files. |
static int |
FIXING_MOVE
Move corrupted files to /lost+found . |
static int |
FIXING_NONE
Don't attempt any fixing . |
Constructor Summary | |
---|---|
DFSck(Configuration conf,
int fixing,
boolean showFiles,
boolean showBlocks,
boolean showLocations)
Filesystem checker. |
Method Summary | |
---|---|
DFSck.Result |
fsck(String path)
Check files on DFS, starting from the indicated path. |
static void |
main(String[] args)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int FIXING_NONE
public static final int FIXING_MOVE
public static final int FIXING_DELETE
Constructor Detail |
---|
public DFSck(Configuration conf, int fixing, boolean showFiles, boolean showBlocks, boolean showLocations) throws Exception
conf
- current Configurationfixing
- one of pre-defined valuesshowFiles
- show each file being checkedshowBlocks
- for each file checked show its block informationshowLocations
- for each block in each file show block locations
Exception
Method Detail |
---|
public DFSck.Result fsck(String path) throws Exception
path
- starting point
Exception
public static void main(String[] args) throws Exception
args
-
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |