 |
 |
 |
 |
| Installation and Live Media Help with Installation & Live Media (Live CD, USB, DVD) problems. |

21st February 2012, 01:27 AM
|
 |
Registered User
|
|
Join Date: Dec 2011
Location: Worcester MA
Posts: 109

|
|
|
Grub, dual win7 & f16
So I reinstalled f16 on my dual boot machine, and grub no longer shows the windows 7 choice.
Only thing I messed up with the first time I did it I grabbed the 64 bit live f16 dvd by mistake but corrected that.
Is there away to edit grub to work again or is the Mbr messed up?
|

21st February 2012, 02:24 AM
|
|
Registered User
|
|
Join Date: Jun 2006
Posts: 7,551

|
|
|
Re: Grub, dual win7 & f16
Quote:
|
Originally Posted by spacin
Is there away to edit grub to work again or is the Mbr messed up?
|
If Fedora 16 is booting, then the master boot record is okay. Forget about that. To me, what you described is a boot menu issue. And GRUB 2 uses the grub.cfg file to create the menu.
I would start by booting Fedora, opening a terminal, and running the command to regenerate the grub.cfg file. Anyway, it should be a harmless thing to do even if it doesn't help the current situation. It usually goes like this...
Code:
su
grub2-mkconfig -o /boot/grub2/grub.cfg
No promises.
|

21st February 2012, 09:33 PM
|
|
Registered User
|
|
Join Date: Jun 2008
Posts: 31

|
|
|
Re: Grub, dual win7 & f16
You can manually edit the grub configuration; normally to boot Windows all you need are two lines, a root command that sets the disk partition where the Windows system resides, and then a chainloader command. So on my system it looks like this in grub.conf or menu.lst:
title Windows 7
root(hd0, 0)
chainloader +1
My Windows is on first partition of first HD.
|

21st February 2012, 09:56 PM
|
|
Registered User
|
|
Join Date: May 2009
Posts: 148

|
|
|
Re: Grub, dual win7 & f16
Quote:
Originally Posted by spacin
So I reinstalled f16 on my dual boot machine, and grub no longer shows the windows 7 choice.
Only thing I messed up with the first time I did it I grabbed the 64 bit live f16 dvd by mistake but corrected that.
Is there away to edit grub to work again or is the Mbr messed up?
|
Please post the output of:
sudo fdisk -l
|

22nd February 2012, 02:09 PM
|
 |
Registered User
|
|
Join Date: Dec 2011
Location: Worcester MA
Posts: 109

|
|
|
Re: Grub, dual win7 & f16
it looks like this one worked i havent rebooted yet....
Code:
su
grub2-mkconfig -o /boot/grub2/grub.cfg
output of that was....
Code:
# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.2.6-3.fc16.i686
Found initrd image: /boot/initramfs-3.2.6-3.fc16.i686.img
Found linux image: /boot/vmlinuz-3.1.0-7.fc16.i686
Found initrd image: /boot/initramfs-3.1.0-7.fc16.i686.img
Found Windows 7 (loader) on /dev/sda1
done
out put of sudo fdisk -l
Code:
Disk /dev/sda: 360.1 GB, 360080695296 bytes
255 heads, 63 sectors/track, 43777 cylinders, total 703282608 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000bac3b
Device Boot Start End Blocks Id System
/dev/sda1 * 2048 309250047 154624000 7 HPFS/NTFS/exFAT
/dev/sda2 309250048 310274047 512000 83 Linux
/dev/sda3 310274048 703281151 196503552 8e Linux LVM
Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xd0a6334e
Device Boot Start End Blocks Id System
/dev/sdb1 63 976768064 488384001 42 SFS
Disk /dev/sdc: 750.2 GB, 750156374016 bytes
255 heads, 63 sectors/track, 91201 cylinders, total 1465149168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x465232c5
Device Boot Start End Blocks Id System
/dev/sdc1 63 1465144064 732572001 7 HPFS/NTFS/exFAT
Disk /dev/sdg: 2045 MB, 2045771776 bytes
128 heads, 32 sectors/track, 975 cylinders, total 3995648 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Device Boot Start End Blocks Id System
/dev/sdg1 * 375 3995647 1997636+ 6 FAT16
Disk /dev/mapper/vg_fedora16-lv_swap: 4227 MB, 4227858432 bytes
255 heads, 63 sectors/track, 514 cylinders, total 8257536 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/vg_fedora16-lv_swap doesn't contain a valid partition table
Disk /dev/mapper/vg_fedora16-lv_root: 53.7 GB, 53687091200 bytes
255 heads, 63 sectors/track, 6527 cylinders, total 104857600 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/vg_fedora16-lv_root doesn't contain a valid partition table
Disk /dev/mapper/pdc_fbdicaff: 500.1 GB, 500107771904 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976772992 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xd0a6334e
Device Boot Start End Blocks Id System
/dev/mapper/pdc_fbdicaff1 63 976768064 488384001 42 SFS
Disk /dev/mapper/pdc_fbdicaffp1: 500.1 GB, 500105217024 bytes
255 heads, 63 sectors/track, 60800 cylinders, total 976768002 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x69205244
This doesn't look like a partition table
Probably you selected the wrong device.
Device Boot Start End Blocks Id System
/dev/mapper/pdc_fbdicaffp1p1 ? 218129509 1920119918 850995205 72 Unknown
/dev/mapper/pdc_fbdicaffp1p2 ? 729050177 1273024900 271987362 74 Unknown
/dev/mapper/pdc_fbdicaffp1p3 ? 168653938 168653938 0 65 Novell Netware 386
/dev/mapper/pdc_fbdicaffp1p4 2692939776 2692991410 25817+ 0 Empty
Partition table entries are not in disk order
Disk /dev/mapper/vg_fedora16-lv_home: 143.3 GB, 143277424640 bytes
255 heads, 63 sectors/track, 17419 cylinders, total 279838720 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000
Disk /dev/mapper/vg_fedora16-lv_home doesn't contain a valid partition table
Disk /dev/sdh: 1500.3 GB, 1500301908992 bytes
255 heads, 63 sectors/track, 182401 cylinders, total 2930277166 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xae6d8257
Device Boot Start End Blocks Id System
/dev/sdh1 63 2930272064 1465136001 7 HPFS/NTFS/exFAT
Disk /dev/sdi: 2000.4 GB, 2000396746752 bytes
255 heads, 63 sectors/track, 243201 cylinders, total 3907024896 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0003990f
Device Boot Start End Blocks Id System
/dev/sdi1 2048 3907024895 1953511424 7 HPFS/NTFS/exFAT
|

22nd February 2012, 02:39 PM
|
|
Registered User
|
|
Join Date: Jun 2006
Posts: 7,551

|
|
|
Re: Grub, dual win7 & f16
Quote:
|
Originally Posted by spacin
it looks like this one worked i havent rebooted yet....
Code:
su
grub2-mkconfig -o /boot/grub2/grub.cfg
output of that was....
Code:
# grub2-mkconfig -o /boot/grub2/grub.cfg
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-3.2.6-3.fc16.i686
Found initrd image: /boot/initramfs-3.2.6-3.fc16.i686.img
Found linux image: /boot/vmlinuz-3.1.0-7.fc16.i686
Found initrd image: /boot/initramfs-3.1.0-7.fc16.i686.img
Found Windows 7 (loader) on /dev/sda1
done
|
Well, it at least found the Windows system.
Quote:
|
Originally Posted by spacin
i havent rebooted yet....
|
If Windows still is not in the boot menu when you reboot (not exactly unheard of), then I would proceed to write a simple custom entry for it in /etc/grub.d/40_custom and run the grub2-mkconfig command again.
To try that idea , open /etc/grub.d/40_custom and add the following lines below the text already there ( see the GRUB Manual)...
Code:
menuentry "Windows" {
insmod chain
insmod ntfs
set root=(hd0,1)
chainloader +1
}
After that, regenerate the grub.cfg file again...
Code:
su
grub2-mkconfig -o /boot/grub2/grub.cfg
Reboot. Try to boot Windows.
|

22nd February 2012, 02:59 PM
|
 |
"Registered User" T-Shirt Winner
|
|
Join Date: Mar 2007
Location: Seville, FL
Posts: 5,126

|
|
|
Re: Grub, dual win7 & f16
You should have the following entry in your /boot/grub2/grub.cfg file after running the grub2-mkconfig -o /boot/grub2/grub.cfg command. But if not, this is the entry that should be there and you can add it manually if need be.
Code:
### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sda1)" --class windows --class os {
insmod part_msdos
insmod ntfs
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set=root 2D42AD5A2CE55342
chainloader +1
}
### END /etc/grub.d/30_os-prober ###
The blue highlighted lines should be pre-exisiting. You add the menu entry between those two lines.
The red highlighted number needs to be the UUID of your /dev/sda1 partition (mine is shown). To get the correct UUID for your /dev/sda1 partition, use the blkid command.
---------- Post added at 09:59 AM ---------- Previous post was at 09:54 AM ----------
The method suggested by stoat should work also.
Last edited by PabloTwo; 22nd February 2012 at 02:56 PM.
|

22nd February 2012, 04:00 PM
|
 |
Registered User
|
|
Join Date: Dec 2011
Location: Worcester MA
Posts: 109

|
|
|
Re: Grub, dual win7 & f16
Quote:
Originally Posted by PabloTwo
You should have the following entry in your /boot/grub2/grub.cfg file after running the grub2-mkconfig -o /boot/grub2/grub.cfg command. But if not, this is the entry that should be there and you can add it manually if need be.
Code:
### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sda1)" --class windows --class os {
insmod part_msdos
insmod ntfs
set root='(hd0,msdos1)'
search --no-floppy --fs-uuid --set=root 2D42AD5A2CE55342
chainloader +1
}
### END /etc/grub.d/30_os-prober ###
The blue highlighted lines should be pre-exisiting. You add the menu entry between those two lines.
The red highlighted number needs to be the UUID of your /dev/sda1 partition (mine is shown). To get the correct UUID for your /dev/sda1 partition, use the blkid command.
---------- Post added at 09:59 AM ---------- Previous post was at 09:54 AM ----------
The method suggested by stoat should work also.
|
and it did... using winders now.... every time i boot into winders i wonder why its still here, i have a laptop thats dual boot also. ugh oh well...
Thanks for the help
|
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
Current GMT-time: 03:57 (Friday, 24-05-2013)
|
|
 |
 |
 |
 |
|
|