mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-18 10:04:20 +03:00
tests: check how thin-pool allocation works
Check allocation of thin-pool works on 2PVs, when one is so full, that even metadata do not fit there (as they need at least 2M, while 99% of 63MB fills >62MB)
This commit is contained in:
parent
6d1c983122
commit
333eb8667e
@ -199,6 +199,17 @@ check vg_field $vg lv_count 6
|
||||
lvremove -ff $vg
|
||||
check vg_field $vg lv_count 0
|
||||
|
||||
|
||||
# Check how allocator works with 2PVs where one is nearly full
|
||||
lvcreate -l99%PV $vg "$dev1"
|
||||
lvs -a $vg
|
||||
# Check when separate metadata is required, allocation needs to fail
|
||||
fail lvcreate -L10 -T --poolmetadataspare n --config 'allocation/thin_pool_metadata_require_separate_pvs=1' $vg
|
||||
# Check when data and metadata may share the same PV, it shall pass
|
||||
lvcreate -L10 -T --poolmetadataspare n --config 'allocation/thin_pool_metadata_require_separate_pvs=0' $vg
|
||||
lvremove -f $vg
|
||||
|
||||
|
||||
# Fail cases
|
||||
# Too small pool size (1 extent 64KB) for given chunk size
|
||||
not lvcreate --chunksize 256 -l1 -T $vg/pool1
|
||||
|
Loading…
x
Reference in New Issue
Block a user