master - pre-release
by Alasdair Kergon
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=b9a16fe73bdbed8a9be...
Commit: b9a16fe73bdbed8a9bece3fb33fb754d62ffb8d4
Parent: 9ed518f19fff387d3b843bcdf4fa900f89ab98d8
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Thu Apr 13 00:43:31 2017 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Thu Apr 13 00:43:31 2017 +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 3b0a11f..204e69d 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-2.02.170(2)-git (2017-03-28)
+2.02.170(2)-git (2017-04-13)
diff --git a/VERSION_DM b/VERSION_DM
index 72fc3fe..5387a46 100644
--- a/VERSION_DM
+++ b/VERSION_DM
@@ -1 +1 @@
-1.02.139-git (2017-03-28)
+1.02.139-git (2017-04-13)
diff --git a/WHATS_NEW b/WHATS_NEW
index b0fc86f..f2482f3 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,4 +1,4 @@
-Version 2.02.170 -
+Version 2.02.170 - 13th April 2017
==================================
Introduce global/fsadm_executable to make fsadm path configurable.
Look for limited thin pool metadata size when using 16G metadata.
diff --git a/WHATS_NEW_DM b/WHATS_NEW_DM
index 2fa2566..fe1aeb1 100644
--- a/WHATS_NEW_DM
+++ b/WHATS_NEW_DM
@@ -1,4 +1,4 @@
-Version 1.02.139 -
+Version 1.02.139 - 13th April 2017
==================================
Fix assignment in _target_version() when dm task can't run.
Flush stdout on each iteration when using --count or --interval.
7 years
master - autoconf
by Alasdair Kergon
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=9ed518f19fff387d3b8...
Commit: 9ed518f19fff387d3b843bcdf4fa900f89ab98d8
Parent: 5ac230095c72c578cb76996b5b8ae687d04e98a9
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Thu Apr 13 00:38:46 2017 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Thu Apr 13 00:38:46 2017 +0100
autoconf
---
configure | 4 +++-
configure.in | 1 +
2 files changed, 4 insertions(+), 1 deletions(-)
diff --git a/configure b/configure
index e691805..4b83118 100755
--- a/configure
+++ b/configure
@@ -699,6 +699,7 @@ HAVE_VALGRIND
HAVE_REALTIME
HAVE_LIBDL
BLKDEACTIVATE
+FSADM_PATH
FSADM
ELDFLAGS
DM_LIB_PATCHLEVEL
@@ -821,8 +822,8 @@ THIN_CHECK_CMD
HAVE_FULL_RELRO
HAVE_PIE
POW_LIB
-LIBOBJS
ALLOCA
+LIBOBJS
SORT
WC
CHMOD
@@ -15669,6 +15670,7 @@ _ACEOF
+
################################################################################
ac_config_files="$ac_config_files Makefile make.tmpl daemons/Makefile daemons/clvmd/Makefile daemons/cmirrord/Makefile daemons/dmeventd/Makefile daemons/dmeventd/libdevmapper-event.pc daemons/dmeventd/plugins/Makefile daemons/dmeventd/plugins/lvm2/Makefile daemons/dmeventd/plugins/raid/Makefile daemons/dmeventd/plugins/mirror/Makefile daemons/dmeventd/plugins/snapshot/Makefile daemons/dmeventd/plugins/thin/Makefile daemons/dmfilemapd/Makefile daemons/lvmdbusd/Makefile daemons/lvmdbusd/path.py daemons/lvmetad/Makefile daemons/lvmpolld/Makefile daemons/lvmlockd/Makefile conf/Makefile conf/example.conf conf/lvmlocal.conf conf/command_profile_template.profile conf/metadata_profile_template.profile include/.symlinks include/Makefile lib/Makefile lib/format1/Makefile lib/format_pool/Makefile lib/locking/Makefile lib/mirror/Makefile lib/replicator/Makefile include/lvm-version.h lib/raid/Makefile lib/snapshot/Makefile lib/thin/Makefile lib/cache_segtype/Makefile libdaemon/Makefile libdaemon
/client/Makefile libdaemon/server/Makefile libdm/Makefile libdm/libdevmapper.pc liblvm/Makefile liblvm/liblvm2app.pc man/Makefile po/Makefile python/Makefile python/setup.py scripts/blkdeactivate.sh scripts/blk_availability_init_red_hat scripts/blk_availability_systemd_red_hat.service scripts/clvmd_init_red_hat scripts/cmirrord_init_red_hat scripts/com.redhat.lvmdbus1.service scripts/dm_event_systemd_red_hat.service scripts/dm_event_systemd_red_hat.socket scripts/lvm2_cluster_activation_red_hat.sh scripts/lvm2_cluster_activation_systemd_red_hat.service scripts/lvm2_clvmd_systemd_red_hat.service scripts/lvm2_cmirrord_systemd_red_hat.service scripts/lvm2_lvmdbusd_systemd_red_hat.service scripts/lvm2_lvmetad_init_red_hat scripts/lvm2_lvmetad_systemd_red_hat.service scripts/lvm2_lvmetad_systemd_red_hat.socket scripts/lvm2_lvmpolld_init_red_hat scripts/lvm2_lvmpolld_systemd_red_hat.service scripts/lvm2_lvmpolld_systemd_red_hat.socket scripts/lvm2_lvmlockd_systemd_red_hat.service scripts/
lvm2_lvmlocking_systemd_red_hat.service scripts/lvm2_monitoring_init_red_hat scripts/lvm2_monitoring_systemd_red_hat.service scripts/lvm2_pvscan_systemd_red_hat@.service scripts/lvm2_tmpfiles_red_hat.conf scripts/lvmdump.sh scripts/Makefile test/Makefile test/api/Makefile test/unit/Makefile tools/Makefile udev/Makefile unit-tests/datastruct/Makefile unit-tests/regex/Makefile unit-tests/mm/Makefile"
diff --git a/configure.in b/configure.in
index 9c1dabe..7dc3095 100644
--- a/configure.in
+++ b/configure.in
@@ -2075,6 +2075,7 @@ AC_SUBST(DMFILEMAPD)
AC_SUBST(DM_LIB_PATCHLEVEL)
AC_SUBST(ELDFLAGS)
AC_SUBST(FSADM)
+AC_SUBST(FSADM_PATH)
AC_SUBST(BLKDEACTIVATE)
AC_SUBST(HAVE_LIBDL)
AC_SUBST(HAVE_REALTIME)
7 years
master - make generate
by Alasdair Kergon
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=5ac230095c72c578cb7...
Commit: 5ac230095c72c578cb76996b5b8ae687d04e98a9
Parent: a3e8354479f2b6c3d35fdc992d4114b244326833
Author: Alasdair G Kergon <agk(a)redhat.com>
AuthorDate: Thu Apr 13 00:30:05 2017 +0100
Committer: Alasdair G Kergon <agk(a)redhat.com>
CommitterDate: Thu Apr 13 00:30:05 2017 +0100
make generate
---
conf/example.conf.in | 28 +++++++++------
man/lvchange.8_pregen | 48 +++++++++++++++++++++----
man/lvconvert.8_pregen | 81 +++++++++++++++++++++++-------------------
man/lvcreate.8_pregen | 15 ++++----
man/lvdisplay.8_pregen | 13 -------
man/lvm-fullreport.8_pregen | 13 -------
man/lvs.8_pregen | 13 -------
man/lvscan.8_pregen | 13 -------
man/pvs.8_pregen | 13 -------
man/vgcfgbackup.8_pregen | 13 -------
man/vgchange.8_pregen | 16 ++++----
man/vgdisplay.8_pregen | 13 -------
man/vgs.8_pregen | 13 -------
man/vgscan.8_pregen | 13 -------
14 files changed, 116 insertions(+), 189 deletions(-)
diff --git a/conf/example.conf.in b/conf/example.conf.in
index 614ce53..78f11d1 100644
--- a/conf/example.conf.in
+++ b/conf/example.conf.in
@@ -389,6 +389,17 @@ allocation {
# Cache pool metadata and data will always use different PVs.
cache_pool_metadata_require_separate_pvs = 0
+ # Configuration option allocation/cache_metadata_format.
+ # Sets default metadata format for new cache.
+ #
+ # Accepted values:
+ # 0 Automatically detected best available format
+ # 1 Original format
+ # 2 Improved 2nd. generation format
+ #
+ # This configuration option has an automatic default value.
+ # cache_metadata_format = 0
+
# Configuration option allocation/cache_mode.
# The default cache mode used for new cache.
#
@@ -403,17 +414,6 @@ allocation {
# This configuration option has an automatic default value.
# cache_mode = "writethrough"
- # Configuration option allocation/cache_metadata_format.
- # Sets default metadata format for new cache.
- #
- # Accepted values:
- # 0 Automatically detected best available format
- # 1 Original format
- # 2 Improved 2nd. generation format
- #
- # This configuration option has an automatic default value.
- # cache_metadata_format = 0
-
# Configuration option allocation/cache_policy.
# The default cache policy used for new cache volume.
# Since kernel 4.2 the default policy is smq (Stochastic multiqueue),
@@ -1069,6 +1069,12 @@ global {
# This configuration option has an automatic default value.
# cache_repair_options = [ "" ]
+ # Configuration option global/fsadm_executable.
+ # The full path to the fsadm command.
+ # LVM uses this command to help with lvresize -r operations.
+ # This configuration option has an automatic default value.
+ # fsadm_executable = "@FSADM_PATH@"
+
# Configuration option global/system_id_source.
# The method LVM uses to set the local system ID.
# Volume Groups can also be given a system ID (by vgcreate, vgchange,
diff --git a/man/lvchange.8_pregen b/man/lvchange.8_pregen
index 199e4cc..174ad32 100644
--- a/man/lvchange.8_pregen
+++ b/man/lvchange.8_pregen
@@ -323,6 +323,14 @@ required, after which the others are optional.
[ \fB-a\fP|\fB--activate\fP \fBy\fP|\fBn\fP|\fBay\fP ]
.ad b
.br
+.ad l
+[ \fB--poll\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
+.ad l
+[ \fB--monitor\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
[ COMMON_OPTIONS ]
.RE
.br
@@ -384,6 +392,14 @@ Activate or deactivate an LV.
.ad b
.br
.ad l
+[ \fB--poll\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
+.ad l
+[ \fB--monitor\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
+.ad l
[ \fB--ignorelockingfailure\fP ]
.ad b
.br
@@ -407,9 +423,17 @@ Reactivate an LV using the latest metadata.
.ad b
.br
.ad l
+[ \fB--activationmode\fP \fBpartial\fP|\fBdegraded\fP|\fBcomplete\fP ]
+.ad b
+.br
+.ad l
[ \fB--poll\fP \fBy\fP|\fBn\fP ]
.ad b
.br
+.ad l
+[ \fB--monitor\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
[ COMMON_OPTIONS ]
.RE
.br
@@ -421,10 +445,6 @@ Start or stop monitoring an LV from dmeventd.
\fBlvchange\fP \fB--monitor\fP \fBy\fP|\fBn\fP \fIVG\fP|\fILV\fP|\fITag\fP|\fISelect\fP ...
.br
.RS 4
-.ad l
-[ \fB--poll\fP \fBy\fP|\fBn\fP ]
-.ad b
-.br
[ COMMON_OPTIONS ]
.RE
.br
@@ -455,6 +475,18 @@ Make the minor device number persistent for an LV.
[ \fB-j\fP|\fB--major\fP \fINumber\fP ]
.ad b
.br
+.ad l
+[ \fB-a\fP|\fB--activate\fP \fBy\fP|\fBn\fP|\fBay\fP ]
+.ad b
+.br
+.ad l
+[ \fB--poll\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
+.ad l
+[ \fB--monitor\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
[ COMMON_OPTIONS ]
.RE
.br
@@ -840,10 +872,10 @@ ignore the devices LVM creates.
.ad l
\fB-P\fP|\fB--partial\fP
.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
+Commands will do their best to activate LVs with missing PV extents.
+Missing extents may be replaced with error or zero segments
+according to the lvm.conf missing_stripe_filler setting.
+Metadata may not be changed with this option.
.ad b
.HP
.ad l
diff --git a/man/lvconvert.8_pregen b/man/lvconvert.8_pregen
index e56b6de..3652303 100644
--- a/man/lvconvert.8_pregen
+++ b/man/lvconvert.8_pregen
@@ -243,6 +243,17 @@ To display the current LV type, run the command:
.B lvs -o name,segtype
.I LV
+In some cases, an LV is a single device mapper (dm) layer above physical
+devices. In other cases, hidden LVs (dm devices) are layered between the
+visible LV and physical devices. LVs in the middle layers are called sub LVs.
+A command run on a visible LV sometimes operates on a sub LV rather than
+the specified LV. In other cases, a sub LV must be specified directly on
+the command line.
+
+Sub LVs can be displayed with the command:
+
+.B lvs -a
+
The
.B linear
type is equivalent to the
@@ -256,48 +267,44 @@ type is deprecated and the
.B raid1
type should be used. They are both implementations of mirroring.
-In some cases, an LV is a single device mapper (dm) layer above physical
-devices. In other cases, hidden LVs (dm devices) are layered between the
-visible LV and physical devices. LVs in the middle layers are called sub LVs.
-A command run on a visible LV sometimes operates on a sub LV rather than
-the specified LV. In other cases, a sub LV must be specified directly on
-the command line.
-
Striped raid types are
-.B raid0/raid0_meta
-,
-.B raid5
-(an alias for raid5_ls),
-.B raid6
-(an alias for raid6_zr) and
-.B raid10
-(an alias for raid10_near).
+\fBraid0/raid0_meta\fP,
+\fBraid5\fP (an alias for raid5_ls),
+\fBraid6\fP (an alias for raid6_zr) and
+\fBraid10\fP (an alias for raid10_near).
As opposed to mirroring, raid5 and raid6 stripe data and calculate parity
-blocks. The parity blocks can be used for data block recovery in case devices
-fail. A maximum number of one device in a raid5 LV may fail and two in case
-of raid6. Striped raid types typically rotate the parity blocks for performance
-reasons thus avoiding contention on a single device. Layouts of raid5 rotating
-parity blocks can be one of left-asymmetric (raid5_la), left-symmetric (raid5_ls
-with alias raid5), right-asymmetric (raid5_ra), right-symmetric (raid5_rs) and raid5_n,
-which doesn't rotate parity blocks. Any \"_n\" layouts allow for conversion between
-raid levels (raid5_n -> raid6 or raid5_n -> striped/raid0/raid0_meta).
-raid6 layouts are zero-restart (raid6_zr with alias raid6), next-restart (raid6_nr),
-next-continue (raid6_nc). Additionally, special raid6 layouts for raid level conversions
-between raid5 and raid6 are raid6_ls_6, raid6_rs_6, raid6_la_6 and raid6_ra_6. Those
-correspond to their raid5 counterparts (e.g. raid5_rs can be directly converted to raid6_rs_6
-and vice-versa).
-raid10 (an alias for raid10_near) is currently limited to one data copy and even number of
-sub LVs. This is a mirror group layout thus a single sub LV may fail per mirror group
-without data loss.
-Striped raid types support converting the layout, their stripesize
-and their number of stripes.
-
-The striped raid types combined with raid1 allow for conversion from linear -> striped/raid0/raid0_meta
-and vice-versa by e.g. linear <-> raid1 <-> raid5_n (then adding stripes) <-> striped/raid0/raid0_meta.
-
-Sub LVs can be displayed with the command
-.B lvs -a
+blocks. The parity blocks can be used for data block recovery in case
+devices fail. A maximum number of one device in a raid5 LV may fail, and
+two in case of raid6. Striped raid types typically rotate the parity and
+data blocks for performance reasons, thus avoiding contention on a single
+device. Specific arrangements of parity and data blocks (layouts) can be
+used to optimize I/O performance, or to convert between raid levels. See
+\fBlvmraid\fP(7) for more information.
+
+Layouts of raid5 rotating parity blocks can be: left-asymmetric
+(raid5_la), left-symmetric (raid5_ls with alias raid5), right-asymmetric
+(raid5_ra), right-symmetric (raid5_rs) and raid5_n, which doesn't rotate
+parity blocks. Layouts of raid6 are: zero-restart (raid6_zr with alias
+raid6), next-restart (raid6_nr), and next-continue (raid6_nc).
+
+Layouts including _n allow for conversion between raid levels (raid5_n to
+raid6 or raid5_n to striped/raid0/raid0_meta). Additionally, special raid6
+layouts for raid level conversions between raid5 and raid6 are:
+raid6_ls_6, raid6_rs_6, raid6_la_6 and raid6_ra_6. Those correspond to
+their raid5 counterparts (e.g. raid5_rs can be directly converted to
+raid6_rs_6 and vice-versa).
+
+raid10 (an alias for raid10_near) is currently limited to one data copy
+and even number of sub LVs. This is a mirror group layout, thus a single
+sub LV may fail per mirror group without data loss.
+
+Striped raid types support converting the layout, their stripesize and
+their number of stripes.
+
+The striped raid types combined with raid1 allow for conversion from
+linear -> striped/raid0/raid0_meta and vice-versa by e.g. linear <-> raid1
+<-> raid5_n (then adding stripes) <-> striped/raid0/raid0_meta.
.SH USAGE
Convert LV to linear.
.br
diff --git a/man/lvcreate.8_pregen b/man/lvcreate.8_pregen
index 6663087..38edc85 100644
--- a/man/lvcreate.8_pregen
+++ b/man/lvcreate.8_pregen
@@ -244,9 +244,9 @@ lvcreate - Create a logical volume
.SH DESCRIPTION
lvcreate creates a new LV in a VG. For standard LVs, this requires
allocating logical extents from the VG's free physical extents. If there
-is not enough free space, then the VG can be extended (see
-\fBvgextend\fP(8)) with other PVs, or existing LVs can be reduced or
-removed (see \fBlvremove\fP, \fBlvreduce\fP.)
+is not enough free space, the VG can be extended with other PVs
+(\fBvgextend\fP(8)), or existing LVs can be reduced or removed
+(\fBlvremove\fP(8), \fBlvreduce\fP(8).)
To control which PVs a new LV will use, specify one or more PVs as
position args at the end of the command line. lvcreate will allocate
@@ -263,7 +263,7 @@ unique PVs be available in the VG for allocation.
Thin pools (for thin provisioning) and cache pools (for caching) are
represented by special LVs with types thin-pool and cache-pool (see
\fBlvmthin\fP(7) and \fBlvmcache\fP(7)). The pool LVs are not usable as
-standard block devices, but the LV names act references to the pools.
+standard block devices, but the LV names act as references to the pools.
Thin LVs are thinly provisioned from a thin pool, and are created with a
virtual size rather than a physical size. A cache LV is the combination of
@@ -271,13 +271,12 @@ a standard LV with a cache pool, used to cache active portions of the LV
to improve performance.
.SS Usage notes
In the usage section below, \fB--size\fP \fISize\fP can be replaced
-with \fB--extents\fP \fINumber\fP. See both descriptions
-the options section.
+with \fB--extents\fP \fINumber\fP. See descriptions in the options section.
In the usage section below, \fB--name\fP is omitted from the required
-options, even though it is typically used. When the name is not
+options, even though it is typically used. When the name is not
specified, a new LV name is generated with the "lvol" prefix and a unique
-numeric suffix. Also see the description in the options section.
+numeric suffix.
.SH USAGE
Create a linear LV.
.br
diff --git a/man/lvdisplay.8_pregen b/man/lvdisplay.8_pregen
index 25ce5b8..49de9cf 100644
--- a/man/lvdisplay.8_pregen
+++ b/man/lvdisplay.8_pregen
@@ -48,10 +48,6 @@ and more, using a more compact and configurable output format.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -343,15 +339,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/lvm-fullreport.8_pregen b/man/lvm-fullreport.8_pregen
index bfc5cd3..11ba4b8 100644
--- a/man/lvm-fullreport.8_pregen
+++ b/man/lvm-fullreport.8_pregen
@@ -29,10 +29,6 @@ if information changes between commands.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -325,15 +321,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/lvs.8_pregen b/man/lvs.8_pregen
index 2ac6f3f..31244e2 100644
--- a/man/lvs.8_pregen
+++ b/man/lvs.8_pregen
@@ -28,10 +28,6 @@ lvs produces formatted output about LVs.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -339,15 +335,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/lvscan.8_pregen b/man/lvscan.8_pregen
index a2c32a0..12211b2 100644
--- a/man/lvscan.8_pregen
+++ b/man/lvscan.8_pregen
@@ -45,10 +45,6 @@ Common options for command:
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB--ignorelockingfailure\fP ]
.ad b
.br
@@ -184,15 +180,6 @@ Display long help text.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/pvs.8_pregen b/man/pvs.8_pregen
index d6afbb9..d0742df 100644
--- a/man/pvs.8_pregen
+++ b/man/pvs.8_pregen
@@ -24,10 +24,6 @@ pvs produces formatted output about PVs.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -326,15 +322,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/vgcfgbackup.8_pregen b/man/vgcfgbackup.8_pregen
index b3f41af..d085a34 100644
--- a/man/vgcfgbackup.8_pregen
+++ b/man/vgcfgbackup.8_pregen
@@ -35,10 +35,6 @@ It may also be useful to regularly back up the files in
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB--foreign\fP ]
.ad b
.br
@@ -179,15 +175,6 @@ Display long help text.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/vgchange.8_pregen b/man/vgchange.8_pregen
index df5c946..d3514b9 100644
--- a/man/vgchange.8_pregen
+++ b/man/vgchange.8_pregen
@@ -270,6 +270,10 @@ required, after which the others are optional.
.RE
.br
.RS 4
+.ad l
+[ \fB--poll\fP \fBy\fP|\fBn\fP ]
+.ad b
+.br
[ COMMON_OPTIONS ]
.RE
.br
@@ -379,10 +383,6 @@ Reactivate LVs using the latest metadata.
.ad b
.br
.ad l
-[ \fB--monitor\fP \fBy\fP|\fBn\fP ]
-.ad b
-.br
-.ad l
[ \fB--poll\fP \fBy\fP|\fBn\fP ]
.ad b
.br
@@ -761,10 +761,10 @@ ignore the devices LVM creates.
.ad l
\fB-P\fP|\fB--partial\fP
.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
+Commands will do their best to activate LVs with missing PV extents.
+Missing extents may be replaced with error or zero segments
+according to the lvm.conf missing_stripe_filler setting.
+Metadata may not be changed with this option.
.ad b
.HP
.ad l
diff --git a/man/vgdisplay.8_pregen b/man/vgdisplay.8_pregen
index 2aa9188..a9a9463 100644
--- a/man/vgdisplay.8_pregen
+++ b/man/vgdisplay.8_pregen
@@ -35,10 +35,6 @@ and more, using a more compact and configurable output format.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -317,15 +313,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/vgs.8_pregen b/man/vgs.8_pregen
index 012697c..b621666 100644
--- a/man/vgs.8_pregen
+++ b/man/vgs.8_pregen
@@ -24,10 +24,6 @@ vgs produces formatted output about VGs.
.ad b
.br
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB-S\fP|\fB--select\fP \fIString\fP ]
.ad b
.br
@@ -321,15 +317,6 @@ See lvmreport(7) for more information about reporting.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
diff --git a/man/vgscan.8_pregen b/man/vgscan.8_pregen
index 011747c..df36e3a 100644
--- a/man/vgscan.8_pregen
+++ b/man/vgscan.8_pregen
@@ -14,10 +14,6 @@ vgscan scans all supported LVM block devices in the system for VGs.
.br
.RS 4
.ad l
-[ \fB-P\fP|\fB--partial\fP ]
-.ad b
-.br
-.ad l
[ \fB--cache\fP ]
.ad b
.br
@@ -165,15 +161,6 @@ notify_dbus config setting is disabled.
.ad b
.HP
.ad l
-\fB-P\fP|\fB--partial\fP
-.br
-When set, the tools will do their best to provide access to VGs
-that are only partially available (one or more PVs belonging
-to the VG are missing from the system). Metadata may not be
-changed with this option.
-.ad b
-.HP
-.ad l
\fB--profile\fP \fIString\fP
.br
An alias for --commandprofile or --metadataprofile, depending
7 years
master - tests: use egrep to check for message
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=a3e8354479f2b6c3d35...
Commit: a3e8354479f2b6c3d35fdc992d4114b244326833
Parent: 59d54d70e73f2ba60a0714a04af3699c23503761
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Apr 12 22:52:56 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 23:05:50 2017 +0200
tests: use egrep to check for message
Seems we may get different '' around option on different nixes.
---
test/shell/vgextend-restoremissing.sh | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/test/shell/vgextend-restoremissing.sh b/test/shell/vgextend-restoremissing.sh
index 7f8fee0..d94eb5c 100644
--- a/test/shell/vgextend-restoremissing.sh
+++ b/test/shell/vgextend-restoremissing.sh
@@ -24,7 +24,7 @@ invalid vgextend
# --metadatacopies => use --pvmetadatacopies
invalid vgextend --metadatacopies 3 $vg "$dev1" 2>&1 | tee out
#grep -- "use --pvmetadatacopies" out
-grep -- "unrecognized option '--metadatacopies'" out
+egrep -- "unrecognized option.*--metadatacopies" out
# VG name should exist
fail vgextend --restoremissing $vg-invalid "$dev1"
7 years
master - tests: aux defines fsadm path
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=59d54d70e73f2ba60a0...
Commit: 59d54d70e73f2ba60a0714a04af3699c23503761
Parent: 1e64386dc69a0e13404eefc2deb0c3908632457c
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Apr 12 23:03:08 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 23:05:50 2017 +0200
tests: aux defines fsadm path
---
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 bc10b44..214db4e 100644
--- a/test/lib/aux.sh
+++ b/test/lib/aux.sh
@@ -1156,6 +1156,7 @@ global/thin_repair_executable = "$LVM_TEST_THIN_REPAIR_CMD"
global/use_lvmetad = $LVM_TEST_LVMETAD
global/use_lvmpolld = $LVM_TEST_LVMPOLLD
global/use_lvmlockd = $LVM_TEST_LVMLOCKD
+global/fsadm_executable = "$TESTDIR/lib/fsadm"
log/activation = 1
log/file = "$TESTDIR/debug.log"
log/indent = 1
7 years
master - raid: use log_error
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=1e64386dc69a0e13404...
Commit: 1e64386dc69a0e13404eefc2deb0c3908632457c
Parent: 1f715ab3b20f3e2589fa547428e84134349465da
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Apr 12 23:05:09 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 23:05:50 2017 +0200
raid: use log_error
Turn log_print into log_error for error path.
---
lib/metadata/raid_manip.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/metadata/raid_manip.c b/lib/metadata/raid_manip.c
index 35f7fa5..34ac2a6 100644
--- a/lib/metadata/raid_manip.c
+++ b/lib/metadata/raid_manip.c
@@ -2225,8 +2225,8 @@ static int _raid_reshape(struct logical_volume *lv,
log_print_unless_silent("No change in RAID LV %s layout, freeing reshape space.", display_lvname(lv));
if (where_it_was == alloc_none) {
- log_print_unless_silent("LV %s does not have reshape space allocated.",
- display_lvname(lv));
+ log_error("LV %s does not have reshape space allocated.",
+ display_lvname(lv));
return 0;
}
7 years
master - lvconvert: return error without conversion
by Heinz Mauelshagen
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=1f715ab3b20f3e2589f...
Commit: 1f715ab3b20f3e2589fa547428e84134349465da
Parent: 56704383bfded631ea16707e598e38df93dfaab5
Author: Heinz Mauelshagen <heinzm(a)redhat.com>
AuthorDate: Wed Apr 12 22:11:30 2017 +0200
Committer: Heinz Mauelshagen <heinzm(a)redhat.com>
CommitterDate: Wed Apr 12 22:11:30 2017 +0200
lvconvert: return error without conversion
lvconvert parameters not causing a conversion (i.e. no type,
number of stripes, stripesize or regionsize changes) will
remove any allocated reshape space in which case the command
returns success. If reshape space does not exist though,
return error.
---
lib/metadata/raid_manip.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/lib/metadata/raid_manip.c b/lib/metadata/raid_manip.c
index d16d49f..35f7fa5 100644
--- a/lib/metadata/raid_manip.c
+++ b/lib/metadata/raid_manip.c
@@ -2227,7 +2227,7 @@ static int _raid_reshape(struct logical_volume *lv,
if (where_it_was == alloc_none) {
log_print_unless_silent("LV %s does not have reshape space allocated.",
display_lvname(lv));
- return 1;
+ return 0;
}
if (!_lv_update_reload_fns_reset_eliminate_lvs(lv, 0, NULL, NULL))
7 years
master - tests: test for new supported commands
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=56704383bfded631ea1...
Commit: 56704383bfded631ea16707e598e38df93dfaab5
Parent: f8034e14e6c8012dbd51dc3c5e5fc1c0036e00a0
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Wed Apr 12 15:01:12 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 21:34:08 2017 +0200
tests: test for new supported commands
New tests for:
lvconvert --regionsize | --swapmetadata | --startpoll |
--mergesnapshot | mergethin
---
test/shell/lvconvert-cache.sh | 4 ++++
test/shell/lvconvert-mirror.sh | 15 +++++++++++++++
test/shell/lvconvert-raid-regionsize.sh | 5 ++++-
test/shell/lvconvert-thin.sh | 4 ++++
test/shell/snapshot-merge.sh | 3 +++
test/shell/thin-merge.sh | 7 +++++++
6 files changed, 37 insertions(+), 1 deletions(-)
diff --git a/test/shell/lvconvert-cache.sh b/test/shell/lvconvert-cache.sh
index 6a8daa3..b1ac154 100644
--- a/test/shell/lvconvert-cache.sh
+++ b/test/shell/lvconvert-cache.sh
@@ -63,6 +63,10 @@ UUID=$(get lv_field $vg/$lv5 uuid)
lvconvert --yes --cachepool $vg/$lv3 --poolmetadata $lv5
check lv_field $vg/${lv3}_cmeta uuid "$UUID"
+# Check swap of cache pool metadata with --swapmetadata
+# (should swap back to lv5)
+lvconvert --yes --swapmetadata $vg/$lv3 --poolmetadata $lv5
+check lv_field $vg/$lv5 uuid "$UUID"
#fail lvconvert --cachepool $vg/$lv1 --poolmetadata $vg/$lv2
#lvconvert --yes --type cache-pool --poolmetadata $vg/$lv2 $vg/$lv1
diff --git a/test/shell/lvconvert-mirror.sh b/test/shell/lvconvert-mirror.sh
index 7e8d663..86ae0e3 100644
--- a/test/shell/lvconvert-mirror.sh
+++ b/test/shell/lvconvert-mirror.sh
@@ -216,6 +216,21 @@ check mirror_no_temporaries $vg $lv1
check mirror_legs $vg $lv1 2
lvremove -ff $vg
+# Check the same with new --startpool lvconvert command option
+lvcreate -aey -l2 --type mirror -m1 -n $lv1 $vg "$dev1" "$dev2" "$dev3:$DEVRANGE"
+LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+1 -b $vg/$lv1 "$dev4"
+# FIXME: Extra wait here for mirror upconvert synchronization
+# otherwise we may fail her on parallel upconvert and downconvert
+# lvconvert-mirror-updown.sh tests this errornous case separately
+should lvconvert --startpoll $vg/$lv1
+lvconvert -m-1 $vg/$lv1 "$dev2"
+should lvconvert --startpoll $vg/$lv1
+
+check mirror $vg $lv1 "$dev3"
+check mirror_no_temporaries $vg $lv1
+check mirror_legs $vg $lv1 2
+lvremove -ff $vg
+
# ---------------------------------------------------------------------
# "rhbz440405: lvconvert -m0 incorrectly fails if all PEs allocated"
diff --git a/test/shell/lvconvert-raid-regionsize.sh b/test/shell/lvconvert-raid-regionsize.sh
index 7a6c7f0..9884c1b 100644
--- a/test/shell/lvconvert-raid-regionsize.sh
+++ b/test/shell/lvconvert-raid-regionsize.sh
@@ -28,8 +28,11 @@ function _test_regionsize
local lv=$5
lvconvert --type $type --yes -R $regionsize $vg/$lv
- [ $? -ne 0 ] && return 1
check lv_field $vg/$lv regionsize "$regionsize_str"
+
+ not lvconvert --regionsize $regionsize $vg/$lv 2>err
+ grep "is already" err
+
fsck -fn "$DM_DEV_DIR/$vg/$lv"
}
diff --git a/test/shell/lvconvert-thin.sh b/test/shell/lvconvert-thin.sh
index c73c648..c08b95a 100644
--- a/test/shell/lvconvert-thin.sh
+++ b/test/shell/lvconvert-thin.sh
@@ -88,6 +88,10 @@ fail lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $lv2
lvchange -an $vg
lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $lv2
check lv_field $vg/${lv1}_tmeta uuid "$UUID"
+
+# and swap again with new command --swapmetadata
+lvconvert --yes --swapmetadata $vg/$lv1 --poolmetadata $lv2
+check lv_field $vg/$lv2 uuid "$UUID"
lvremove -f $vg
diff --git a/test/shell/snapshot-merge.sh b/test/shell/snapshot-merge.sh
index a301d22..bdbbdba 100644
--- a/test/shell/snapshot-merge.sh
+++ b/test/shell/snapshot-merge.sh
@@ -56,6 +56,9 @@ not lvconvert --merge
lvconvert --merge $vg/$(snap_lv_name_ $lv1)
lvremove -f $vg/$lv1
+setup_merge_ $vg $lv1
+lvconvert --mergesnapshot $vg/$(snap_lv_name_ $lv1)
+lvremove -f $vg/$lv1
# test that an actively merging snapshot may not be removed
setup_merge_ $vg $lv1
diff --git a/test/shell/thin-merge.sh b/test/shell/thin-merge.sh
index f044f57..9955aab 100644
--- a/test/shell/thin-merge.sh
+++ b/test/shell/thin-merge.sh
@@ -109,5 +109,12 @@ check lv_not_exists $vg oldsnapof_${lv1}
lvcreate -s -L10 -n oldsnapof_snap $vg/snap
lvconvert --merge $vg/snap
lvremove -f $vg/oldsnapof_snap
+check lv_field $vg/$lv1 thin_id "3"
+
+# Check --mergethin
+lvcreate -s -n snap $vg/$lv1
+check lv_field $vg/snap thin_id "4"
+lvconvert --mergethin $vg/snap
+check lv_field $vg/$lv1 thin_id "4"
vgremove -ff $vg
7 years
master - tests: restore some test changes
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=f8034e14e6c8012dbd5...
Commit: f8034e14e6c8012dbd51dc3c5e5fc1c0036e00a0
Parent: 3018cdcaa7aa258a432738b95077098985fb0c74
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Mon Apr 3 15:57:32 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 21:34:08 2017 +0200
tests: restore some test changes
Restore existing tests and separate new tests
for new options later.
Keep coverage for existing syntax
Reverts bits from commits:
a801b92b2c81213dddccc9f9a09794208f92bfc9.
d71aaca07b2c14049130ab368221510c65236af7
fa2a728a395639a32707bb75e6bb4197b02769de
1e2420bca85da9a37570871cd70192e9ae831786
46abc28a480069b3e8b2c5c7c3448ffa25ec17ba
0e3e611a137a264a343335d18d500fce7af8e0f7
---
test/shell/lvconvert-cache-snapshot.sh | 2 +-
test/shell/lvconvert-cache.sh | 44 ++++++++++---------
test/shell/lvconvert-mirror.sh | 18 ++++----
test/shell/lvconvert-repair-thin.sh | 8 ++--
test/shell/lvconvert-thin-raid.sh | 6 ++-
test/shell/lvconvert-thin.sh | 25 ++++++-----
test/shell/lvcreate-cache.sh | 3 +-
test/shell/lvextend-thin-full.sh | 2 +-
test/shell/lvextend-thin-metadata-dmeventd.sh | 12 +++---
.../shell/lvmetad-pvscan-autoactivation-polling.sh | 2 +-
test/shell/snapshot-merge-stack.sh | 2 +-
test/shell/snapshot-merge.sh | 16 ++++----
test/shell/thin-flags.sh | 2 +-
test/shell/thin-merge.sh | 6 +-
test/shell/thin-vglock.sh | 2 +-
test/shell/vgextend-restoremissing.sh | 2 +
16 files changed, 81 insertions(+), 71 deletions(-)
diff --git a/test/shell/lvconvert-cache-snapshot.sh b/test/shell/lvconvert-cache-snapshot.sh
index 4ecec70..8f0ab53 100644
--- a/test/shell/lvconvert-cache-snapshot.sh
+++ b/test/shell/lvconvert-cache-snapshot.sh
@@ -33,7 +33,7 @@ lvcreate -L3 -n cow $vg
not lvconvert -s cow $vg/$lv1
# Use cached LV with 'striped' cow volume
-lvconvert -y -s $vg/$lv1 $vg/cow
+lvconvert -y -s $vg/$lv1 cow
check lv_field $vg/cow segtype linear
check lv_field $vg/$lv1 segtype cache
diff --git a/test/shell/lvconvert-cache.sh b/test/shell/lvconvert-cache.sh
index 5263028..6a8daa3 100644
--- a/test/shell/lvconvert-cache.sh
+++ b/test/shell/lvconvert-cache.sh
@@ -60,7 +60,7 @@ check lv_field $vg/$lv2 cache_settings "random_threshold=56,sequential_threshold
# Check swap of cache pool metadata
lvconvert --yes --type cache-pool --poolmetadata $lv4 $vg/$lv3
UUID=$(get lv_field $vg/$lv5 uuid)
-lvconvert --yes --swapmetadata --poolmetadata $lv5 $vg/$lv3
+lvconvert --yes --cachepool $vg/$lv3 --poolmetadata $lv5
check lv_field $vg/${lv3}_cmeta uuid "$UUID"
@@ -108,30 +108,32 @@ lvcreate -an -Zn -L 8 -n $lv4 $vg
invalid lvconvert --type cache --poolmetadata $vg/$lv2 $vg/$lv1
# Cannot mix with thins
-not lvconvert --type cache --poolmetadata $vg/$lv2 --thinpool $vg/$lv1
-not lvconvert --type cache --thin --poolmetadata $vg/$lv2 $vg/$lv1
+invalid lvconvert --type cache --poolmetadata $vg/$lv2 --thinpool $vg/$lv1
+invalid lvconvert --type cache --thin --poolmetadata $vg/$lv2 $vg/$lv1
# Undefined cached volume
-not lvconvert --type cache --cachepool $vg/$lv1
-not lvconvert --cache --cachepool $vg/$lv1
+invalid lvconvert --type cache --cachepool $vg/$lv1
+invalid lvconvert --cache --cachepool $vg/$lv1
+# FIXME: temporarily we return error code 5
+INVALID=not
# Single vg is required
-not lvconvert --type cache --cachepool $vg/$lv1 --poolmetadata $vg1/$lv2 $vg/$lv3
-not lvconvert --type cache --cachepool $vg/$lv1 --poolmetadata $lv2 $vg1/$lv3
-not lvconvert --type cache --cachepool $vg1/$lv1 --poolmetadata $vg2/$lv2 $vg/$lv3
-not lvconvert --type cache-pool --poolmetadata $vg2/$lv2 $vg1/$lv1
+$INVALID lvconvert --type cache --cachepool $vg/$lv1 --poolmetadata $vg1/$lv2 $vg/$lv3
+$INVALID lvconvert --type cache --cachepool $vg/$lv1 --poolmetadata $lv2 $vg1/$lv3
+$INVALID lvconvert --type cache --cachepool $vg1/$lv1 --poolmetadata $vg2/$lv2 $vg/$lv3
+$INVALID lvconvert --type cache-pool --poolmetadata $vg2/$lv2 $vg1/$lv1
-not lvconvert --cachepool $vg1/$lv1 --poolmetadata $vg2/$lv2
+$INVALID lvconvert --cachepool $vg1/$lv1 --poolmetadata $vg2/$lv2
# Invalid syntax, vg is unknown
-not lvconvert --yes --cachepool $lv3 --poolmetadata $lv4
+$INVALID lvconvert --yes --cachepool $lv3 --poolmetadata $lv4
# Invalid chunk size is <32KiB >1GiB
-not lvconvert --type cache-pool --chunksize 16 --poolmetadata $lv2 $vg/$lv1
-not lvconvert --type cache-pool --chunksize 2G --poolmetadata $lv2 $vg/$lv1
+$INVALID lvconvert --type cache-pool --chunksize 16 --poolmetadata $lv2 $vg/$lv1
+$INVALID lvconvert --type cache-pool --chunksize 2G --poolmetadata $lv2 $vg/$lv1
# Invalid chunk size is bigger then data size, needs to open VG
-not lvconvert --yes --type cache-pool --chunksize 16M --poolmetadata $lv2 $vg/$lv1
+fail lvconvert --yes --type cache-pool --chunksize 16M --poolmetadata $lv2 $vg/$lv1
lvremove -f $vg
@@ -142,7 +144,7 @@ lvcreate --type cache-pool -an -v -L 2 -n cpool $vg
lvcreate -H -L 4 -n corigin --cachepool $vg/cpool
# unsupported yet
-not lvconvert --repair $vg/cpool 2>&1 | tee out
+fail lvconvert --repair $vg/cpool 2>&1 | tee out
#grep "Cannot convert internal LV" out
lvremove -f $vg
@@ -154,13 +156,13 @@ lvcreate --type cache-pool -L10 $vg/$lv1
lvcreate --cache -L20 $vg/$lv1
lvcreate -L10 -n $lv2 $vg
-not lvconvert --yes --type cache $vg/$lv2 --cachepool $vg/$lv1
-not lvconvert --yes --type cache $vg/$lv1 --cachepool $vg/$lv2
-not lvconvert --yes --type cache-pool $vg/$lv1
-not lvconvert --yes --type mirror -m1 $vg/$lv1
+fail lvconvert --yes --type cache $vg/$lv2 --cachepool $vg/$lv1
+fail lvconvert --yes --type cache $vg/$lv1 --cachepool $vg/$lv2
+fail lvconvert --yes --type cache-pool $vg/$lv1
+fail lvconvert --yes --type mirror -m1 $vg/$lv1
not aux have_raid 1 0 0 || fail lvconvert --yes --type raid1 -m1 $vg/$lv1
-not lvconvert --yes --type snapshot $vg/$lv1 $vg/$lv2
-not lvconvert --yes --type snapshot $vg/$lv2 $vg/$lv1
+fail lvconvert --yes --type snapshot $vg/$lv1 $vg/$lv2
+fail lvconvert --yes --type snapshot $vg/$lv2 $vg/$lv1
not aux have_thin 1 0 0 || fail lvconvert --yes -T --thinpool $vg/$lv2 $vg/$lv1
lvremove -f $vg
diff --git a/test/shell/lvconvert-mirror.sh b/test/shell/lvconvert-mirror.sh
index 1f059ca..7e8d663 100644
--- a/test/shell/lvconvert-mirror.sh
+++ b/test/shell/lvconvert-mirror.sh
@@ -87,7 +87,7 @@ aux delay_dev "$dev2" 0 2000 ${offset}:1
lvcreate -aey -l5 -Zn -Wn --type mirror --regionsize 16K -m2 -n $lv1 $vg "$dev1" "$dev2" "$dev4" "$dev3:$DEVRANGE"
should not lvconvert -m-1 $vg/$lv1 "$dev1"
aux enable_dev "$dev2"
-lvconvert --startpoll $vg/$lv1 || true # wait
+should lvconvert $vg/$lv1 # wait
lvconvert -m2 $vg/$lv1 "$dev1" "$dev2" "$dev4" "$dev3:0" # If the above "should" failed...
aux wait_for_sync $vg $lv1
@@ -113,7 +113,7 @@ LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+1 -b $vg/$lv1 "$dev4"
# Next convert should fail b/c we can't have 2 at once
should not lvconvert -m+1 $vg/$lv1 "$dev5"
aux enable_dev "$dev4"
-lvconvert --startpoll $vg/$lv1 || true # wait
+should lvconvert $vg/$lv1 # wait
lvconvert -m2 $vg/$lv1 # In case the above "should" actually failed
check mirror $vg $lv1 "$dev3"
@@ -156,7 +156,7 @@ lvcreate -aey -l2 --type mirror -m1 -n $lv1 $vg "$dev1" "$dev2" "$dev3:$DEVRANGE
lvchange -an $vg/$lv1
lvconvert -m+1 $vg/$lv1 "$dev4"
lvchange -aey $vg/$lv1
-lvconvert --startpoll $vg/$lv1 || true # wait
+should lvconvert $vg/$lv1 # wait
check mirror $vg $lv1 "$dev3"
check mirror_no_temporaries $vg $lv1
lvremove -ff $vg
@@ -168,7 +168,7 @@ lvremove -ff $vg
lvcreate -aey -l2 --type mirror -m1 -n $lv1 $vg "$dev1" "$dev2" "$dev3:$DEVRANGE"
LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+1 -b $vg/$lv1 "$dev4"
lvconvert -m-1 $vg/$lv1 "$dev4"
-lvconvert --startpoll $vg/$lv1 || true # wait
+should lvconvert $vg/$lv1 # wait
check mirror $vg $lv1 "$dev3"
check mirror_no_temporaries $vg $lv1
@@ -179,7 +179,7 @@ lvremove -ff $vg
lvcreate -aey -l2 --type mirror -m1 -n $lv1 $vg "$dev1" "$dev2" "$dev3:$DEVRANGE"
LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+2 -b $vg/$lv1 "$dev4" "$dev5"
lvconvert -m-1 $vg/$lv1 "$dev4"
-lvconvert --startpoll $vg/$lv1 || true # wait
+should lvconvert $vg/$lv1 # wait
check mirror $vg $lv1 "$dev3"
check mirror_no_temporaries $vg $lv1
@@ -192,9 +192,9 @@ LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+1 -b $vg/$lv1 "$dev4"
# FIXME: Extra wait here for mirror upconvert synchronization
# otherwise we may fail her on parallel upconvert and downconvert
# lvconvert-mirror-updown.sh tests this errornous case separately
-lvconvert --startpoll $vg/$lv1 || true
+should lvconvert $vg/$lv1
lvconvert -m-1 $vg/$lv1 "$dev2"
-lvconvert --startpoll $vg/$lv1 || true
+should lvconvert $vg/$lv1
check mirror $vg $lv1 "$dev3"
check mirror_no_temporaries $vg $lv1
@@ -207,9 +207,9 @@ LVM_TEST_TAG="kill_me_$PREFIX" lvconvert -m+1 -b $vg/$lv1 "$dev4"
# FIXME: Extra wait here for mirror upconvert synchronization
# otherwise we may fail her on parallel upconvert and downconvert
# lvconvert-mirror-updown.sh tests this errornous case separately
-lvconvert --startpoll $vg/$lv1 || true
+should lvconvert $vg/$lv1
lvconvert -m-1 $vg/$lv1 "$dev2"
-lvconvert --startpoll $vg/$lv1 || true
+should lvconvert $vg/$lv1
check mirror $vg $lv1 "$dev3"
check mirror_no_temporaries $vg $lv1
diff --git a/test/shell/lvconvert-repair-thin.sh b/test/shell/lvconvert-repair-thin.sh
index 923b9c8..8930894 100644
--- a/test/shell/lvconvert-repair-thin.sh
+++ b/test/shell/lvconvert-repair-thin.sh
@@ -45,7 +45,7 @@ lvchange -an $vg/$lv2 $vg/$lv1 $vg/pool $vg/repair
# Manual repair steps:
# Test swapping - swap out thin-pool's metadata with our repair volume
-lvconvert -y -f --swapmetadata --poolmetadata $vg/repair $vg/pool
+lvconvert -y -f --poolmetadata $vg/repair --thinpool $vg/pool
lvchange -ay $vg/repair
@@ -74,7 +74,7 @@ not "$LVM_TEST_THIN_DUMP_CMD" "$DM_DEV_DIR/$vg/repair" | tee dump
lvchange -an $vg
# Swap repaired metadata back
-lvconvert -y -f --swapmetadata --poolmetadata $vg/fixed $vg/pool
+lvconvert -y -f --poolmetadata $vg/fixed --thinpool $vg/pool
# Check pool still preserves its original settings
check lv_field $vg/pool chunksize "128.00k"
@@ -87,7 +87,7 @@ vgchange -ay $vg
vgchange -an $vg
# Put back 'broken' metadata
-lvconvert -y -f --swapmetadata --poolmetadata $vg/repair $vg/pool
+lvconvert -y -f --poolmetadata $vg/repair --thinpool $vg/pool
# Check --repair usage
lvconvert -v --repair $vg/pool
@@ -98,7 +98,7 @@ lvchange -ay $vg/pool
vgchange -an $vg
# Restore damaged metadata
-lvconvert -y -f --swapmetadata --poolmetadata $vg/pool_meta0 $vg/pool
+lvconvert -y -f --poolmetadata $vg/pool_meta0 --thinpool $vg/pool
# Check lvremove -ff works even with damaged pool
lvremove -ff $vg
diff --git a/test/shell/lvconvert-thin-raid.sh b/test/shell/lvconvert-thin-raid.sh
index 807b1dc..b243a55 100644
--- a/test/shell/lvconvert-thin-raid.sh
+++ b/test/shell/lvconvert-thin-raid.sh
@@ -29,9 +29,11 @@ aux wait_for_sync $vg $lv1
aux wait_for_sync $vg $lv2
lvchange -an $vg/$lv1
+# FIXME: temporarily we return error code 5
+INVALID=not
# conversion fails for internal volumes
-not lvconvert --thinpool $vg/${lv1}_rimage_0
-not lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $vg/${lv2}_rimage_0
+$INVALID lvconvert --thinpool $vg/${lv1}_rimage_0
+$INVALID lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $vg/${lv2}_rimage_0
lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
diff --git a/test/shell/lvconvert-thin.sh b/test/shell/lvconvert-thin.sh
index 2a54614..c73c648 100644
--- a/test/shell/lvconvert-thin.sh
+++ b/test/shell/lvconvert-thin.sh
@@ -57,14 +57,17 @@ lvchange -an $vg/$lv1
# conversion fails for mirror segment type
fail lvconvert --thinpool $vg/$lv1
+
+# FIXME: temporarily we return error code 5
+INVALID=not
# cannot use same LV
-not lvconvert --yes --thinpool $vg/$lv2 --poolmetadata $vg/$lv2
+$INVALID lvconvert --yes --thinpool $vg/$lv2 --poolmetadata $vg/$lv2
prepare_lvs
# conversion fails for internal volumes
# can't use --readahead with --poolmetadata
-not lvconvert --thinpool $vg/$lv1 --poolmetadata $vg/$lv2 --readahead 512
+invalid lvconvert --thinpool $vg/$lv1 --poolmetadata $vg/$lv2 --readahead 512
lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
prepare_lvs
@@ -81,9 +84,9 @@ grep "Pool zeroing and large" err
UUID=$(get lv_field $vg/$lv2 uuid)
# Fail is pool is active
# TODO maybe detect inactive pool and deactivate
-fail lvconvert --swapmetadata --yes --poolmetadata $lv2 $vg/$lv1
+fail lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $lv2
lvchange -an $vg
-lvconvert --swapmetadata --yes --poolmetadata $lv2 $vg/$lv1
+lvconvert --yes --thinpool $vg/$lv1 --poolmetadata $lv2
check lv_field $vg/${lv1}_tmeta uuid "$UUID"
lvremove -f $vg
@@ -96,20 +99,20 @@ lvcreate -L1M -n $lv3 $vg
# chunk size is bigger then size of thin pool data
fail lvconvert --yes -c 1G --thinpool $vg/$lv3
# stripes can't be used with poolmetadata
-not lvconvert --stripes 2 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
+invalid lvconvert --stripes 2 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
# too small metadata (<2M)
fail lvconvert --yes -c 64 --thinpool $vg/$lv1 --poolmetadata $vg/$lv3
# too small chunk size fails
-not lvconvert -c 4 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
+$INVALID lvconvert -c 4 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
# too big chunk size fails
-not lvconvert -c 2G --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
+$INVALID lvconvert -c 2G --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
# negative chunk size fails
-not lvconvert -c -256 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
+$INVALID lvconvert -c -256 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
# non multiple of 64KiB fails
-not lvconvert -c 88 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
+$INVALID lvconvert -c 88 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2
# cannot use same LV for pool and convertion
-not lvconvert --yes --thinpool $vg/$lv3 -T $vg/$lv3
+$INVALID lvconvert --yes --thinpool $vg/$lv3 -T $vg/$lv3
# Warning about smaller then suggested
lvconvert --yes -c 256 --thinpool $vg/$lv1 --poolmetadata $vg/$lv2 2>&1 | tee err
@@ -129,7 +132,7 @@ if test "$TSIZE" = 64T; then
lvcreate -L24T -n $lv1 $vg
# Warning about bigger then needed (24T data and 16G -> 128K chunk)
lvconvert --yes -c 64 --thinpool $vg/$lv1 2>&1 | tee err
-grep "too small" err
+grep "WARNING: Chunk size is too small" err
lvremove -f $vg
fi
diff --git a/test/shell/lvcreate-cache.sh b/test/shell/lvcreate-cache.sh
index 9222bea..646bd10 100644
--- a/test/shell/lvcreate-cache.sh
+++ b/test/shell/lvcreate-cache.sh
@@ -56,7 +56,8 @@ fail lvcreate -l 1 --cachepool pool8 $vg
# no size specified
invalid lvcreate --cachepool pool $vg 2>&1 | tee err
-# grep "specify either size or extents" err
+#grep "specify either size or extents" err
+grep "Incorrect syntax" err
# Check nothing has been created yet
check vg_field $vg lv_count 0
diff --git a/test/shell/lvextend-thin-full.sh b/test/shell/lvextend-thin-full.sh
index 5b7b9e7..3bafad4 100644
--- a/test/shell/lvextend-thin-full.sh
+++ b/test/shell/lvextend-thin-full.sh
@@ -38,7 +38,7 @@ lvchange -an $vg
lvcreate -L2M -n $lv1 $vg
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
-lvconvert -y --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --thinpool $vg/pool --poolmetadata $vg/$lv1
# Cannot resize if set to 0%
not lvextend --use-policies --config 'activation{thin_pool_autoextend_percent = 0}' $vg/pool 2>&1 | tee err
diff --git a/test/shell/lvextend-thin-metadata-dmeventd.sh b/test/shell/lvextend-thin-metadata-dmeventd.sh
index 2cfa1c3..6d27600 100644
--- a/test/shell/lvextend-thin-metadata-dmeventd.sh
+++ b/test/shell/lvextend-thin-metadata-dmeventd.sh
@@ -78,7 +78,7 @@ fake_metadata_ 400 2 >data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
# Swap volume with restored fake metadata
-lvconvert -y --chunksize 64k --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --chunksize 64k --thinpool $vg/pool --poolmetadata $vg/$lv1
# Not alllowed when thin-pool metadata free space is <75% for 2M meta
fail lvcreate -V20 $vg/pool
@@ -91,7 +91,7 @@ lvchange -an $vg/pool
fake_metadata_ 7400 2 >data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv2"
# Swap volume with restored fake metadata
-lvconvert -y --chunksize 64k --swapmetadata --poolmetadata $vg/$lv2 $vg/pool
+lvconvert -y --chunksize 64k --thinpool $vg/pool --poolmetadata $vg/$lv2
lvchange -ay $vg/pool
# Check generated metadata consume more then 88%
test "$(meta_percent_)" -gt "88"
@@ -138,7 +138,7 @@ lvchange -an $vg/thin $vg/thin2 $vg/pool
# Transaction_id is lower by 1 and there are no messages -> ERROR
fake_metadata_ 10 0 >data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
-lvconvert -y --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --thinpool $vg/pool --poolmetadata $vg/$lv1
not vgchange -ay $vg 2>&1 | tee out
grep expected out
@@ -147,7 +147,7 @@ check inactive $vg pool_tmeta
# Transaction_id is higher by 1
fake_metadata_ 10 3 >data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
-lvconvert -y --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --thinpool $vg/pool --poolmetadata $vg/$lv1
not vgchange -ay $vg 2>&1 | tee out
grep expected out
@@ -158,7 +158,7 @@ fake_metadata_ 400 2 >data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
# Swap volume with restored fake metadata
-lvconvert -y --chunksize 64k --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --chunksize 64k --thinpool $vg/pool --poolmetadata $vg/$lv1
vgchange -ay $vg
@@ -173,7 +173,7 @@ fake_metadata_ 350 2 >data
lvchange -ay $vg/$lv1
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
-lvconvert -y --chunksize 64k --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --chunksize 64k --thinpool $vg/pool --poolmetadata $vg/$lv1
lvchange -ay $vg/pool $vg/$lv1
lvs -a $vg
diff --git a/test/shell/lvmetad-pvscan-autoactivation-polling.sh b/test/shell/lvmetad-pvscan-autoactivation-polling.sh
index 58afbed..34139df 100644
--- a/test/shell/lvmetad-pvscan-autoactivation-polling.sh
+++ b/test/shell/lvmetad-pvscan-autoactivation-polling.sh
@@ -54,7 +54,7 @@ mkdir test_mnt
setup_merge_ $vg1 $lv1
mount "$(lvdev_ $vg1 $lv1)" test_mnt
-lvconvert --mergesnapshot $vg1/$(snap_lv_name_ $lv1)
+lvconvert --merge $vg1/$(snap_lv_name_ $lv1)
umount test_mnt
vgchange -an $vg1
diff --git a/test/shell/snapshot-merge-stack.sh b/test/shell/snapshot-merge-stack.sh
index f9d2e62..2fdfaa4 100644
--- a/test/shell/snapshot-merge-stack.sh
+++ b/test/shell/snapshot-merge-stack.sh
@@ -32,7 +32,7 @@ snap_and_merge() {
SLEEP_PID=$(aux hold_device_open $vg $lv1 20)
# initiate background merge
- lvconvert -b --mergesnapshot $vg/$lv2
+ lvconvert -b --merge $vg/$lv2
lvs -a -o+lv_merging,lv_merge_failed $vg
get lv_field $vg/$lv1 lv_attr | grep "Owi-ao"
diff --git a/test/shell/snapshot-merge.sh b/test/shell/snapshot-merge.sh
index 0d3e1cb..a301d22 100644
--- a/test/shell/snapshot-merge.sh
+++ b/test/shell/snapshot-merge.sh
@@ -51,15 +51,15 @@ mkdir test_mnt
# test full merge of a single LV
setup_merge_ $vg $lv1
-# make sure lvconvert --mergesnapshot requires explicit LV listing
-not lvconvert --mergesnapshot
-lvconvert --mergesnapshot $vg/$(snap_lv_name_ $lv1)
+# make sure lvconvert --merge requires explicit LV listing
+not lvconvert --merge
+lvconvert --merge $vg/$(snap_lv_name_ $lv1)
lvremove -f $vg/$lv1
# test that an actively merging snapshot may not be removed
setup_merge_ $vg $lv1
-lvconvert -i+100 --mergesnapshot --background $vg/$(snap_lv_name_ $lv1)
+lvconvert -i+100 --merge --background $vg/$(snap_lv_name_ $lv1)
not lvremove -f $vg/$(snap_lv_name_ $lv1)
lvremove -f $vg/$lv1
@@ -67,7 +67,7 @@ lvremove -f $vg/$lv1
# "onactivate merge" test
setup_merge_ $vg $lv1
mount "$(lvdev_ $vg $lv1)" test_mnt
-lvconvert --mergesnapshot $vg/$(snap_lv_name_ $lv1)
+lvconvert --merge $vg/$(snap_lv_name_ $lv1)
# -- refresh LV while FS is still mounted (merge must not start),
# verify 'snapshot-origin' target is still being used
lvchange --refresh $vg/$lv1
@@ -88,7 +88,7 @@ lvremove -f $vg/$lv1
# to make sure preload of origin's metadata is _not_ performed
setup_merge_ $vg $lv1
mount "$(lvdev_ $vg $lv1)" test_mnt
-lvconvert --mergesnapshot $vg/$(snap_lv_name_ $lv1)
+lvconvert --merge $vg/$(snap_lv_name_ $lv1)
# -- refresh LV while FS is still mounted (merge must not start),
# verify 'snapshot-origin' target is still being used
lvchange --refresh $vg/$lv1
@@ -99,7 +99,7 @@ lvremove -f $vg/$lv1
# test multiple snapshot merge; tests copy out that is driven by merge
setup_merge_ $vg $lv1 1
-lvconvert --mergesnapshot $vg/$(snap_lv_name_ $lv1)
+lvconvert --merge $vg/$(snap_lv_name_ $lv1)
lvremove -f $vg/$lv1
@@ -108,7 +108,7 @@ setup_merge_ $vg $lv1
setup_merge_ $vg $lv2
lvchange --addtag this_is_a_test $vg/$(snap_lv_name_ $lv1)
lvchange --addtag this_is_a_test $vg/$(snap_lv_name_ $lv2)
-lvconvert --mergesnapshot @this_is_a_test
+lvconvert --merge @this_is_a_test
lvs $vg | tee out
not grep $(snap_lv_name_ $lv1) out
not grep $(snap_lv_name_ $lv2) out
diff --git a/test/shell/thin-flags.sh b/test/shell/thin-flags.sh
index cbf9d19..7d87553 100644
--- a/test/shell/thin-flags.sh
+++ b/test/shell/thin-flags.sh
@@ -71,7 +71,7 @@ aux prepare_thin_metadata 490 1 | tee data
"$LVM_TEST_THIN_RESTORE_CMD" -i data -o "$DM_DEV_DIR/mapper/$vg-$lv1"
# Swap volume with restored fake metadata
-lvconvert -y --swapmetadata --poolmetadata $vg/$lv1 $vg/pool
+lvconvert -y --thinpool $vg/pool --poolmetadata $vg/$lv1
lvchange -ay $vg
diff --git a/test/shell/thin-merge.sh b/test/shell/thin-merge.sh
index d932924..f044f57 100644
--- a/test/shell/thin-merge.sh
+++ b/test/shell/thin-merge.sh
@@ -44,7 +44,7 @@ touch mntsnap/test_snap
lvs -o+tags,thin_id $vg
-lvconvert --mergethin $vg/snap
+lvconvert --merge $vg/snap
umount mnt
@@ -102,12 +102,12 @@ lvcreate -s -n snap $vg/$lv1
lvcreate -s -L10 -n oldsnapof_${lv1} $vg/$lv1
not lvconvert --merge $vg/snap
$MKFS "$DM_DEV_DIR/$vg/oldsnapof_${lv1}"
-lvconvert --mergesnapshot $vg/oldsnapof_${lv1}
+lvconvert --merge $vg/oldsnapof_${lv1}
fsck -n "$DM_DEV_DIR/$vg/$lv1"
check lv_not_exists $vg oldsnapof_${lv1}
# Add old snapshot to thin snapshot
lvcreate -s -L10 -n oldsnapof_snap $vg/snap
-lvconvert --mergethin $vg/snap
+lvconvert --merge $vg/snap
lvremove -f $vg/oldsnapof_snap
vgremove -ff $vg
diff --git a/test/shell/thin-vglock.sh b/test/shell/thin-vglock.sh
index 0b96b4b..40f3adf 100644
--- a/test/shell/thin-vglock.sh
+++ b/test/shell/thin-vglock.sh
@@ -34,7 +34,7 @@ mount "$DM_DEV_DIR/$vg/$lv1" mnt
lvcreate -s -n snap $vg/$lv1
check lv_field $vg/snap thin_id "3"
-lvconvert --mergethin $vg/snap
+lvconvert --merge $vg/snap
umount mnt
diff --git a/test/shell/vgextend-restoremissing.sh b/test/shell/vgextend-restoremissing.sh
index 2a82115..7f8fee0 100644
--- a/test/shell/vgextend-restoremissing.sh
+++ b/test/shell/vgextend-restoremissing.sh
@@ -23,6 +23,8 @@ lvcreate -l 1 -n lv1 $vg "$dev1"
invalid vgextend
# --metadatacopies => use --pvmetadatacopies
invalid vgextend --metadatacopies 3 $vg "$dev1" 2>&1 | tee out
+#grep -- "use --pvmetadatacopies" out
+grep -- "unrecognized option '--metadatacopies'" out
# VG name should exist
fail vgextend --restoremissing $vg-invalid "$dev1"
7 years
master - fsadm: support configurable full path
by Zdenek Kabelac
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=3018cdcaa7aa258a432...
Commit: 3018cdcaa7aa258a432738b95077098985fb0c74
Parent: 109532290138d3b8b535457150052b6bda4f797c
Author: Zdenek Kabelac <zkabelac(a)redhat.com>
AuthorDate: Sat Apr 8 19:43:20 2017 +0200
Committer: Zdenek Kabelac <zkabelac(a)redhat.com>
CommitterDate: Wed Apr 12 21:34:08 2017 +0200
fsadm: support configurable full path
Just like with other tools lvm2 is using allow to define
fully configurable path.
Default is selected by $PREFIX/sbin/fsadm
---
WHATS_NEW | 1 +
configure | 8 ++++++++
configure.in | 4 ++++
include/configure.h.in | 3 +++
lib/config/config_settings.h | 4 ++++
lib/config/defaults.h | 2 ++
lib/metadata/lv_manip.c | 8 ++++----
7 files changed, 26 insertions(+), 4 deletions(-)
diff --git a/WHATS_NEW b/WHATS_NEW
index bc958e2..b0fc86f 100644
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
Version 2.02.170 -
==================================
+ Introduce global/fsadm_executable to make fsadm path configurable.
Look for limited thin pool metadata size when using 16G metadata.
Add lvconvert pool creation rule disallowing options with poolmetadata.
Fix lvconvert when the same LV is incorrectly reused in options.
diff --git a/configure b/configure
index c3901d4..e691805 100755
--- a/configure
+++ b/configure
@@ -15319,6 +15319,14 @@ cat >>confdefs.h <<_ACEOF
_ACEOF
+
+FSADM_PATH="$lvm_exec_prefix/sbin/fsadm"
+
+cat >>confdefs.h <<_ACEOF
+#define FSADM_PATH "$FSADM_PATH"
+_ACEOF
+
+
################################################################################
if test "$BUILD_DMEVENTD" = yes; then
diff --git a/configure.in b/configure.in
index 42ec52f..9c1dabe 100644
--- a/configure.in
+++ b/configure.in
@@ -1895,6 +1895,10 @@ test "$prefix" != NONE && clvmd_prefix=$prefix
CLVMD_PATH="$clvmd_prefix/sbin/clvmd"
AC_DEFINE_UNQUOTED(CLVMD_PATH, ["$CLVMD_PATH"], [Path to clvmd binary.])
+
+FSADM_PATH="$lvm_exec_prefix/sbin/fsadm"
+AC_DEFINE_UNQUOTED(FSADM_PATH, ["$FSADM_PATH"], [Path to fsadm binary.])
+
################################################################################
dnl -- dmeventd pidfile and executable path
if test "$BUILD_DMEVENTD" = yes; then
diff --git a/include/configure.h.in b/include/configure.h.in
index 04e7f4b..5172650 100644
--- a/include/configure.h.in
+++ b/include/configure.h.in
@@ -148,6 +148,9 @@
/* Library version */
#undef DM_LIB_VERSION
+/* Path to fsadm binary. */
+#undef FSADM_PATH
+
/* Define to 1 if you have the `alarm' function. */
#undef HAVE_ALARM
diff --git a/lib/config/config_settings.h b/lib/config/config_settings.h
index b701722..3b0eebb 100644
--- a/lib/config/config_settings.h
+++ b/lib/config/config_settings.h
@@ -1035,6 +1035,10 @@ cfg_array(global_cache_check_options_CFG, "cache_check_options", global_CFG_SECT
cfg_array(global_cache_repair_options_CFG, "cache_repair_options", global_CFG_SECTION, CFG_ALLOW_EMPTY | CFG_DEFAULT_COMMENTED, CFG_TYPE_STRING, DEFAULT_CACHE_REPAIR_OPTIONS_CONFIG, vsn(2, 2, 108), NULL, 0, NULL,
"List of options passed to the cache_repair command.\n")
+cfg(global_fsadm_executable_CFG, "fsadm_executable", global_CFG_SECTION, CFG_DEFAULT_COMMENTED, CFG_TYPE_STRING, DEFAULT_FSADM_PATH, vsn(2, 2, 170), "@FSADM_PATH@", 0, NULL,
+ "The full path to the fsadm command.\n"
+ "LVM uses this command to help with lvresize -r operations.\n")
+
cfg(global_system_id_source_CFG, "system_id_source", global_CFG_SECTION, 0, CFG_TYPE_STRING, DEFAULT_SYSTEM_ID_SOURCE, vsn(2, 2, 117), NULL, 0, NULL,
"The method LVM uses to set the local system ID.\n"
"Volume Groups can also be given a system ID (by vgcreate, vgchange,\n"
diff --git a/lib/config/defaults.h b/lib/config/defaults.h
index 2340636..b5d9983 100644
--- a/lib/config/defaults.h
+++ b/lib/config/defaults.h
@@ -135,6 +135,8 @@
#define DEFAULT_CACHE_METADATA_FORMAT CACHE_METADATA_FORMAT_UNSELECTED /* Autodetect */
#define DEFAULT_CACHE_MODE "writethrough"
+#define DEFAULT_FSADM_PATH FSADM_PATH
+
#define DEFAULT_UMASK 0077
#define DEFAULT_FORMAT "lvm2"
diff --git a/lib/metadata/lv_manip.c b/lib/metadata/lv_manip.c
index 0dfbad4..50f5167 100644
--- a/lib/metadata/lv_manip.c
+++ b/lib/metadata/lv_manip.c
@@ -4567,13 +4567,13 @@ static int _request_confirmation(const struct logical_volume *lv,
}
enum fsadm_cmd_e { FSADM_CMD_CHECK, FSADM_CMD_RESIZE };
-#define FSADM_CMD "fsadm"
+
#define FSADM_CMD_MAX_ARGS 6
#define FSADM_CHECK_FAILS_FOR_MOUNTED 3 /* shell exist status code */
/*
- * FSADM_CMD --dry-run --verbose --force check lv_path
- * FSADM_CMD --dry-run --verbose --force resize lv_path size
+ * fsadm --dry-run --verbose --force check lv_path
+ * fsadm --dry-run --verbose --force resize lv_path size
*/
static int _fsadm_cmd(enum fsadm_cmd_e fcmd,
struct logical_volume *lv,
@@ -4588,7 +4588,7 @@ static int _fsadm_cmd(enum fsadm_cmd_e fcmd,
const char *argv[FSADM_CMD_MAX_ARGS + 2];
unsigned i = 0;
- argv[i++] = FSADM_CMD;
+ argv[i++] = find_config_tree_str(cmd, global_fsadm_executable_CFG, NULL);
if (test_mode())
argv[i++] = "--dry-run";
7 years