1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

tests: move cache test to separate file

Don't mix plain raid test with  'raid+cache' test.
This commit is contained in:
Zdenek Kabelac 2016-09-09 23:38:47 +02:00
parent b592ea5bbc
commit a4363fbcb5
2 changed files with 43 additions and 11 deletions

View File

@ -0,0 +1,43 @@
#!/bin/sh
# Copyright (C) 2016 Red Hat, Inc. All rights reserved.
#
# This copyrighted material is made available to anyone wishing to use,
# modify, copy, or redistribute it subject to the terms and conditions
# of the GNU General Public License v.2.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
# test activation race for raid's --syncaction check
SKIP_WITH_LVMLOCKD=1
SKIP_WITH_LVMPOLLD=1
# Current support for syncaction in cluster is broken
# might get fixed one day though
# meanwhile skipped
SKIP_WITH_CLVMD=1
. lib/inittest
aux have_cache 1 5 0 || skip
# Proper mismatch count 1.5.2+ upstream, 1.3.5 < x < 1.4.0 in RHEL6
aux have_raid 1 3 5 &&
! aux have_raid 1 4 0 ||
aux have_raid 1 5 2 || skip
aux prepare_vg 3
# Bug 1169495 - RFE: allow raid scrubbing on cache origin raid volumes
# lvcreate RAID1 origin, lvcreate cache-pool, and lvconvert to cache
# then test that the origin can be scrubbed.
lvcreate --type raid1 -m 1 --nosync -l 2 -n $lv1 $vg
lvcreate --type cache-pool -l 1 -n ${lv1}_cachepool $vg
lvconvert --cache -Zy --cachepool $vg/${lv1}_cachepool $vg/$lv1
lvchange --syncaction check $vg/${lv1}_corig
# Check may go too quickly to verify with check of syncaction
vgremove -ff $vg

View File

@ -88,15 +88,4 @@ aux wait_for_sync $vg $lv1
# Retest mistmatch exists
check lv_field $vg/$lv1 raid_mismatch_count "128"
lvremove -ff $vg
# Bug 1169495 - RFE: allow raid scrubbing on cache origin raid volumes
# lvcreate RAID1 origin, lvcreate cache-pool, and lvconvert to cache
# then test that the origin can be scrubbed.
lvcreate --type raid1 -m 1 --nosync -l 2 -n $lv1 $vg
lvcreate --type cache-pool -l 1 -n ${lv1}_cachepool $vg
lvconvert --cache -Zy --cachepool $vg/${lv1}_cachepool $vg/$lv1
lvchange --syncaction check $vg/${lv1}_corig
# Check may go too quickly to verify with check of syncaction
vgremove -ff $vg