[lvm-devel] [PATCH] Handle a failure of all mirror devices but one mirror leg

Takahiro Yasui takahiro.yasui at hds.com
Wed Jul 21 15:57:29 UTC 2010


On 07/19/10 18:09, Takahiro Yasui wrote:
> - With Jon's second patch, we think that we don't have to call
>   remove_mirror_log() in _lv_update_mirrored_log() because will be
>   handled remove_mirror_images() in _lvconvert_mirrors_repaire().

Additional comment on remove_mirror_log().

Calling remove_mirror_log() in _lv_update_mirrored_log() is not good.
The reason is that remove_mirror_log() calls suspend_lv() and resume_lv()
for an original mirror volume which contains the broken mirrored log when
VG metadata is updated in _remove_mirror_images(), but there is a problem
when there is a broken mirror leg.

suspend_lv() and resume_lv() will suspend and resume an original LV with
broken legs. When the original mirror volume is resumed, recovery process
is executed in kernel according to the state of log. This time, mirror volume
is fixed in termes of *log* but not in terms of mirror legs. So I'm afraid the
recovery process will fail. We need to resume an original mirror volume only
after its mirror legs are completely fixed.

When I introduced _lv_update_mirrored_log(), it called remove_mirror_images()
for a mirrored log. This means that suspend and resume are executed only
for a mirrored log but not for original volume.

With this information, I appreciate your review of this patch.
https://www.redhat.com/archives/lvm-devel/2010-July/msg00131.html

Thanks,
Taka




More information about the lvm-devel mailing list