Has anyone else had this issue before when updating the BIOS on PopOS or any Linux flavor?

I’m running PopOS 22.04 on a Dell XPS 13 9300 and when I try to update the Dell firmware from 1.17.0 to 1.18.0 I get the following error:

error in fwupd client: calling Install method failed: /boot/efi does not have sufficient space, required 59.2 MB, got 48.6 MB

Running sudo apt autoremove does not fix this. Running sudo fwupdmgr refresh --force and then sudo fwupdmgr update still has the error.

I would really like to not have to backup and resize and pray that nothing breaks when resizing the main partition for more space. Plus there’s no good guide on exactly what steps to take for that.

Any help would be appreciated.

More info:

sudo ls /boot/efi
EFI  f52dfaf1ebdd214ad023db586322b2ef  loader

Firmware Upgrade Screen

  • Michael Murphy (S76)@lemmy.worldM
    link
    fedilink
    English
    arrow-up
    4
    ·
    1 year ago

    If you have an older installation with a the 512 MB EFI partition, you need to edit /etc/initramfs-tools/initramfs.conf and set COMPRESS to xz. Then the next time you update the initramfs (sudo update-initramfs -c -k all), it should recover around 150 MB of space. We will probably change this to xz soon.

    • pnutzh4x0r@programming.dev
      link
      fedilink
      English
      arrow-up
      2
      ·
      edit-2
      1 year ago

      I just did this and was able to recover closer to 100MB (now have 128MB available)… still a great improvement. Boot times don’t appear to be impacted, though compression is slower (almost 3-4x slower).

  • pnutzh4x0r@lemmy.world
    link
    fedilink
    English
    arrow-up
    3
    ·
    1 year ago

    Yes, I’ve run into this issue recently. The /boot/efi folder is actually its own partition, so removing packages from / will not give your more space for the efi partition. On my recentish Pop install, the /boot/efi partition is about 512MB which is just about enough space for two kernels but… not much else (they may have increased this to 1GB for new installs).

    The workaround I did was to simply delete one of the kernels in /boot/efi/EFI/Pop_OS-... (the ... is some string of letters). In this folder you should have the following:

    $ ls -l /boot/efi/EFI/Pop_OS-f2c685b9-a9c2-48f0-907b-ebe199e94a55
    total 289256
    -rwx------ 1 root root       167 Jul 12 15:24 cmdline
    -rwx------ 1 root root 134046998 Jul 12 15:24 initrd.img
    -rwx------ 1 root root 134449391 Jul 12 15:24 initrd.img-previous
    -rwx------ 1 root root  13844192 Jul 12 15:24 vmlinuz.efi
    -rwx------ 1 root root  13846496 Jul 12 15:24 vmlinuz-previous.efi
    

    As you can see, Pop stores the current kernel (vmlinuz) and ramdisk (initrd) along with the corresponding previous versions in case you need/want to revert back to the previous kernel. To free up some space, you can simply delete either the initrd.img-previous or vmlinuz-previous.efi file if you are not using the previous kernel. That should allow you to then download the firmware and update it.

    After the firmware update, if you want to restore the previous (backup) kernel, you can copy it from /boot back to the efi folder above. Otherwise, the next kernel update will replace it for you anyways.

    I hope this helps, good luck.

    • JoyfulCodingGuy@lemmy.mlOP
      link
      fedilink
      English
      arrow-up
      2
      ·
      1 year ago

      Thank you so much for this. It made a lot of sense and I followed exactly and it all worked! Which makes sense. I ended up removing the initrd.img-previous and went through with the update. Eventually maybe I’ll need to resize the partition but for now this is my solution.

    • eric5949@lemmy.cloudaf.site
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      You can also burn gparted to a USB and resize the partition. I had to do this a year or two ago on my arch install when I installed zen kernel.