master - tests: update test
Gitweb: http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=96a1943fb8d208aa84c386cf48f2b62038b09e2e Commit: 96a1943fb8d208aa84c386cf48f2b62038b09e2e Parent: 14902d173917e814061a80f16ea54435abba1f91 Author: Zdenek Kabelac <[email protected]> AuthorDate: Fri Dec 23 12:52:45 2016 +0100 Committer: Zdenek Kabelac <[email protected]> CommitterDate: Fri Dec 23 13:16:35 2016 +0100
tests: update test
lvm2 now correctly reports thin_id after action of merged thin, but before physical metadata update as we know the merge has happened.
--- test/shell/thin-vglock.sh | 15 ++++++++++++--- 1 files changed, 12 insertions(+), 3 deletions(-)
test/shell/thin-vglock.sh +12 -3
@@ -1,5 +1,5 @@ #!/bin/sh -# Copyright (C) 2014 Red Hat, Inc. All rights reserved. +# Copyright (C) 2014-2016 Red Hat, Inc. All rights reserved. # # This copyrighted material is made available to anyone wishing to use, # modify, copy, or redistribute it subject to the terms and conditions
@@ -37,15 +37,24 @@ check lv_field $vg/snap thin_id "3" lvconvert --merge $vg/snap umount mnt + +check lv_field $vg/$lv1 thin_id "1" +check lv_field $vg/pool transaction_id "3" + vgchange -an $vg # Check reboot case vgchange -ay --sysinit $vg -# Metadata are still not updated (--poll n) -check lv_field $vg/$lv1 thin_id "1" + +# Check correct thin_id is shown after activation +# even when metadata were not yet physically modified. +# Merge take its place during activation, +# but pool transaction_id still needs metadata update. +check lv_field $vg/$lv1 thin_id "3" check lv_field $vg/pool transaction_id "3" # Check the metadata are updated after refresh +# vgchange --refresh $vg check lv_field $vg/$lv1 thin_id "3" check lv_field $vg/pool transaction_id "4"