summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* man: expanded explanation of pvscandev-dct-man-pvscanDavid Teigland2015-05-011-27/+118
| | | | Related to it's role with lvmetad and auto-activation.
* tests: free -h is quite new optionZdenek Kabelac2015-05-011-1/+1
| | | | Stay with -g and and ignore failure.
* tests: minor simplificationsZdenek Kabelac2015-05-015-20/+11
| | | | minor updates
* tests: disable usage of fuserZdenek Kabelac2015-05-011-4/+4
| | | | | Seems we captured problems with debug.log overwrite, so avoid quite expensive usage of fuser tool with each lvm command.
* tests: run api tests from startup dirZdenek Kabelac2015-05-011-2/+2
|
* tests: no lvmetad reload for debugless outputZdenek Kabelac2015-05-019-23/+26
| | | | | | | | | Introduce LVM_TEST_LVMETAD_DEBUG_OPTS to allow to override default debug opts for lvmetad. However could be still overloaded on command line: make check_lvmetad LVM_TEST_LVMETAD_DEBUG_OPTS="-l all"...
* tests: lower version of dm-delayZdenek Kabelac2015-05-011-1/+4
| | | | | | Let's see what will break with lower version 1.1. Also avoid repeated check of target version.
* tests: rename kill_tagged_processesZdenek Kabelac2015-05-017-12/+31
| | | | | | | Better name for aux function. First use normal -TERM, and only after a while use -KILL (leaving some time to correctly finish) Print INFO about killed processes.
* tests: move conf preparingZdenek Kabelac2015-05-012-2/+1
| | | | | If the test in the middle is restarting lvmetad avoid conf regenerating.
* tests: hide error messageZdenek Kabelac2015-05-011-1/+1
| | | | Hide error about missing declare -A support.
* tests: wait between remountZdenek Kabelac2015-05-011-0/+2
| | | | Let's see if this help with some races...
* tests: move kernel_at_least to auxZdenek Kabelac2015-05-016-23/+12
| | | | | Hide func processing and reuse existing version_at_least().
* tests: watch out for RAM sizeZdenek Kabelac2015-05-013-0/+10
| | | | | | | Reduce mem-requirements on low memory boxes, activate less volumes if machine is below 0.5G. Also print mem size at test header.
* config: add CFG_DEFAULT_COMMENTED to comment out default value on outputPeter Rajnoha2015-04-303-3/+6
|
* man: lvmconfig: also mention '--type list' in synopsisPeter Rajnoha2015-04-301-1/+1
|
* lvmconfig: add supporting code for handling deprecated settingsPeter Rajnoha2015-04-307-19/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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 ... }
* config_settings: devices/cache, activation/mirror_region_size and ↵Peter Rajnoha2015-04-301-6/+9
| | | | activation/mirror_device_fault_policy are deprecated
* config: preparation for marking configuration nodes as deprecatedPeter Rajnoha2015-04-303-213/+221
| | | | | | | | | A preparatory code for marking configuration nodes as deprecated: - struct cfg_def_item gains 2 new fields ("deprecated_since_version" and "deprecation_comment" - cfg* macros to handle new fields - related config_settings.h edits to add new fields for each item (null for all at the moment) Patch with implementation will follow...
* cleanup: config_settings.h: commentsPeter Rajnoha2015-04-301-40/+54
|
* cleanup: config_settings.h: add some commentsPeter Rajnoha2015-04-301-2/+6
|
* lvmconfig: allow --withversions alone with --type listPeter Rajnoha2015-04-301-12/+14
| | | | | | | | | | | | | | | | | | Before this patch: $ lvmconfig --type list --withversions --withsummary global/use_lvmetad global/use_lvmetad - Use lvmetad to cache metadata and reduce disk scanning. [2.2.93] $ lvmconfig --type list --withversions global/use_lvmetad global/use_lvmetad With this patch applied: $ lvmconfig --type list --withversions --withsummary global/use_lvmetad global/use_lvmetad - Use lvmetad to cache metadata and reduce disk scanning. [2.2.93] $ lvmconfig --type list --withversions global/use_lvmetad global/use_lvmetad - [2.2.93]
* lvmconfig: comment out settings with proper space/tab prefixPeter Rajnoha2015-04-301-3/+11
| | | | | | | | | | | | | | | | | | | | | | | | | We're commenting out settings with undefined default values. The comment character '#' was printed at the very beginning of the line, it should be placed just at the beginning of the setting, after the space/tab prefix is printed. Before this patch: $ lvmconfig --type default activation activation { ... # volume_list=[] ... } With this patch applied: $ lvmconfig --type default activation activation { ... # volume_list=[] ... }
* tests: lvmconf updateZdenek Kabelac2015-04-301-3/+17
| | | | | | | | | New lvmconf function is using bash associative arrays - however older systems like RHEL5 doesn't provide this feature. In this case stay with older variant. Restore support for use case like this: aux lvmconf 'tags/@foo {}'
* spec: Pull in lvmconfig and associated manpages.Petr Rockai2015-04-301-0/+3
|
* man: Fix references to lvmcache(7) that mentioned section 8 by mistake.Petr Rockai2015-04-301-2/+2
|
* man: lvmthin section about use-policiesDavid Teigland2015-04-291-2/+116
|
* man: 'lvmconfig' is preferred over 'lvm config'David Teigland2015-04-292-3/+3
|
* WHATS_NEW: commit e0a62b8fdc8d041c14ca523643e319Ondrej Kozina2015-04-291-0/+1
|
* libdaemon: introduce support for exit on idleOndrej Kozina2015-04-292-2/+58
| | | | | | | | works with systemd activated daemons only as of now each daemon implementation may decide to signalize its internal idle state (i.e. all background tasks unrelated to client threads are finished)
* toollib: code cleanup in lv_spawn_background_pollingOndrej Kozina2015-04-291-9/+10
| | | | | we're going to extract parameters from lv_mirr later with code refactoring of polldaemon
* man: 'lvm config' is preferred over 'lvm lvmconfig'David Teigland2015-04-292-3/+3
|
* cleanup: lvmconfig man page typoPeter Rajnoha2015-04-291-1/+1
|
* config: consolidate CFG_UNSUPPORTED and CFG_ADVANCED settingsPeter Rajnoha2015-04-298-26/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These settings are in the "unsupported" group: devices/loopfiles log/activate_file metadata/disk_areas (section) metadata/disk_areas/<disk_area> (section) metadata/disk_areas/<disk_area>/size metadata/disk_areas/<disk_area>/id These settings are in the "advanced" group: devices/dir devices/scan devices/types global/proc activation/missing_stripe_filler activation/mlock_filter metadata/pvmetadatacopies metadata/pvmetadataignore metadata/stripesize metadata/dirs Also, this patch causes the --ignoreunsupported and --ignoreadvanced switches to be honoured for all config types (lvmconfig --type). By default, the --type current and --type diff display unsupported settings, the other types ignore them - this patch also introduces --showunsupported switch for all these other types to display even unsupported settings in their output if needed.
* tests: minimize teardown when uneededZdenek Kabelac2015-04-292-19/+16
| | | | | If test has not yet initilized any device, make teardown a bit faster.
* tests: bash-fu for lvmconfZdenek Kabelac2015-04-291-10/+23
| | | | | Sqeeze about 0.1s out of every created conf and use internal bash associative arrays instead of lot of command forking
* lvmetad: drop unused varsZdenek Kabelac2015-04-291-3/+1
| | | | Squash some unused vars introduced in some previous commit.s
* python: python 3 compat patch for lvm2bkabrda@redhat.com2015-04-294-51/+89
| | | | As provided by rhbz: 1136366
* lvmetad: Avoid duplicate entries in the list of alternate devices.Petr Rockai2015-04-291-6/+23
|
* lvmconfig: add --type list and -l|--listPeter Rajnoha2015-04-296-19/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lvmconfig --type list displays plain list of configuration settings. Some of the existing decorations can be used (--withsummary and --withversions) as well as existing options/switches (--ignoreadvanced, --ignoreunsupported, --ignorelocal, --atversion). For example (displaying only "config" section so the list is not long): $lvmconfig --type list config config/checks config/abort_on_errors config/profile_dir $ lvmconfig --type list --withsummary config config/checks - If enabled, any LVM configuration mismatch is reported. config/abort_on_errors - Abort the LVM process if a configuration mismatch is found. config/profile_dir - Directory where LVM looks for configuration profiles. $ lvmconfig -l config config/checks - If enabled, any LVM configuration mismatch is reported. config/abort_on_errors - Abort the LVM process if a configuration mismatch is found. config/profile_dir - Directory where LVM looks for configuration profiles. $ lvmconfig --type list --withsummary --withversions config config/checks - If enabled, any LVM configuration mismatch is reported. [2.2.99] config/abort_on_errors - Abort the LVM process if a configuration mismatch is found. [2.2.99] config/profile_dir - Directory where LVM looks for configuration profiles. [2.2.99] Example with --atversion (displaying global section): $ lvmconfig --type list global global/umask global/test global/units global/si_unit_consistency global/suffix global/activation global/fallback_to_lvm1 global/format global/format_libraries global/segment_libraries global/proc global/etc global/locking_type global/wait_for_locks global/fallback_to_clustered_locking global/fallback_to_local_locking global/locking_dir global/prioritise_write_locks global/library_dir global/locking_library global/abort_on_internal_errors global/detect_internal_vg_cache_corruption global/metadata_read_only global/mirror_segtype_default global/raid10_segtype_default global/sparse_segtype_default global/lvdisplay_shows_full_device_path global/use_lvmetad global/thin_check_executable global/thin_dump_executable global/thin_repair_executable global/thin_check_options global/thin_repair_options global/thin_disabled_features global/cache_check_executable global/cache_dump_executable global/cache_repair_executable global/cache_check_options global/cache_repair_options global/system_id_source global/system_id_file $ lvmconfig --type list global --atversion 2.2.50 global/umask global/test global/units global/suffix global/activation global/fallback_to_lvm1 global/format global/format_libraries global/segment_libraries global/proc global/locking_type global/wait_for_locks global/fallback_to_clustered_locking global/fallback_to_local_locking global/locking_dir global/library_dir global/locking_library
* refactor: dumpconfig: keep --withcomments to display full comment and use ↵Peter Rajnoha2015-04-299-25/+25
| | | | --withsummary for one line summary
* polldaemon: remove redundant log messagesOndrej Kozina2015-04-281-15/+5
| | | | | also alter comments describing the change in _poll_vg wrt correct handling of multiple LVs
* pvmove: make log messages more comprehensibleOndrej Kozina2015-04-281-2/+2
| | | | | | clarify messages printed during pvmove set up (in _update_metadata fn) and subsequent metadata updates during a segment progression
* update copyright info in various filesOndrej Kozina2015-04-282-2/+3
| | | | | basically transfer former date ranges from files where the code originated from (pvmove.c and lvconvert.c)
* tests: try harder to kill all dangling procsOndrej Kozina2015-04-286-160/+117
| | | | | also simplify and make less prone to an error checks for running bg processes inside a pvmove-resume tests
* tests: simplify removal of dangling bg procsOndrej Kozina2015-04-285-31/+17
| | | | | | | | | | | | | | | | | | | | | | some tests left dangling bg processes originating in lvm2 commands being able to spawn any bg polling process (lvchange, vgchange, pvmove, lvconvert...) Initial fn 'add_to_kill_list' should collect processes with specific parameters (proc's command line and parent processes ID). After testing finishes the fn kill_listed_processes should remove these listed by 'add_to_kill_list'. Unfortunately it proved to be prone to an error especially in scenarios where cmd line of initiating command contained characters required to be espaced before passing to shell script to make it work correctly. (Or if cmd spawned more than one bg process with same cmd line. i.e.: vgchange or lvchange). The new implementation is much simpler. It uses env. variable (LVM_TEST_TAG) for marking a process desired to be killed later or during test env. teardown. (i.e.: LVM_TEST_TAG=kill_me_$PREFIX to kill only processes related to current test environment)
* config: Introduce lvmconfig.Alasdair G Kergon2015-04-2814-187/+261
| | | | | | | | | | 'lvm dumpconfig' now does a lot more than just dumping configuration information and is no longer only a support tool. Users now need to run it to find out about configuration information that has been removed from the lvm.conf man page so we need to promote this to full command line status as 'lvmconfig'. Also accept 'lvm config' and mention it in the usage information of lvmconf (which should also get merged in eventually).
* devices: improve handling of duplicate PVsDavid Teigland2015-04-283-48/+220
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Example: /dev/loop0 and /dev/loop1 are duplicates, created by copying one backing file to the other. 'identity /dev/loopX' creates an identity mapping for loopX named idmloopX, which adds a duplicate for the named device. The duplicate selection code for lvmetad is incomplete, and lvmetad is disabled for this example. [~]# losetup -f loopfile0 [~]# pvs PV VG Fmt Attr PSize PFree /dev/loop0 foo lvm2 a-- 308.00m 296.00m [~]# losetup -f loopfile1 [~]# pvs Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/loop1 not /dev/loop0 Using duplicate PV /dev/loop1 which is more recent, replacing /dev/loop0 PV VG Fmt Attr PSize PFree /dev/loop1 foo lvm2 a-- 308.00m 308.00m [~]# ./identity /dev/loop0 [~]# pvs Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/loop1 not /dev/loop0 Using duplicate PV /dev/loop1 without holders, replacing /dev/loop0 Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/mapper/idmloop0 not /dev/loop1 Using duplicate PV /dev/mapper/idmloop0 from subsystem DM, replacing /dev/loop1 PV VG Fmt Attr PSize PFree /dev/mapper/idmloop0 foo lvm2 a-- 308.00m 296.00m [~]# ./identity /dev/loop1 [~]# pvs WARNING: duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV is being used from both devices /dev/loop0 and /dev/loop1 Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/loop1 not /dev/loop0 Using duplicate PV /dev/loop1 which is more recent, replacing /dev/loop0 Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/mapper/idmloop0 not /dev/loop1 Using duplicate PV /dev/mapper/idmloop0 from subsystem DM, replacing /dev/loop1 Found duplicate PV LnSOEqzEYED3RvIOa5PZP2s7uyuBLmAV: using /dev/mapper/idmloop1 not /dev/mapper/idmloop0 Using duplicate PV /dev/mapper/idmloop1 which is more recent, replacing /dev/mapper/idmloop0 PV VG Fmt Attr PSize PFree /dev/mapper/idmloop1 foo lvm2 a-- 308.00m 308.00m
* config: improve the description of options listsDavid Teigland2015-04-281-4/+4
| | | | | | | | | | | Describe thin_check_options, thin_repair_options, cache_check_option, scache_repair_options as a "list of options", rather than a "string of options" because a single string, e.g. "-q --clear-needs-check-flag" does not work, and needs to be entered as a list, e.g. ["-q", "--clear-needs-check-flag"]
* config: also evaluate default unconfigured values in runtime for ↵Peter Rajnoha2015-04-283-44/+97
| | | | | | | | | | | | | | | | | | | | 'cfg_runtime' settings The settings which have their default value evaluated in runtime should have their 'unconfigured' counterparts also evaluated in runtime since those values can be constructed by using other settings. For example, before this patch: $ lvm dumpconfig --type default --unconfigured devices/cache_dir devices/cache cache_dir="@DEFAULT_SYS_DIR@/@DEFAULT_CACHE_SUBDIR@" cache="/etc/lvm/cache/.cache With this patch applied: $ lvm dumpconfig --type default --unconfigured devices/cache_dir devices/cache cache_dir="@DEFAULT_SYS_DIR@/@DEFAULT_CACHE_SUBDIR@" cache="@DEFAULT_SYS_DIR@/@DEFAULT_CACHE_SUBDIR@/.cache"
* config: make it possible to set default unconfigured_value for settings of ↵Peter Rajnoha2015-04-281-4/+4
| | | | | | | | all types, not just strings The @something@ used for unconfigured default value is not bound to CFG_TYPE_STRING settings defined in config_settings.h, it can be used for any other config type too.