Bug 495266

Summary: GRUB fails to update MBR of ICH-R mirrors
Product: [Fedora] Fedora Reporter: Josef Carlin <josef.carlin>
Component: grubAssignee: Peter Jones <pjones>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: low    
Version: 10CC: pjones
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-12-18 09:13:52 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
A copy of current MBR none

Description Josef Carlin 2009-04-10 23:32:43 UTC
Description of problem: 
In Fedora 10 both grub and grub-install fail to write to the MBR of Intel ICH-R based RAID set. This severely restricts ability to recover system if the MBR should be altered.

Version-Release number of selected component (if applicable):
Fedora release 10 (Cambridge)
grub-0.97-38.fc10.i386

How reproducible:
"Easily" reproducible but a bit involved because of another bug that will not allow Fedora 10 to be installed directly on a Intel ICH-R based RAID using Fedora 10 local installation media (DVD, CDROM). 

Steps to Reproduce:
1. Using computer BIOS create two mirrored volumes (1) Windows and (2) UNIX on two SATA/RAID drives. I created a two 300GB mirrored volumes on two 600GB drives.
2.Install Windows XP Pro on the first volume named "Windows" and confirm it boots using its native bootloader.
3.Install Fedora 9 (Fedora 10's anaconda/installer can NOT be used because it doesn't see the RAID sets). Reboot and confirm GRUB boots both Windows XP Pro and Fedora 9.
4. Boot Fedora 9 and use yum upgrade to upgrade to Fedora 10.
5. Reboot and notice that grub-install fails in Fedora 10.
6. Also notice that tab completion while at the grub> prompt fails as well.
  
Actual results:
[root@mango ~]# grub-install /dev/mapper/isw_cabahdgdcf_Windows
/dev/mapper/isw_cabahdgdcf_UNIXp1 does not have any corresponding BIOS drive.

If you try and update the /boot/grub/device.map with an appropriate entry for UNIXp1, you get other errors:

[root@mango dev]# vim /boot/grub/device.map
# this device map was generated by anaconda
(hd1)     /dev/mapper/isw_cabahdgdcf_UNIX
(hd1,0)     /dev/mapper/isw_cabahdgdcf_UNIXp1
(hd0)     /dev/mapper/isw_cabahdgdcf_Windows

[root@mango dev]# grub-install /dev/mapper/isw_cabahdgdcf_Windows
/boot/grub/device.map:3: error: No close parenthesis found
/boot/grub/device.map:3: error: No close parenthesis found
/boot/grub/device.map:3: error: No close parenthesis found
/boot/grub/device.map:3: error: No close parenthesis found
/boot/grub/device.map:3: error: No close parenthesis found
The file /boot/grub/stage1 not read correctly.

Expected results:
grub-install should silently complete after writing to the specified MBR without complaining.

Additional info:
[root@mango ~]# df -h /boot
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/isw_cabahdgdcf_UNIXp1
                      494M   24M  445M   6% /boot

[root@mango ~]# ls -la /dev/mapper/
total 0
drwxr-xr-x  2 root root     300 2009-04-10 12:30 .
drwxr-xr-x 17 root root    5500 2009-04-10 12:31 ..
crw-rw----  1 root root  10, 63 2009-04-10 12:30 control
brw-rw----  1 root disk 253,  0 2009-04-10 12:30 isw_cabahdgdcf_UNIX
brw-rw----  1 root disk 253,  1 2009-04-10 12:31 isw_cabahdgdcf_UNIXp1
brw-rw----  1 root disk 253,  2 2009-04-10 12:30 isw_cabahdgdcf_UNIXp2
brw-rw----  1 root disk 253,  3 2009-04-10 12:30 isw_cabahdgdcf_Windows
brw-rw----  1 root disk 253,  4 2009-04-10 12:30 isw_cabahdgdcf_Windowsp1
brw-rw----  1 root disk 253, 10 2009-04-10 12:31 vg00-homevol
brw-rw----  1 root disk 253,  6 2009-04-10 12:31 vg00-optvol
brw-rw----  1 root disk 253,  5 2009-04-10 12:31 vg00-rootvol
brw-rw----  1 root disk 253, 11 2009-04-10 12:30 vg00-swapvol
brw-rw----  1 root disk 253,  9 2009-04-10 12:31 vg00-tmpvol
brw-rw----  1 root disk 253,  7 2009-04-10 12:31 vg00-usrvol
brw-rw----  1 root disk 253,  8 2009-04-10 12:31 vg00-varvol


[root@mango ~]# cat /boot/grub/grub.conf
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd1,0)
#          kernel /vmlinuz-version ro root=/dev/vg00/rootvol
#          initrd /initrd-version.img
#boot=/dev/mapper/isw_cabahdgdcf_Windows
default=0
timeout=10
splashimage=(hd1,0)/grub/splash.xpm.gz
#hiddenmenu
title Fedora (2.6.27.21-170.2.56.fc10.i686)
	root (hd1,0)
	kernel /vmlinuz-2.6.27.21-170.2.56.fc10.i686 ro root=UUID=49bb45b4-200b-4ba2-b0c8-7cc7d2fc501c
	initrd /initrd-2.6.27.21-170.2.56.fc10.i686.img
title Fedora (2.6.25-14.fc9.i686)
	root (hd1,0)
	kernel /vmlinuz-2.6.25-14.fc9.i686 ro root=UUID=49bb45b4-200b-4ba2-b0c8-7cc7d2fc501c
	initrd /initrd-2.6.25-14.fc9.i686.img
title Other
	rootnoverify (hd0,0)
	chainloader +1

[root@mango ~]# cat /boot/grub/device.map
# this device map was generated by anaconda
(hd1)     /dev/mapper/isw_cabahdgdcf_UNIX
(hd0)     /dev/mapper/isw_cabahdgdcf_Windows

[root@mango ~]# fdisk -l /dev/dm-3

Disk /dev/dm-3: 320.0 GB, 320082153472 bytes
255 heads, 63 sectors/track, 38914 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x279063ed

     Device Boot      Start         End      Blocks   Id  System
/dev/dm-3p1   *           1        9763    78421266    7  HPFS/NTFS
[root@mango ~]# fdisk -l /dev/dm-0

Disk /dev/dm-0: 320.0 GB, 320047550464 bytes
255 heads, 63 sectors/track, 38910 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x00063eae

     Device Boot      Start         End      Blocks   Id  System
/dev/dm-0p1   *           1          65      522081   83  Linux
/dev/dm-0p2              66        9759    77867055   8e  Linux LVM


Final Comments: I marked this bug as HIGH because being able to actually install Fedora 10 on fakeraid based systems seems relatively important. Once a fairly involved "workaround" is used (install Fedora 9 -> yum upgrade) to install and boot Fedora 10 one expects to be able to use grub-install to fix a variety of problems.
because of a string of GRUB, motherboard BIOS based "fakeraid" issues that appear to have plagued Fedora 10 from the begining.

Comment 1 Josef Carlin 2009-04-11 00:09:15 UTC
Created attachment 339139 [details]
A copy of current MBR

I attached a copy of my MBR as Fedora 10 may have never upgraded it from Fedora 9. This MBR image was created using dd. It may be of some help to developers or troubleshooters.

[root@mango dev]# dd if=/dev/mapper/isw_cabahdgdcf_Windows of=/root/mbr.img bs=512 count=1
1+0 records in
1+0 records out
512 bytes (512 B) copied, 3.2347e-05 s, 15.8 MB/s

[root@mango dev]# file /root/mbr.img
/root/mbr.img: x86 boot sector; partition 1: ID=0x7, active, starthead 1, startsector 63, 156842532 sectors

Comment 2 Bug Zapper 2009-11-18 09:59:12 UTC
This message is a reminder that Fedora 10 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 10.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '10'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 10's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 10 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 3 Bug Zapper 2009-12-18 09:13:52 UTC
Fedora 10 changed to end-of-life (EOL) status on 2009-12-17. Fedora 10 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.