[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH V2] Add support for BTRFS raid5/6 to GRUB
From: |
Goffredo Baroncelli |
Subject: |
[PATCH V2] Add support for BTRFS raid5/6 to GRUB |
Date: |
Tue, 24 Apr 2018 21:13:09 +0200 |
Hi All,
the aim of this patches set is to provide support for a BTRFS raid5/6
filesystem in GRUB.
The first patch, implements the basic support for raid5/6. I.e this works when
all the disks
are present.
The next 4 patches, are preparatory ones.
The last two implements the support for raid5/6 recovery. It allow to read
from the filesystem even when 1 or 2 (for raid 6) disk(s) are missing.
The last one is the more controversial. The code for the raid6 recovery is
copied from the GRUB file reaid6_recovery.c . I preferred this approach,
because the original code assumes that the read is GRUB_DISK_SECTOR_SIZE
bytes based (512 bytes). Instead the GRUB BTRFS implementation need to
read the disk with a granularity of the byte.
I tried to update the code (and the function which the code calls), but
the change was quite invasive. So for now I preferred to duplicating the
code, to get some feedback.
I tested the code in grub-emu, and it works (for me) both with all the disks,
and with some disks missing. I checked the sh1sums calculated from grub and
from linux and these matched.
Comments are welcome.
BR
G.Baroncelli
--
gpg @keyserver.linux.it: Goffredo Baroncelli <kreijackATinwind.it>
Key fingerprint BBF5 1610 0B64 DAC6 5F7D 17B2 0EDA 9B37 8B82 E0B5
- [PATCH V2] Add support for BTRFS raid5/6 to GRUB,
Goffredo Baroncelli <=
- [PATCH 1/7] Add support for reading a filesystem with a raid5 or raid6 profile., Goffredo Baroncelli, 2018/04/24
- [PATCH 2/7] Add helper to check the btrfs header., Goffredo Baroncelli, 2018/04/24
- [PATCH 3/7] Move from the find_device the error logging logic to the callee., Goffredo Baroncelli, 2018/04/24
- [PATCH 4/7] Avoiding scanning for an already not found device., Goffredo Baroncelli, 2018/04/24
- [PATCH 5/7] Refactor the code of read from disk, Goffredo Baroncelli, 2018/04/24
- [PATCH 6/7] Add support for recovery for a raid5 btrfs profiles., Goffredo Baroncelli, 2018/04/24
- [PATCH 7/7] Add raid6 recovery., Goffredo Baroncelli, 2018/04/24