1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-02 01:18:26 +03:00

Abort if automatic metadata correction fails when reading VG to update it.

This commit is contained in:
Alasdair Kergon 2009-06-26 09:19:13 +00:00
parent 024e2cd0e6
commit 2f5a1df42c
5 changed files with 5 additions and 5 deletions

View File

@ -1,6 +1,6 @@
Version 2.02.48 -
===============================
Abort operation if automatic metadata correction in lvconvert fails.
Abort if automatic metadata correction fails when reading VG to update it.
Explicitly request fallback to default major number in device mapper.
Ignore suspended devices during repair.
Call vgreduce --removemissing automatically to clean up bad PVs in dmeventd.

View File

@ -996,7 +996,7 @@ int lvcreate(struct cmd_context *cmd, int argc, char **argv)
log_verbose("Finding volume group \"%s\"", lp.vg_name);
if (!(vg = vg_lock_and_read(cmd, lp.vg_name, NULL, LCK_VG_WRITE,
CLUSTERED | EXPORTED_VG | LVM_WRITE,
CORRECT_INCONSISTENT)))
CORRECT_INCONSISTENT | FAIL_INCONSISTENT)))
return ECMD_FAILED;
if (!_lvcreate(cmd, vg, &lp))

View File

@ -104,7 +104,7 @@ int lvrename(struct cmd_context *cmd, int argc, char **argv)
log_verbose("Checking for existing volume group \"%s\"", vg_name);
if (!(vg = vg_lock_and_read(cmd, vg_name, NULL, LCK_VG_WRITE,
CLUSTERED | EXPORTED_VG | LVM_WRITE,
CORRECT_INCONSISTENT)))
CORRECT_INCONSISTENT | FAIL_INCONSISTENT)))
return ECMD_FAILED;
if (!(lvl = find_lv_in_vg(vg, lv_name_old))) {

View File

@ -673,7 +673,7 @@ int lvresize(struct cmd_context *cmd, int argc, char **argv)
log_verbose("Finding volume group %s", lp.vg_name);
if (!(vg = vg_lock_and_read(cmd, lp.vg_name, NULL, LCK_VG_WRITE,
CLUSTERED | EXPORTED_VG | LVM_WRITE,
CORRECT_INCONSISTENT))) {
CORRECT_INCONSISTENT | FAIL_INCONSISTENT))) {
stack;
return ECMD_FAILED;
}

View File

@ -59,7 +59,7 @@ static int _pvchange_single(struct cmd_context *cmd, struct physical_volume *pv,
vg_name, pv_name);
if (!(vg = vg_lock_and_read(cmd, vg_name, NULL, LCK_VG_WRITE,
CLUSTERED | EXPORTED_VG | LVM_WRITE,
CORRECT_INCONSISTENT)))
CORRECT_INCONSISTENT | FAIL_INCONSISTENT)))
return_0;
if (!(pvl = find_pv_in_vg(vg, pv_name))) {