From: Forza <forza@tnonline.net>
To: Matt Zagrabelny <mzagrabe@d.umn.edu>
Cc: Btrfs BTRFS <linux-btrfs@vger.kernel.org>,
Matthew Warren <matthewwarren101010@gmail.com>
Subject: Re: raid1 root device with efi
Date: Thu, 28 Mar 2024 12:42:27 +0100 (GMT+01:00) [thread overview]
Message-ID: <5c2a178.354ec378.18e84de55cf@tnonline.net> (raw)
In-Reply-To: <CAOLfK3UuMNn1Q2t-seqcOXu4xVbWQU4rOSVkY2qn4RsyOcBCAA@mail.gmail.com>
---- From: Matt Zagrabelny <mzagrabe@d.umn.edu> -- Sent: 2024-03-27 - 21:21 ----
>
> Are folks using the "degraded" option in /etc/fstab or the grub mount
> options for the btrfs mount?
>
> I've read online [0] that the degraded option can cause issues due to
> timeouts being exceeded.
No, i do not recommend it. The issue isn't with grub, but if a device is missing during boot (hotplug, cables, errors, etc), and the system continues to use the remaining disk and later the disk comes back online you would have a split-brain situation. As far as I know there is no specific handling in btrfs for this, and the recommended way is to wipefs a removed device before adding it back.
For this reason it is better to be forced to manually handle the situation. You could, for example have a second boot entry for degraded mode, etc.
>
> Also, I'm seeing some confusing results of looking at the UUID of my disks:
>
> root@achilles:~# blkid | grep /dev/sd
> /dev/sdb2: UUID="9a46a8ad-de37-48c0-ad96-2c54df42dd5a"
> UUID_SUB="7737fc5f-036d-4126-9d7c-f1726d550444" BLOCK_SIZE="4096"
> TYPE="btrfs" PARTUUID="3a22621c-a4e1-8641-aa0f-990a824fabf4"
> /dev/sdb1: UUID="BD42-AEB1" BLOCK_SIZE="512" TYPE="vfat"
> PARTUUID="43e432b1-6c68-4b5c-9c30-793fcc10a700"
> /dev/sda2: UUID="9a46a8ad-de37-48c0-ad96-2c54df42dd5a"
> UUID_SUB="9436f570-6d15-4c74-aff8-5bd85995d92d" BLOCK_SIZE="4096"
> TYPE="btrfs" PARTUUID="e3b4b268-99e8-4043-a879-acfc8318232b"
> /dev/sda1: UUID="BD42-AEB1" BLOCK_SIZE="512" TYPE="vfat"
> PARTUUID="02568ee9-db21-4d03-a898-3d1a106ecbec"
>
> ...why does /dev/sdb2 show up in the following /dev/disk/by-uuid, but
> not /dev/sda2:
>
> root@achilles:~# ls -alh /dev/disk/by-uuid/
> total 0
> drwxr-xr-x 2 root root 80 Mar 25 21:16 .
> drwxr-xr-x 7 root root 140 Mar 25 21:16 ..
> lrwxrwxrwx 1 root root 10 Mar 25 21:16
> 9a46a8ad-de37-48c0-ad96-2c54df42dd5a -> ../../sdb2
> lrwxrwxrwx 1 root root 10 Mar 25 21:16 BD42-AEB1 -> ../../sda1
I believe only the first device found can have a link. It is not possible to have multiple link from one UUID to several devices.
>
> What do folks think about the following fstab?
>
> root@achilles:~# cat /etc/fstab
> #
> # <file system> <mount point> <type>
> <options> <dump> <pass>
> # / was on /dev/sda2 during installation
> UUID=9a46a8ad-de37-48c0-ad96-2c54df42dd5a / btrfs
> defaults,degraded,subvol=@ 0 0
> UUID=9a46a8ad-de37-48c0-ad96-2c54df42dd5a /home btrfs
> defaults,degraded,subvol=@home 0 0
> # /boot/efi was on /dev/sda1 during installation
> UUID=BD42-AEB1 /boot/efi vfat
> umask=0077 0 1
>
I recommend you do not use degraded. Instead maybe you'd want noatime, unless you have strong reasons for using atime system-wide. The keyword "defaults" is mostly a placeholder and isn't needed if you have other options.
https://github.com/kdave/btrfs-progs/issues/377
~ Forza
prev parent reply other threads:[~2024-03-28 12:11 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-08 20:39 raid1 root device with efi Matt Zagrabelny
2024-03-08 21:02 ` Qu Wenruo
2024-03-08 21:46 ` Matthew Warren
2024-03-08 21:48 ` Matt Zagrabelny
2024-03-08 21:54 ` Matthew Warren
2024-03-08 21:58 ` Matt Zagrabelny
2024-03-10 17:57 ` Forza
2024-03-11 14:34 ` Kai Krakow
2024-03-11 19:26 ` Goffredo Baroncelli
2024-03-12 12:39 ` Kai Krakow
2024-03-12 18:55 ` Goffredo Baroncelli
2024-03-27 20:21 ` Matt Zagrabelny
2024-03-28 4:03 ` Andrei Borzenkov
2024-03-28 11:42 ` Forza [this message]
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=5c2a178.354ec378.18e84de55cf@tnonline.net \
--to=forza@tnonline.net \
--cc=linux-btrfs@vger.kernel.org \
--cc=matthewwarren101010@gmail.com \
--cc=mzagrabe@d.umn.edu \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox