Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=f32973c78e981226…
Commit: f32973c78e981226577e88db662a285ea6c11bd5
Parent: 8fdca0de7910052594a55bfb7bd3815afe701dad
Author: Peter Rajnoha <prajnoha(a)redhat.com>
AuthorDate: Wed Apr 8 11:14:16 2015 +0200
Committer: Peter Rajnoha <prajnoha(a)redhat.com>
CommitterDate: Wed Apr 8 11:14:16 2015 +0200
select: mention { } use in lvm.8 man page and '-S help' properly
---
libdm/libdm-report.c | 2 +-
man/lvm.8.in | 10 +++++++++-
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/libdm/libdm-report.c b/libdm/libdm-report.c
index 6f528f1..9f50ff3 100644
--- a/libdm/libdm-report.c
+++ b/libdm/libdm-report.c
@@ -2612,7 +2612,7 @@ static void _display_selection_help(struct dm_report *rh)
log_warn(" size - Floating point value with units, 'm' unit used by default if not specified.");
log_warn(" percent - Non-negative integer with or without %% suffix.");
log_warn(" string - Characters quoted by \' or \" or unquoted.");
- log_warn(" string list - Strings enclosed by [ ] and elements delimited by either");
+ log_warn(" string list - Strings enclosed by [ ] or { } and elements delimited by either");
log_warn(" \"all items must match\" or \"at least one item must match\" operator.");
log_warn(" regular expression - Characters quoted by \' or \" or unquoted.");
log_warn(" ");
diff --git a/man/lvm.8.in b/man/lvm.8.in
index 2faaba4..26d94ee 100644
--- a/man/lvm.8.in
+++ b/man/lvm.8.in
@@ -470,6 +470,10 @@ that can be used in selection, see the output of \fB<lvm reporting command> -S h
\fB[\fP \(em List start
.IP
\fB]\fP \(em List end
+.IP
+\fB{\fP \(em List subset start
+.IP
+\fB}\fP \(em List subset end
.LP
\fBInformal grammar specification\fP:
.IP
@@ -477,7 +481,11 @@ that can be used in selection, see the output of \fB<lvm reporting command> -S h
.IP
.BR VALUE " = " [VALUE " log_op " VALUE]
.br
-For list-based types: string list. The log_op must always be of one type within the whole list value.
+For list-based types: string list. Matches strictly. The log_op must always be of one type within the whole list value.
+.IP
+.BR VALUE " = " {VALUE " log_op " VALUE}
+.br
+For list-based types: string list. Matches a subset. The log_op must always be of one type within the whole list value.
.IP
.BR VALUE " = " value
.br
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=64353ff74b56c71b…
Commit: 64353ff74b56c71b508fd040a45062facb395bae
Parent: ba049e203b35d6e03e38669a2a92af6538a0b2d0
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Tue Apr 7 13:40:15 2015 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Tue Apr 7 13:40:15 2015 +0200
tests: when test fails collect more info
In some case it might be worth to know some more surrouding info
when command has crashed.
So collect tables and some udev db content in this case.
---
test/lib/utils.sh | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
diff --git a/test/lib/utils.sh b/test/lib/utils.sh
index 2f7dc65..401a862 100644
--- a/test/lib/utils.sh
+++ b/test/lib/utils.sh
@@ -130,6 +130,21 @@ STACKTRACE() {
test -z "$LVM_TEST_NODEBUG" -a -f debug.log && {
sed -e "s,^,## DEBUG: ,;s,$top_srcdir/\?,," < debug.log
test -e strace.log && sed -e "s,^,## STRACE: ,;s,$top_srcdir/\?,," < strace.log
+ echo "========= Info ==========="
+ dmsetup info -c | grep "$PREFIX"
+ echo "========= Active table ==========="
+ dmsetup table | grep "$PREFIX"
+ echo "======== Inactive table =========="
+ dmsetup table --inactive | grep "$PREFIX"
+ echo "======== Status =========="
+ dmsetup status | grep "$PREFIX"
+ echo "======== Tree =========="
+ dmsetup ls --tree
+ echo "======== Recursive list of $DM_DEV_DIR =========="
+ ls -Rla "$DM_DEV_DIR"
+ for i in "/sys/block/dm-* /sys/block/loop*" ; do
+ udevadm info --export-db "$i" || true
+ done
}
test -f SKIP_THIS_TEST && exit 200
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=4f94669eca3c2a90…
Commit: 4f94669eca3c2a90577a972fd748f4b0c4e89928
Parent: c88ffbf9dfab5c636b45c51fda6ecf1e6f270b85
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Fri Apr 3 17:14:50 2015 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Fri Apr 3 17:18:11 2015 +0200
pvmove: don't crash when name is not found
If the device name is not found in our metadata,
we cannot call strdup few lines later with NULL name.
More intersting story goes behind how it happens -
pvmove removal is unfortunatelly 'multi-state' process
and at some point (for now) we have in lvm2 metadata
LV pvmove0 as stripe and mirror image as error.
If such metadata are left - we fail with any further removal.
---
tools/polldaemon.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/tools/polldaemon.c b/tools/polldaemon.c
index 6cdcbbb..1b6e1b4 100644
--- a/tools/polldaemon.c
+++ b/tools/polldaemon.c
@@ -223,6 +223,12 @@ static int _poll_vg(struct cmd_context *cmd, const char *vgname,
if (!name && !parms->aborting)
continue;
+ if (!name) {
+ log_error("Device name for LV %s not found in metadata. "
+ "(unfinished pvmove mirror removal?)", display_lvname(lv));
+ goto err;
+ }
+
/* FIXME Need to do the activation from _set_up_pvmove here
* if it's not running and we're not aborting. */
if (!lv_is_active(lv)) {