Saturday, February 27, 2010

Set active partition in Windows XP, Vista & 7 using command line

Scenario: you have installed an OS such as Mac OS X on a secondary partition, and after restart you can no longer boot-up your system.

Solution: boot using your Windows cd/dvd; get into the command prompt and type diskpart 

 1

Type list disk to see the list of disks installed in your system. Type select disk 0, assuming 0 is the number of your disk containing your partitions.

2


Now that we have selected the disk, type  list partitions to get the list of all partitions on the disk.

3

To activate the desired partition type select partition n, where n is the partition number. 
Now that we have selected the desired partition, we can mark it as active by typing active

Adrian