summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Typo: change loose to loseworkingJonathan Brassow2017-04-122-6/+6
| | | | | | | loose (v): set free; release lose (v) : be deprived of or cease to have or retain We 'lose' redundancy or 'lose' meaning.
* lvconvert: fix failing valid regionsize changeHeinz Mauelshagen2017-04-122-7/+5
| | | | | | | | | | Reshape check failed when regionsize changed and current raid type was provided with no other change requested (stripes or stripesize). E.g. "lvconvert --type raid6 --regionsize 256K" on a raid6 LV with != 256K regionsize. Enable --type in test script.
* lvconvert: add segment type raid10_nearHeinz Mauelshagen2017-04-124-8/+31
| | | | | | | Introducing this alias for "raid10", avoid allocating reshape space when converting between them. Resolves: rhbz1441347
* raid: handle insufficent PVs on takeover from striped/raid0Heinz Mauelshagen2017-04-121-2/+23
| | | | | | | | Remove any newly allocated sub LV (pair) remnants in case allocation fails due to lag of (parallel) free PV space and keep initial raid type. Resolves: rhbz1438013
* man lvmraid: wrap long linesDavid Teigland2017-04-111-119/+165
| | | | Break lines in examples to keep line length under 80.
* raid_manip: fix typo warning messageDavid Teigland2017-04-111-1/+1
|
* man lvmraid: fix line wrapping in examplesDavid Teigland2017-04-111-17/+17
|
* man lvmraid: use same style as generated pagesDavid Teigland2017-04-111-25/+26
|
* lvconvert: require different LV for poolDavid Teigland2017-04-111-0/+12
| | | | | | When convering an LV to a cache or thin LV, require that an LV being converted to cache pool or thin pool at the same time be a different LV.
* lvconvert: prevent duplicate use of metadata lvDavid Teigland2017-04-111-4/+15
| | | | | The LV being processed cannot be used as the pool metadata LV.
* man lvmraid: improve text layoutDavid Teigland2017-04-111-23/+41
|
* lvconvert: validate vg name prefix for pool metadata nameDavid Teigland2017-04-111-0/+5
|
* man lvcreate/lvconvert: minor clean up rewordingDavid Teigland2017-04-112-45/+51
|
* commands: check required option value when matching commandDavid Teigland2017-04-101-3/+28
| | | | | | | | | | | | | | | | | | | | A command def can include a specific constant option value, but the value was not being checked for optional opts. e.g. this is an incorrect command and does not match any command defs: lvconvert --type cache --cachepool vg/lv However, it was mistakely being matched to this cmd def, where the required options match, but the optional options do not: lonvert --cachepool LV_linear_striped_raid_cachepool OO: --type cache-pool, ... The optional options were mistakely considered matching because 'cache' and 'cache-pool' were not being compared.
* signals: fix comparison flawHeinz Mauelshagen2017-04-101-1/+1
| | | | | | | | commit 9a689fb8f0a6b1675a4e819f4837bf2e0269832f fixed SIGINT blocking but introduced a comparision flaw to sigint_restore(). Related: rhbz1440766
* signals: fix SIGINT blocking flaw causing inconsistent metadataHeinz Mauelshagen2017-04-101-4/+4
| | | | | | | | | | | | | | | | | | | | SIGINT isn't blocked properly after a sigint_allow(), sigint_restore() cycle leading to illicit interruptable metadata updates. These can leave corrupted metadata behind. Issues addressed in this commit: sigint_allow() fails to set _oldmasked[] members properly due to an offset by one bug on indexing the members of the array. It bails out prematurely comparing to MAX_SIGINTS causing nesting depths to be one less than MAX_SIGINTS. Fix the comparision. Correct the related comparison flaw in sigint_restore(). Initialize all sig_atomic_t variables consequently. Resolves: rhbz1440766
* lvconvert: cleanup promptingHeinz Mauelshagen2017-04-061-17/+12
|
* lvconvert: fixe conversion messageHeinz Mauelshagen2017-04-061-3/+4
| | | | | | When selecting a convenience RAID type only display the selected type when it changed. Display proper current raid type when prompting.
* lvconvert: raid1 -> linear promptHeinz Mauelshagen2017-04-061-2/+3
| | | | | Avoid 2 prompts when downconverting raid1 to linear (related commit 0f65d7ec3a7325165af1a9f722cb760fd363e932).
* lvconvert: avoid error message on raid1 -> raid4 conversionHeinz Mauelshagen2017-04-061-2/+2
| | | | | | | | | Avoid error message "Logical Volume *_rimage_0 already exists in volume group,,," on takeover conversion from a 2-legged raid1 to raid4 (aiming to reshape it adding images). Resolves: rhbz1439398
* lvconvert: prompt on raid1 image changesHeinz Mauelshagen2017-04-068-28/+35
| | | | | | Don't change resilience of raid1 LVs without --yes. Adjust respective tests.
* raid: reload on removing imagesHeinz Mauelshagen2017-04-061-7/+6
| | | | | | | Requesting _raid_remove_images() to commit the metadata missed to reload the origin causing a kernel takeover error converting a 2-legged raid1 (with previously removed images) to raid5.
* man: lvmraid.7 raid6_n_6 fixHeinz Mauelshagen2017-04-061-12/+2
|
* raid: tidyingHeinz Mauelshagen2017-04-061-1/+1
|
* lvconvert: allow --type with --regionsizeHeinz Mauelshagen2017-04-061-2/+24
| | | | | | | | | Allow the combination of both arguments keeping the raid level but changing the regionssize (e.g. "lvconvert --type raid1 --regionsize 1M RaidLV" on an existing raid1 LV). Resolves: rhbz1438396
* lvchange/lvconvert: fix missing lvmlockd LV locksDavid Teigland2017-04-052-10/+45
| | | | | | | | | | | | | lvchange/lvconvert operations that do not require the LV to already be active need to acquire a transient LV lock before changing/converting the LV to ensure the LV is not active on another host. If the LV is already active, a persistent LV lock already exists on the host and the transient LV lock request is a no-op. Some lvmlockd locks in lvchange were lost in the cmd def changes. The lvmlockd locks in lvconvert seem to have been missed from the start.
* lvchange: tidy switch code in _lvchange_properties_single()Heinz Mauelshagen2017-04-051-32/+59
|
* lvchange: fix missing return valueDavid Teigland2017-04-051-0/+2
| | | | | A return value from lvchange_persistent_cmd() was missed in commit 1c41898c07ad750820fb39770355fded8e9b030a
* lvmconf: fix systemd unit existence check for lvmconf --services ↵Peter Rajnoha2017-04-052-2/+5
| | | | | | | | | | --startstopservices We have to unset the LoadState variable from previous use when we check for systemd unit state. We use this variable to check if systemd services are loaded or not and if it is loaded, we issue systemctl commands to enable/disable and start/stop the service. We don't issue these commands if the unit is not loaded to avoid error messages which may confuse users.
* commands: fix misspelling of option valueDavid Teigland2017-04-041-1/+1
| | | | | (The cmd def parser really needs to catch mistakes like this as it did when it was external.)
* lvchange: fix --poll value when set from optionDavid Teigland2017-04-041-5/+14
| | | | | | | | | | The actual value specified by the --poll y|n option was not being used. The way the --poll value is used is hidden through an indirection where the value is stored in a global variable at the start of the command, and then the value is read from there later. Setting the global variable early in the command had been lost with the cmd def changes.
* vgchange/lvchange: fix poll and monitor useDavid Teigland2017-04-042-16/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fill in some gaps where old versions of lvm allowed --poll and --monitor in combination with other operations, but those combinations had been lost since the cmd def work. (The new cmd def code also added some combinations that had been missed by the old code.) Changes: lvchange --activate: add poll and monitor options, and add calls to them in implementation. lvchange --refresh: add monitor option (poll already there), and call to monitor in implementation. lvchange <metadata ops>: add poll and monitor options, and add calls to them in implementation. vgchange <metadata ops>: add poll option (call to poll already in implementation). vgchange --refresh: remove monitor option (not used by code) lvchange --persistent y: add poll and monitor options, and add calls to them, and to activate in the implementation. (Making it match the main lvchange metadata command.) Summary of current usage: lvchange --activate: monitor, poll vgchange --activate: monitor, poll lvchange --refresh: monitor, poll vgchange --refresh: poll lvchange --monitor: ok lvchange --poll: ok lvchange --monitor --poll: ok vgchange --monitor: ok vgchange --poll: ok vgchange --monitor --poll: ok lvchange <metadata ops>: monitor, poll vgchange <metadata ops>: poll
* lvchange: enhance avoiding multiple metadata updates/reloads/backupsHeinz Mauelshagen2017-04-041-68/+179
| | | | | | | | | | | Enhance commit 25b5915c9b5260c59d627bd1f6db8220bd4ad61e to process options requiring immediate metadata commits and reloads after those we can group together doing just one commit and an optional reload for the whole group. Backup metadata after processing options successfully. Related: rhbz1437611
* man: '-pool' regexpHeinz Mauelshagen2017-04-041-0/+1
|
* lvconvert: fix converting hidden lv to poolDavid Teigland2017-04-041-0/+2
| | | | A hidden LV can not be converted to a thin pool or cache pool.
* help: print all options in abbreviated help outputDavid Teigland2017-04-031-5/+3
| | | | | | | Don't abbreviate the --help output quite as much when there are many command defs. Print all the options in the cmd defs that are shown. --longhelp output is unchanged and includes everything.
* commands: missing comma in cmd def option listDavid Teigland2017-04-031-1/+1
| | | | Does not affect parsing, but keep it consistent.
* help: include cmd def info in verbose outputDavid Teigland2017-04-031-0/+5
| | | | | | It can sometimes be important to correlate a command with its cmd def entry, so include the cross reference info in help -vv output.
* commands: recognize ignored optionsDavid Teigland2017-04-031-1/+5
|
* commands: ignore partial option in most casesDavid Teigland2017-04-031-7/+17
| | | | | | | | | | | | | | | | These days --partial is only used with activation in lvchange/vgchange. It probably had another meaning at some point in history which is no longer used, so ignore it in those cases. When included in the OO list, the option is advertised in help/man output, implying it is meaningful to the command, when in fact the command never uses it. The IO list means the option won't cause an error if it's used, but is not displayed as an valid option for the command. If the option is not included in either OO or IO lists, using the option would cause a command error, which would cause problems for anyone is using the option for historical reasons.
* man: fix description of --partial optionDavid Teigland2017-04-031-6/+4
|
* lvchange: refresh command missing activationmode optionDavid Teigland2017-04-031-1/+1
|
* lvchange: avoid multiple metadata updates/reloads/backupsHeinz Mauelshagen2017-04-011-73/+120
| | | | | | | | | | | | _lvchange_properties_single() processes multiple command line arguments in a loop causing metadata updates and/or backups per argument. Optimize to only perform one update and/or backup (but necessary interim ones; e.g. for --resync) per command run. Related: rhbz1437611
* tests: fix LD_LIBRARY_PATHZdenek Kabelac2017-03-311-6/+5
| | | | | | | Use only selected paths for finding .so in builddir. So if builddir constains some embeded subdirs with some more occurences of project (i.e. 'make rpm' build subdir) those library paths will not get into list.
* cache: scan kallsyms for kernel symbolsZdenek Kabelac2017-03-311-5/+40
| | | | | | | | | | | | With monolithic kernels we can't actually modprobe for cache modules as they are already compiled-in and policy modules do not export version symbol. Reported issue on list: https://www.redhat.com/archives/dm-devel/2017-March/msg00061.html Fix will try to look for explicit kernel symbols first before calling modprobe.
* lvchange: persistent major/minor processing regressionHeinz Mauelshagen2017-03-311-7/+2
| | | | | | Optimized change. Resolves: rhbz1437611
* lvchange: persistent major/minor processing regressionHeinz Mauelshagen2017-03-311-2/+7
| | | | | | | | | Fix a regression introduced by new command line processing (see starting commit 1e2420bca85da9a37570871cd70192e9ae831786) causing activation to be rejected in combination with setting persistent minor device numbers. Resolves: rhbz1437611
* man: pregen file changeHeinz Mauelshagen2017-03-301-1/+1
|
* man-generator: shutdown stdout bufferHeinz Mauelshagen2017-03-301-1/+4
| | | | Flush stdout and switch it back to line buffering before exit.
* man-generator: enhance performanceHeinz Mauelshagen2017-03-301-5/+19
| | | | | Set block buffering on stdout to save ~30% time generating manuals.