bugGNU GRUB - Bugs: bug #36846, Grub 2 hangs on boot after...

 
 

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

bug #36846: Grub 2 hangs on boot after installing on RAID1 device (/dev/md0) but reports no problems during installation

Submitted by:  Iordan <iiordanov>
Submitted on:  Fri 13 Jul 2012 07:55:34 PM UTC  
 
Category: InstallationSeverity: Major
Priority: 5 - NormalItem Group: Software Error
Status: Wont FixPrivacy: Public
Assigned to: NoneOriginator Name: 
Open/Closed: ClosedRelease: 
Release: otherReproducibility: Every Time
Planned Release: None

Sun 22 Jul 2012 04:57:07 PM UTC, comment #1:

1.99 is pretty old. I'm not going to look into its mdraid code for this. If problem appears with 2.00 as well feel free to reopen the bug.

Vladimir Serbinenko <phcoder>
Project Administrator
Fri 13 Jul 2012 07:55:34 PM UTC, original submission:

Reproducibility: Always

Steps to reproduce:

0) Zero out the beginning of couple of drives with dd to ensure no previous grub installation lingers. E.g.:

dd if=/dev/zero of=/dev/sda bs=1024k count=1
dd if=/dev/zero of=/dev/sdb bs=1024k count=1

1) Make a RAID1 device with metadata 0.9 or 1.0. It doesn't matter whether its degraded (i.e. with one device missing), or not. The resulting device is /dev/md0.

Since we are creating the RAID array with metadata 0.9 or 1.0, the metadata ends up at the end of the array, and so the BIOS should have no trouble reading from each disk individually to load the boot-loader, etc. What's more, grub2 supports GPT, and ordinarily has no trouble booting from a GPT labeled disk.

2) Partition said device with GPT, and make a bios partition for Grub2. The resulting partitions have the form /dev/md0p1, /dev/md0p2, etc.

3) Install Ubuntu 12.04 onto the said RAID1 device. The version of grub that is installed is 1.99-21ubuntu3.1. We install with FAI, but probably installing from LiveCD will do just as well.

4) Install Grub2 onto /dev/md0, like this:

grub-install /dev/md0

Expected result:

What we expect at this point is for md to automatically
sync the grub2 changes to both /dev/sda and /dev/sdb, and for the BIOS to be able to boot from either device.

What happens instead:

What happens instead is that when the BIOS attempts to boot from
either device, it hangs with a cursor blinking at the top-left corner of the screen indefinitely. So, it seems like although Grub 2 thinks the installation went fine, it is not actually OK.

Notes:

The interesting thing is that when we install Grub 2 to /dev/sda and /dev/sdb individually, rather than /dev/md0, everything works as intended. I've seen references on the web indicating that installing to the raw devices is the right thing to do, but I could not find any official documentation supporting the claims.

If grub is supposed to be installed to /dev/sda and /dev/sdb, then the bug is that it doesn't complain when an attempt is made to install it to /dev/md0.

If it should work even when installed to /dev/md0 (with metadata 0.9 and 1.0), then the bug is that it doesn't actually install properly.

In case it is relevant, here is a print out of the partition table, even though (as mention previously), Grub 2 does install successfully when the raw devices are specified (/dev/sda, /dev/sdb):

# parted /dev/md0 print

Model: Linux Software RAID Array (md)
Disk /dev/md0: 500GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt

Number Start End Size File system Name Flags
1 17.4kB 8389kB 8372kB grub bios_grub
2 8389kB 21.0GB 21.0GB ext4 root
3 21.0GB 23.1GB 2097MB linux-swap(v1) swap
4 23.1GB 33.6GB 10.5GB ext4 var
5 33.6GB 54.5GB 21.0GB ext4 tmp
6 54.5GB 75.5GB 21.0GB ext4 local
7 75.5GB 500GB 425GB ext4 data

Here is a link to the original bug-report on launchpad which contains similar information to what's in this bug-report;

https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/1019389

Iordan <iiordanov>

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by phcoder (Posted a comment)
  • -unavailable- added by iiordanov (Submitted the item)
  • -unavailable- added by iiordanov
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 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 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 22 Jul 2012 04:57:07 PM UTCphcoderStatusNone=>Wont Fix
      Open/ClosedOpen=>Closed
    Fri 13 Jul 2012 07:55:34 PM UTCiiordanovCarbon-Copy-=>Added iiordanov

    Back to the top


    Powered by Savane 3.1-cleanup1