mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-22 17:35:59 +03:00
Adjusted mirror region size only for mirrors and raids
Update region_size only for mirror and raid targets. This fixes warning messages when vg is using small extent size like 1KiB and no mirror/raid is created, but the user still got the message: $> vgcreate -s 1K vg <pvs> $> lvcreate -L10K vg Using reduced mirror region size of 4 sectors
This commit is contained in:
parent
4c1d56cdcf
commit
986a6d9d85
@ -1,5 +1,6 @@
|
||||
Version 2.02.89 -
|
||||
==================================
|
||||
Adjusted mirror region size only for mirrors and raids.
|
||||
Reorder prompt conditions for removal of active volumes.
|
||||
Avoid 'mda inconsistency' by properly registering UNLABELLED_PV flag (2.02.86).
|
||||
Fix --enable-static_link unless using --enable-dmeventd / --enable-udev_sync.
|
||||
|
@ -4197,6 +4197,10 @@ static struct logical_volume *_lv_create_an_lv(struct volume_group *vg, struct l
|
||||
lp->segtype->name);
|
||||
status |= LV_NOTSYNCED;
|
||||
}
|
||||
|
||||
lp->region_size = adjusted_mirror_region_size(vg->extent_size,
|
||||
lp->extents,
|
||||
lp->region_size);
|
||||
}
|
||||
|
||||
if (!(lv = lv_create_empty(new_lv_name ? : "lvol%d", NULL,
|
||||
@ -4218,10 +4222,6 @@ static struct logical_volume *_lv_create_an_lv(struct volume_group *vg, struct l
|
||||
|
||||
dm_list_splice(&lv->tags, &lp->tags);
|
||||
|
||||
lp->region_size = adjusted_mirror_region_size(vg->extent_size,
|
||||
lp->extents,
|
||||
lp->region_size);
|
||||
|
||||
if (!lv_extend(lv, lp->segtype,
|
||||
lp->stripes, lp->stripe_size,
|
||||
lp->mirrors,
|
||||
|
Loading…
Reference in New Issue
Block a user