master - lvresize: Allow approximation with +%FREE.
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=c7b9f0ab424136...
Commit: c7b9f0ab424136b686cd08ff7416078e7c3728c3
Parent: 0dc3684b872fa1f225e06deeb0136d1ef66d4c1e
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Fri Aug 1 00:35:43 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Fri Aug 1 00:35:43 2014 +0100
lvresize: Allow approximation with +%FREE.
Make lvresize -l+%FREE support approximate allocation.
Move existing "Reducing/Extending' message to verbose level
and change it to say 'up to' if approximate allocation is being used.
Replace it with a new message that gives the actual old and new size or
says 'unchanged'.
---
WHATS_NEW | 2 ++
lib/metadata/lv_manip.c | 22 ++++++++++++++++++----
2 files changed, 20 insertions(+), 4 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index 03cf668..a1099fe 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,7 @@
Version 2.02.109 -
=================================
+ Display actual size changed when resizing LV.
+ Allow approximate allocation with +%FREE in lvextend.
Remove possible spurious "not found" message on PV create before wiping.
Handle upgrade from 2.02.105 when an LV now gaining a uuid suffix is active.
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index 0d39166..3e1f9e9 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -4155,6 +4155,8 @@ static int _lvresize_adjust_extents(struct cmd_context *cmd, struct logical_volu
if (lp->sign == SIGN_NONE && (lp->percent != PERCENT_LV && lp->percent != PERCENT_ORIGIN))
lp->approx_alloc = 1;
/* FIXME Adjust for parallel areas here before processing relative allocations */
+ if (lp->sign == SIGN_PLUS && lp->percent == PERCENT_FREE)
+ lp->approx_alloc = 1;
}
if (lp->sign == SIGN_PLUS) {
@@ -4456,6 +4458,7 @@ static struct logical_volume *_lvresize_volume(struct cmd_context *cmd,
struct volume_group *vg = lv->vg;
struct logical_volume *lock_lv = NULL;
struct lv_segment *seg = NULL;
+ uint32_t old_extents;
int status;
alloc_policy_t alloc;
@@ -4500,10 +4503,11 @@ static struct logical_volume *_lvresize_volume(struct cmd_context *cmd,
if (!archive(vg))
return_NULL;
- log_print_unless_silent("%sing logical volume %s to %s",
- (lp->resize == LV_REDUCE) ? "Reduc" : "Extend",
- lv->name,
- display_size(cmd, (uint64_t) lp->extents * vg->extent_size));
+ old_extents = lv->le_count;
+ log_verbose("%sing logical volume %s to %s%s",
+ (lp->resize == LV_REDUCE) ? "Reduc" : "Extend",
+ display_lvname(lv), lp->approx_alloc ? "up to " : "",
+ display_size(cmd, (uint64_t) lp->extents * vg->extent_size));
if (lp->resize == LV_REDUCE) {
if (!lv_reduce(lv, lv->le_count - lp->extents))
@@ -4516,6 +4520,16 @@ static struct logical_volume *_lvresize_volume(struct cmd_context *cmd,
pvh, alloc, lp->approx_alloc))
return_NULL;
+ if (old_extents == lv->le_count)
+ log_print_unless_silent("Size of logical volume %s unchanged from %s.",
+ display_lvname(lv),
+ display_size(cmd, (uint64_t) old_extents * vg->extent_size));
+ else
+ log_print_unless_silent("Size of logical volume %s changed from %s to %s.",
+ display_lvname(lv),
+ display_size(cmd, (uint64_t) old_extents * vg->extent_size),
+ display_size(cmd, (uint64_t) lv->le_count * vg->extent_size));
+
if (lock_lv) {
/* Update thin pool segment from the layered LV */
seg->area_len = lv->le_count;
8 years, 7 months
master - test: Skip lvextend-thin when thin not available
by Marian Csontos
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=0dc3684b872fa1...
Commit: 0dc3684b872fa1f225e06deeb0136d1ef66d4c1e
Parent: ef8599798069b2c49aa1c296e6f8b050458b6aeb
Author: Marian Csontos <mcsontos(a)redhat.com>
AuthorDate: Thu Jul 31 22:56:19 2014 +0200
Committer: Marian Csontos <mcsontos(a)redhat.com>
CommitterDate: Thu Jul 31 22:56:19 2014 +0200
test: Skip lvextend-thin when thin not available
---
test/shell/lvextend-thin.sh | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/test/shell/lvextend-thin.sh b/test/shell/lvextend-thin.sh
index 0d5a2f5..1a0b440 100644
--- a/test/shell/lvextend-thin.sh
+++ b/test/shell/lvextend-thin.sh
@@ -11,6 +11,8 @@
. lib/inittest
+aux have_thin 1 0 0 || skip
+
aux prepare_vg 3
lvcreate -i2 -l2 -T $vg/pool2
lvextend -l+2 $vg/pool2 $dev2 $dev3
8 years, 7 months
master - metadata: remove spurious "Physical volume <dev_name> not found"
by Peter Rajnoha
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=ef8599798069b2...
Commit: ef8599798069b2c49aa1c296e6f8b050458b6aeb
Parent: 7cff640d9ae20a94647610e5adbb4151b7652fe5
Author: Peter Rajnoha <prajnoha(a)redhat.com>
AuthorDate: Thu Jul 31 09:30:25 2014 +0200
Committer: Peter Rajnoha <prajnoha(a)redhat.com>
CommitterDate: Thu Jul 31 10:03:30 2014 +0200
metadata: remove spurious "Physical volume <dev_name> not found"
This is addendum to commit 2e82a070f3c9224da5c9f383d47e75a1715586cf
which fixed these spurious messages that appeared after commit
651d5093edde3e0ebee9d75be1c9834efc152d91 ("avoid pv_read in
find_pv_by_name").
There was one more "not found" message issued in case the device
could not be found in device cache (commit 2e82a07 fixed this only
for PV lookup itself). But if we "allow_unformatted" for
find_pv_by_name, we should not issue this message even in case
the device can't be found in dev cache as we just need to know
whether there's a PV or not for the code to decide on next steps
and we don't want to issue any messages if either device itself
is not found or PV is not found.
For example, when we were creating a new PV (and so allow_unformatted = 1)
and the device had a signature on it which caused it to be filtered
by device filter (e.g. MD signature if md filtering is enabled),
or it was part of some other subsystem (e.g. multipath), this message
was issued on find_pv_by_name call which was misleading.
Also, remove misleading "stack" call in case find_pv_by_name
returns NULL in pvcreate_check - any error state is reported
later by pvcreate_check code so no need to "stack" here.
There's one more and proper check to issue "not found" message if
the device can't be found in device cache within pvcreate_check fn
so this situation is still covered properly later in the code.
Before this patch (/dev/sda contains MD signature and is therefore filtered):
$ pvcreate /dev/sda
Physical volume /dev/sda not found
WARNING: linux_raid_member signature detected on /dev/sda at offset 4096. Wipe it? [y/n]:
With this patch applied:
$ pvcreate /dev/sda
WARNING: linux_raid_member signature detected on /dev/sda at offset 4096. Wipe it? [y/n]:
Non-existent devices are still caught properly:
$ pvcreate /dev/sdx
Device /dev/sdx not found (or ignored by filtering).
---
WHATS_NEW | 1 +
lib/metadata/metadata.c | 7 ++++---
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index ace357b..03cf668 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.02.109 -
=================================
+ Remove possible spurious "not found" message on PV create before wiping.
Handle upgrade from 2.02.105 when an LV now gaining a uuid suffix is active.
Version 2.02.108 - 23rd July 2014
diff --git a/lib/metadata/metadata.c b/lib/metadata/metadata.c
index 0832750..39fa45f 100644
--- a/lib/metadata/metadata.c
+++ b/lib/metadata/metadata.c
@@ -685,8 +685,8 @@ static int vg_extend_single_pv(struct volume_group *vg, char *pv_name,
{
struct physical_volume *pv;
- if (!(pv = find_pv_by_name(vg->cmd, pv_name, 1, 1)))
- stack;
+ pv = find_pv_by_name(vg->cmd, pv_name, 1, 1);
+
if (!pv && !pp) {
log_error("%s not identified as an existing "
"physical volume", pv_name);
@@ -1858,7 +1858,8 @@ struct physical_volume *find_pv_by_name(struct cmd_context *cmd,
lvmcache_seed_infos_from_lvmetad(cmd);
if (!(dev = dev_cache_get(pv_name, cmd->filter))) {
- log_error("Physical volume %s not found", pv_name);
+ if (!allow_unformatted)
+ log_error("Physical volume %s not found", pv_name);
return_NULL;
}
8 years, 7 months
master - activation: Fix upgrades using uuid suffixes.
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=7cff640d9ae20a...
Commit: 7cff640d9ae20a94647610e5adbb4151b7652fe5
Parent: c4484d90503c4e5c2bc945461da50a6b85c5d7e7
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Wed Jul 30 21:55:11 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Wed Jul 30 21:55:11 2014 +0100
activation: Fix upgrades using uuid suffixes.
2.02.106 added suffixes to some LV uuids in the kernel.
If any of these LVs is activated with 2.02.105 or earlier,
and then a later version is used, the LVs appear invisible and
activation commands fail.
The code now has to check the kernel for both old and new uuids.
---
WHATS_NEW | 1 +
WHATS_NEW_DM | 1 +
lib/activate/dev_manager.c | 29 ++++++++++++++++++++++++++++-
lib/misc/lvm-string.c | 1 +
libdm/libdevmapper.h | 5 +++++
libdm/libdm-deptree.c | 41 +++++++++++++++++++++++++++++++++++++++--
6 files changed, 75 insertions(+), 3 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index 64b174b..ace357b 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.02.109 -
=================================
+ Handle upgrade from 2.02.105 when an LV now gaining a uuid suffix is active.
Version 2.02.108 - 23rd July 2014
=================================
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index ad25215..b663bfc 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,5 +1,6 @@
Version 1.02.88 -
================================
+ Add dm_tree_set_optional_uuid_suffixes to handle upgrades.
Version 1.02.87 - 23rd July 2014
================================
diff --git a/lib/activate/dev_manager.c b/lib/activate/dev_manager.c
index d5fe620..2cf0b65 100644
--- a/lib/activate/dev_manager.c
+++ b/lib/activate/dev_manager.c
@@ -41,6 +41,9 @@ typedef enum {
CLEAN
} action_t;
+/* This list must match lib/misc/lvm-string.c:build_dm_uuid(). */
+const char *uuid_suffix_list[] = { "pool", "cdata", "cmeta", "tdata", "tmeta", NULL};
+
struct dev_manager {
struct dm_pool *mem;
@@ -482,11 +485,31 @@ static int _info(const char *dlid, int with_open_count, int with_read_ahead,
struct dm_info *info, uint32_t *read_ahead)
{
int r = 0;
+ char old_style_dlid[sizeof(UUID_PREFIX) + 2 * ID_LEN];
+ const char *suffix, *suffix_position;
+ unsigned i = 0;
+ /* Check for dlid */
if ((r = _info_run(NULL, dlid, info, read_ahead, 0, with_open_count,
with_read_ahead, 0, 0)) && info->exists)
return 1;
- else if ((r = _info_run(NULL, dlid + sizeof(UUID_PREFIX) - 1, info,
+
+ /* Check for original version of dlid before the suffixes got added in 2.02.106 */
+ if ((suffix_position = rindex(dlid, '-'))) {
+ while ((suffix = uuid_suffix_list[i++])) {
+ if (strcmp(suffix_position + 1, suffix))
+ continue;
+
+ (void) strncpy(old_style_dlid, dlid, sizeof(old_style_dlid));
+ old_style_dlid[sizeof(old_style_dlid) - 1] = '\0';
+ if ((r = _info_run(NULL, old_style_dlid, info, read_ahead, 0, with_open_count,
+ with_read_ahead, 0, 0)) && info->exists)
+ return 1;
+ }
+ }
+
+ /* Check for dlid before UUID_PREFIX was added */
+ if ((r = _info_run(NULL, dlid + sizeof(UUID_PREFIX) - 1, info,
read_ahead, 0, with_open_count,
with_read_ahead, 0, 0)) && info->exists)
return 1;
@@ -2011,6 +2034,8 @@ static struct dm_tree *_create_partial_dtree(struct dev_manager *dm, struct logi
return NULL;
}
+ dm_tree_set_optional_uuid_suffixes(dtree, &uuid_suffix_list[0]);
+
if (!_add_lv_to_dtree(dm, dtree, lv, (lv_is_origin(lv) || lv_is_thin_volume(lv)) ? origin_only : 0))
goto_bad;
@@ -3001,6 +3026,8 @@ int dev_manager_device_uses_vg(struct device *dev,
return r;
}
+ dm_tree_set_optional_uuid_suffixes(dtree, &uuid_suffix_list[0]);
+
if (!dm_tree_add_dev(dtree, (uint32_t) MAJOR(dev->dev), (uint32_t) MINOR(dev->dev))) {
log_error("Failed to add device %s (%" PRIu32 ":%" PRIu32") to dtree",
dev_name(dev), (uint32_t) MAJOR(dev->dev), (uint32_t) MINOR(dev->dev));
diff --git a/lib/misc/lvm-string.c b/lib/misc/lvm-string.c
index 5858638..84c8708 100644
--- a/lib/misc/lvm-string.c
+++ b/lib/misc/lvm-string.c
@@ -185,6 +185,7 @@ char *build_dm_uuid(struct dm_pool *mem, const struct logical_volume *lv,
* an internal LV they should not scan.
* Should also make internal detection simpler.
*/
+ /* Suffixes used here MUST match lib/activate/dev_manager.c */
layer = lv_is_cache_pool_data(lv) ? "cdata" :
lv_is_cache_pool_metadata(lv) ? "cmeta" :
// FIXME: dm-tree needs fixes for mirrors/raids
diff --git a/libdm/libdevmapper.h b/libdm/libdevmapper.h
index dc3da78..e37ee39 100644
--- a/libdm/libdevmapper.h
+++ b/libdm/libdevmapper.h
@@ -526,6 +526,11 @@ struct dm_tree *dm_tree_create(void);
void dm_tree_free(struct dm_tree *tree);
/*
+ * List of suffixes to be ignored when matching uuids against existing devices.
+ */
+void dm_tree_set_optional_uuid_suffixes(struct dm_tree *dtree, const char **optional_uuid_suffixes);
+
+/*
* Add nodes to the tree for a given device and all the devices it uses.
*/
int dm_tree_add_dev(struct dm_tree *tree, uint32_t major, uint32_t minor);
diff --git a/libdm/libdm-deptree.c b/libdm/libdm-deptree.c
index f34c40f..55f061a 100644
--- a/libdm/libdm-deptree.c
+++ b/libdm/libdm-deptree.c
@@ -16,6 +16,7 @@
#include "libdm-targets.h"
#include "libdm-common.h"
#include "kdev_t.h"
+#include "dm-ioctl.h"
#include <stdarg.h>
#include <sys/param.h>
@@ -300,6 +301,7 @@ struct dm_tree {
int no_flush; /* 1 sets noflush (mirrors/multipath) */
int retry_remove; /* 1 retries remove if not successful */
uint32_t cookie;
+ const char **optional_uuid_suffixes; /* uuid suffixes ignored when matching */
};
/*
@@ -325,6 +327,7 @@ struct dm_tree *dm_tree_create(void)
dtree->skip_lockfs = 0;
dtree->no_flush = 0;
dtree->mem = dmem;
+ dtree->optional_uuid_suffixes = NULL;
if (!(dtree->devs = dm_hash_create(8))) {
log_error("dtree hash creation failed");
@@ -539,23 +542,57 @@ static struct dm_tree_node *_find_dm_tree_node(struct dm_tree *dtree,
sizeof(dev));
}
+void dm_tree_set_optional_uuid_suffixes(struct dm_tree *dtree, const char **optional_uuid_suffixes)
+{
+ dtree->optional_uuid_suffixes = optional_uuid_suffixes;
+}
+
static struct dm_tree_node *_find_dm_tree_node_by_uuid(struct dm_tree *dtree,
const char *uuid)
{
struct dm_tree_node *node;
const char *default_uuid_prefix;
size_t default_uuid_prefix_len;
+ const char *suffix, *suffix_position;
+ char uuid_without_suffix[DM_UUID_LEN];
+ unsigned i = 0;
+ const char **suffix_list = dtree->optional_uuid_suffixes;
- if ((node = dm_hash_lookup(dtree->uuids, uuid)))
+ if ((node = dm_hash_lookup(dtree->uuids, uuid))) {
+ log_debug("Matched uuid %s in deptree.", uuid);
return node;
+ }
default_uuid_prefix = dm_uuid_prefix();
default_uuid_prefix_len = strlen(default_uuid_prefix);
+ if (suffix_list && (suffix_position = rindex(uuid, '-'))) {
+ while ((suffix = suffix_list[i++])) {
+ if (strcmp(suffix_position + 1, suffix))
+ continue;
+
+ (void) strncpy(uuid_without_suffix, uuid, sizeof(uuid_without_suffix));
+ uuid_without_suffix[suffix_position - uuid] = '\0';
+
+ if ((node = dm_hash_lookup(dtree->uuids, uuid_without_suffix))) {
+ log_debug("Matched uuid %s (missing suffix -%s) in deptree.", uuid_without_suffix, suffix);
+ return node;
+ }
+
+ break;
+ };
+ }
+
if (strncmp(uuid, default_uuid_prefix, default_uuid_prefix_len))
return NULL;
- return dm_hash_lookup(dtree->uuids, uuid + default_uuid_prefix_len);
+ if ((node = dm_hash_lookup(dtree->uuids, uuid + default_uuid_prefix_len))) {
+ log_debug("Matched uuid %s (missing prefix) in deptree.", uuid + default_uuid_prefix_len);
+ return node;
+ }
+
+ log_debug("Not matched uuid %s in deptree.", uuid + default_uuid_prefix_len);
+ return NULL;
}
void dm_tree_node_set_udev_flags(struct dm_tree_node *dnode, uint16_t udev_flags)
8 years, 7 months
master - test: Add a test for lvextend -l+100%FREE of a striped thin pool.
by Petr Rockai
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=c4484d90503c4e...
Commit: c4484d90503c4e5c2bc945461da50a6b85c5d7e7
Parent: 321bed713727a81d743b42c98c1fd91c18ecddb5
Author: Petr Rockai <prockai(a)redhat.com>
AuthorDate: Wed Jul 30 16:15:16 2014 +0200
Committer: Petr Rockai <prockai(a)redhat.com>
CommitterDate: Wed Jul 30 16:17:29 2014 +0200
test: Add a test for lvextend -l+100%FREE of a striped thin pool.
---
test/shell/lvextend-thin.sh | 17 +++++++++++++++++
1 files changed, 17 insertions(+), 0 deletions(-)
diff --git a/test/shell/lvextend-thin.sh b/test/shell/lvextend-thin.sh
new file mode 100644
index 0000000..0d5a2f5
--- /dev/null
+++ b/test/shell/lvextend-thin.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+# Copyright (C) 2014 Red Hat, Inc. All rights reserved.
+#
+# This copyrighted material is made available to anyone wishing to use,
+# modify, copy, or redistribute it subject to the terms and conditions
+# of the GNU General Public License v.2.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software Foundation,
+# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+. lib/inittest
+
+aux prepare_vg 3
+lvcreate -i2 -l2 -T $vg/pool2
+lvextend -l+2 $vg/pool2 $dev2 $dev3
+should lvextend -l+100%FREE $vg/pool2
8 years, 7 months
master - post-release
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=321bed713727a8...
Commit: 321bed713727a81d743b42c98c1fd91c18ecddb5
Parent: 52217f6ebd3dee25808344a9425fc085427075e4
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Wed Jul 23 16:23:52 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Wed Jul 23 16:23:52 2014 +0100
post-release
---
VERSION | 2 +-
VERSION_DM | 2 +-
WHATS_NEW | 3 +++
WHATS_NEW_DM | 3 +++
4 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/VERSION b/VERSION
index fa96924..79c463f 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.02.108(2)-git (2014-07-23)
+2.02.109(2)-git (2014-07-23)
diff --git a/VERSION_DM b/VERSION_DM
index 307f41d..a6ea805 100644
--- a/VERSION_DM
+++ b/VERSION_DM
@@ -1 +1 @@
-1.02.87-git (2014-07-23)
+1.02.88-git (2014-07-23)
diff --git a/WHATS_NEW b/WHATS_NEW
index e443834..64b174b 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,3 +1,6 @@
+Version 2.02.109 -
+=================================
+
Version 2.02.108 - 23rd July 2014
=================================
Add lvscan --cache which re-scans constituents of a particular LV.
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index a39099f..ad25215 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,3 +1,6 @@
+Version 1.02.88 -
+================================
+
Version 1.02.87 - 23rd July 2014
================================
Fix dm_report_field_string_list to handle delimiter with multiple chars.
8 years, 8 months
master - raid: Fix partial activation logic for non-raid.
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=52217f6ebd3dee...
Commit: 52217f6ebd3dee25808344a9425fc085427075e4
Parent: 25fa725b05a83dd67e907802d1938bf983ffaad8
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Wed Jul 23 16:13:12 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Wed Jul 23 16:13:12 2014 +0100
raid: Fix partial activation logic for non-raid.
---
lib/activate/activate.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/activate/activate.c b/lib/activate/activate.c
index ebeaa79..1230c9a 100644
--- a/lib/activate/activate.c
+++ b/lib/activate/activate.c
@@ -2224,8 +2224,8 @@ static int _lv_activate(struct cmd_context *cmd, const char *lvid_s,
goto out;
}
- if ((!lv->vg->cmd->partial_activation) && (lv->status & PARTIAL_LV) && lv_is_raid_type(lv)) {
- if (!partial_raid_lv_supports_degraded_activation(lv)) {
+ if ((!lv->vg->cmd->partial_activation) && (lv->status & PARTIAL_LV)) {
+ if (!lv_is_raid_type(lv) || !partial_raid_lv_supports_degraded_activation(lv)) {
log_error("Refusing activation of partial LV %s. "
"Use '--activationmode partial' to override.",
display_lvname(lv));
8 years, 8 months
master - pre-release
by Alasdair Kergon
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=25fa725b05a83d...
Commit: 25fa725b05a83dd67e907802d1938bf983ffaad8
Parent: 8d63d94d853b9675f9d3a86de8b34c68db5d5226
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Wed Jul 23 16:05:22 2014 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Wed Jul 23 16:05:22 2014 +0100
pre-release
---
VERSION | 2 +-
VERSION_DM | 2 +-
WHATS_NEW | 2 +-
WHATS_NEW_DM | 2 +-
4 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/VERSION b/VERSION
index 4695aab..fa96924 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.02.108(2)-git (2014-06-23)
+2.02.108(2)-git (2014-07-23)
diff --git a/VERSION_DM b/VERSION_DM
index 12a8c3d..307f41d 100644
--- a/VERSION_DM
+++ b/VERSION_DM
@@ -1 +1 @@
-1.02.87-git (2014-06-23)
+1.02.87-git (2014-07-23)
diff --git a/WHATS_NEW b/WHATS_NEW
index 3595517..e443834 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,4 +1,4 @@
-Version 2.02.108 -
+Version 2.02.108 - 23rd July 2014
=================================
Add lvscan --cache which re-scans constituents of a particular LV.
Make dmeventd's RAID plugin re-scan failed PVs when lvmetad is in use.
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index ab94bc4..a39099f 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,4 +1,4 @@
-Version 1.02.87 -
+Version 1.02.87 - 23rd July 2014
================================
Fix dm_report_field_string_list to handle delimiter with multiple chars.
Add dm_report_field_reserved_value for per-field reserved value definition.
8 years, 8 months
master - tests: still unusable kernel
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=8d63d94d853b96...
Commit: 8d63d94d853b9675f9d3a86de8b34c68db5d5226
Parent: 22be7c441784fd89cf76cb6ed56fd50da126864d
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Jul 23 00:29:32 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Jul 23 00:29:32 2014 +0200
tests: still unusable kernel
---
test/lib/aux.sh | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/test/lib/aux.sh b/test/lib/aux.sh
index 7b96ad4..dcc86ed 100644
--- a/test/lib/aux.sh
+++ b/test/lib/aux.sh
@@ -736,6 +736,7 @@ raid456_replace_works() {
3.13.*.fc20.i686*|3.13.*.fc20.x86_64) return 1 ;;
3.14.*.fc21.i686*|3.14.*.fc21.x86_64) return 1 ;;
3.15.*rc6*.fc21.i686*|3.15.*rc6*.fc21.x86_64) return 1 ;;
+ 3.16.*rc4*.fc21.i686*|3.16.*rc4*.fc21.x86_64) return 1 ;;
esac
}
8 years, 8 months
master - tests: support cluster run
by Zdenek Kabelac
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=22be7c441784fd...
Commit: 22be7c441784fd89cf76cb6ed56fd50da126864d
Parent: 3a8bb8d3a4ef379298e97ca5f087a1c8908841ed
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Jul 23 00:25:49 2014 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Jul 23 00:25:49 2014 +0200
tests: support cluster run
needs exclusive activation
---
test/shell/lvcreate-cache.sh | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/test/shell/lvcreate-cache.sh b/test/shell/lvcreate-cache.sh
index 4274897..03ff214 100644
--- a/test/shell/lvcreate-cache.sh
+++ b/test/shell/lvcreate-cache.sh
@@ -71,14 +71,14 @@ lvremove -f $vg/cache_pool
# Bug 1110026
# Create origin, then cache_pool and cache
-lvcreate -l 2 -n $lv1 $vg
+lvcreate -aey -l 2 -n $lv1 $vg
lvcreate --type cache -l 1 $vg/$lv1
#should dmsetup table ${vg}-$lv1 | grep cache # ensure it is loaded in kernel
lvremove -ff $vg
# Bug 1110026 & Bug 1095843
# Create RAID1 origin, then cache_pool and cache
-lvcreate -l 2 -n $lv1 $vg
+lvcreate -aey -l 2 -n $lv1 $vg
lvcreate --type cache -l 1 $vg/$lv1
#should lvs -a $vg/${lv1}_corig_rimage_0 # ensure images are properly renamed
#should dmsetup table ${vg}-$lv1 | grep cache # ensure it is loaded in kernel
@@ -101,7 +101,7 @@ done
##############################
# Attempt to create smaller cache than origin should fail
-lvcreate -l 1 -n $lv1 $vg
+lvcreate -aey -l 1 -n $lv1 $vg
not lvcreate --type cache -l 2 $vg/$lv1
8 years, 8 months