Whamcloud - gitweb
LU-14489 utils: fix 'lfs find --mdt-count' 66/43866/3
authorAndreas Dilger <adilger@whamcloud.com>
Fri, 28 May 2021 21:15:10 +0000 (15:15 -0600)
committerOleg Drokin <green@whamcloud.com>
Mon, 21 Jun 2021 22:16:16 +0000 (22:16 +0000)
commitbaba1fd07a977a62295482919e9218f877c0535a
treecdf168d189ee943e4034fedcb3de9776f18644d3
parentae1404feefc1572fdafed938a3fc18131d675678
LU-14489 utils: fix 'lfs find --mdt-count'

Running "lfs find --mdt-count" causes the find to exit if there
is no directory striping, rather than continuing to the next item.

If cb_get_dirstripe() receives ENODATA then it should consider
that directory as not having any striping and move on, rather
than returning this error to the caller.

Don't crash in cb_getdirstripe() if it is called with a NULL
directory pointer or no directory is opened.

Test-Parameters: trivial
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: If8dd135a86a6a8911bf804542132b2e7a3ce7057
Reviewed-on: https://review.whamcloud.com/43866
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Lai Siyao <lai.siyao@whamcloud.com>
Reviewed-by: Olaf Faaland-LLNL <faaland1@llnl.gov>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/doc/lfs-find.1
lustre/tests/sanity.sh
lustre/utils/liblustreapi.c