Created attachment 422647
A crude bug fix that would prevent the erroneous error message.
Description of problem:
pvmove relies on polldaemon.c:_wait_for_single_lv() to read the percentage complete on the mirror that is used to do the pvmove. However, the mirror goes away sometimes while this program is running, presumably in between init_full_scan_done(0) and locking the volume group. This would appear to be a race condition, so it only happens sometimes.
When the problem occurs, a user gets something like this printed out:
/dev/sde1: Moved: 99.6%
ABORTING: Can't find mirror LV in homedirs for /dev/sde1
This is very confusing, as the user may think that the pvmove operation failed.
Version-Release number of selected component (if applicable):
2.02.54, code appears similar in 2.02.67
How reproducible:
As this is a race condition, it does not always happen. However users have reported it happening with enough frequency to cause alarm as the error message
Steps to reproduce:
assuming /dev/sdb has two equal sized partitions of at least 10G
Setup:
pvcreate /dev/sdb1
pvcreate /dev/sdb2
vgcreate test /dev/sdb1 /dev/sdb2
lvcreate -L 9G -n t1 test /dev/sdb1
Then repeat these in an alternating manner:
pvmove -i1 /dev/sdb1
pvmove -i1 /dev/sdb2
It may take many iterations to reproduce the race, or it may never reproduce it, as other factors may be necessary to make it more likely (such as many more physical volumes).
Actual results:
Expected results:
I would expect that if the pvmove completes successfully, that pvmove would show that fact rather than abort.
Created attachment 422647
A crude bug fix that would prevent the erroneous error message.
Description of problem:
pvmove relies on polldaemon. c:_wait_ for_single_ lv() to read the percentage complete on the mirror that is used to do the pvmove. However, the mirror goes away sometimes while this program is running, presumably in between init_full_ scan_done( 0) and locking the volume group. This would appear to be a race condition, so it only happens sometimes.
When the problem occurs, a user gets something like this printed out:
/dev/sde1: Moved: 99.6%
ABORTING: Can't find mirror LV in homedirs for /dev/sde1
This is very confusing, as the user may think that the pvmove operation failed.
Version-Release number of selected component (if applicable):
2.02.54, code appears similar in 2.02.67
How reproducible:
As this is a race condition, it does not always happen. However users have reported it happening with enough frequency to cause alarm as the error message
Steps to reproduce:
assuming /dev/sdb has two equal sized partitions of at least 10G
Setup:
pvcreate /dev/sdb1
pvcreate /dev/sdb2
vgcreate test /dev/sdb1 /dev/sdb2
lvcreate -L 9G -n t1 test /dev/sdb1
Then repeat these in an alternating manner:
pvmove -i1 /dev/sdb1
pvmove -i1 /dev/sdb2
It may take many iterations to reproduce the race, or it may never reproduce it, as other factors may be necessary to make it more likely (such as many more physical volumes).
Actual results:
Expected results:
I would expect that if the pvmove completes successfully, that pvmove would show that fact rather than abort.
Additional info: