aboutsummaryrefslogtreecommitdiff
path: root/gnu/tests
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-01-19 15:18:25 +0100
committerLudovic Courtès <ludo@gnu.org>2020-01-19 23:11:37 +0100
commit3adf320e44e54017a67f219ce9667a379c393dad (patch)
tree3193dd6a9b44e9b4f12b51a3d52194f80ad1088f /gnu/tests
parent1fa342323619372326106fb923e72ae7beecb5e6 (diff)
downloadguix-3adf320e44e54017a67f219ce9667a379c393dad.tar
guix-3adf320e44e54017a67f219ce9667a379c393dad.tar.gz
tests: install: "raid-root-os" test uses RAID-1 instead of RAID-0.
Fixes <https://bugs.gnu.org/38086>. Thanks to Vagrant and Tobias! * gnu/tests/install.scm (%raid-root-os)[initrd-modules]: Add "raid1" instead of "raid0". (%raid-root-installation-script): Make the partitions twice as big. Invoke 'mdadm' with '--level=mirror' instead of '--level=stripe'; connect "yes" to its stdin. (%test-raid-root-os): Set #:target-size to 2.8 GiB.
Diffstat (limited to 'gnu/tests')
-rw-r--r--gnu/tests/install.scm14
1 files changed, 7 insertions, 7 deletions
diff --git a/gnu/tests/install.scm b/gnu/tests/install.scm
index 8842d48df8..d475bda2c7 100644
--- a/gnu/tests/install.scm
+++ b/gnu/tests/install.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2016, 2017, 2018, 2019, 2020 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2017, 2019 Tobias Geerinckx-Rice <me@tobias.gr>
;;;
;;; This file is part of GNU Guix.
@@ -546,8 +546,8 @@ where /gnu lives on a separate partition.")
(target "/dev/vdb")))
(kernel-arguments '("console=ttyS0"))
- ;; Add a kernel module for RAID-0 (aka. "stripe").
- (initrd-modules (cons "raid0" %base-initrd-modules))
+ ;; Add a kernel module for RAID-1 (aka. "mirror").
+ (initrd-modules (cons "raid1" %base-initrd-modules))
(mapped-devices (list (mapped-device
(source (list "/dev/vda2" "/dev/vda3"))
@@ -578,11 +578,11 @@ guix --version
export GUIX_BUILD_OPTIONS=--no-grafts
parted --script /dev/vdb mklabel gpt \\
mkpart primary ext2 1M 3M \\
- mkpart primary ext2 3M 600M \\
- mkpart primary ext2 600M 1200M \\
+ mkpart primary ext2 3M 1.4G \\
+ mkpart primary ext2 1.4G 2.8G \\
set 1 boot on \\
set 1 bios_grub on
-mdadm --create /dev/md0 --verbose --level=stripe --raid-devices=2 \\
+yes | mdadm --create /dev/md0 --verbose --level=mirror --raid-devices=2 \\
/dev/vdb2 /dev/vdb3
mkfs.ext4 -L root-fs /dev/md0
mount /dev/md0 /mnt
@@ -605,7 +605,7 @@ by 'mdadm'.")
%raid-root-os-source
#:script
%raid-root-installation-script
- #:target-size (* 1300 MiB)))
+ #:target-size (* 2800 MiB)))
(command (qemu-command/writable-image image)))
(run-basic-test %raid-root-os
`(,@command) "raid-root-os")))))