[Bug 256024] [zfs] `zpool upgrade' doesn't warn about updating bootloader anymore

From: <bugzilla-noreply_at_freebsd.org>
Date: Fri, 21 May 2021 10:18:40 +0000
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=256024

Ronald Klop <ronald-lists_at_klop.ws> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ronald-lists_at_klop.ws

--- Comment #11 from Ronald Klop <ronald-lists_at_klop.ws> ---
My upgrade script does something like this: (pseudocode for brevity)

PART=/dev/ada0p1
BOOTFILE=/boot/gptzfsboot
FILESIZE=$( stat -f "%z" $BOOTFILE )

CURBOOT_MD5=`head -c $FILESIZE $PART | md5 -q /dev/stdin`
NEWBOOT_MD5=`md5 -q $BOOTFILE`
if CURBOOT_MD5 != NEWBOOT_MD5; then
    echo "Upgrade your bootblocks."
    echo "gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 $PART"
fi

This can probably made more general. Just my 2 cents.

-- 
You are receiving this mail because:
You are the assignee for the bug.
Received on Fri May 21 2021 - 10:18:40 UTC

Original text of this message