I have since moved the hard drive to another compuetr. The first inkling that things weren’t right was when I booted into the BIOS to find the drive is not seen in UEFI but only when Legacy mode is also included. It boots in Legacy mode.
The disk is partitioned as
Code: Select all
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 206847 204800 100M b W95 FAT32
/dev/sda2 206848 468860927 468654080 223.5G 83 Linux
But when I try run
# grub-install /dev/sda
Code: Select all
grub-install: error: /usr/lib/grub/i386-pc/modinfo.sh doesn't exist. Please specify --target or --directory.
# dpkg -l | grep grub
Code: Select all
ii grub-common 2.02+dfsg1-20+deb10u2 amd64 GRand Unified Bootloader (common files)
ii grub-customizer 5.1.0-3 amd64 GUI to configure GRUB2 and BURG
ii grub-efi 2.02+dfsg1-20+deb10u2 amd64 GRand Unified Bootloader, version 2 (dummy package)
ii grub-efi-amd64 2.02+dfsg1-20+deb10u2 amd64 GRand Unified Bootloader, version 2 (EFI-AMD64 version)
ii grub-efi-amd64-bin 2.02+dfsg1-20+deb10u2 amd64 GRand Unified Bootloader, version 2 (EFI-AMD64 modules)
ii grub-efi-amd64-signed 1+2.02+dfsg1+20+deb10u2 amd64 GRand Unified Bootloader, version 2 (amd64 UEFI signed by Debian)
hi grub2-common 2.02+dfsg1-20+deb10u2 amd64 GRand Unified Bootloader (common files for version 2)
So to try and resolve this I picked up what is believed should work. Using the debian 10 live dvd, I chroot into the system
Code: Select all
# mount /dev/sda2 /mnt
# mount /dev/sda1 /mnt/boot/efi
# for name in proc sys dev; do mount --bind /$name /mnt/$name; done
# chroot /mnt /bin/bash
# mount -t efivarfs efivarfs /sys/firmware/efi/efivars
# grub-install /dev/sda
But of course when I reboot I get the error above
Some other things I have looked at
# modprobe efivars
Code: Select all
modprobe: ERROR: could not insert 'efivars': No such device
Code: Select all
efivar: error listing variables: Function not implemented
Code: Select all
EFI variables are not supported on this system.