[SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post please read how to get help
Post Reply
openletter
Level 1
Level 1
Posts: 21
Joined: Sat Aug 26, 2017 11:09 am
Location: USA

[SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by openletter »

I trying to fix a damaged GRUB installation[1] with Boot-Repair and I'm at the following step

Image

When I run sudo apt-get install -y grub-pc os-prober I get the following dialog box:

Image

I selected [*] /dev/sda (128035 MB; Samsung_SSD_850_PRO_128GB) as that is the drive that Mint is installed to.

However, after it is completed I get the following error:

Code: Select all

Setting up grub-pc (2.02-2ubuntu8.14) ...
Installing for i386-pc platform.
Installation finished. No error reported.
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/50_linuxmint.cfg'
Sourcing file `/etc/default/grub.d/60_mint-theme.cfg'
Generating grub configuration file ...
/usr/sbin/grub-probe: error: failed to get canonical path of `/boot/grub/fonts/UbuntuMono16.pf2'.
No path or device is specified.
Usage: grub-probe [OPTION...] [OPTION]... [PATH|DEVICE]
Try 'grub-probe --help' or 'grub-probe --usage' for more information.
dpkg: error processing package grub-pc (--configure):
 installed grub-pc package post-installation script subprocess returned error exit status 64
Errors were encountered while processing:
 grub-pc
E: Sub-process /usr/bin/dpkg returned an error code (1)
Should I be concerned?

[1] Install of Mint to new drive broke GRUB on old drive
Last edited by openletter on Fri Mar 06, 2020 5:16 pm, edited 1 time in total.
sleeper12
Level 12
Level 12
Posts: 4454
Joined: Thu May 25, 2017 3:22 pm

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by sleeper12 »

Try:

Code: Select all

 sudo dpkg --configure -a 
openletter
Level 1
Level 1
Posts: 21
Joined: Sat Aug 26, 2017 11:09 am
Location: USA

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by openletter »

In the mean time, over at [SOLVED] GRUB won't reinstall on DUAL-BOOT drive! I discovered:
bionicle_159 wrote:
Sun Jan 26, 2020 7:55 pm
bionicle_159 wrote:
Sun Jan 26, 2020 3:25 pm

The mint-theme.cfg made me suspicious so I peeked in that file.

Code: Select all

#! /bin/sh
set -e

GRUB_FONT="/boot/grub/fonts/UbuntuMono16.pf2"
GRUB_THEME="/boot/grub/themes/linuxmint/theme.txt"
I went looking for the theme address and it doesn't exist!
I also compared with my old 18.3 install and there is no 'gfxblacklist.txt' file to be seen in the 19.3 installation.
Mint must have changed or overwritten the default file when they released the theme update for 19.3 as I got rid of the sluggish 19.3 theme by removing it in the Grub GUI.
If I reboot without this file I am pretty sure it will not change regardless of what commands I've previously entered.
I need to find a way to restore that theme.txt as it's parent folder and the "themes" folder don't exist, so there's no chance of it still being in the grub folder or a backup as I've checked those too.
After a lot of hair-pulling false-positives, I tried changing the line in that same mint-theme.cfg to have the font as 'unicode' and it restored it!
Let this be a way of getting back to the old Grub if people are in the same boat as me, running legacy hardware that can only cope with the old version :lol:
So I edited /etc/default/grub.d/60_mint-theme.cfg and changed the font to /boot/grub/fonts/unicode.pf2 and the script completed with "only" a warning:

Code: Select all

After this operation, 0 B of additional disk space will be used.
Setting up grub-pc (2.02-2ubuntu8.14) ...
Installing for i386-pc platform.
Installation finished. No error reported.
Sourcing file `/etc/default/grub'
Sourcing file `/etc/default/grub.d/50_linuxmint.cfg'
Sourcing file `/etc/default/grub.d/60_mint-theme.cfg'
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-5.3.0-40-generic
Found initrd image: /boot/initrd.img-5.3.0-40-generic
Found linux image: /boot/vmlinuz-5.3.0-28-generic
Found initrd image: /boot/initrd.img-5.3.0-28-generic
Found linux image: /boot/vmlinuz-5.3.0-26-generic
Found initrd image: /boot/initrd.img-5.3.0-26-generic
Found linux image: /boot/vmlinuz-5.0.0-32-generic
Found initrd image: /boot/initrd.img-5.0.0-32-generic
Found linux image: /boot/vmlinuz-4.15.0-88-generic
Found initrd image: /boot/initrd.img-4.15.0-88-generic
Found linux image: /boot/vmlinuz-4.15.0-76-generic
Found initrd image: /boot/initrd.img-4.15.0-76-generic
Found linux image: /boot/vmlinuz-4.15.0-20-generic
Found initrd image: /boot/initrd.img-4.15.0-20-generic
done
W: APT had planned for dpkg to do more than it reported back (0 vs 4).
   Affected packages: grub-pc:amd64
openletter
Level 1
Level 1
Posts: 21
Joined: Sat Aug 26, 2017 11:09 am
Location: USA

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by openletter »

sleeper12 wrote:
Fri Mar 06, 2020 4:50 pm
Try:

Code: Select all

 sudo dpkg --configure -a 
Didn't catch this until after completing the boot-repair.

Dare I reboot? (I've got backups, but you know how fun that is.)
sleeper12
Level 12
Level 12
Posts: 4454
Joined: Thu May 25, 2017 3:22 pm

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by sleeper12 »

I'd try that command before you reboot.
openletter
Level 1
Level 1
Posts: 21
Joined: Sat Aug 26, 2017 11:09 am
Location: USA

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by openletter »

I ran it and it completed without printing anything.
sleeper12
Level 12
Level 12
Posts: 4454
Joined: Thu May 25, 2017 3:22 pm

Re: Boot-Repair step reports errors and do I select device or /boot/?

Post by sleeper12 »

No errors is good I guess.
openletter
Level 1
Level 1
Posts: 21
Joined: Sat Aug 26, 2017 11:09 am
Location: USA

Re: [SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by openletter »

Rebooted flawlessly.
sleeper12
Level 12
Level 12
Posts: 4454
Joined: Thu May 25, 2017 3:22 pm

Re: [SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by sleeper12 »

Good job. :wink: I don't know if that command helped, but at least it did no harm.
miyago
Level 1
Level 1
Posts: 1
Joined: Thu Apr 30, 2020 6:00 pm

Re: [SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by miyago »

I ran into the same problem doing the exact same thing as you.

I did some research about the font and it's in the package grub2-theme-mint-2k and can be installed in this situation using>

Code: Select all

sudo chroot "/mnt/boot-sav/sda3" apt-get install -y grub2-theme-mint-2k grub-pc
Very important that the theme package is installed before grub-pc is.
gdcondor
Level 1
Level 1
Posts: 2
Joined: Tue Aug 04, 2020 1:52 pm

Re: [SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by gdcondor »

I got the exact same error:
/usr/sbin/grub-probe: error: failed to get canonical path of `/boot/grub/fonts/UbuntuMono16.pf2'.

Tried:
sudo chroot "/mnt/boot-sav/sda3" apt-get install -y grub2-theme-mint-2k grub-pc
(by changing to the right drive)

Then when I am trying to reconfigure now I have:
/usr/sbin/grub-probe: error: failed to get canonical path of `/boot/grub/fonts/UbuntuMono32.pf2'.

But I don't know in which package this font is (and I am surprised it is not in the same package)
I tried to change the font editing this file in the right chroot:
sudo xed /etc/default/grub.d60_mint-theme.cfg
(but on my system it is not the right file...)

I am stuck and everything is related to the last automatic grub update with a RAID on my system, see:
https://bugs.launchpad.net/ubuntu/+sour ... ug/1889509
https://askubuntu.com/questions/1263125 ... -not-found

It is quite frustrating as everything was working fine and impossible to boot the next day with just the standard automatic update running... no way to figure a solution to boot anymore :-(

Any idea?

Thank you!

Florian
gdcondor
Level 1
Level 1
Posts: 2
Joined: Tue Aug 04, 2020 1:52 pm

Re: [SOLVED] Boot-Repair step reports errors and do I select device or /boot/?

Post by gdcondor »

If someone is facing the same issue I finally managed to solve it by also editing:
/etc/default/grub.d/63_mint-theme-2k.cfg and changed the font to /boot/grub/fonts/unicode.pf2

Florian
Post Reply

Return to “Installation & Boot”