Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Last revision Both sides next revision | ||
hdfs_fsck [2015/09/09 10:36] steve |
hdfs_fsck [2015/09/09 10:40] steve |
||
---|---|---|---|
Line 26: | Line 26: | ||
0. BP-1693696885-172.17.0.2-1441734712805:blk_1073742259_1435 len=2633979 repl=3 | 0. BP-1693696885-172.17.0.2-1441734712805:blk_1073742259_1435 len=2633979 repl=3 | ||
... | ... | ||
+ | </code> | ||
+ | |||
+ | ** Check the health of a file, display the blocks, and which nodes the file is on ** | ||
+ | |||
+ | <code> | ||
+ | hdfs fsck /user/root/sample.txt -files -blocks -locations | ||
+ | </code> | ||
+ | |||
+ | <code> | ||
+ | ... | ||
+ | 0. BP-1693696885-172.17.0.2-1441734712805:blk_1073742259_1435 len=2633979 repl=3 [172.17.0.2:50010, 172.17.0.3:50010, 172.17.0.4:50010] | ||
+ | ... | ||
+ | </code> | ||
+ | |||
+ | ** Check the health of the entire filesystem ** | ||
+ | |||
+ | This must be run as user ''hdfs'' since ''root'' does not have full permissions. | ||
+ | |||
+ | <code> | ||
+ | hdfs fsck / | ||
</code> | </code> |