Comment 1 for bug 446764

Revision history for this message
David (deivi73) wrote :

I solved this issue with two modifications.

In first place, I wrote a grub detector based on /usr/lib/os-probes/mounted/90linux-distro with sequence number 89 to run before linux distribution detection:

/usr/lib/os-probes/mounted/89grub is attached

Then, I modified /etc/grub.d/30_os-prober to deal with the grub case. I set the following before the *) default option:

grub)
      found_other_os=1
      cat << EOF
menuentry "${LONGNAME} (on ${DEVICE})" --class linux --class gnu --class os {
EOF
      GDRIVE="`grub-probe -d /dev/sda4 -t drive 2> /dev/null`"
      cat <<EOF
 insmod ext2
 set root='${GDRIVE}'
 chainloader +1
}
EOF
    ;;
*)