master - thin: fix resize of stacked thin pool volume
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=4c001a78544d29688f6609b1ceafe123af280323 Commit: 4c001a78544d29688f6609b1ceafe123af280323 Parent: fe6b19a6a3deb707243a5728842fff17e52258e0 Author: Zdenek Kabelac <[email protected]> AuthorDate: Fri Sep 6 10:54:50 2013 +0200 Committer: Zdenek Kabelac <[email protected]> CommitterDate: Sat Sep 7 03:24:48 2013 +0200
thin: fix resize of stacked thin pool volume
When the pool is created from non-linear target the more complex rules have to be used and stacking needs to properly decode args for _tdata LV. Also proper allocation policies are being used according to those set in lvm2 metadata for data and metadata LVs.
Also properly check for active pool and extra code to active it temporarily.
With this fix it's now possible to use:
lvcreate -L20 -m2 -n pool vg --alloc anywhere lvcreate -L10 -m2 -n poolm vg --alloc anywhere lvconvert --thinpool vg/pool --poolmetadata vg/poolm
lvresize -L+10 vg/pool
--- WHATS_NEW | 1 + lib/metadata/lv_manip.c | 160 +++++++++++++++++++++++++------------- lib/metadata/metadata-exported.h | 1 + 3 files changed, 107 insertions(+), 55 deletions(-)
WHATS_NEW +1 -0
@@ -1,5 +1,6 @@ Version 2.02.101 - =================================== + Fix lvresize for stacked thin pool volumes (i.e. mirrors). Write Completed debug message before reinstating log defaults after command. Skip pvmove of RAID, thin, snapshot, origin, or mirror LVs in a cluster. Refresh existing VG before autoactivation (event retrigger/device reappeared).
lib/metadata/lv_manip.c +105 -55
280 lines not on this page · raw message
lib/metadata/metadata-exported.h +1 -0
@@ -455,6 +455,7 @@ struct lvresize_params {sign_t sign;uint64_t poolmetadatasize;sign_t poolmetadatasign; +uint32_t poolmetadataextents;percent_type_t percent;enum {