Skip to content
Snippets Groups Projects
  1. Feb 03, 2022
    • Diederik de Haas's avatar
      Replace resize-roofs mechanism entirely · 9a744b05
      Diederik de Haas authored
      All credits for this go to 'dilinger', ie Andres Salomon.
      
      Instead of resizing the root partition and its filesystem via a systemd
      unit file, do it via a script in the initramfs, thus before the root
      filesystem gets mounted.
      The needed programs are copied into the initramfs during image build,
      but the files themselves get removed again, so that when the initramfs
      gets rebuild (on kernel upgrade f.e.), the resize-rootfs script and its
      needed components get removed entirely.
      
      The logic is that it looks whether there is free space after the *last*
      partition and if so, resize that partition to use all the available
      space. This actually (also) fixes a bug as previously the assumption was
      that the root partition was partition number 3, which of course fails
      when that was not the case.
      After resizing the partition, resize the filesystem on it too.
      Note that it uses the resize2fs program, so it only works on ext[2|3|4].
      
      raspi-team/image-specs@0f23b8e3
      raspi-team/image-specs@4816680b
      are the 2 commits from which this commit is derived.
      9a744b05
  2. Nov 12, 2021
  3. Sep 27, 2021
  4. Aug 21, 2021
  5. Aug 20, 2021
  6. Jul 29, 2021
  7. Mar 21, 2021
  8. Mar 20, 2021
  9. Mar 15, 2021
Loading