10_lupin case problem with ntfs UUIDs

Bug #695290 reported by Heiko Helmle on 2010-12-29
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Undecided
Unassigned
Lucid
High
Colin Watson
Maverick
High
Colin Watson

Bug Description

1) Ubuntu 10.10
2) lupin-support 0.32

Normally, when running update-grub, 10_lupin should add entries to grub.cfg with the root=UUID=x parameter.

On my system, this fails and the script falls back to using device nodes (/dev/sda?) - which prevented the system from booting correctly, because the device order gets mixed on every boot (sometimes it's sda, sometimes sdb).

I found out the problem is on line 53 in /etc/grub.d/10_lupin:
host_device_uuid="`${grub_probe} --device "${host_device}" --target=fs_uuid 2> /dev/null`" || true

this returns the UUID in lower case, and on the next line this gets compared to /dev/disk/by-uuid/*:
test -e "/dev/disk/by-uuid/${host_device_uuid}"

But the device node in /dev/disk/by-uuid is in uppercase.

Workaround is to change line 53 to:
host_device_uuid="`${grub_probe} --device "${host_device}" --target=fs_uuid 2> /dev/null | tr '[:lower:]' '[:upper:]'`" || true

But I guess this is not correct (the conversion to uppercase should only happen on NTFS hosts) - so a more proper fix would be necessary.

Colin Watson (cjwatson) wrote :

This was fixed in GRUB upstream:

2010-11-06 Vladimir Serbinenko <email address hidden>

        * grub-core/fs/ntfs.c (grub_ntfs_uuid): Make uppercase.

It's therefore fixed in natty. However, we need to backport this to lucid and maverick.

affects: lupin (Ubuntu) → grub2 (Ubuntu)
Changed in grub2 (Ubuntu):
status: New → Fix Released
Colin Watson (cjwatson) on 2011-04-06
Changed in grub2 (Ubuntu Lucid):
status: New → In Progress
importance: Undecided → High
assignee: nobody → Colin Watson (cjwatson)
Changed in grub2 (Ubuntu Maverick):
status: New → In Progress
importance: Undecided → High
assignee: nobody → Colin Watson (cjwatson)

Accepted grub2 into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in grub2 (Ubuntu Lucid):
status: In Progress → Fix Committed
tags: added: verification-needed
Changed in grub2 (Ubuntu Maverick):
status: In Progress → Fix Committed
Martin Pitt (pitti) wrote :

Accepted grub2 into maverick-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Colin Watson (cjwatson) wrote :

The testing done in bug 610898 should be sufficient to cover this. Marking verification-done.

tags: added: verification-done
removed: verification-needed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 1.98-1ubuntu12

---------------
grub2 (1.98-1ubuntu12) lucid-proposed; urgency=low

  * Fix use of freed memory when replacing existing loopback device
    (LP: #742967).
  * Make sure to reinstall GRUB on upgrade if Wubi is in use (LP: #742967).
  * Enable grub-fstest, so that we can use it to help find wubildr
    (LP: #610898).
  * Make NTFS UUIDs uppercase (LP: #695290).

grub2 (1.98-1ubuntu11) lucid-proposed; urgency=low

  * Backport multipath probing fixes (LP: #687501).
 -- Colin Watson <email address hidden> Wed, 27 Apr 2011 10:39:15 +0100

Changed in grub2 (Ubuntu Lucid):
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package grub2 - 1.98+20100804-5ubuntu3.3

---------------
grub2 (1.98+20100804-5ubuntu3.3) maverick-proposed; urgency=low

  * Fix use of freed memory when replacing existing loopback device
    (LP: #742967).
  * Make sure to reinstall GRUB on upgrade if Wubi is in use (LP: #742967).
  * Enable grub-fstest, so that we can use it to help find wubildr
    (LP: #610898).
  * Make NTFS UUIDs uppercase (LP: #695290).

grub2 (1.98+20100804-5ubuntu3.2) maverick-proposed; urgency=low

  * Backport multipath probing fixes (LP: #687501).
 -- Colin Watson <email address hidden> Wed, 27 Apr 2011 10:32:26 +0100

Changed in grub2 (Ubuntu Maverick):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers