From: Minh Diep Date: Fri, 5 Dec 2014 20:03:25 +0000 (-0800) Subject: LU-4864 tests: cleanup shared files in sanity-hsm X-Git-Tag: 2.5.3.90~10 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=refs%2Fchanges%2F62%2F12962%2F2;p=fs%2Flustre-release.git LU-4864 tests: cleanup shared files in sanity-hsm Test creates shared files need to remove them completely This patch is back-ported from the following one: Lustre-commit: 9c096264c14c70e88e38ee1de9b05b494491fd28 Lustre-change: http://review.whamcloud.com/10073 Signed-off-by: Minh Diep Change-Id: I94e5de73f867f87a6e63b2ea213637a5d0cad488 Reviewed-on: http://review.whamcloud.com/12962 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: James Nunez Reviewed-by: Bob Glossman Reviewed-by: Oleg Drokin --- diff --git a/lustre/tests/sanity-hsm.sh b/lustre/tests/sanity-hsm.sh index 935f8aa..26161ac 100755 --- a/lustre/tests/sanity-hsm.sh +++ b/lustre/tests/sanity-hsm.sh @@ -263,11 +263,13 @@ get_copytool_event_log() { copytool_cleanup() { trap - EXIT - local agents=${1:-$(facet_active_host $SINGLEAGT)} + local facet=$SINGLEAGT + local agents=${1:-$(facet_active_host $facet)} local mdtno local idx local oldstate local mdt_hsmctrl + local hsm_root=$(copytool_device $facet) do_nodesv $agents "pkill -INT -x $HSMTOOL_BASE" || return 0 sleep 1 @@ -292,6 +294,7 @@ copytool_cleanup() { "$oldstate" 20 || error "mds${mdtno} cdt state is not $oldstate" done + do_facet $facet "rm -rf $hsm_root" } copytool_suspend() {