Dual Boot Windows 7 and Fedora 12 Linux with Dell Utility and Recovery Partitions 9

After successfully setting up a dual boot of Windows 7 (64-bit) and Fedora 12 on my new Dell Studio laptop, I wanted to record some of the tricks that were necessary to get it done.

The laptop is a Dell Studio 1737 (why didn’t they call it 1337?) which came pre-installed with Windows Vista Home Premium. The drive is 320 GB, which Dell had pre-partitioned into three partitions:

  1. Dell Utility Partition (82 MB FAT 16-bit)
  2. Dell Recovery (16 GB NTFS)
  3. OS (304 GB NTFS)

First, I did a full install of Windows 7 64-bit from DVD. I kept the Dell Utility and Recovery partitions intact, and installed Win7 on the OS partition.

After the installation was complete, I used the built-in Disk Management tool in Windows 7 to shrink the OS partition, so I could make some space for the Fedora Linux install. To do this, hit Start, right-click Computer, and select Manage. The Disk Management tool is in the Storage category. I selected the OS partition, right-clicked, and then selected Shrink Disk Volume. It took a few minutes for the system to run a query to see how much space was available for shrinking. The more fragmented your drive, the less space you have available to shrink your partition.

After the query, the system asked me to enter the amount of space to shrink in MB. This is the same as asking you how big you want the new unallocated space to be, which is the same as asking how much space you want to make available for your Linux installation. I chose a nice round number like 100000 (approx 100 GB), and hit Shrink.

It wasn’t a super-fast operation, but it took much less time than I thought it would. After the shrink, I had 105 GB of unallocated space. That’s more than enough for a comfortable Fedora 12 install, but I’m a fan of overkill. One thing that surprised me is that Win7 didn’t prompt me to reboot after the shrink!

Next, I popped in my Fedora 12 Live CD and rebooted (I needed to hit F12 at the BIOS post screen to tell the system to boot from the CD). Once the Fedora desktop was up, I logged in as the Live User, connected to the wireless network, and selected the Install to Disk option on the desktop. I told the installer where I wanted Linux installed (the unpartitioned space) and also checked the button that allowed me to review the partition layout. Everything was fine by default.

I installed the Bootloader on /dev/sda, which is the default. Keep in mind that this will overwrite the Windows bootloader, but I didn’t care. I’d rather have GRUB handle the booting, thank you. After the install was complete, I rebooted to see if everything worked.

I assumed that the Fedora install would recognize the Windows 7 install and automatically add it to the GRUB boot menu. I was half right. When the GRUB screen appeared and I hit the space bar to see my boot options, I had one line with FC12 and a second line that just said “Other.” Assuming that to be Windows 7, I selected it and hit ENTER. Then I got a black screen telling me that no boot manager was present, and that I needed to hit CTRL+ALT+DEL. Clearly, I’d done something wrong.

Not one to panic, I rebooted and selected Fedora as my operating system. I inspected the /boot/grub/menu.lst file, and saw the following:

title Fedora (
root (hd0,4)
kernel /vmlinuz- ro root=/dev/mapper/vg_studio-lv_root noiswmd LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet
initrd /initramfs-
title Other
rootnoverify (hd0,0)
chainloader +1

Hmmm… I realized that GRUB might be trying to boot the Utility Partition instead of the Windows 7 OS one. To verify this, I ran the fdisk -l command as root and saw the following:

Device Boot Start End Blocks Id System
/dev/sda1 1 10 80293+ de Dell Utility
/dev/sda2 11 1969 15728640 7 HPFS/NTFS
/dev/sda3 1969 26165 194360320 7 HPFS/NTFS
/dev/sda4 26166 38913 102398310 5 Extended
/dev/sda5 * 26166 26191 204800 83 Linux
/dev/sda6 26191 38913 102193151+ 8e Linux LVM

Yep! It was trying to boot Windows from /dev/sda1, which is referred to as hd(0,0) in the menu.lst file. Since zero is the first number in Linux systems, that technially means “first hard drive, first partition.” I wanted the first hard drive, but the third partition, so I edited the /boot/grub/menu.lst file so that the last three lines read:

title Microsoft Windows 7 (64-bit)
rootnoverify (hd0,2)
chainloader +1

This makes the title that appears on the boot screen more informative, and tells GRUB to boot from the third partition on the first hard disk.

One more reboot, to test, and everything worked fine! I’ve now got a Windows 7 / Fedora 12 dual-booting laptop with the Dell Utility and Recovery partitions intact!

  • Pingback: Enabling Desktop Effects on Fedora 12 with ATI Radeon HD 3650 | Steve Jenkins' Blog()

  • cod3fr3ak

    Thanks for this. This is precisely what I am about to do with my new quad core desktop.

  • Chandra

    Thank you very much.

    This is exactly what I am trying to do…..will try it soon.

  • shane

    And have you confirmed that you can boot into the utility and restore partitions?

  • @Shane: Yes – pressing the appropriate function key while the initial POST screen is displayed will allow you to access the BIOS Boot menu or boot directly into the utility partition.

  • Anwar

    Thanks a lot Steve for this article.
    I had this problem and I gave up Fedora just because of this..Ubuntu does a fantastic job of doing it right(It does allow me to boot into windows instead of giving a message about not finding the boot loader). I found that only Fedora needs this kind of manual configuration. Ubuntu does it just fine..

  • Your article (blog) is very well done and absolutely clear. I currently have a two disk system with XP-F12 and second drive with W7. I want to begin looking at F13 as a guinea pig.

  • anuranj

    thank you vry much… its wrking….

  • abhijit

    Hello, i want to install fedora 12, but when i want to install it the whole heard drive is erised. I want to install it with windows7 OS. I heave already windows7 in my computer,so how can i install fedora12 without uninstalling windows7. Please please help me on this topic.