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

config: remove read_only_lock_modes

It had been added as part of lvmlockd code, but it does
not seem particularly useful.
This commit is contained in:
David Teigland 2015-07-06 11:42:52 -05:00
parent e1733a6271
commit 633aea92fb
2 changed files with 0 additions and 19 deletions

View File

@ -845,10 +845,6 @@ cfg(global_sanlock_lv_extend_CFG, "sanlock_lv_extend", global_CFG_SECTION, CFG_D
"the amount specified here. Setting this to 0 disables the\n"
"automatic extension and can cause lvcreate to fail.\n")
cfg(global_read_only_lock_modes_CFG, "read_only_lock_modes", global_CFG_SECTION, 0, CFG_TYPE_BOOL, 0, vsn(2, 2, 124), NULL, 0, NULL,
"Limit commands to actions that use read locks.\n"
"This disallows any actions that require a write (exclusive) lock.\n")
cfg(global_thin_check_executable_CFG, "thin_check_executable", global_CFG_SECTION, CFG_ALLOW_EMPTY | CFG_DEFAULT_COMMENTED, CFG_TYPE_STRING, THIN_CHECK_CMD, vsn(2, 2, 94), "@THIN_CHECK_CMD@", 0, NULL,
"The full path to the thin_check command.\n"
"LVM uses this command to check that a thin metadata\n"

View File

@ -1130,11 +1130,6 @@ int lockd_gl_create(struct cmd_context *cmd, const char *def_mode, const char *v
return 0;
}
if (!strcmp(mode, "ex") && find_config_tree_bool(cmd, global_read_only_lock_modes_CFG, NULL)) {
log_error("Exclusive global lock not allowed with read_only_lock_modes");
return 0;
}
req:
if (!_lockd_request(cmd, "lock_gl",
NULL, vg_lock_type, NULL, NULL, NULL, NULL, mode, NULL,
@ -1365,11 +1360,6 @@ int lockd_gl(struct cmd_context *cmd, const char *def_mode, uint32_t flags)
return 0;
}
if (!strcmp(mode, "ex") && find_config_tree_bool(cmd, global_read_only_lock_modes_CFG, NULL)) {
log_error("Exclusive global lock not allowed with read_only_lock_modes");
return 0;
}
req:
log_debug("lockd global mode %s", mode);
@ -1579,11 +1569,6 @@ int lockd_vg(struct cmd_context *cmd, const char *vg_name, const char *def_mode,
if (!mode)
mode = cmd->lockd_vg_default_sh ? "sh" : "ex";
if (!strcmp(mode, "ex") && find_config_tree_bool(cmd, global_read_only_lock_modes_CFG, NULL)) {
log_error("Exclusive VG lock not allowed with read_only_lock_modes");
return 0;
}
if (!strcmp(mode, "ex"))
*lockd_state |= LDST_EX;