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

Fix lvconvert mirror change case detection logic.

Fix mirror log detachment so it correctly becomes a standalone LV.
This commit is contained in:
Alasdair Kergon 2006-09-19 19:13:41 +00:00
parent 3ccf241d54
commit 13ba0f9492
3 changed files with 6 additions and 3 deletions

View File

@ -1,5 +1,7 @@
Version 2.02.10 -
==================================
Fix lvconvert mirror change case detection logic.
Fix mirror log detachment so it correctly becomes a standalone LV.
Extend _check_contiguous() to detect single-area LVs.
Include mirror log (untested) in _for_each_pv() processing.
Use MIRROR_LOG_SIZE constant.

View File

@ -161,9 +161,11 @@ int remove_mirror_images(struct lv_segment *mirrored_seg, uint32_t num_mirrors,
remove_log = 1;
}
if (remove_log) {
if (remove_log && mirrored_seg->log_lv) {
log_lv = mirrored_seg->log_lv;
mirrored_seg->log_lv = NULL;
log_lv->status &= ~MIRROR_LOG;
log_lv->status |= VISIBLE_LV;
}
/*

View File

@ -344,8 +344,7 @@ static int lvconvert_mirrors(struct cmd_context * cmd, struct logical_volume * l
lp->mirrors - 1);
return 1;
}
}
if (lp->mirrors > existing_mirrors) {
} else if (lp->mirrors > existing_mirrors) {
/* FIXME Unless anywhere, remove PV of log_lv
* from allocatable_pvs & allocate
* (mirrors - existing_mirrors) new areas