diff options
| author | Cyril Brulebois <cyril@debamax.com> | 2021-10-21 16:35:40 +0200 |
|---|---|---|
| committer | Cyril Brulebois <cyril@debamax.com> | 2021-10-21 16:35:43 +0200 |
| commit | f89f71560d2ca1bd60d97dbb26b89782657d56ae (patch) | |
| tree | 8d803cfd9183385b87d651d49eb74333524f55cd | |
| parent | 46ead8a58dcc3e267627e329cd73f2a1013a7003 (diff) | |
Make label-based booting persistent (see: #996915).
Without this, the block device holding the root filesystem would be
resolved at the first boot when reconfiguring raspi-firmware (e.g.
/dev/mmcblk1p2) which would then make the system fail to boot if it
ever shows up under a different name (e.g. /dev/mmcblk0p2).
Set ROOTPART parameter explicitly to stick to label-based booting.
| -rw-r--r-- | raspi_master.yaml | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/raspi_master.yaml b/raspi_master.yaml index 41b1a90..e4383a0 100644 --- a/raspi_master.yaml +++ b/raspi_master.yaml @@ -140,11 +140,13 @@ steps: # the partition labeled raspiroot instead of forcing it to mmcblk0p2 # # These changes will be overwritten after the hardware is probed - # after dpkg reconfigures raspi-firmware (upon first boot). + # after dpkg reconfigures raspi-firmware (upon first boot), so make + # sure we don't lose label-based booting. - chroot: / shell: | sed -i 's/^/console=__SERIAL_CONSOLE__ /' /boot/firmware/cmdline.txt sed -i 's#root=/dev/mmcblk0p2#root=LABEL=RASPIROOT#' /boot/firmware/cmdline.txt + sed -i 's/^#ROOTPART=.*/ROOTPART=LABEL=RASPIROOT/' /etc/default/raspi-firmware # TODO(https://github.com/larswirzenius/vmdb2/issues/24): remove once vmdb # clears /etc/resolv.conf on its own. |
