All of lore.kernel.org
 help / color / mirror / Atom feed
From: snitzer@sourceware.org <snitzer@sourceware.org>
To: lvm-devel@redhat.com
Subject: LVM2/test t-metadata.sh
Date: 16 Aug 2010 23:21:20 -0000	[thread overview]
Message-ID: <20100816232120.25384.qmail@sourceware.org> (raw)

CVSROOT:	/cvs/lvm2
Module name:	LVM2
Changes by:	snitzer at sourceware.org	2010-08-16 23:21:20

Modified files:
	test           : t-metadata.sh 

Log message:
	Add some v1 to v2 metadata upgrade testing.

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/test/t-metadata.sh.diff?cvsroot=lvm2&r1=1.4&r2=1.5

--- LVM2/test/t-metadata.sh	2009/12/28 18:33:04	1.4
+++ LVM2/test/t-metadata.sh	2010/08/16 23:21:20	1.5
@@ -51,5 +51,32 @@
 pvcreate -M1 $dev1
 pvcreate -M1 $dev2
 pvcreate -M1 $dev3
+pv3_uuid=$(pvs --noheadings -o pv_uuid $dev3)
 vgcreate -M1 -c n $vg $dev1 $dev2 $dev3
 pvchange --uuid $dev1
+
+# verify pe_start of all M1 PVs
+pv_align="128.00k"
+check_pv_field_ $dev1 pe_start $pv_align
+check_pv_field_ $dev2 pe_start $pv_align
+check_pv_field_ $dev3 pe_start $pv_align
+
+pvs --units k -o name,pe_start,vg_mda_size,vg_name
+
+# upgrade from v1 to v2 metadata
+vgconvert -M2 $vg
+
+# verify pe_start of all M2 PVs
+check_pv_field_ $dev1 pe_start $pv_align
+check_pv_field_ $dev2 pe_start $pv_align
+check_pv_field_ $dev3 pe_start $pv_align
+
+pvs --units k -o name,pe_start,vg_mda_size,vg_name
+
+# create backup and then restore $dev3
+vgcfgbackup -f $TESTDIR/bak-%s $vg
+pvcreate -ff -y --restorefile $TESTDIR/bak-$vg --uuid $pv3_uuid $dev3
+vgcfgrestore -f $TESTDIR/bak-$vg $vg
+
+# verify pe_start of $dev3
+check_pv_field_ $dev3 pe_start $pv_align



             reply	other threads:[~2010-08-16 23:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-16 23:21 snitzer [this message]
  -- strict thread matches above, loose matches on Subject: below --
2010-10-26 12:52 LVM2/test t-metadata.sh mornfall

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100816232120.25384.qmail@sourceware.org \
    --to=snitzer@sourceware.org \
    --cc=lvm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.