From 8b572c4de0243d64769c61b272e8f62a105407ae Mon Sep 17 00:00:00 2001 From: Alexandre Ioffe Date: Mon, 12 Dec 2022 22:20:33 -0800 Subject: [PATCH] EX-6169 lipe: sanity-lipe-find3 reformat to clean lost+found Reformat file system when .lustre/lost+found/ has garbage Test-Parameters: trivial testlist=sanity-lipe-find3 Signed-off-by: Alexandre Ioffe Change-Id: Ib78b06e685aaeabb8356662747285ed7a27dde15 Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/49385 Tested-by: jenkins Tested-by: Maloo Reviewed-by: Jian Yu Reviewed-by: Andreas Dilger --- lustre/tests/sanity-lipe-find3.sh | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lustre/tests/sanity-lipe-find3.sh b/lustre/tests/sanity-lipe-find3.sh index 2009e80..cebfb0e 100644 --- a/lustre/tests/sanity-lipe-find3.sh +++ b/lustre/tests/sanity-lipe-find3.sh @@ -31,8 +31,13 @@ done which jq || skip_env "jq is not installed" build_test_filter -check_and_setup_lustre - +if [ -d $MOUNT/.lustre/lost+found ] && [ "$(ls -A $MOUNT/.lustre/lost+found)" ] +then + echo "Reformat file system" + REFORMAT="yes" cleanup_and_setup_lustre +else + check_and_setup_lustre +fi # Try to support running from the build directory. if [[ "$mds_HOST" == "$HOSTNAME" ]]; then # Fixup GUILE_LOAD_PATH to support running from the build directory. -- 1.8.3.1