summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* lvchange: reject writemostly/writebehind on raid1 during resyncsourceware_masterHeinz Mauelshagen2017-02-235-1/+65
| | | | | | | | | | | | | | | | | | | | | | | | | The MD kernel raid1 personality does no use any writemostly leg as the primary. In case a previous linear LV holding data gets upconverted to raid1 it becomes the primary leg of the new raid1 LV and a full resynchronization is started to update the new legs. No writemostly and/or writebehind setting may be allowed during this initial, full synchronization period of this new raid1 LV (using the lvchange(8) command), because that would change the primary (i.e the previous linear LV) thus causing data loss. lvchange has a bug not preventing this scenario. Fix rejects setting writemostly and/or writebehind on resychronizing raid1 LVs. Once we have status in the lvm2 metadata about the linear -> raid upconversion, we may relax this constraint for other types of resynchronization (e.g. for user requested "lvchange --resync "). New lvchange-raid1-writemostly.sh test is added to the test suite. Resolves: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=855895
* man/help: improve the style of units indicatorDavid Teigland2017-02-222-16/+15
| | | | | | | | | | | | | | | We use --foo Number[k|Units] to indicate that the default units of the number is k, but other units listed below are also accepted. Capitalize and underline Units so it is consistent with other variables, and reference it at the end. Technically, the k should be bold, but this tends to make the text visually hard to read because of the excessive highlights scattered everywhere. So it's left normal text for now (it's unlikely to confuse anyone.)
* man: indicate repeatable optionsDavid Teigland2017-02-221-3/+5
| | | | | | Print ... after a repeatable option in the OPTIONS section. An alternative would be to just mention in the text description that the option is repeatable.
* man: improve writemostly PV argDavid Teigland2017-02-221-10/+15
|
* tests: support zero_devZdenek Kabelac2017-02-221-4/+15
| | | | | | | | | | | When the test would need to try to write some large amount of data we can give it 'zero' segments - for obvious reason such written data can't be verified but in some test cases it doesn't really matter. Usage follows 'error_dev' style. For now test suite is not supporting any combination of error/delay/zero segments so only 1 type could be used per PV.
* tests: not slowing work with metadataZdenek Kabelac2017-02-221-2/+2
| | | | Slows only data extents on a PV.
* snapshot: improve removal of active origin volumeZdenek Kabelac2017-02-222-4/+14
| | | | | | | | | | | | Previously when lvremove tried to remove 'active' origin, it had been asking for every 'snapshot' LV separately and doing individual single snapshot removals first. To be faster it now deactivates origin before removal all connected snapshots. This avoids multiple reloads of dm table for origin volume which were unnecessary as origin was meant to be removed as well.
* WHATS_NEW: add entryZdenek Kabelac2017-02-222-1/+1
|
* man/help: enclose each option in bracketsDavid Teigland2017-02-211-48/+25
| | | | | Placing [] around each individual option is the most common style, and it improves the readability.
* man/help: use separate common option listsDavid Teigland2017-02-214-57/+160
| | | | | | | | | | | There are two kinds of common options: 1. options common to all variants of a given command name 2. options common to all lvm commands Previously, both kinds of common options were listed together under "Common options". Now the first are printed under "Common options for command" (when needed), and the second are printed under "Common options for lvm" (always).
* man: teaking output formatDavid Teigland2017-02-211-1/+33
|
* commands: adjust default help outputDavid Teigland2017-02-213-41/+23
| | | | | | | | | | Remove the "usage notes" which should just live in the man pages. When there are 3 or more variants of a command, print all the options produces a lot of output, so require --longhelp to print all the options in these cases.
* man lvm: update see also listDavid Teigland2017-02-211-43/+65
| | | | | add several missing references remove references to lvmdiskscan lvmchange
* man: expand type option descriptionDavid Teigland2017-02-211-1/+10
|
* dmsetup: Indicate device repetition in usage summaries.Alasdair G Kergon2017-02-212-33/+32
|
* tests: some debug codeZdenek Kabelac2017-02-211-1/+4
| | | | | Checking if --deferred would make it any faster - but it's as slow as without this new optional flag anyway (4.10).
* tests: ensure first call is version testZdenek Kabelac2017-02-211-6/+8
| | | | | | | Check 'dmsetup version' is called before starting any more advanced logic in $DM_DEV_DIR. Call also replaces mkdir as it creates needed path with control node.
* tests: make sure which PV is used for allocationZdenek Kabelac2017-02-211-1/+1
|
* tests: paralelize creation and teardownZdenek Kabelac2017-02-211-16/+23
| | | | | | To speedup initial construction and destruction of test devices (mainly in case more then 1 is needed) call dmsetup in parallel.
* tests: use exclusive activation for mirrorZdenek Kabelac2017-02-211-1/+1
| | | | Test suite does not support clustered mirroring.
* man: use .HP instead of .TPDavid Teigland2017-02-201-9/+9
|
* man/help: print general raid type as "raid"David Teigland2017-02-201-1/+1
| | | | | Instead of printing "raid*". There are already notes mentioning that "raid" refers to "raid<N>"
* man vgchange/lvchange: note special option usageDavid Teigland2017-02-201-2/+6
|
* man lvcreate: add special option notes at the startDavid Teigland2017-02-201-0/+11
| | | | | | The --name, --size, --extents options deserve a special note at the start of the man page, before appearing in the usage section.
* man: add variables descriptionsDavid Teigland2017-02-201-20/+152
| | | | | | | | Add a section describing variables. In the full options list, include common options in the alphabetical listing instead of at the end.
* lvresize/lvextend: accept type optionDavid Teigland2017-02-201-7/+22
| | | | | | | The --type option has previously been accepted for lvresize/lvextend. Using it did not affect the operation of the command. The value was simply verified as matching the current seg type of the LV.
* tests: update lvresize testingZdenek Kabelac2017-02-201-0/+17
| | | | Add missing tests for some lvresize acceptable options.
* cleanup: simplier codeZdenek Kabelac2017-02-201-2/+1
| | | | Already know string is 'lvm-' so use name[3].
* cleanup: same sign for compareZdenek Kabelac2017-02-201-3/+1
|
* cleanup: use multiline stringZdenek Kabelac2017-02-201-25/+25
|
* cleanup: use constZdenek Kabelac2017-02-203-5/+5
|
* man: thin dmeventd plugin updateZdenek Kabelac2017-02-201-34/+74
| | | | Document new dmeventd/thin_command lvm.conf configurable.
* man: dmstats updateZdenek Kabelac2017-02-191-16/+11
| | | | Fixing colorization bugs
* man: dmsetup updateZdenek Kabelac2017-02-191-7/+7
|
* commands: fix memleakZdenek Kabelac2017-02-191-1/+1
| | | | Keep all allocations 'mempool' allocated for simple cleanup.
* lvresize: fix regressiong on accepting argsZdenek Kabelac2017-02-191-5/+8
| | | | | | | | | | Commit f45b68940667563e1a8d3bbd5d30864c04381bdf caused regression of lvresize -m and --type parameter After fix this sequence may work when we also fix syntax description: lvcreate -l1 -m1 -n lv1 vg lvextend --type mirror -m1 -l+1 vg/lv1
* man/help: fix description of r|R unitDavid Teigland2017-02-171-3/+2
|
* man: print space before built-in nameDavid Teigland2017-02-171-1/+4
| | | | print 'lvm config' not 'lvm-config'
* man pvmove: move details to notesDavid Teigland2017-02-172-45/+47
|
* man: mention force behavior in various placesDavid Teigland2017-02-175-0/+19
|
* man lvmconfig: refer to typeconfig option nameDavid Teigland2017-02-171-2/+2
|
* man/help: show recently added r|R unitDavid Teigland2017-02-172-5/+8
|
* args: in yes option mention qq for auto-noDavid Teigland2017-02-171-1/+2
|
* lvconvert: include swap behavior in generic pool syntaxDavid Teigland2017-02-179-99/+166
| | | | | | | | | | | | | | | | | For this syntax: lvconvert --thinpool LV1 --poolmetadata LV2 lvconvert --cachepool LV1 --poolmetadata LV2 Restore the metadata swapping behavior in addition to the pool creation behavior. When LV1 is already a pool, the metadata LV will be swapped with LV2. When LV1 is not a pool, it will be converted to a pool using the specified LV for metadata. This syntax is no longer advertised because of the ambiguous behavior. The primary syntaxes for pool creation and metadata swapping will be the advertised methods.
* commands: compensate --uuidZdenek Kabelac2017-02-171-0/+5
| | | | | | | | | | | As we now user binary search - it's nondeterministict which of the same 'args' will be give - so duplicates need 'extra' care. So provide same hack for output for --uuidstr_ARG as for input. Solves 'pvscan -u'.
* commands: some more dm wrappersZdenek Kabelac2017-02-171-0/+12
| | | | As man-generator is not liked with libdm as of now - some more wrappers.
* cleanup: unused uninit varsZdenek Kabelac2017-02-171-3/+2
|
* cleanup: use strchr for 1-byte lookupZdenek Kabelac2017-02-171-11/+11
|
* cleanup: add comment for longer macroZdenek Kabelac2017-02-171-2/+2
|
* commands: optimize binary searchZdenek Kabelac2017-02-171-34/+45
| | | | | | | | | | | | | | | | | Since there is a lot of options and lot of searches, use binary search to keep strcmp at minimum. The interesting part is - alphabetically sorted array contains duplicates and some of them are not the 'right anwer', so after we find matching string but not matching long_ARG, we may need to check if the surrouding strings are the right matching one. The single loops is used also for strictly define --foo_long (i.e. --stripes) and just differs at final part. TODO1: replace strstr call with some flag (just like short_opt). TODO2: drop '--' from being stored and tests by strcmp.