15

I want to install windows 7 on an unallocated space made by shrinking an extended partition. the problem is that windows setup can't create new partition on unallocated space. how I can create a partition there using diskpart while that space is not shown by "list partition" of diskpart?

3 Answers 3

22

I wouldn't suggest using diskpart if the hard drive already has some data on it, especially if you've installed the system on it. This is because if you don't know how to use it, then it's better to avoid using it to prevent you from data loss. You can use a third party tool to do that instead, which will give you the same results. Use EaseUS Partition Master (Free Edition).

In case you still prefer to do it the long way, using diskpart, follow these steps :

  1. Open the Command Prompt as Administrator. Type diskpart and hit Enter.
  2. Once you enter to the diskpart screen type list disk and hit Enter.
  3. Now a list of the disks will be shown, type select disk x (the X is the disk number that has an unallocated space) and hit Enter.
  4. Now, type create partition primary size=x (The X is the number that you got from the Free column on the previous step) and hit Enter.
  5. After the creating is done, type select partition 2 and hit Enter.
  6. Now that you are in the new partition, you need to format it by typing format fs=ntfs quick and hit Enter.
  7. After that, type assign and hit Enter.
  8. Then, type active and hit Enter.
  9. Now, your new partition is ready to use.

P.S: Make sure that you select the correct disk that you want to create a new partition on it. Also, Disk 0 is the disk that has the current system installed on.

This is an example of how the above process works: Suppose that I have an 8GB flash drive that it has one partition with size 4GB, and an unallocated space of 3535MB (about 3.5GB). So I need to use the unallocated space and create a new partition to be used. enter image description here

3
  • Hi, I have a brand new ssd disk, for some reason when i do list disk, the disk have 0 free, i am wondering why? this (0 free) doesnt have any sense
    – user668027
    Commented Apr 29, 2016 at 9:19
  • @user668027 if you mean that the "0" under Free column, don't worry about it, because it shows the total unpartitioned space on your SSD.
    – iSR5
    Commented Apr 29, 2016 at 9:40
  • If you have a partition that occupies a part of the disk, you can select it, delete it and then create a partition.
    – Asu
    Commented Jul 27, 2017 at 23:19
0

You could try using Disk Management this will allow resizing partitions and creating new ones with great ease. Create a NTFS partition if you want to be able to boot Windows from it.

2
  • Thanks. but I have formatted windows partition and there is no other windows installed. windows setup gui can't create new partition, when I press apply nothing happens! Is it safe to use tools like Hiren's Boot CD?
    – Hadi
    Commented Oct 12, 2014 at 0:21
  • 1
    Yes that is one of the many uses of Hiren´s but I would recommend that unless you know it is one of the real copies to just dowload ubuntu and use the gparted command it will bring a easy to use gui. Commented Oct 12, 2014 at 0:24
0

Problem solved. thanks. I used a boot tool from Acronis and problem solved. the main problem was error "Setup was unable to use the existing partition because it does not contain the required free space." when I wanted to select partition to install windows 7. that problem solved by deleting system partition (I think it's a small partition for boot data, etc).

1
  • Super thanks man for this great step by step explanation! Cool for when there are lazy ones among us, like me today :-D Thanks man!
    – Lawrence
    Commented Jun 21, 2016 at 16:57

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .