* [PATCH] cluser mirror: Allow VGs to be built on cluster mirrors
@ 2012-10-15 15:28 Jonathan Brassow
0 siblings, 0 replies; only message in thread
From: Jonathan Brassow @ 2012-10-15 15:28 UTC (permalink / raw)
To: lvm-devel
cluser mirror: Allow VGs to be built on cluster mirrors
While it is possible to create VGs on top of cluster mirrors,
it is currently worthless to do so because no LVs can be created.
This is not a limitation of 'locking_type = 1' LVM. IOW, you can
happily stack a VG on top of a single machine LV of 'mirror'
segment type.
The disconnect comes because of the way 'ignore_suspended_devices'
is set. That is, it is not set during lvcreate/lvremove when
running 'locking_type = 1' (i.e. single machine). However, it is set
- every time - when 'locking_type = 3' and the activation is sent
through clvmd.
'ignore_suspended_devices' is meant to avoid reading any DM device
that is suspended. However, a mirror device can block I/O for a couple
reasons. The first is because it is suspended. The second is because
it has a unaddressed device failure. The first case would be already
addressed by the generic rejection of all DM devices that are suspended.
The second is not addressed at all by also rejecting mirror devices if
'ignore_suspended_devices' is set. Therefore, this chunk of code is
pointless. It also is the cause of not being able to use mirrors as
a source for VG stacking.
Index: lvm2/lib/activate/dev_manager.c
===================================================================
--- lvm2.orig/lib/activate/dev_manager.c
+++ lvm2/lib/activate/dev_manager.c
@@ -181,16 +181,10 @@ int device_is_usable(struct device *dev)
}
/* FIXME Also check for mirror block_on_error and mpath no paths */
- /* For now, we exclude all mirrors */
-
do {
next = dm_get_next_target(dmt, next, &start, &length,
&target_type, ¶ms);
/* Skip if target type doesn't match */
- if (target_type && !strcmp(target_type, "mirror") && ignore_suspended_devices()) {
- log_debug("%s: Mirror device %s not usable.", dev_name(dev), name);
- goto out;
- }
/*
* Snapshot origin could be sitting on top of a mirror which
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2012-10-15 15:28 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-15 15:28 [PATCH] cluser mirror: Allow VGs to be built on cluster mirrors Jonathan Brassow
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.