diff --git a/WHATS_NEW b/WHATS_NEW index a5eef634f..a9b3a084c 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,5 +1,6 @@ Version 2.02.174 - ================================= + Add synchronization points with udev during reshape of raid LVs. Version 2.02.173 - 20th July 2017 ================================= diff --git a/lib/metadata/raid_manip.c b/lib/metadata/raid_manip.c index b90d6f414..043292849 100644 --- a/lib/metadata/raid_manip.c +++ b/lib/metadata/raid_manip.c @@ -3853,6 +3853,12 @@ static int _eliminate_extracted_lvs_optional_write_vg(struct volume_group *vg, struct dm_list *removal_lvs, int vg_write_requested) { + if (!sync_local_dev_names(vg->cmd)) { + log_error("Failed to sync local devices after removing %u LVs in VG %s.", + dm_list_size(removal_lvs), vg->name); + return 0; + } + if (!removal_lvs || dm_list_empty(removal_lvs)) return 1; @@ -3868,6 +3874,13 @@ static int _eliminate_extracted_lvs_optional_write_vg(struct volume_group *vg, backup(vg); } + /* Wait for events following any deactivation. */ + if (!sync_local_dev_names(vg->cmd)) { + log_error("Failed to sync local devices after removing %u LVs in VG %s.", + dm_list_size(removal_lvs), vg->name); + return 0; + } + return 1; }