components/boot, teams/server: Add partitioning hack for the Raspberry Pi 3

The Raspberry Pi 3 does not recognize a FAT filesystem marked with
the 0xef type, so until we drop support for this device, hack the
partition manually to use a legacy FAT filesystem partition type.
This commit is contained in:
Neal Gompa
2025-02-20 14:46:28 -05:00
parent 5844c5c608
commit fcdcd34d50
3 changed files with 19 additions and 2 deletions
+1 -1
View File
@@ -29,7 +29,7 @@
<preferences profiles="BootDiskCore" arch="aarch64"> <preferences profiles="BootDiskCore" arch="aarch64">
<type image="oem" <type image="oem"
filesystem="btrfs" btrfs_root_is_subvolume="true" btrfs_set_default_volume="false" fsmountoptions="x-systemd.growfs,compress=zstd:1" filesystem="btrfs" btrfs_root_is_subvolume="true" btrfs_set_default_volume="false" fsmountoptions="x-systemd.growfs,compress=zstd:1"
kernelcmdline="rhgb quiet" devicepersistency="by-uuid" force_mbr="true" kernelcmdline="rhgb quiet" devicepersistency="by-uuid" force_mbr="true" editbootinstall="editbootinstall_rpilegacy.sh"
bootpartition="true" bootpartsize="1024" bootfilesystem="ext4" efipartsize="500" firmware="uefi" bootpartition="true" bootpartsize="1024" bootfilesystem="ext4" efipartsize="500" firmware="uefi"
rootfs_label="fedora" rootfs_label="fedora"
> >
+17
View File
@@ -0,0 +1,17 @@
#!/bin/bash
set -euxo pipefail
diskname=$1
devname="$2"
loopname="${devname%*p?}"
loopdev=/dev/${loopname#/dev/*}
#==========================================
# Force the ESP to use legacy MBR identifier
#------------------------------------------
#
# Raspberry Pi 3 and older systems don't handle
# the 0xef partition type for the ESP, so switch
# to the legacy one.
#
sfdisk --change-id ${loopdev} 1 6
+1 -1
View File
@@ -110,7 +110,7 @@
<preferences profiles="ServerDisk" arch="aarch64"> <preferences profiles="ServerDisk" arch="aarch64">
<type image="oem" <type image="oem"
filesystem="xfs" filesystem="xfs"
devicepersistency="by-uuid" force_mbr="true" devicepersistency="by-uuid" force_mbr="true" editbootinstall="editbootinstall_rpilegacy.sh"
bootpartition="true" bootpartsize="1000" bootfilesystem="ext4" efipartsize="500" firmware="uefi" bootpartition="true" bootpartsize="1000" bootfilesystem="ext4" efipartsize="500" firmware="uefi"
rootfs_label="fedora" rootfs_label="fedora"
> >