Anda di halaman 1dari 5

Install Dual-Boot of Fedora 11 on Windows 7 computer (Win7 installed first and GRUB controlling startup after Linux installation)

Introduction
This guide shows how to correctly and safely create a natural dual-boot of Windows 7 and Linux Fedora 11 on a computer with Windows 7 already installed. Linux's boot loader (GRUB) will be in control of startup. You can then run either by selecting one from a Linux menu during bootup. No data loss will occur and a third-party boot utility is not used. In this procedure you need to shrink the Windows 7 drive to make room for Linux. The example shown here uses one hard disk. 32 and 64-bit versions of Windows 7 Home Basic, Enterprise and Ultimate were used in testing so this will also work with Windows 7 Premium and Professional. The computers used were (1) a 32bit Dell Optiplex with Pentium 4 (2.26GHz), 2.0 GB RAM, 160 GB ATA hard disk, and (2) AMD Athlon 64-bit (2.4GHz), 2.0 GB RAM, 1 TB SATA hard disk. Following these instructions correctly should always succeed. However, any change to your computer should not even be considered unless your have a rescue plan. This guide also contains that rescue plan - just in case! The procedure used is suitable for experienced computer users. If you wish Windows to be in control of the dual-boot, go to http://www.thpc.info/dual/win7/dualboot_win7+fedora11_bcd_on_win7.html If you are not installing version 11 of Fedora, you must go to this page and select the correct version.
[top of page]

Important Installation Notes


Shrinking a Windows 7 or Vista drive. You should use Shrink in Windows' Disk Management to resize the Windows partition. If the free space achieved is inadequate, you can read Shrink the Windows 7 or Vista Partition for instructions on completing this task successfully. Use the free GParted Live CD to gain disk space only if you absolutely must - read the page Use GParted to Resize the Windows 7 or Vista Partition to learn how and, before you use GParted, read Repair Windows 7 Startup (below). Where should you install the Linux boot loader (GRUB) ? 1. To the Linux partition. In this case the Linux partition must be a Primary because it must be made Active during installation. However the original MBR and boot loader remains intact and you can easily restore the Windows-controlled boot by just making the original partition Active again. 2. To the MBR (Master Boot Record). Doing this overwrites the existing Windows MBR and boot loader (BCD) and makes it difficult to restore Windows as a single entity should you wish to do so at a later time. It has the advantage that you can install Linux itself on a Logical partition.
[top of page]

SUMMARY of Procedure
1. 2. 3.

(Advanced users)

4.

Backup. Create Unallocated space for Linux at end of Windows NTFS disk (use Shrink in Disk Management). Install Linux Fedora 11 on the free space - select "Create custom layout" and create partitions yourself. - install GRUB on the MBR (the default option) or install GRUB on the Linux partition (in "Install boot loader on ...", select "First sector of boot partition"). Restart computer. Select which OS you wish to use from the GRUB menu.

That's it! The GRUB boot loader menu will boot Linux Fedora 11 or Windows 7.

Details: Install Linux Fedora 11 and GRUB when Windows 7 was installed first
Installing other operating systems on your Windows 7 computer may invalidate your warrantee. It's important to follow the instructions exactly as stated and you should have a properly working Windows.

A. Make your preparations


1. 2. 3. 4. Backup important data before making any changes to a partition. You can burn files to a CD, clone an image of your hard disk, copy files to a USB flash/pen/thumb drive, or use an USB external drive (a good choice) Download Fedora 11, standard or 64-bit version from http://fedoraproject.org/. You can use the excellent free GetRight download manager to help with the large download. Create the Fedora Live DVD from the downloaded .ISO file. Optional: Download NeoSmart's free Windows 7 System Recovery Disk if your Win7 DVD is missing! Disconnect all external devices before you start.

B. Make free space (Unallocated) for Linux


The single 160 GB disk usually used in testing initially had: System Reserved (100 MB, Primary, Hidden, NTFS), Windows 7 (150 GB, Primary, NTFS). The Windows 7 drive was shrunk leaving about 60 GB Unallocated space at the end of the disk (to the right). After repartitioning it had: System Reserved (100 MB, Primary, Hidden, NTFS), Win7 (90 GB, Primary, NTFS), Linux (60 GB, Unallocated). 1. 2. Restart computer correctly (close all programs/software before Restart). Open Disk Management in Windows 7 (right-click Computer, select Manage, click Disk Management). o Note which partition is marked Active. o Right-click the Win7 volume, and click Shrink Volume. In Enter the amount of space to shrink in MB: enter enough for Linux and its Swap file.

Click the Shrink button (it may take some time!). Note that we are leaving the newly acquired free space as Unallocated.

If Shrink does not give you sufficient Unallocated space, read Shrink the Windows 7 or Windows Vista Partition for instructions on how to complete this task successfully. Then return here. 3. Restart to Windows 7 two times. o Open Disk Management and check that the change made is correct.

Use the free GParted Live CD to gain adequate disk space only if you absolutely must - read the page Use GParted to Resize the Windows 7 or Vista Partition to learn how, and read Repair Windows 7 Startup (below) before you use GParted.

C. Install Fedora 11
Raid/LVM was not an issue when testing so partitions were created manually during installation. Grub was installed either to the Linux EXT3 partition or to the MBR - both worked fine though the Linux partition is preferred unless you have specific reasons for overwriting the Windows boot sector and boot loader. 1. Bootup from the Linux Fedora 11 installation CD/DVD. Select Install or upgrade an existing system. o Continue with the initial screens until you're presented with the option of partitioning your hard disk (you can skip the testing of media - it checks your CD/DVD for errors). Select Create custom layout in the top drop-down list and click Next. o Highlight the Free space, and click the New button. Add Partition will open. First create the Fedora partition. In Mount Point:, select / (a forward slash). In File System Type:, select ext3 In Size (MB):, enter all available space (for Fedora) except 1 GB (for the Swap File) Click the OK button. o Highlight the remaining Free space, and click the New button. Add Partition will open. Now create the Swap partition. In Mount Point:, leave it blank. In File System Type:, select swap. Tick to enable Fill to maximum allowable size Click the OK button (it's fine if the Swap is made a Logical partition in an Extended partition).

Click Next when ready, or click Back to recreate partitions. Then click Write changes to disk or Go back if unhappy with the changes. The new partitions will be created and formatted on the disk now.

The next screen is vital to ensure the correct location for GRUB.

If you want to overwrite the Windows boot loader, leave the default at Install boot loader on /dev/sda or

2. 3.

/dev/hda If you do not want to overwrite the Windows boot loader Click the Change device button. Select First sector of boot partition and click OK. Using a boot loader password is optional. Under Boot loader operating system list, highlight the Device labelled Other and click the Edit button. In Label, enter a name like "Windows 7". Leave Default Boot Target unchecked unless you want Windows 7 to be the default on bootup. Click OK. Click Next. o Deal with the software applications screen as you think fit ("Customize later" is fine). o Click Next and the install process will start. Fedora will reboot your computer once before installation is completed (remove the DVD). Restart computer. Press the required key (within three seconds!) when you see Press ... key to enter the menu to access the boot menu.

Congratulations! You have created a GRUB-controlled natural dual-boot of Windows 7 and Linux Fedora 11 when Windows 7 was installed first. Finished!

Help! I want Windows-control back again!


The Windows boot loader can be recovered relatively easily. Doing so will stop you booting to Linux Fedora.

How to reinstall/recover the Windows 7/Vista boot loader (BCD)


1. If you installed GRUB to the Linux partition: o Read Make the originally active partition Active again at: http://www.thpc.info/how/make_active.html (new window) o Reboot. Finished! If you installed GRUB to the MBR: Bootup any Windows 7/Vista installation DVD or even from NeoSmart's free Windows 7 System Recovery Disk. It must be a 64-bit version if a 64-bit Windows 7/Vista is installed. o Press a key when you see Press any key to boot from a CD or DVD. o Select your Language and then Time.... o Select Repair your computer (bottom left of the Install now screen). An automatic check of your system will run but will not identify GRUB control! o In System Recovery Options, highlight Windows 7, and click Next. o Click Command Prompt in System Recovery Options. Type in (and press ENTER) Bootrec.exe /fixmbr exit (GRUB will be overwritten and the Windows boot loader reinstalled). o Now click Startup Repair in System Recovery Options. o Restart computer. Windows 7 should boot as originally.

2.

Related Reading

How do I ...

Shrink the Windows 7 or Windows Vista Partition Use GParted to Resize the Windows 7 or Vista Partition Mark a Partition as Active Show Hidden Files in Windows, MS-DOS, Command Prompt Boot from a bootable CD/DVD Add a new Hard Disk without changing drive letters Reinstall GRUB Edit Grub's Boot Menu Options

Anda mungkin juga menyukai