File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/tools Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 5151import org .apache .hadoop .util .DataChecksum ;
5252import org .apache .hadoop .util .StringUtils ;
5353import org .apache .hadoop .util .Tool ;
54+ import org .apache .hadoop .util .ToolRunner ;
5455
5556/**
5657 * This class implements debug operations on the HDFS command-line.
@@ -458,11 +459,14 @@ private void printUsage() {
458459 if (!command .name .equals ("help" )) {
459460 System .out .println (command .usageText );
460461 }
462+ System .out .println ();
463+ ToolRunner .printGenericCommandUsage (System .out );
461464 }
462465 }
463466
464- public static void main (String [] argsArray ) throws IOException {
467+ public static void main (String [] argsArray ) throws Exception {
465468 DebugAdmin debugAdmin = new DebugAdmin (new Configuration ());
466- System .exit (debugAdmin .run (argsArray ));
469+ int res = ToolRunner .run (debugAdmin , argsArray );
470+ System .exit (res );
467471 }
468472}
You can’t perform that action at this time.
0 commit comments