diff options
author | David Teigland <teigland@redhat.com> | 2019-03-14 16:25:55 -0500 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2019-04-05 14:04:42 -0500 |
commit | f58a70c168f8ac225b0e4e40c2f0e1d1c98357fa (patch) | |
tree | d3c3b9b4180714d74c02979042dd9e6fdbcadd4b | |
parent | 0ba316f102ac3fcea48a6e60dfb8c0ddef8d197e (diff) | |
download | lvm2-f58a70c168f8ac225b0e4e40c2f0e1d1c98357fa.tar.gz |
pvscan: don't print warning about lvmlockd not running
pvscan --cache ignores shared VGs, so it doesn't need to
consider lvmlockd, and shouldn't include a warning about it.
-rw-r--r-- | tools/lvmcmdline.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/lvmcmdline.c b/tools/lvmcmdline.c index 44b7724b8..1e3b1e382 100644 --- a/tools/lvmcmdline.c +++ b/tools/lvmcmdline.c @@ -2714,6 +2714,13 @@ static int _init_lvmlockd(struct cmd_context *cmd) const char *lvmlockd_socket; int use_lvmlockd = find_config_tree_bool(cmd, global_use_lvmlockd_CFG, NULL); + if (cmd->command->command_enum == pvscan_cache_CMD) { + /* pvscan cache ignores shared vgs, it only activates local vgs. */ + if (use_lvmlockd) + log_debug("Ignore lvmlockd for pvscan cache."); + return 1; + } + /* * Think about when/how to enable hints with lvmlockd. */ |