1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-03 05:18:29 +03:00
lvm2/lib
Peter Rajnoha fc65269d68 lvmconfig: add supporting code for handling deprecated settings
This patch adds supporting code for handling deprecated settings.

Deprecated settings are not displayed by default in lvmconfig output
(except for --type current and --type diff). There's a new
"--showdeprecated" lvmconfig option to display them if needed.

Also, when using lvmconfig --withcomments, the comments with info
about deprecation are displayed for deprecated settings and with
lvmconfig --withversions, the version in which the setting was
deprecated is displayed in addition to the version of introduction.

If using --atversion with a version that is lower than the one
in which the setting was deprecated, the setting is then considered
as not deprecated (simply because at that version it was not
deprecated).

For example:

$ lvmconfig --type default activation
activation {
        ...
	raid_region_size=512
        ...
}

$ lvmconfig --type default activation --showdeprecated
activation {
        ...
	mirror_region_size=512
	raid_region_size=512
        ...
}

$ lvmconfig --type default activation --showdeprecated --withversions
activation {
        ...
	# Available since version 1.0.0.
	# Deprecated since version 2.2.99.
	mirror_region_size=512
	# Available since version 2.2.99.
	raid_region_size=512
        ...
}

$ lvmconfig --type default activation --showdeprecated --withcomments
activation {
        ...
	# Configuration option activation/mirror_region_size.
	# This has been replaced by the activation/raid_region_size
	# setting.
	# Size (in KB) of each copy operation when mirroring.
	# This configuration option is deprecated.
	mirror_region_size=512

	# Configuration option activation/raid_region_size.
	# Size in KiB of each raid or mirror synchronization region.
	# For raid or mirror segment types, this is the amount of
	# data that is copied at once when initializing, or moved
	# at once by pvmove.
	raid_region_size=512
        ...
}

$ lvmconfig --type default activation --withcomments --atversion 2.2.98
activation {
       ...
       # Configuration option activation/mirror_region_size.
       # Size (in KB) of each copy operation when mirroring.
       mirror_region_size=512
       ...
}
2015-04-30 17:55:04 +02:00
..
activate config: fix check_options array 2015-04-23 10:35:34 -05:00
cache devices: improve handling of duplicate PVs 2015-04-28 10:41:32 -05:00
cache_segtype cache: use writethrough cache_mode for older metadata 2015-01-29 12:05:58 +01:00
commands systemid: Use correct mempool. 2015-03-18 23:25:30 +00:00
config lvmconfig: add supporting code for handling deprecated settings 2015-04-30 17:55:04 +02:00
datastruct datastruct: Add str_list_add_list. 2015-03-26 18:30:37 +00:00
device devices: improve handling of duplicate PVs 2015-04-28 10:41:32 -05:00
display display: fix return values 2015-03-10 14:10:18 +01:00
error segtype: drop cmdcontex pointer 2014-10-30 23:58:49 +01:00
filters config: use timestamp with nanosecond precision 2015-03-18 13:42:56 +01:00
format1 cache: Store metadata size and checksum. 2015-03-18 23:43:02 +00:00
format_pool cache: Store metadata size and checksum. 2015-03-18 23:43:02 +00:00
format_text alloc: Respect cling_tag_list in contig alloc. 2015-04-11 01:55:24 +01:00
freeseg segtype: drop cmdcontex pointer 2014-10-30 23:58:49 +01:00
label cache: Store metadata size and checksum. 2015-03-18 23:43:02 +00:00
locking locking: rename LCK_CONVERT 2014-11-18 16:50:49 +01:00
log debug: change envvar 2015-04-20 19:18:56 +02:00
metadata alloc: Respect cling_tag_list in contig alloc. 2015-04-11 01:55:24 +01:00
mirror cmirror: Adjust region size to work around CPG msg limit to avoid hang. 2015-02-25 14:42:15 -06:00
misc lvm-file: wrapper to read ctim from stat 2015-03-18 13:42:24 +01:00
mm memory: disable check with valgrind pool build 2015-02-12 15:40:53 +01:00
properties report: add separate fields for PV/VG/LV attributes 2014-07-04 15:40:17 +02:00
raid segtype: add SEG_ONLY_EXCLUSIVE flag 2014-11-10 22:05:48 +01:00
replicator cleanup: drop default implementation 2014-10-24 16:39:31 +02:00
report cleanup: ancestors -> lv_ancestors, descendants -> lv_descendants 2015-04-24 14:19:28 +02:00
snapshot segtype: add SEG_ONLY_EXCLUSIVE flag 2014-11-10 22:05:48 +01:00
striped segtype: drop cmdcontex pointer 2014-10-30 23:58:49 +01:00
thin cleanup: add lv_is_error_when_full() macro 2015-01-20 14:52:06 +01:00
unknown segtype: drop cmdcontex pointer 2014-10-30 23:58:49 +01:00
uuid cleanup: drop unused define 2014-03-12 19:12:34 +01:00
zero cleanup: remove unused headers 2014-11-13 17:49:42 +01:00
Makefile.in configure: Look for valgrind.h independently of VALGRIND_POOLS. 2015-02-05 13:50:34 +01:00