Bug#1103935: os-prober: Hurd detection produces unusable grub.cfg fragment
Package: os-prober
Severity: important
X-Debbugs-Cc: martin-eric.racine@iki.fi
Usertags: hurd-i386
In its current form, os-prober produces an unusable GRUB config segment when it finds a Hurd partition:
1) It wants to boot a /boot/gnumach.gz file that doesn't exist. Mach kernel files include version numbers.
Once that has been manually fixed in grub.cfg to e.g. /boot/gnumach-1.8-486-up.gz, a second problem emerges:
2) The config fragment passes the incorrect root device, which makes the Mach kernel fail to find its Hurd of services.
What's expected is something like this (for each Mach kernel found):
menuentry "Debian GNU/Hurd, with Mach 1.8" {
set root='hd0,msdos1'
echo 'Loading GNU Mach ...'
multiboot /boot/gnumach-1.8-486-up.gz root=part:1:device:hd0
echo 'Loading the Hurd ...'
module /hurd/pci-arbiter.static pci-arbiter \
--host-priv-port='${host-port}' --device-master-port='${device-port}' \
--next-task='${acpi-task}' \
'$(pci-task=task-create)' '$(task-resume)'
module /hurd/acpi.static acpi \
--next-task='${disk-task}' \
'$(acpi-task=task-create)'
module /hurd/rumpdisk.static rumpdisk \
--next-task='${fs-task}' \
'$(disk-task=task-create)'
module /hurd/ext2fs.static ext2fs \
--multiboot-command-line='${kernel-command-line}' \
--exec-server-task='${exec-task}' -T typed '${root}' \
'$(fs-task=task-create)'
module /hurd/exec.static exec '$(exec-task=task-create)'
}
Perhaps it would be a good idea for os-prober to copy the 10_hurd script that comes with GRUB for the Hurd port, passing it the correct root device for the Hurd partition (instead of the Linux partition that os-prober runs from), to generate the menu entries.
Martin-Éric
-- System Information:
Debian Release: trixie/sid
APT prefers unstable-debug
APT policy: (500, 'unstable-debug'), (500, 'unstable')
Architecture: i386 (x86_64)
Kernel: Linux 6.12.12+bpo-amd64 (SMP w/8 CPU threads; PREEMPT)
Locale: LANG=fi_FI.UTF-8, LC_CTYPE=fi_FI.UTF-8 (charmap=UTF-8), LANGUAGE=fi:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages os-prober depends on:
pn grub-common <none>
ii libc6 2.41-7
ii mount 2.41-4
os-prober recommends no packages.
os-prober suggests no packages.
Reply to: