From 327caa1f084acca6fba288781c99002b6a71aff7 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Sat, 18 Mar 2017 10:11:13 +0000 Subject: [PATCH] test-data: Use another name for boot and root MD devices. mdadm 4.0 no longer lets you create devices called literally "boot" or "root", giving a very obscure error message: https://bugzilla.redhat.com/show_bug.cgi?id=1433575 Work around this by calling them something else. --- test-data/phony-guests/make-fedora-img.pl | 10 +++++----- tests/md/test-inspect-fstab-md.sh | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/test-data/phony-guests/make-fedora-img.pl b/test-data/phony-guests/make-fedora-img.pl index 21b3312b4..a08965e48 100755 --- a/test-data/phony-guests/make-fedora-img.pl +++ b/test-data/phony-guests/make-fedora-img.pl @@ -83,7 +83,7 @@ LABEL=ROOT / ext2 default 0 0 EOF close ($fstab) or die; - $bootdev = '/dev/md/boot'; + $bootdev = '/dev/md/bootdev'; foreach my $img (@images) { $g->disk_create ($img, "raw", $IMAGE_SIZE); @@ -100,8 +100,8 @@ EOF } } - $g->md_create ('boot', ['/dev/sda1', '/dev/sdb1']); - $g->md_create ('root', ['/dev/sda2', '/dev/sdb2']); + $g->md_create ('bootdev', ['/dev/sda1', '/dev/sdb1']); + $g->md_create ('rootdev', ['/dev/sda2', '/dev/sdb2']); open (my $mdadm, '>', "fedora.mdadm") or die; print $mdadm <md_detail ("/dev/md/$_"); print $mdadm "ARRAY /dev/md$i level=raid1 num-devices=2 UUID=", $detail{uuid}, "\n"; @@ -119,7 +119,7 @@ EOF close ($mdadm) or die; - init_lvm_root ('/dev/md/root'); + init_lvm_root ('/dev/md/rootdev'); } elsif ($ENV{LAYOUT} eq 'btrfs') { diff --git a/tests/md/test-inspect-fstab-md.sh b/tests/md/test-inspect-fstab-md.sh index 1744dfa93..5d381038e 100755 --- a/tests/md/test-inspect-fstab-md.sh +++ b/tests/md/test-inspect-fstab-md.sh @@ -40,10 +40,10 @@ if [ "$(cat inspect-fstab-md.output)" != "true" ]; then exit 1 fi -# Test inspection when /boot is specfied as /dev/md/boot +# Test inspection when /boot is specfied as /dev/md/bootdev cat <<'EOF' > inspect-fstab-md.fstab /dev/VG/Root / ext2 default 0 0 -/dev/md/boot /boot ext2 default 0 0 +/dev/md/bootdev /boot ext2 default 0 0 EOF guestfish --format=raw -a inspect-fstab-md-1.img --format=raw -a inspect-fstab-md-2.img <<'EOF' @@ -57,7 +57,7 @@ guestfish -i --format=raw -a inspect-fstab-md-1.img --format=raw -a inspect-fsta EOF if [ "$(cat inspect-fstab-md.output)" != "true" ]; then - echo "$0: error: /boot not correctly mounted (/dev/md/boot)" + echo "$0: error: /boot not correctly mounted (/dev/md/bootdev)" cat inspect-fstab-md.output exit 1 fi