D10203: loader: zfs reader should check all labels
Toomas Soome
tsoome at me.com
Thu Mar 30 16:52:56 UTC 2017
Hi!
Sorry about forward, but this patch is something a bit more complicated and if we have some people willing to test, it would be really nice:) I have had it around for my illumos port for some time now, but those small details about the zfsboot/gptzfsboot etc sometimes do count a lot…
thanks,
toomas
> Begin forwarded message:
>
> From: "tsoome (Toomas Soome)" <phabric-noreply at FreeBSD.org>
> Subject: [Differential] D10203: loader: zfs reader should check all labels
> Date: 30. märts 2017 18:39.44 GMT+3
> To: tsoome at me.com
> Reply-To: D10203+574+d76c8a36ba3c3f0a at reviews.freebsd.org
>
> tsoome created this revision.
> Herald added a subscriber: delphij.
>
> REVISION SUMMARY
> The current zfs reader is only checking first label from each device, however,
> we do have 4 labels on device and we should check all 4 to be protected
> against disk failures and incomplete label updates.
>
> The difficulty is about the fact that 2 label copies are in front of the
> pool data, and 2 are at the end, which means, we have to know the size of
> the pool data area.
>
> Since we have now the mechanism from common/disk.c to use the partition
> information, it does help us in this task; however, there are still some
> corner cases.
>
> Namely, if the pool is created without partition, directly on the disk,
> and firmware will give us the wrong size for the disk, we only can check
> the first two label copies.
>
> REPOSITORY
> rS FreeBSD src repository
>
> REVISION DETAIL
> https://reviews.freebsd.org/D10203
>
> AFFECTED FILES
> sys/boot/efi/boot1/zfs_module.c
> sys/boot/efi/loader/main.c
> sys/boot/i386/common/drv.h
> sys/boot/i386/loader/main.c
> sys/boot/i386/zfsboot/zfsboot.c
> sys/boot/zfs/libzfs.h
> sys/boot/zfs/zfsimpl.c
>
> EMAIL PREFERENCES
> https://reviews.freebsd.org/settings/panel/emailpreferences/
>
> To: tsoome, allanjude, imp, avg
> Cc: delphij
More information about the freebsd-current
mailing list