From: Milan Broz <mbroz@redhat.com>
To: lvm-devel@redhat.com
Subject: [PATCH v2] improve activation monitoring option processing
Date: Wed, 24 Mar 2010 10:19:01 +0100 [thread overview]
Message-ID: <4BA9D905.9090107@redhat.com> (raw)
In-Reply-To: <1269372233-4199-1-git-send-email-snitzer@redhat.com>
On 03/23/2010 08:23 PM, Mike Snitzer wrote:
> Add "monitoring" option to "activation" section of lvm.conf
>
> Have clvmd consult the lvm.conf "activation/monitoring" too.
please do it something like this... (untested)
Milan
---
daemons/clvmd/lvm-functions.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/daemons/clvmd/lvm-functions.c b/daemons/clvmd/lvm-functions.c
index 60b6db4..b62969c 100644
--- a/daemons/clvmd/lvm-functions.c
+++ b/daemons/clvmd/lvm-functions.c
@@ -483,6 +483,7 @@ const char *do_lock_query(char *resource)
int do_lock_lv(unsigned char command, unsigned char lock_flags, char *resource)
{
int status = 0;
+ int dmeventd_mode = dmeventd_monitor_mode();
DEBUGLOG("do_lock_lv: resource '%s', cmd = %s, flags = %s, memlock = %d\n",
resource, decode_locking_cmd(command), decode_flags(lock_flags), memlock());
@@ -542,12 +543,8 @@ int do_lock_lv(unsigned char command, unsigned char lock_flags, char *resource)
if (lock_flags & LCK_MIRROR_NOSYNC_MODE)
init_mirror_in_sync(0);
- if (!(lock_flags & LCK_DMEVENTD_MONITOR_MODE)) {
- int dmeventd_mode =
- find_config_tree_bool(cmd, "activation/monitoring",
- DEFAULT_DMEVENTD_MONITOR);
+ if (!(lock_flags & LCK_DMEVENTD_MONITOR_MODE))
init_dmeventd_monitor(dmeventd_mode);
- }
cmd->partial_activation = 0;
@@ -638,6 +635,9 @@ int do_refresh_cache()
return -1;
}
+ init_dmeventd_monitor(find_config_tree_bool(cmd,
+ "activation/monitoring",
+ DEFAULT_DMEVENTD_MONITOR));
init_full_scan_done(0);
init_ignore_suspended_devices(1);
lvmcache_label_scan(cmd, 2);
next prev parent reply other threads:[~2010-03-24 9:19 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-23 19:23 [PATCH v2] improve activation monitoring option processing Mike Snitzer
2010-03-24 8:49 ` Milan Broz
2010-03-24 9:19 ` Milan Broz [this message]
2010-03-24 13:07 ` Mike Snitzer
2010-03-24 15:44 ` Mike Snitzer
2010-03-25 21:51 ` Mike Snitzer
2010-03-26 2:59 ` [PATCH] allow disabled dmeventd monitoring to propagate via clvmd Mike Snitzer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4BA9D905.9090107@redhat.com \
--to=mbroz@redhat.com \
--cc=lvm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.