mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-02 01:18:26 +03:00
tests: adapt waiting for pvmove start
Previous commit cause the pvmove could actually be started in unexpected order - so make sure, we are not starting new pvmove in same VG until the previous one is started.
This commit is contained in:
parent
7f2939d328
commit
ffead4f333
@ -2025,11 +2025,6 @@ wait_pvmove_lv_ready() {
|
||||
|
||||
test -e LOCAL_LVMPOLLD && die "Waiting for lvmpolld timed out"
|
||||
die "Waiting for pvmove LV to get activated has timed out"
|
||||
|
||||
# TODO: remove, uneedeed ??
|
||||
# Adding settle here, to avoid remove, before processing of 'add' is finished
|
||||
# (masking systemd-udevd issue)
|
||||
#udev_wait 2 || true
|
||||
}
|
||||
|
||||
# Holds device open with sleep which automatically expires after given timeout
|
||||
|
@ -53,10 +53,10 @@ cmd3=(pvmove -i1 $backgroundarg $mode -n $vg1/$lv1 "$dev4" "$dev6")
|
||||
|
||||
if test -z "$backgroundarg" ; then
|
||||
"${cmd1[@]}" &
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove0"
|
||||
"${cmd2[@]}" &
|
||||
"${cmd3[@]}" &
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove0" "$vg-pvmove1" "$vg1-pvmove0"
|
||||
lvs -a $vg $vg1
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove1" "$vg1-pvmove0"
|
||||
else
|
||||
LVM_TEST_TAG="kill_me_$PREFIX" "${cmd1[@]}"
|
||||
LVM_TEST_TAG="kill_me_$PREFIX" "${cmd2[@]}"
|
||||
|
@ -42,13 +42,13 @@ cmd2=(pvmove -i1 $backgroundarg $mode "$dev2" "$dev3")
|
||||
|
||||
if test -z "$backgroundarg" ; then
|
||||
"${cmd1[@]}" &
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove0"
|
||||
"${cmd2[@]}" &
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove0" "$vg-pvmove1"
|
||||
aux wait_pvmove_lv_ready "$vg-pvmove1"
|
||||
else
|
||||
LVM_TEST_TAG="kill_me_$PREFIX" "${cmd1[@]}"
|
||||
LVM_TEST_TAG="kill_me_$PREFIX" "${cmd2[@]}"
|
||||
fi
|
||||
|
||||
# remove specific device
|
||||
pvmove --abort "$dev1"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user