From b78b4a1536b6d47a37ff7c309857a628a864c957 Mon Sep 17 00:00:00 2001 From: Colin Patrick Mccabe Date: Mon, 12 Jan 2015 12:16:36 -0800 Subject: [PATCH] HDFS-7326. Add documentation for hdfs debug commands (Vijay Bhat via Colin P. McCabe) --- hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt | 3 ++ .../src/site/apt/HDFSCommands.apt.vm | 43 +++++++++++++++++++ 2 files changed, 46 insertions(+) diff --git a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt index 1a5a22bf61c..f83ac654060 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt +++ b/hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt @@ -490,6 +490,9 @@ Release 2.7.0 - UNRELEASED HDFS-7323. Move the get/setStoragePolicy commands out from dfsadmin. (jing9 via yliu) + HDFS-7326: Add documentation for hdfs debug commands (Vijay Bhat via Colin + P. McCabe) + OPTIMIZATIONS HDFS-7454. Reduce memory footprint for AclEntries in NameNode. diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/site/apt/HDFSCommands.apt.vm b/hadoop-hdfs-project/hadoop-hdfs/src/site/apt/HDFSCommands.apt.vm index 281221dab03..4cf31ac68df 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/site/apt/HDFSCommands.apt.vm +++ b/hadoop-hdfs-project/hadoop-hdfs/src/site/apt/HDFSCommands.apt.vm @@ -464,3 +464,46 @@ HDFS Commands Guide | -geteditsize | Prints the number of uncheckpointed transactions on | the NameNode. *----------------------+------------------------------------------------------+ + +* Debug Commands + + Useful commands to help administrators debug HDFS issues, like validating + block files and calling recoverLease. + +** <<>> + + Verify HDFS metadata and block files. If a block file is specified, we + will verify that the checksums in the metadata file match the block + file. + + Usage: <<] [-block ]>>> + +*------------------------+----------------------------------------------------+ +|| COMMAND_OPTION | Description +*------------------------+----------------------------------------------------+ +| -meta | Absolute path for the metadata file on the local file +| | system of the data node. +*------------------------+----------------------------------------------------+ +| -block | Optional parameter to specify the absolute path for +| | the block file on the local file system of the data +| | node. +*------------------------+----------------------------------------------------+ + + + +** <<>> + + Recover the lease on the specified path. The path must reside on an + HDFS filesystem. The default number of retries is 1. + + Usage: <<] [-retries ]>>> + +*-------------------------------+--------------------------------------------+ +|| COMMAND_OPTION || Description +*-------------------------------+---------------------------------------------+ +| [-path ] | HDFS path for which to recover the lease. +*-------------------------------+---------------------------------------------+ +| [-retries ] | Number of times the client will retry calling +| | recoverLease. The default number of retries +| | is 1. +*-------------------------------+---------------------------------------------+