summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Teigland <teigland@redhat.com>2017-02-24 16:43:05 -0600
committerDavid Teigland <teigland@redhat.com>2017-02-24 16:43:05 -0600
commit07c0ae59ce34dc0ee7b0337d08727321fc27cd8d (patch)
tree175e1ce8babf8e8397320f5615e2386536efa8dd
parent4f7631b4adb9c6fff5cd47b5bd733ee716d05c8f (diff)
downloadlvm2-dev-dct-cmd-defs-raid.tar.gz
commands: fixes for recent raid changesdev-dct-cmd-defs-raid
- Combine the equivalent lvconvert --type raid defs. - Remove unwanted options from lvconvert --stripes and lvconvert --stripesize. - Use Number for --stripes_long val type. - Disable the lvconvert LV replica of existing cmd def. (The new operation to clear reshape space will need a new option to distinguish it from the existing polling command, or the new operation would need to be detected and called from the existing start_poll command.)
-rw-r--r--tools/command-lines.in36
1 files changed, 19 insertions, 17 deletions
diff --git a/tools/command-lines.in b/tools/command-lines.in
index c3d684ef9..f2d729ae6 100644
--- a/tools/command-lines.in
+++ b/tools/command-lines.in
@@ -338,19 +338,16 @@ ID: lvconvert_raid_types
DESC: Convert LV to type mirror (also see type raid1).
RULE: all not lv_is_locked lv_is_pvmove
+# When LV is already raid, this changes the raid layout
+# (changing layout of raid0 and raid1 not allowed.)
+
lvconvert --type raid LV
OO: OO_LVCONVERT_RAID, OO_LVCONVERT
OP: PV ...
ID: lvconvert_raid_types
-DESC: Convert LV to raid.
-RULE: all not lv_is_locked lv_is_pvmove
-
-lvconvert --type raid LV_raid
-OO: OO_LVCONVERT_RAID, OO_LVCONVERT
-ID: lvconvert_raid_types
-DESC: Convert raid LV to different layout algorithm.
+DESC: Convert LV to raid or change raid layout.
RULE: all not lv_is_locked lv_is_pvmove
-RULE: all not LV_raid0 LV_raid1
+RULE: LV_raid not LV_raid0 LV_raid1
lvconvert --mirrors SNumber LV
OO: OO_LVCONVERT_RAID, OO_LVCONVERT, --mirrorlog MirrorLog
@@ -359,8 +356,8 @@ ID: lvconvert_raid_types
DESC: Convert LV to raid1 or mirror, or change number of mirror images.
RULE: all not lv_is_locked lv_is_pvmove
-lvconvert --stripes_long SNumber LV_raid
-OO: OO_LVCONVERT_RAID, OO_LVCONVERT
+lvconvert --stripes_long Number LV_raid
+OO: OO_LVCONVERT, --interval Number
OP: PV ...
ID: lvconvert_raid_types
DESC: Convert raid LV to change number of stripe images.
@@ -368,7 +365,7 @@ RULE: all not lv_is_locked lv_is_pvmove
RULE: all not LV_raid0 LV_raid1
lvconvert --stripesize SizeKB LV_raid
-OO: OO_LVCONVERT_RAID, OO_LVCONVERT
+OO: OO_LVCONVERT, --interval Number
ID: lvconvert_raid_types
DESC: Convert raid LV to change the stripe size.
RULE: all not lv_is_locked lv_is_pvmove
@@ -381,12 +378,17 @@ DESC: Change the region size of an LV.
RULE: all not lv_is_locked lv_is_pvmove
RULE: all not LV_raid0
-lvconvert LV_mirror_raid
-OO: OO_LVCONVERT
-ID: lvconvert_raid_types
-DESC: Remove out-of-place reshape space
-RULE: all not lv_is_locked lv_is_pvmove
-RULE: all not LV_raid0 LV_raid1
+# FIXME: this is equivalent to lvconvert_start_poll below,
+# so we need to add a new option to identify this command, or
+# detect this case in lvconvert_start_poll_cmd() and redirect to
+# lvconvert_raid_types().
+#
+# lvconvert LV_mirror_raid
+# OO: OO_LVCONVERT
+# ID: lvconvert_raid_types
+# DESC: Remove out-of-place reshape space
+# RULE: all not lv_is_locked lv_is_pvmove
+# RULE: all not LV_raid0 LV_raid1
---