bugGNU GRUB - Bugs: bug #31647, Option to use labels instead of...


You are not allowed to post comments on this tracker with your current authentification level.

bug #31647: Option to use labels instead of uuid's in Linux grub.cfg

Submitted by:  Barry Jackson <barjac>
Submitted on:  Sat Nov 13 21:12:58 2010  
Votes:  131  
Category: Disk & PartitionSeverity: Major
Priority: 3 - LowItem Group: None
Status: NonePrivacy: Public
Assigned to: NoneOriginator Name: Barry Jackson
Open/Closed: OpenRelease: 
Release: Bazaar - trunkReproducibility: None
Planned Release: 2.03+

(Jump to the original submission Jump to the original submission)

Wed Sep 3 09:55:57 2014, comment #7:


I too would like to have a supported way to generate a grub.cfg with LABEL= instead of UUID=

I am using 2.02~beta2 and this does not seems to be possible yet.

My use case is: prepare a baseline bootable system on a USB drive, make an image of it with dd, write that image with dd to several other USB disks.

The attached patches seem to be a good starting point as they do not change the default behavior, unlike #38366.

If the grub developers at least acknowledge the usefulness of the feature, then some of us may be willing to spend some more time on working out the details of the implementation.


Antonio Ospite <ao2>
Sun Jun 30 05:44:13 2013, comment #6:

Another attempt to fix this bug: https://savannah.gnu.org/bugs/?38366

Thu May 24 01:07:24 2012, comment #5:

There's a use case for this that makes me want it too: backup.

If I periodically clone my HDD to an external one, I'd like to be able to swap them when the internal one fails, like described here: <http://www.jwz.org/blog/2007/09/psa-backups/>. However, with UUIDs in the bootloader I can't do this. With labels I would be able to.

Ian Dalton <iaindalton>
Thu Sep 29 08:58:51 2011, comment #4:

It changes from UUIDs to LABELs in several, unrelated modules which should be configurable separately.

Vladimir Serbinenko <phcoder>
Project Administrator
Tue Aug 16 17:09:10 2011, comment #3:

I'm not sure I follow.
Without GRUB_USE_LABEL set "true" it changes nothing.

Are you saying it breaks something un-related ?
If so then could you please explain as I would like to try to correct it.

Otherwise, could you please add a similar feature to grub2 ?

I have used this for about 12 months now with no issues and prefer labels for many reasons.

Barry Jackson <barjac>
Tue Aug 16 15:22:25 2011, comment #2:

This patch isn't appropriate since it changes behaviour of several unrelated parts with a single option.

Vladimir Serbinenko <phcoder>
Project Administrator
Wed Jun 15 11:15:28 2011, comment #1:

I have attached an updated patch for 1.99 release version, in the hope that this may at least be reviewed.

Barry Jackson <barjac>
Sat Nov 13 21:12:58 2010, original submission:

It would be good in Linux to be able to specify that grub use labels rather than UUID's in grub.cfg, if the user specifies GRUB_USE_LABEL=true in /etc/default/grub.

I have attached patches for grub-mkconfig.in, grub-mkconfig_lib.in and 10_linux.in that achieve this in my system. (rev 2937).

Whilst my patches may have deficiencies and possibly overlook many scenarios that I do not understand, I feel that the principle illustrated is one that is desirable and should be fully developed.

Thanks for your time.

Barry Jackson (barjac)

Barry Jackson <barjac>


Attached Files
file #23526:  grub2_labels.patch added by barjac (2kB - application/octet-stream - Patch updated for 1.99 release version - works for me.)
file #22009:  grub-mkconfig.in.patch added by barjac (801B - application/octet-stream - Patches)
file #22010:  10_linux.in.patch added by barjac (521B - application/octet-stream - Patches)
file #22011:  grub-mkconfig_lib.patch added by barjac (771B - application/octet-stream - Patches)


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -unavailable- added by ao2 (Posted a comment)
  • -unavailable- added by jpt (Voted in favor of this item)
  • -unavailable- added by mrmazda (Voted in favor of this item)
  • -unavailable- added by kernc (Posted a comment)
  • -unavailable- added by kernc (Voted in favor of this item)
  • -unavailable- added by iaindalton (Posted a comment)
  • -unavailable- added by iaindalton (Voted in favor of this item)
  • -unavailable- added by rduke15 (Voted in favor of this item)
  • -unavailable- added by rduke15
  • -unavailable- added by phcoder (Updated the item)
  • -unavailable- added by barjac (Submitted the item)

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 131 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follow 12 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Wed Mar 2 10:29:52 2016phcoderPlanned ReleaseNone=>2.03+
    Mon Jul 1 10:40:10 2013jptCarbon-Copy-=>Added jpt
    Sun Jun 30 09:28:17 2013mrmazdaCarbon-Copy-=>Added mrmazda
    Sun Jun 30 05:44:13 2013kerncCarbon-Copy-=>Added kernc
    Thu May 24 00:36:03 2012iaindaltonCarbon-Copy-=>Added iaindalton
    Wed Jun 15 11:05:31 2011barjacAttached File-=>Added grub2_labels.patch, #23526
    Sun May 1 14:07:13 2011rduke15Carbon-Copy-=>Added rduke15
    Sun May 1 14:07:12 2011rduke15Carbon-Copy-=>Added -unavailable-
    Sat Nov 13 21:26:05 2010phcoderPriority5 - Normal=>3 - Low
    Sat Nov 13 21:12:58 2010barjacAttached File-=>Added grub-mkconfig.in.patch, #22009
      Attached File-=>Added 10_linux.in.patch, #22010
      Attached File-=>Added grub-mkconfig_lib.patch, #22011

    Back to the top

    Powered by Savane 3.1-cleanup1