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

Don't remove mirror LV until after other LVs reloaded.

This commit is contained in:
Alasdair Kergon 2003-11-20 16:22:04 +00:00
parent de3cac3d2c
commit 2d8612c8ae

View File

@ -445,14 +445,15 @@ static int _finish_pvmove(struct cmd_context *cmd, struct volume_group *vg,
r = 0;
}
unlock_lvs(cmd, lvs_changed);
if (!lock_vol(cmd, lv_mirr->lvid.s, LCK_LV_DEACTIVATE)) {
log_error("ABORTING: Unable to deactivate temporary logical "
"volume \"%s\"", lv_mirr->name);
r = 0;
}
unlock_lvs(cmd, lvs_changed);
log_verbose("Removing temporary pvmove LV");
if (!lv_remove(vg, lv_mirr)) {
log_error("ABORTING: Removal of temporary pvmove LV failed");
return 0;