LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   grub error failed to get canonical path (https://www.linuxquestions.org/questions/ubuntu-63/grub-error-failed-to-get-canonical-path-4175732214/)

Dain_Bramage 12-27-2023 09:25 PM

grub error failed to get canonical path
 
I am running Ubuntu 22.04 root on zfs with mirrored pools.

Code:

root@orac:/home/mike# blkid | grep bpool
/dev/sdd3: LABEL="bpool" UUID="10149266795976124053" UUID_SUB="7554971749162667878" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="ffc44ed2-67ac-b14d-8674-5653f5457c8f"
/dev/sde3: LABEL="bpool" UUID="10149266795976124053" UUID_SUB="1881332597513951535" BLOCK_SIZE="4096" TYPE="zfs_member" PARTUUID="09185217-6483-d64d-a146-25b9b2ef7fcc"

Code:

root@orac:/home/mike# lsblk | grep sdd
sdd          8:48  0  1.8T  0 disk
├─sdd1        8:49  0  512M  0 part /boot/grub
├─sdd2        8:50  0    2G  0 part [SWAP]
├─sdd3        8:51  0    2G  0 part
└─sdd4        8:52  0  1.8T  0 part

So as you can see grub is installed on /dev/sdd and the operating system boots from /dev/sdd

I decided that I wanted to change the UUID of /dev/sde but when I ran update-grub I got this error:

Code:

root@orac:/home/mike# update-grub
/usr/sbin/grub-probe: error: failed to get canonical path of `/dev/disk/by-partuuid/09185217-6483-d64d-a146-25b9b2ef7fcc'.

It was easily fixed by changing the UUID back but I am puzzled as to why grub cares about the UUID of a drive it is not installed on?

mrmazda 12-27-2023 10:09 PM

Have you considered un-bramaging; or the functions of update-grub, and thus grub-probe? One of them is to produce a grub.cfg that works. That involves probing filesystems that Grub may not be "installed on".

Dain_Bramage 12-28-2023 11:02 PM

Hi mrmazda,

Thank you for your reply.

I think I may not have phrased my question very well.

After I changed the UUID and before I ran
Code:

update-grub
I ran
Code:

partprobe
so that the operating system kernel is aware of the partition table change.

What I am trying to understand is why does grub expects to find the specific UUID 09185217-6483-d64d-a146-25b9b2ef7fcc?

enigma9o7 12-28-2023 11:15 PM

That's where it hibernates to.

mrmazda 12-29-2023 12:53 AM

Quote:

Originally Posted by Dain_Bramage (Post 6473310)
What I am trying to understand is why does grub expects to find the specific UUID 09185217-6483-d64d-a146-25b9b2ef7fcc?

That's not a UUID. It's the PARTUUID of sde3.

I don't use zfs, so can't know what if any part it plays in understanding this, but perhaps it would explain this:
Quote:

Code:

├─sdd1 8:49 0 512M 0 part /boot/grub/

What reason is there for mounting a discrete filesystem on /boot/grub/? /boot/ and /boot/efi/ I know reasons for.


All times are GMT -5. The time now is 07:25 AM.