Whamcloud - gitweb
LU-11124 utils: add "lfs getstripe -N" option 80/33280/3
authorAndreas Dilger <adilger@whamcloud.com>
Wed, 3 Oct 2018 22:41:56 +0000 (16:41 -0600)
committerOleg Drokin <green@whamcloud.com>
Mon, 29 Oct 2018 16:01:38 +0000 (16:01 +0000)
commit818340364d51ac9fb97151b0c244c4e2fd477715
tree55d1fc84042691d294136337f9b329cb1121d140
parent9b5dd960ac6910085c34a4c15b82ed7fe1e72065
LU-11124 utils: add "lfs getstripe -N" option

Add an "lfs getstripe -N" option to print the number of mirrors on a
file.  The code for printing the mirror count was already in
liblustreapi.c, but there was no option to request only this value
to be printed.

Move the VERBOSE_* flags into an enum and change the various functions
and structures using these flags to use the enum.  Rename a few of the
constants to be more specific, but add compatibility definitions.

Use "lfs getstripe -N" in sanity-flr and sanity-lfsck for mirror count
instead of parsing the mirror count from the verbose layout.

Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: Iafd111c25e22d94153596f9bd4a16750548cab07
Reviewed-on: https://review.whamcloud.com/33280
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Emoly Liu <emoly@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/include/lustre/lustreapi.h
lustre/tests/sanity-flr.sh
lustre/tests/sanity-lfsck.sh
lustre/utils/lfs.c
lustre/utils/liblustreapi.c