When upgrading Ubuntu 18.04 or Ubuntu 20.04 on your BinaryLane cloud server, you may see a message like this:
Setting up grub-efi-amd64-signed (1.142.6+2.04-1ubuntu26.4) ... Unknown device "/dev/disk/by-id/*": No such file or directory dpkg: error processing package grub-efi-amd64-signed (--configure): installed grub-efi-amd64-signed package post-installation script subprocess returned error exit status 1 Errors were encountered while processing: grub-efi-amd64-signed E: Sub-process /usr/bin/dpkg returned an error code (1)
This error occurs because of a recent change to Ubuntu repository that marks EFI boot packages as essential, but our VPSs do not use EFI. To correct this, run the following commands separately as root:
apt-get install -y grub-pc 'grub-efi*-' --allow-remove-essential && grub-install /dev/vda GRUB_CMDLINE='s/^(GRUB_CMDLINE_LINUX_DEFAULT=)"[^"]*"/\1"quiet nosplash net.ifnames=0 vga=770"/' sed -Ei "$GRUB_CMDLINE" /etc/default/grub && update-grub
If the error message specifically references the shim-signed package instead of grub-efi*, you can replace 'grub-efi*-' with 'shim-signed-' in the removal command:
apt-get install -y grub-pc 'shim-signed-' --allow-remove-essential && grub-install /dev/vda
GRUB_CMDLINE='s/^(GRUB_CMDLINE_LINUX_DEFAULT=)"[^"]*"/\1"quiet nosplash net.ifnames=0 vga=770"/'
sed -Ei "$GRUB_CMDLINE" /etc/default/grub && update-grub
If you require assistance, feel free to submit a support ticket at our helpdesk here: Submit a ticket | BinaryLane