xps13 icon indicating copy to clipboard operation
xps13 copied to clipboard

grub-install: error: failed to register the EFI boot entry: No space left on device.

Open dahabakuk opened this issue 6 years ago • 6 comments

hi, my grub works and i can boot my system just fine but since some time now, it looks like grub cannot update the bootloader: i run debian buster and currently i get this everytime theres a grub update:

Installing for x86_64-efi platform. grub-install: warning: Cannot set EFI variable Boot0008. grub-install: warning: efivarfs_set_variable: writing to fd 7 failed: No space left on device. grub-install: warning: _efi_set_variable_mode: ops->set_variable() failed: No space left on device. grub-install: error: failed to register the EFI boot entry: No space left on device. Failed: grub-install --target=x86_64-efi
WARNING: Bootloader is not properly installed, system may not be bootable Generating grub configuration file ... Found background image: .background_cache.png Found linux image: /boot/vmlinuz-4.19.0-4-amd64 Found initrd image: /boot/initrd.img-4.19.0-4-amd64 Found linux image: /boot/vmlinuz-4.19.0-2-amd64 Found initrd image: /boot/initrd.img-4.19.0-2-amd64 Found Windows Boot Manager on /dev/sda1@/EFI/Microsoft/Boot/bootmgfw.efi Adding boot menu entry for EFI firmware configuration done

there is more than enough space in /boot/efi and its alos mounted rw

Filesystem Size Used Avail Use% Mounted on /dev/sda1 496M 56M 441M 12% /boot/efi

bash# cat /proc/mounts |grep efi efivarfs /sys/firmware/efi/efivars efivarfs rw,nosuid,nodev,noexec,relatime 0 0 /dev/sda1 /boot/efi vfat rw,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro 0 0

anyone has any idea - i think thats xps specific. if no one encouters this i guess i have to create a bugreport for debian :)

dahabakuk avatar Mar 30 '19 06:03 dahabakuk

Note it's an error generated by efivarfs_set_variable.

I don't really know about the internals of grub, but I doubt it has anything to do with /boot/efi, but rather with the efivarfs that's generally mounted at /sys/firmware/efi/efivars.

Perhaps there is a problem in that area, like the efivarfs filesystem not mounting at all, or maybe some other kind of problem that's present in a specific version in Buster. Either way, I haven't experienced the problem yet (using Debian Stretch, targeting stretch-backports).

timwienk avatar Mar 30 '19 10:03 timwienk

I have the same issue.

Czechball avatar May 17 '19 03:05 Czechball

I switched from shim-signed to shim-unsigned, and this problem went away.

dannyob avatar Jun 05 '19 18:06 dannyob

I installed Debian Buster on my NVME drive and UEFI BIOS, and It seems that I am running in similar problems. During the install I was not able to install the grub dummy package. And when I perform a grub-install I get similiar error messages as reported above. How do I switch form shim-signed to shim unsigned as mentioned by @dannyob?

hawaltie avatar Aug 04 '19 08:08 hawaltie

Hi @hawaltie, I did dist-upgrade from stretch to buster and I encountered it as well. I found advices that you should remove some entries in efi boot order see https://bbs.archlinux.org/viewtopic.php?id=234954 but i wasnt able to delete anything due to no space :) so you can try ... Therefore i rebooted a server and it didnt booted - so i did following procedure:

  • I rebooted it into live debian on my USB stick
  • Decrypted root partion and mount root, boot, efi partition + plus other such /run, /dev, etc.
  • I did chroot into mounted root partion
  • I upgraded initramfs
  • Server booted up

FYI - My issue doesnt have anything in common with xps13.

findmyname666 avatar Aug 26 '19 06:08 findmyname666

Hi @findmyname666 ,

I recently solved the problem by deleting several dump files in the efisys folder. Due to the dump files, there was no space left for updating grub. Removing the dumpfiles and running update-grub solved the issue.

hawaltie avatar Aug 26 '19 09:08 hawaltie