I have a multiboot setup using Grub managed by Manjaro. Three Linux versions are on two nvme drives. The ‘bios’ of my pc gives out nvme0 and nvme1 -names in a unpredictable way. That should not be a problem when using the UUID to identify boot partitions.
With ‘sudo update-grub’ /boot/grub/grub.cfg is updated. I have enabled the use of os-prober. This results in something strange: for linux Mint the UUID is used, for Arch /dev/nvme0n1p3. Sometimes this works, sometimes not.
So my question is Why this /dev/nvme0n1p3 and not the UUID for Arch?
The generated grub.cfg: see line 167
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
### BEGIN /etc/grub.d/00_header ###
insmod part_gpt
insmod part_msdos
if [ -s $prefix/grubenv ]; then
load_env
fi
if [ "${next_entry}" ] ; then
set default="${next_entry}"
set next_entry=
save_env next_entry
set boot_once=true
else
set default="${saved_entry}"
fi
if [ x"${feature_menuentry_id}" = xy ]; then
menuentry_id_option="--id"
else
menuentry_id_option=""
fi
export menuentry_id_option
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi
function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}
function load_video {
if [ x$feature_all_video_module = xy ]; then
insmod all_video
else
insmod efi_gop
insmod efi_uga
insmod ieee1275_fb
insmod vbe
insmod vga
insmod video_bochs
insmod video_cirrus
fi
}
set menu_color_normal=light-gray/black
set menu_color_highlight=green/black
if [ x$feature_default_font_path = xy ] ; then
font=unicode
else
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
font="/usr/share/grub/unicode.pf2"
fi
if loadfont $font ; then
set gfxmode=1920x1440x32
load_video
insmod gfxterm
set locale_dir=$prefix/locale
set lang=en_US
insmod gettext
fi
terminal_input console
terminal_output gfxterm
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
insmod gfxmenu
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_24.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_48.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_bold_16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/dejavu_sans_mono_12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-18.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b12.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b14.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b16.pf2
loadfont ($root)/usr/share/grub/themes/manjaro/terminus-b18.pf2
insmod png
set theme=($root)/usr/share/grub/themes/manjaro/theme.txt
export theme
if [ x$feature_timeout_style = xy ] ; then
set timeout_style=hidden
set timeout=9
# Fallback hidden-timeout code in case the timeout_style feature is
# unavailable.
elif sleep --interruptible 9 ; then
set timeout=0
fi
### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Manjaro Linux' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-adcda0b2-d3e3-4d08-a9bd-802191d2faf3' {
savedefault
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
linux /boot/vmlinuz-6.6-x86_64 root=UUID=adcda0b2-d3e3-4d08-a9bd-802191d2faf3 ro nowatchdog quiet apparmor=1 security=apparmor udev.log_priority=3
initrd /boot/intel-ucode.img /boot/initramfs-6.6-x86_64.img
}
submenu 'Advanced options for Manjaro Linux' $menuentry_id_option 'gnulinux-advanced-adcda0b2-d3e3-4d08-a9bd-802191d2faf3' {
menuentry 'Manjaro Linux (Kernel: 6.6.44-1-MANJARO x64)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.6.44-1-MANJARO x64-advanced-adcda0b2-d3e3-4d08-a9bd-802191d2faf3' {
savedefault
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
linux /boot/vmlinuz-6.6-x86_64 root=UUID=adcda0b2-d3e3-4d08-a9bd-802191d2faf3 ro nowatchdog quiet apparmor=1 security=apparmor udev.log_priority=3
initrd /boot/intel-ucode.img /boot/initramfs-6.6-x86_64.img
}
menuentry 'Manjaro Linux (Kernel: 6.6.44-1-MANJARO x64 - fallback initramfs)' --class manjaro --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-6.6.44-1-MANJARO x64-fallback-adcda0b2-d3e3-4d08-a9bd-802191d2faf3' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
linux /boot/vmlinuz-6.6-x86_64 root=UUID=adcda0b2-d3e3-4d08-a9bd-802191d2faf3 ro nowatchdog quiet apparmor=1 security=apparmor udev.log_priority=3
initrd /boot/initramfs-6.6-x86_64-fallback.img
}
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/25_bli ###
if [ "$grub_platform" = "efi" ]; then
insmod bli
fi
### END /etc/grub.d/25_bli ###
### BEGIN /etc/grub.d/30_os-prober ###
menuentry 'Arch Linux (rolling) (on /dev/nvme0n1p3)' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-f8a20f45-b2f8-4887-8a38-cf0442ad21ac' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root f8a20f45-b2f8-4887-8a38-cf0442ad21ac
linux /boot/vmlinuz-linux-lts root=/dev/nvme0n1p3
initrd /boot/initramfs-linux-lts.img
}
submenu 'Advanced options for Arch Linux (rolling) (on /dev/nvme0n1p3)' $menuentry_id_option 'osprober-gnulinux-advanced-f8a20f45-b2f8-4887-8a38-cf0442ad21ac' {
menuentry 'Arch Linux (rolling) (on /dev/nvme0n1p3)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-linux-lts--f8a20f45-b2f8-4887-8a38-cf0442ad21ac' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root f8a20f45-b2f8-4887-8a38-cf0442ad21ac
linux /boot/vmlinuz-linux-lts root=/dev/nvme0n1p3
initrd /boot/initramfs-linux-lts.img
}
}
menuentry 'Linux Mint 22 Wilma (22) (on /dev/nvme0n1p5)' --class linuxmint --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7
linux /boot/vmlinuz-6.8.0-39-generic root=UUID=c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7 ro quiet splash
initrd /boot/initrd.img-6.8.0-39-generic
}
submenu 'Advanced options for Linux Mint 22 Wilma (22) (on /dev/nvme0n1p5)' $menuentry_id_option 'osprober-gnulinux-advanced-c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7' {
menuentry 'Linux Mint 22 Cinnamon (on /dev/nvme0n1p5)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-6.8.0-39-generic--c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7
linux /boot/vmlinuz-6.8.0-39-generic root=UUID=c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7 ro quiet splash
initrd /boot/initrd.img-6.8.0-39-generic
}
menuentry 'Linux Mint 22 Cinnamon, with Linux 6.8.0-39-generic (on /dev/nvme0n1p5)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-6.8.0-39-generic--c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7
linux /boot/vmlinuz-6.8.0-39-generic root=UUID=c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7 ro quiet splash
initrd /boot/initrd.img-6.8.0-39-generic
}
menuentry 'Linux Mint 22 Cinnamon, with Linux 6.8.0-39-generic (recovery mode) (on /dev/nvme0n1p5)' --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-/boot/vmlinuz-6.8.0-39-generic--c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7
linux /boot/vmlinuz-6.8.0-39-generic root=UUID=c22c6ba2-5463-40a1-b24f-6aab8e7ae8d7 ro recovery nomodeset dis_ucode_ldr
initrd /boot/initrd.img-6.8.0-39-generic
}
}
set timeout_style=menu
if [ "${timeout}" = 0 ]; then
set timeout=10
fi
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/30_uefi-firmware ###
if [ "$grub_platform" = "efi" ]; then
menuentry 'UEFI Firmware Settings' $menuentry_id_option 'uefi-firmware' {
fwsetup
}
fi
### END /etc/grub.d/30_uefi-firmware ###
### BEGIN /etc/grub.d/35_fwupd ###
### END /etc/grub.d/35_fwupd ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
menuentry 'Arch Linux fixed' --class arch --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-f8a20f45-b2f8-4887-8a38-cf0442ad21ac' {
savedefault
insmod part_gpt
insmod ext2
search --no-floppy --fs-uuid --set=root f8a20f45-b2f8-4887-8a38-cf0442ad21ac
linux /boot/vmlinuz-linux-lts root=UUID=f8a20f45-b2f8-4887-8a38-cf0442ad21ac rw nowatchdog quiet splash
initrd /boot/initramfs-linux-lts.img
}
menuentry "OpenCore" {
insmod fat
insmod chain
search --no-floppy --set=root --fs-uuid A7F1-FC7C
chainloader /EFI/BOOT/BOOTx64.efi
}
menuentry 'FoxClone' --class linuxmint --class gnu-linux --class gnu --class os $menuentry_id_option 'osprober-gnulinux-simple-12aeee6a-3d72-4b97-9f1a-ff94be2c75f7' {
insmod part_msdos
insmod ext2
set root='hd0,msdos5'
if [ x$feature_platform_search_hint = xy ]; then
search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos5 --hint-efi=hd0,msdos5 --hint-baremetal=ahci0,msdos5 12aeee6a-3d72-4b97-9f1a-ff94be2c75f7
else
search --no-floppy --fs-uuid --set=root 12aeee6a-3d72-4b97-9f1a-ff94be2c75f7
fi
linux /boot/vmlinuz-5.15.0-53-generic root=UUID=12aeee6a-3d72-4b97-9f1a-ff94be2c75f7 ro quiet splash
initrd /boot/initrd.img-5.15.0-53-generic
}
### END /etc/grub.d/40_custom ###
### BEGIN /etc/grub.d/41_custom ###
if [ -f ${config_directory}/custom.cfg ]; then
source ${config_directory}/custom.cfg
elif [ -z "${config_directory}" -a -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg
fi
### END /etc/grub.d/41_custom ###
### BEGIN /etc/grub.d/60_memtest86+ ###
if [ "${grub_platform}" == "pc" ]; then
menuentry "Memory Tester (memtest86+)" --class memtest86 --class gnu --class tool {
search --fs-uuid --no-floppy --set=root adcda0b2-d3e3-4d08-a9bd-802191d2faf3
linux16 /boot/memtest86+/memtest.bin
}
fi
### END /etc/grub.d/60_memtest86+ ###
Thanks!