mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
tests: use aux mdadm wrapper
Wrapper takes care of proper MD device name around its various incarnations.
This commit is contained in:
parent
d7c4fb7743
commit
f5acdc2d79
@ -586,9 +586,6 @@ aux wipefs_a "$dev2"
|
||||
aux wipefs_a "$dev3"
|
||||
aux wipefs_a "$dev4"
|
||||
|
||||
mddev="/dev/md33"
|
||||
not grep $mddev /proc/mdstat || skip
|
||||
|
||||
rm "$DF"
|
||||
touch "$DF"
|
||||
vgcreate $vg1 "$dev1" "$dev2"
|
||||
@ -603,7 +600,9 @@ OPVID2=`pvs "$dev2" --noheading -o uuid | awk '{print $1}'`
|
||||
PVID1=`pvs "$dev1" --noheading -o uuid | tr -d - | awk '{print $1}'`
|
||||
PVID2=`pvs "$dev2" --noheading -o uuid | tr -d - | awk '{print $1}'`
|
||||
|
||||
mdadm --create --metadata=1.0 "$mddev" --level 1 --raid-devices=2 "$dev3" "$dev4"
|
||||
aux mdadm_create --metadata=1.0 --level 1 --raid-devices=2 "$dev3" "$dev4"
|
||||
mddev=$(< MD_DEV)
|
||||
|
||||
wait_md_create "$mddev"
|
||||
|
||||
sed -e "s|DEVNAME=$dev1|DEVNAME=$dev3|" "$ORIG" > tmp1.devices
|
||||
|
@ -363,14 +363,13 @@ wait_md_create() {
|
||||
test -f /proc/mdstat && grep -q raid1 /proc/mdstat || \
|
||||
modprobe raid1 || skip
|
||||
|
||||
mddev="/dev/md33"
|
||||
not grep $mddev /proc/mdstat || skip
|
||||
|
||||
wipe_all
|
||||
rm $DF
|
||||
touch $DF
|
||||
|
||||
mdadm --create --metadata=1.0 "$mddev" --level 1 --chunk=64 --raid-devices=2 "$dev1" "$dev2"
|
||||
aux mdadm_create --metadata=1.0 --level 1 --chunk=64 --raid-devices=2 "$dev1" "$dev2"
|
||||
mddev=$(< MD_DEV)
|
||||
|
||||
wait_md_create "$mddev"
|
||||
vgcreate $vg9 "$mddev"
|
||||
lvmdevices --adddev "$mddev" || true
|
||||
@ -383,7 +382,7 @@ lvcreate -l1 -an -n $lv2 $vg9
|
||||
|
||||
mdadm --stop "$mddev"
|
||||
_clear_online_files
|
||||
mdadm --assemble "$mddev" "$dev1" "$dev2"
|
||||
aux mdadm_assemble "$mddev" "$dev1" "$dev2"
|
||||
|
||||
# this trigger might be redundant because the mdadm --assemble
|
||||
# probably triggers an add uevent
|
||||
|
Loading…
Reference in New Issue
Block a user