[linux-lvm] activation mode=degraded doesn't work with thin pool
Alexander 'Leo' Bergolth
leo at strike.wu.ac.at
Tue Oct 17 13:45:25 UTC 2017
Hi!
I just tested lv activation with a degraded raid1 thin pool.
Unfortunately it looks like activation mode=degraded only works for
plain raid1 lvs. If you add a thin pool, lvm won't activate it in
degraded mode. (Unless you specify --activationmode partial, which is
IMHO rather dangerous.)
Is this the intended behavior?
-------------------- 8< --------------------
# lvcreate --type raid1 -m 1 -n thinmeta -L100m vg1 /dev/sda2 /dev/sdb2
Logical volume "thinmeta" created.
# lvcreate --type raid1 -m 1 -n Thin -L2g vg1 /dev/sda2 /dev/sdb2
Logical volume "Thin" created.
# lvconvert -y --type thin-pool --poolmetadata vg1/thinmeta vg1/Thin
Thin pool volume with chunk size 64.00 KiB can address at most 15.81 TiB of data.
WARNING: Converting logical volume vg1/Thin and vg1/thinmeta to thin pool's data and metadata volumes with metadata wiping.
THIS WILL DESTROY CONTENT OF LOGICAL VOLUME (filesystem etc.)
Converted vg1/Thin_tdata to thin pool.
# vgchange -a n vg1
0 logical volume(s) in volume group "vg1" now active
### filter one leg of the raid: global_filter = [ "r|^/dev/sdb2|" ]
# systemctl restart lvm2-lvmetad.service
# pvscan --cache
# vgchange -a y
WARNING: Device for PV WzDZS1-Hj9B-RZCa-uhOc-pY9L-1rLN-GB5Zs1 not found or rejected by a filter.
Refusing activation of partial LV vg1/Thin. Use '--activationmode partial' to override.
0 logical volume(s) in volume group "vg1" now active
-------------------- 8< --------------------
(--activationmode partial works)
I am using lvm2-2.02.171-8.el7.x86_64.
Cheers,
--leo
--
e-mail ::: Leo.Bergolth (at) wu.ac.at
fax ::: +43-1-31336-906050
location ::: IT-Services | Vienna University of Economics | Austria
More information about the linux-lvm
mailing list