From: Elena Gryaznova Date: Sun, 8 Jan 2023 18:05:19 +0000 (+0100) Subject: LU-16455 tests: recovery-small test_139() fix X-Git-Tag: 2.15.54~71 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=refs%2Fchanges%2F79%2F49579%2F5;p=fs%2Flustre-release.git LU-16455 tests: recovery-small test_139() fix mds device calculated before stop () can not be used after stop() because of a device-mapper device is removed and facet device is restored: stop () -> elif dm_flakey_supported $facet; then if [[ -n ${!failover_host} && ${!failover_host} != ${!host} ]] dm_cleanup_dev $facet -> unexport_dm_dev $facet Without this fix test_139 fails on failover setup: losetup: /dev/mapper/mds1_flakey: failed to set up loop device: No such file or directory To reproduce the failure just run: sh llmountcleanup.sh ONLY=139 sh recovery-small.sh on failover setup where mds1_HOST != mds1failover_HOST Fixes: 4597fa7d88 ("LU-13061 osp: check catlog FID after reading in") Test-Parameters: trivial testlist="recovery-small" failover=true iscsi=1 \ env=ONLY=139,SLOW=yes mdssizegb=10 clientcount=4 osscount=2 mdscount=2 \ mdtcount=2 austeroptions=-R Test-Parameters: trivial testlist="recovery-small" failover=true iscsi=1 \ env=FAILURE_MODE=HARD,ONLY=139,SLOW=yes mdssizegb=10 clientcount=4 \ osscount=2 mdscount=2 mdtcount=2 austeroptions=-R Signed-off-by: Elena Gryaznova Reviewed-by: Vladimir Saveliev Reviewed-by: Alexander Boyko HPE-bug-id: LUS-10912 Change-Id: I67d98f633de4023a4430b55c6b4d308c7f17d988 Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/49579 Tested-by: Maloo Tested-by: jenkins Reviewed-by: Vladimir Saveliev Reviewed-by: Jian Yu Reviewed-by: Oleg Drokin Reviewed-by: Andreas Dilger --- diff --git a/lustre/tests/recovery-small.sh b/lustre/tests/recovery-small.sh index 43d2eeb..bc0c5d1 100755 --- a/lustre/tests/recovery-small.sh +++ b/lustre/tests/recovery-small.sh @@ -2952,13 +2952,12 @@ test_139() { [ $MDS1_VERSION -lt $(version_code 2.13.50) ] && skip "Need MDS version at least 2.13.50" - mdt_dev=$(mdsdevname 1) - stop $SINGLEMDS || error "stop $SINGLEMDS failed" #define OBD_FAIL_OSP_INVALID_LOGID 0x2106 do_facet $SINGLEMDS $LCTL set_param fail_val=0x68 fail_loc=0x80002106 - start $SINGLEMDS $mdt_dev $MDS_MOUNT_OPTS || error "Fail to start MDT" + start $SINGLEMDS $(mdsdevname ${SINGLEMDS//mds/}) $MDS_MOUNT_OPTS || + error "Fail to start $SINGLEMDS" } run_test 139 "corrupted catid won't cause crash"