5 November 2012

How to Dual Boot Windows 8 and Windows 7 Using VHD

The final version of the Windows 8 released and so many of users upgraded their operating system to the Windows 8. You might be still using Windows 7 or Vista and don’t want to create a fresh install of Windows 8 and lose all your installed programs and setting. Or you are not sure about upgrading to Win 8 and want to work around with it and familiar with its environment. The solution for you is to install Windows 8 alongside Windows 7 or Vista. There are some few ways that you can achieve this goal:

First using a virtual machine software like VirtualBox

Second allocate and partition a portion of your hard disk and install the Windows 8

Third is to use the VHD (Virtual Hard Drive) feature of Windows 7 and Vista

Using Virtualization software is easy to set up and host the Win 8 on your guest operating system, but it has its limitation specially in performance as the guest OS and host OS have to share the same resources. The second option is better but I am not recommending it, because you have to create a new partition and allocated to the Windows 8. Especially if you already have three primary partitions then you need to convert your hard drive to a dynamic hard drive and then make a new partition for the Win 8 OS. So in my opinion the last option is the best one. Microsoft included a new feature in Windows Vista and 7 and it is the ability to boot from Virtual Hard Disk or VHD. You can simply create a VHD, allocate some fixed or expanded space and install the Windows 8. In that way you have two operating systems (Win 8 and 7/Vista) alongside each other and when you boot your system you have the option to choose Win 8 or Win 7/Vista. The installation process is easy and in this post I’ll show you how to install Windows 8 using VHD. Before doing anything it is better to get a backup of your operating system and important data in case something goes wrong. Now follow these steps:

Step 1
For the sake of this tutorial, I have downloaded the Windows 8 evaluation for developers. The Windows 8 Enterprise is free to download and works for 90 days. I think 90 days is enough for you to get familiar with the Win 8 environment and then decide to upgrade your OS. You should know after the 90 days you cannot upgrade it again and you have to uninstall it and install a fresh version. If you already have the Windows 8 DVD so you don’t need to download this version and use your own Win 8 but if you don’t then download Windows 8 Enterprise 90-day evaluation from the Microsoft official website:

The size of the image file is 2.37 GB and to mount the image you need utility software like Demon Tools or MagicDisk. There are lots of emulation freeware in the Internet that you can use. Just Google it.

The next thing you need is the imageX.exe file. This file is included in the Microsoft Windows AIK (for developers) and you can download it from the Microsoft official website. The size of this kit is 1.66 GB and the size of the imageX.exe is only 470 KB. Unfortunately I cannot upload it on my website for you as it is licensed by Microsoft. So you have to download the whole kit to get the imageX.exe.

Step 2
After you finished downloading the files, go to the Start and in the Search box type Disk management then hit the Enter key. The Disk Management window will be opened.

Step 3
Now we create the VHD on which we are going to install Windows 8. From the Action menu, you have to click on Create VHD.

Step 4
In the Create and Attach Virtual Hard Disk window, inside the text box under the Location, enter the path that you want to save your VHD file or navigate it with the Browse. Also assign a name for it with extension .vhd. I will create my VHD file in drive D: and name it Win8.vhd as you can see in the figure.

Determine disk space for your VHD file. For Win 8 - 32 bit you need at least 16 Giga byte disk space and for 64 bit 20. I have entered 30 GB for my VHD (you can assign whatever space you want according to your hard disk free space). For Virtual hard disk format you have two options, Dynamically expanding and Fixed size. Choose any one that suits your need and hit then click on OK. Wait for few minutes till the Windows finished the process.

Step 5
When the VHD file generated you will see another Disk (usually Disk 1) in the Disk management window that Unallocated

Right-click on it and from the drop down menu, select Initialize Disk and choose MBR.

Step 6
Next step is to format and make a volume for your disk. For this you need to right-click on gray area and select New Simple Volume

The New Simple Volume Wizard will be opened. Click on the Next button. Leave everything at its default except the Volume label. Give a Volume name for your disk like Win 8. The Windows will format the VHD disk and give a letter to it. In my case it is J.

Step 7
Go to the Command Prompt (enter CMD in the Start Search box), but before that we need the imageX.exe file. First of all install the Microsoft Windows AIK (Automated Installation Kit). To do that you need to mount the ISO file. I use Demon Tools Light (Freeware) to mount the image. You can use any other program you want.

When the installation finished, go to the

My Computer>C:>Program Files>Windows AIK>Tools>x86

And copy the imagex file to any of you system drive you want. I created a new folder and named it imagex and then copied the file inside it.

Step 8
Back to the command prompt again and navigate to the folder you have copied the imageX.exe file.

Un-mount the AIK ISO file and mount the Windows 8 image file then enter the following command in CMD:

Imagex /apply i:\sources\install.wim 1 j:\

The i: is my virtual drive that the Windows 8 has been mounted and j: is the VHD drive. This command will install the Win 8 on the VHD. Wait till process finished.

Step 9
Enter the command below to add the Win 8 to the system Boot:

Bcdboot j:\windows

Exit from the command prompt and Disk Management, and then restart your system. The system will boot from the Windows 8 and start installing the device drivers. The rest of the process after that is just like any other Windows installation process (asking for your PC name, Region and Language, User Password and so on). During the installation the system may restart for one or several times. At this time you have two operating system Windows 7 and 8. Whenever you boot your system, you have the option to choose between the Windows 7 and 8. Congratulation you have installed the Windows 8. If you face any problem or difficulty, just leave a comment in this post.