summaryrefslogtreecommitdiff
path: root/tools/lvchange.c
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2018-05-24 11:41:14 -0500
committerDavid Teigland <teigland@redhat.com>2018-05-30 09:25:45 -0500
commit7f7ec769d98cfe7af47b202189b279f354763b5a (patch)
tree9dd289a7ec240e05e9a9742e93fb16cf83810ef9 /tools/lvchange.c
parentcd369d8a7fc5324f66d9965528ef9b92828b1a19 (diff)
downloadlvm2-7f7ec769d98cfe7af47b202189b279f354763b5a.tar.gz
lvmlockd: do not use an LV lock for some lvchange options
Some lvchange options can be used even if the LV is active.
Diffstat (limited to 'tools/lvchange.c')
-rw-r--r--tools/lvchange.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/tools/lvchange.c b/tools/lvchange.c
index 0aac5ac19..6144852b6 100644
--- a/tools/lvchange.c
+++ b/tools/lvchange.c
@@ -1056,9 +1056,11 @@ static int _lvchange_properties_single(struct cmd_context *cmd,
int i, opt_enum;
uint32_t mr = 0;
- /* If LV is inactive here, ensure it's not active elsewhere. */
- if (!lockd_lv(cmd, lv, "ex", 0))
- return_ECMD_FAILED;
+ /*
+ * We do not acquire an lvmlockd lock on the LV here because these are
+ * VG metadata changes that do not conflict with the LV being active on
+ * another host.
+ */
/* First group of options which allow for one metadata commit/update for the whole group */
for (i = 0; i < cmd->command->ro_count; i++) {