diff --git a/WHATS_NEW b/WHATS_NEW index 2b897e89d..6ef9d5ca3 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,6 @@ Version 2.02.98 - ================================= + Disallow RAID1 upconvert if the LV was created with --nosync. Depend on systemd-udev-settle in units generated by activation generator. Fix vgchange -aay to activate proper logical volumes. Properly handle 'resync' of RAID LVs. diff --git a/lib/metadata/raid_manip.c b/lib/metadata/raid_manip.c index 4eced6fbd..131f9d236 100644 --- a/lib/metadata/raid_manip.c +++ b/lib/metadata/raid_manip.c @@ -639,6 +639,18 @@ static int _raid_add_images(struct logical_volume *lv, struct lv_list *lvl; struct lv_segment_area *new_areas; + if (lv->status & LV_NOTSYNCED) { + log_error("Can't add image to out-of-sync RAID LV:" + " use 'lvchange --resync' first."); + return 0; + } + + if (!_raid_in_sync(lv)) { + log_error("Can't add image to RAID LV that" + " is still initializing."); + return 0; + } + dm_list_init(&meta_lvs); /* For image addition */ dm_list_init(&data_lvs); /* For image addition */