summaryrefslogtreecommitdiff
path: root/tools/commands.h
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2016-06-03 09:56:48 -0500
committerDavid Teigland <teigland@redhat.com>2016-06-03 09:56:48 -0500
commitb321d2b1b9a3b6a1f8d67888a04c7318aa3148c2 (patch)
treea0a0217837ae1c267e893bc9c4311e107324fb85 /tools/commands.h
parent68e097972462e3c7c208ac34c62e737b161dd3c4 (diff)
downloadlvm2-b321d2b1b9a3b6a1f8d67888a04c7318aa3148c2.tar.gz
pvmove: disallow tag args
pvmove began processing tags unintentionally from commit, 6d7dc87cb pvmove: use toollib pvmove works on a single PV, but tags can match multiple PVs. If we allowed tags, but processed only the first matching PV, then the resulting PV would be unpredictable. Also, the current processing code does not allow us to simply report an error and do nothing if more than one PV matches the tag, because the command starts processing PVs as they are found, so it's too late to do nothing if a second PV matches.
Diffstat (limited to 'tools/commands.h')
-rw-r--r--tools/commands.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/commands.h b/tools/commands.h
index da432a708..888f3a279 100644
--- a/tools/commands.h
+++ b/tools/commands.h
@@ -874,9 +874,11 @@ xx(pvdisplay,
select_ARG, separator_ARG, shared_ARG, short_ARG, sort_ARG, unbuffered_ARG,
units_ARG)
+/* ALL_VGS_IS_DEFAULT is for polldaemon to find pvmoves in-progress using process_each_vg. */
+
xx(pvmove,
"Move extents from one physical volume to another",
- ALL_VGS_IS_DEFAULT, /* For polldaemon to find pvmoves in-progress using process_each_vg. */
+ ALL_VGS_IS_DEFAULT | DISALLOW_TAG_ARGS,
"pvmove\n"
"\t[--abort]\n"
"\t[--alloc AllocationPolicy]\n"