After generate a new efi boot entry with efibootmgr:

# efibootmgr -c -g -L "Debian (EFI stub)" -l '\EFI\debian\vmlinuz' -u "root=UUID=955548bd-9c77-4893-8633-3a5e7966dfc9 ro quiet rootfstype=ext4 add_efi_memmap initrd=\\EFI\\debian\\initrd.img"

The system doesn't start, only fall into a BusyBox shell.

How is possible to change the boot order to the old entry? Something like

# efibootmgr -o 0004,0005,0000,0001,0002,0003
  • That's Debian fail, not UEFI fail. UEFI doesn't have anything to do with your OS – 炸鱼薯条德里克 Sep 14 '18 at 9:13
  • It's due a bad disk UUID, but anyway, the recover solution is equal to any issue like this, select the old entry that was default just before the problem. – Rfraile Sep 14 '18 at 9:22

These are the steps to change the efi boot order on a Debian system:

On the BusyBox, load kernel module for the fs, in our case:

# modprobe ext4 

Mount the required partitions needed. Note that root fs is on sda3 in our particular case:

# mkdir /mnt
# mount -t ext4 /dev/sda3 /mnt
# mount /proc /mnt/proc
# mount /sys /mnt/sys

Chroot into it:

# chroot /mnt

Load the kernel modules needed to mount the filesystems and to work with efibootmgr:

# modprobe efivars
# modprobe vfat
# modprobe efivarfs

Mount the required path:

# mount -t efivarfs efivarfs /sys/firmware/efi/efivars

Now, you can play with efibootmgr:

# bin/efibootmgr -v
# bin/efibootmgr -o 0005,0004,0000,0001,0003,0001,0002

End with the chroot and exit:

# sync
# exit

Reboot and enjoy.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.