From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ludovic =?UTF-8?Q?Court=C3=A8s?= Subject: bug#38086: RAID installation script with =?UTF-8?Q?=E2=80=98mdadm=E2=80=99?= no longer works Date: Sat, 18 Jan 2020 22:46:48 +0100 Message-ID: <87lfq4v3nb.fsf@gnu.org> References: <87sgn18g92.fsf@inria.fr> <877e46m1qd.fsf@gnu.org> <87r1zx902a.fsf@yucca> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:34491) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1isvvr-0004sh-H7 for bug-guix@gnu.org; Sat, 18 Jan 2020 16:47:04 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1isvvq-0005Gt-Ci for bug-guix@gnu.org; Sat, 18 Jan 2020 16:47:03 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:36439) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1isvvq-0005Gk-9W for bug-guix@gnu.org; Sat, 18 Jan 2020 16:47:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1isvvq-0002le-4f for bug-guix@gnu.org; Sat, 18 Jan 2020 16:47:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87r1zx902a.fsf@yucca> (Vagrant Cascadian's message of "Fri, 17 Jan 2020 14:42:53 -0800") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane-mx.org@gnu.org Sender: "bug-Guix" To: Vagrant Cascadian Cc: 38086@debbugs.gnu.org --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Hi! Vagrant Cascadian skribis: > So, this might be sort of a tangent, but I'm wondering why you're > testing raid0 (striping, for performance+capacity at risk of data loss) > instead of raid1 (mirroring, for redundancy, fast reads, slow writes, > half capacity of storage), or another raid level with more disks (raid5, > raid6, raid10). raid1 would be the simplest to switch the code to, since > it uses only two disks. Good point! I guess it would make sense to test RAID1, indeed. I gave it a shot with the patch below. Problem is that installation seemingly hangs here: --8<---------------cut here---------------start------------->8--- + parted --script /dev/vdb mklabel gpt mkpart primary ext2 1M 3M mkpart pri= mary ext2 3M 1.4G mkpart primary ext2 1.4G 2.8G set 1 boot on set 1 bios_gr= ub on + mdadm --create /dev/md0 --verbose --level=3Dmirror --raid-devices=3D2 /de= v/vdb2 /dev/vdb3 mdadm: Note: this array has metadata at the start and may not be suitable as a boot device. If you plan to store '/boot' on this device please ensure that your boot-loader understands md/v1.x metadata, or use --metadata=3D0.90 mdadm: size set to 1361920K mdadm: largest drive (/dev/vdb3) exceeds size (1361920K) by more than 1% --8<---------------cut here---------------end--------------->8--- As you can see, it=E2=80=99s attempting to make a RAID1 device out of two partitions (not two disks), which makes no sense in the real world, but is easier to handle here. So I wonder if this is what=E2=80=99s causing it= to hang=E2=80=A6 Thoughts? Ludo=E2=80=99. --=-=-= Content-Type: text/x-patch Content-Disposition: inline diff --git a/gnu/tests/install.scm b/gnu/tests/install.scm index 8842d48df8..12e6eb26df 100644 --- a/gnu/tests/install.scm +++ b/gnu/tests/install.scm @@ -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 \\ +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"))))) --=-=-=--