summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* restrict lv segment types in cluster vgdev-dct-cluster-vg-typesDavid Teigland2014-10-315-1/+51
|
* tests: update raid syncZdenek Kabelac2014-10-311-2/+1
|
* tests: wait for raid syncZdenek Kabelac2014-10-311-0/+2
|
* tests: explicitely use old snapshotsZdenek Kabelac2014-10-311-2/+2
|
* tests: lvcreate snapshot usage updateZdenek Kabelac2014-10-301-1/+9
|
* tests: use aux func to disable deviceZdenek Kabelac2014-10-301-3/+4
|
* tests: raid syncaction testZdenek Kabelac2014-10-301-2/+8
| | | | | Add sync wait for syncaction of raid1 test. --syncaction requires raid to be in sync first.
* cleanup: shorter codeZdenek Kabelac2014-10-301-6/+4
|
* cleanup: extents_from_size is 32bit valueZdenek Kabelac2014-10-302-3/+4
| | | | Current lvm2 does support only 32bit extents count.
* cleanup: prints and stacksZdenek Kabelac2014-10-301-6/+6
|
* cleanup: remove unneeded assignZdenek Kabelac2014-10-301-1/+0
|
* metadata: add extents_from_percent_sizeZdenek Kabelac2014-10-302-0/+64
| | | | | | | | Add API call to calculate extents from percentage value. Size is based in DM_PERCENT_1 units. (Supporting decimal point number). This commit is preparing functionality for more global usage of % with i.e. --size option.
* pv_manip: check for pe_rangesZdenek Kabelac2014-10-301-0/+4
|
* lvmcmdline: support size_mb_arg_with_percentZdenek Kabelac2014-10-303-19/+49
| | | | | | | New size_mb_arg_with_percent is able to read size_mb_arg but also it's able to read % values. Percent parsing is share with int_arg_with_sign_and_percent.
* lvmcmdline: extra support for decimal pointZdenek Kabelac2014-10-302-0/+13
| | | | | | | | If root has locales with different decimal point then '.' (i.e. Czech with ',') lets be tolerant and retry with "C" locales in the case '.' is found during parse of number. Locales are then restored back.
* segtype: drop cmdcontex pointerZdenek Kabelac2014-10-3012-22/+1
| | | | | Users of context provide their cmd pointer, so don't keep it inside segtype.
* lvcreate: improving recent lvcreate updatesZdenek Kabelac2014-10-301-5/+6
| | | | | | | | We need to be able to parse: lvcreate --type snapshot -s lvcreate --type thin -s lvcreate --type cache-pool -H
* man: update lvcreate with sparseZdenek Kabelac2014-10-301-8/+14
| | | | Document sparse device creation and its default segtype selection.
* configure: autoreconfZdenek Kabelac2014-10-302-69/+127
| | | | Just rebuild after configure.in update.
* sparse: configurable type for sparse volumesZdenek Kabelac2014-10-307-21/+85
| | | | | | | | | | | Support compile type configurable defaults for creation of sparse volumes. By default now create 'thin-pools' for sparse volumes. Use the global/sparse_segtype_default to switch back to old snapshots if needed. Apply the same compile logic for newly introduces mirror/raid1 options.
* configure: option cleanupZdenek Kabelac2014-10-301-60/+51
| | | | | Drop double [[ ]] around default args. (AC_HELP_STRING is already quoted so double [[]] are not needed).
* test: for issue fixed in previous commit ↵Peter Rajnoha2014-10-271-0/+5
| | | | 2f7f6932dcd450ba75fe590aba8c09838d2618dc
* report: selection: fix selection criteria to not match reserved values when ↵Peter Rajnoha2014-10-272-57/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | using >, <, >=, < Some values are reserved for special purpose like 'undefined', 'unmanaged' etc. When using >, <, >= and < comparison operators where the range is considered, do not include reserved values as proper values in this range which would otherwise result in not so obvious criteria match (as the reserved value is actually transparent for the user). It's incorrect. Example scenario: $ vgs -o vg_name,vg_mda_copies vg1 vg2 VG #VMdaCps vg1 1 vg2 unmanaged The "unmanaged" is actually mapped onto reserved value 18446744073709551615 (2^64 - 1) internally. Such reseved value is already caught on selection criteria input properly: $ vgs -o name,vg_mda_copies vg1 vg2 -S 'vg_mda_copies=18446744073709551615' Numeric value 18446744073709551615 found in selection is reserved. However, we still need to fix situaton where the reserved value may be included in resulting range: Before this patch: $ vgs -o vg_name,vg_mda_copies vg1 vg2 -S 'vg_mda_copies >= 1' VG #VMdaCps vg1 1 vg2 unmanaged With this patch applied: $ vgs -o vg_name,vg_mda_copies vg1 vg2 -S 'vg_mda_copies >= 1' VG #VMdaCps vg1 1 From the examples above, we can see that without this patch applied, the vg_mda_copies >= 1 also matched the reserved value 18446744073709551615 (which is represented by the "unamanged" string on report). When applying the operators, such values must be skipped! They're meant to be matched only against their string representation only, e.g.: $ vgs -o name,vg_mda_copies vg1 vg2 -S 'vg_mda_copies=unmanaged' VG #VMdaCps vg2 unmanaged ...or any synonyms: $ vgs -o name,vg_mda_copies vg1 vg2 -S 'vg_mda_copies=undefined' VG #VMdaCps vg2 unmanaged
* pools: workaround hintsZdenek Kabelac2014-10-262-10/+20
| | | | Missing code for stacked hint estimation
* tests: update cache creation testsZdenek Kabelac2014-10-261-0/+21
|
* tests: lvcreate-updateZdenek Kabelac2014-10-261-3/+3
| | | | Test with old mirror type.
* tests: pytest updateZdenek Kabelac2014-10-262-1/+4
|
* lvcreate: delay check for free extentsZdenek Kabelac2014-10-261-8/+8
| | | | | As the rounding for cache creation may change the value of extents postpone check for free extents.
* cache: support more argsZdenek Kabelac2014-10-262-10/+17
| | | | | | | | | | | | Unlike with thin-pool - with cache we support all args also directly when create cache volume. So the result of 'separate' cache-pool creation and setting its options should give same result as specifying those args during cache creation. Cache-pool values are used as defaults if the params are not specified with cache creation.
* thin: simplify thin volume creationZdenek Kabelac2014-10-269-104/+54
| | | | | | | Move code for creation of thin volume into a single place out of lv_extend(). This allows to drop extra pool arg for alloc_lv_segment() && lv_extend() and makes code more easier to read and follow.
* cache: apply chunk rounding also for cache creation.Zdenek Kabelac2014-10-261-12/+14
| | | | | | | When we create volumes with chunk size bigger then extent size we try to round up to some nearest chunk boundary. Until now we did this for thins - use same logic for cache volumes.
* pools: prefetch pool_lv and origin_lvZdenek Kabelac2014-10-261-50/+55
| | | | | Load pool_lv and origin_lv at a single place and use it for more types as they need them.
* lvm2app: update to new lv_create_single APIZdenek Kabelac2014-10-262-23/+16
| | | | lv_create_single is more type based.
* vg_read: Remove unused READ_WITHOUT_LOCK.David Teigland2014-10-242-3/+2
| | | | | | Unused since 67a7b7a87da65b2350f975272e581be5f41976e0: report: Iterate over labels instead of PVs for label-only reports. (included in 2.02.105).
* tests: syncaction needs kernel fixZdenek Kabelac2014-10-242-4/+8
| | | | | | | Add 'should' as we currently cannot pass this test. FIXME: Add properly wrapper to not use 'should' with fixed kernel.
* tests: new lvcreate functionalityZdenek Kabelac2014-10-244-41/+116
| | | | | | | | | | | | | Fixed syntax parsing means that some commands that used to work are now failing. Particullary this case: $ invalid lvcreate -l1 --type thin vg/pool > Needs to fail becase thin type LV needs --virtualsize $ invalid lvcreate --type snapshot vg/lv1 > Needs to fail because old-snapshot segment type needs --size Some reported error messages have been also updated.
* tests: lvcreate usageZdenek Kabelac2014-10-241-61/+98
|
* mirror: extra parsing for mirrorlog argZdenek Kabelac2014-10-248-36/+59
| | | | Put validation of mirrorlog arg into a separate function.
* man: lvconvert/create updatesZdenek Kabelac2014-10-243-205/+314
| | | | | More description for cache support. Introduce --pooldatasize option.
* cache: separate func for pool/origin validationZdenek Kabelac2014-10-245-32/+32
| | | | | | | Split validate_lv_cache_create() into 2 function once is called for pool validation other for origin. It's less misleading the accepting NULLs.
* segments: mark more of them unzeroableZdenek Kabelac2014-10-244-3/+4
| | | | | | | | | | | Use segment flags to avoid zeroing of cache, cache pool snapshot and thin pool segments. We never want to zero these segment types. Note: Snapshot COW and Cache origin are created as stripes thus are then properly zeroed.
* lvcreate: check for conflicting -Zy -WyZdenek Kabelac2014-10-242-35/+56
| | | | | | | | | | | | | | Let the finaly state of zero & wipe_signature to be resolved later together with all the types. Don't play with zero assigment and segtype flag (i.e. thin-pool -Z has different meaning). Check if the passed options do allow requested zeroing/wiping. lvcreate without -Z or -W will fallback to warning if the device cannot be zeroed, however if user requested them explicitely it will give user error.
* toollib: persistent major minorZdenek Kabelac2014-10-243-49/+53
| | | | | Deduce -M from presence of --minor, --major option if not specified on command line.
* lvcreate: new validation codeZdenek Kabelac2014-10-245-631/+799
| | | | | | | | | | | | | | | | | | | | | Refactor lvcreate code. Prefer to use arg_outside_list_is_set() so we get automatic 'white-list' validation of supported options with different segment types. Drop used lp->cache, lp->cache and use seg_is_cache(), seg_is_thin() Draw clear border where is the last moment we could change create segment type. When segment type is given with --type - do not allow it to be changed later. Put together tests related to individual segment types. Finish cache conversion at proper part of lv_manip code after the vg_metadata are written - so we could correcly clean-up created stripe LV for cache volume.
* pools: error path removes metadataZdenek Kabelac2014-10-241-5/+15
| | | | | When pool volume is create - it has already managed to update metadata once within lv_extend - so revert new created LV here.
* lvcreate: handle linear segmentZdenek Kabelac2014-10-243-1/+18
| | | | | | | Put in code to accept 'linear' segment type (when specified stripes cannot be used) Also report 'error' when unknown type is specified.
* pool: better error path handlingZdenek Kabelac2014-10-241-23/+29
| | | | | | | | | | | | | Move test for size of new LV names in front before any creation of LV. Properly check striped segtype kernel presence, since passed 'segtype' is already tested. Keep deactivation error path local to wiping part of the function. Create metadata with temporary flag (it's activated, zeroed and deactivated).
* cleanup: code moveZdenek Kabelac2014-10-241-98/+98
| | | | | Update comment and move code to new place. Gets updated with next commit.
* cleanup: function embededZdenek Kabelac2014-10-241-11/+5
| | | | It's used just in one place now.
* cleanup: better stack tracingZdenek Kabelac2014-10-241-9/+13
| | | | Show proper backtrace on error path.