From: Alexander Boyko Date: Fri, 16 Dec 2016 06:59:22 +0000 (+0300) Subject: LU-8947 test: fix getting OST name at sanity test_253 X-Git-Tag: 2.9.54~49 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=9d13d286c72cb67617a8159faf515efd0f7a9aa8 LU-8947 test: fix getting OST name at sanity test_253 The test gets OST name the wrong way. And if system has more than ten OSTs, the test fail. This patch resolves the issue. Signed-off-by: Alexander Boyko Seagate-bug-id: MRP-3330 Test-Parameters: trivial Change-Id: Ic6080f725c6e693f6cca49d9aebf06c6add4610b Reviewed-on: https://review.whamcloud.com/24387 Reviewed-by: Andreas Dilger Tested-by: Jenkins Tested-by: Maloo Reviewed-by: James Nunez --- diff --git a/lustre/tests/sanity.sh b/lustre/tests/sanity.sh index 0bcbeba..c24e419 100755 --- a/lustre/tests/sanity.sh +++ b/lustre/tests/sanity.sh @@ -14072,8 +14072,8 @@ test_253() { remote_mds_nodsh && skip "remote MDS with nodsh" && return remote_mgs_nodsh && skip "remote MGS with nodsh" && return - local ost_name=$($LFS osts | grep ${ostidx}": " | \ - awk '{print $2}' | sed -e 's/_UUID$//') + local ost_name=$($LFS osts | + sed -n 's/^'$ostidx': \(.*\)_UUID .*/\1/p') # on the mdt's osc local mdtosc_proc1=$(get_mdtosc_proc_path $SINGLEMDS $ost_name) do_facet $SINGLEMDS $LCTL get_param -n \