How to merge 2 Partions in Your Windows XP PC.

August 10, 2007

**** DISCLAIMER (09/2010):  Hi guys… I wrote this back in 2007 while cleaning up my old PC which is a windows XP machine (don’t remember SP ver).  So this may work for you if you running same version of XP or other version of windows.  Some of the users noticed it didn’t work for them.  So please try it at your own risk and I hope you don’t add me to your most hated list *******

Say you have 2 partitions named C and E and you no longer need E partition and wants to merge with C.
1) Download DISKPART.EXE from this Microsoft website and Install it.
2) Backup Data in Volume E ( if it has any)
3) Start DISKPART.EXE

C:Program FilesResource Kit>DISKPART.EXE  

Microsoft DiskPart version 5.1.3553  

Copyright (C) 1999-2001 Microsoft Corporation.  

On computer: YOURPCNAME  

DISKPART>

4) List and Select Volume E

DISKPART> LIST VOLUME  

Volume ###  Ltr  Label        Fs     Type        Size       

Volume 0     F   CDRoot       CDFS   DVD-ROM     4254 MB  

Volume 1     C                NTFS   Partition     11 GB    

Volume 2     E   New Volume   NTFS   Partition   7844 MB   

Volume 3     D                       Removeable      0 B  

DISKPART>  SELECT  VOLUME  2

Make sure Volume E is Selected. It should show a * infront volume

DISKPART> LIST VOLUME  

  Volume ###  Ltr  Label        Fs     Type        Size       

  Volume 0     F   CDRoot       CDFS   DVD-ROM     4254 MB  

  Volume 1     C                NTFS   Partition     11 GB    

* Volume 2     E   New Volume   NTFS   Partition   7844 MB   

  Volume 3     D                       Removeable      0 B

5) Delete Volume E

DISKPART> DELETE VOLUME  

DiskPart successfully deleted the volume.  

DISKPART> LIST VOLUME  

  Volume ###  Ltr  Label        Fs     Type        Size       

  Volume 0     F   CDRoot       CDFS   DVD-ROM     4254 MB  

  Volume 1     C                NTFS   Partition     11 GB   

  Volume 2     D                       Removeable      0 B

6) Now Select Volume C

DISKPART> SELECT VOLUME 1  

******** DISCLAIMER (09/2010):  Hi Guys..I wrote this back in 2007 while cleaning up my old PC which is a Windows XP machine.
So this may work for your PC OR NOT. I have noticed it worked for some of you without issues but some noticed issues...So please try
at your own risk and don't add me to your most hated list ********

Volume 1 is the selected volume.  

DISKPART> LIST VOLUME  

  Volume ###  Ltr  Label        Fs     Type        Size       

  Volume 0     F   CDRoot       CDFS   DVD-ROM     4254 MB  

* Volume 1     C                NTFS   Partition     11 GB   

  Volume 2     D                       Removeable      0 B

7) Claim the Remaining Space left by Volume E

DISKPART> EXTEND  

DiskPart successfully extended the volume.  

DISKPART> LIST VOLUME  

  Volume ###  Ltr  Label        Fs     Type        Size       

  Volume 0     F   CDRoot       CDFS   DVD-ROM     4254 MB  

* Volume 1     C                NTFS   Partition     19 GB    

  Volume 2     D                       Removeable      0 B

Thats It!

Advertisements

24 Responses to “How to merge 2 Partions in Your Windows XP PC.”

  1. CypherBit Says:

    This actually seems too good to be true.

    I assume C: can have a much of data on it or will that be lost in the process?
    Does this work only for dynamic disks?

    I have yet to find a free utility that allows me to merge partitions without data loss…hopefully this is it.

  2. Zak Says:

    Hi,

    You sure this works as diskpart cannot be used to expand a volume with the paging file on it or a system volume???

  3. Bharath Says:

    N Rao, thanks for sharing the knowledge…it was helpful.
    kind regards,
    bharath

  4. Eric Says:

    This does work as described above. As far as extending a volume with a page file on it. The partition was deleted. No page file.

  5. Rachel Says:

    I did this sucessfully on windows xp home edition

  6. Itai Says:

    wow. Worked like a charm!!

    Thanks a lot.

  7. Marco Says:

    hmm strange.. I’ve got XP Pro, installed it from scratch, now I´m stuck with too little space on the program disk…
    I followed all your steps, and got (transl. from Dutch version)Selected volume is necessary for the computer to function. This Volume can’t be deleted.

    Any suggestions?

  8. sebyelton Says:

    Awesome!!! It really worked. I finished my job in 1 minute! I have just merged my H drive into C (where I have the SO = Win XP SP3)! I have to mention that H was fully empty…

    Try it!

  9. sebyelton Says:

    I also tryed partition Manager 8 and Partition Table doctor 3.5 but nothing worked since Diskpart.exe ;)

  10. Derek Says:

    Stunning in it’s simplicity…..Worked a treat ……Thanks very much for this simple yet brilliant fix…..

  11. Anonymous Says:

    I wanted to merge C: (volume 1)and D: drive (volume 2), where D: drive is empty. I have deleted D: Drive by deleting the volume. However, i have accidentally deleted all partitions. This maybe the reason why I couldn’t extend C:Drive (after I select volume 1, then extend).

    Pls anyone know how to solve this issue and merging the 2 disks into one?

  12. calvinT Says:

    I wanted to merge C: (volume 1)and D: drive (volume 2), where D: drive is empty. I have deleted D: Drive by deleting the volume. However, i have accidentally deleted all partitions. This maybe the reason why I couldn’t extend C:Drive (after I select volume 1, then extend).

    Pls anyone know how to solve this issue and merging the 2 disks into one?

  13. RED house Says:

    I have followed all the step, but when is time to extend volume C, the program fails to extend the volume

  14. Anonymous Says:

    Yup doesn’t work

  15. Anonymous Says:

    http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/diskpart.mspx?mfr=true

    “You cannot extend the current system or boot partitions.”

    I think this either means you can’t do this from within windows, or you can’t do it to the C drive at all.

    • Exheon Says:

      in fact, I did it from within windows, make sure you follow all of the steps, some are just checking but is worth doing that way.

      For people having troubles with this guide or diskpart itslf, I’ll suggest Gparted, booting from a live cd and using it. I think it’s slower but you can get the job done without losing any data from both partitions, but, of course, you have to be careful

  16. MANOJ Says:

    I have followed all the step, but when is time to extend volume C, the program fails to extend the
    volume.

    what should I do ?


  17. The information is interesting, and very useful for those who read it.

  18. dracs Says:

    Worked smoothly!! for xp pro. Thanks.

  19. Krishna Says:

    Thanks Much. It Worked. I would have saved 7 hours if seen this page first.

  20. Anonymous Says:

    Thanks, this was very helpful
    you are NOT one of my most hated guys on my list ;)

    I make it work on Windows Developer Preview, which in case you don’t know it, is a preview of Windows 8, and works great

  21. Anonymous Says:

    thanks a lot ..it works as described


  22. Quck guide for Vbox Win XP with a dynamically expanding disk that is stuck at 10GB that you want to expand to say 20 or 40GB.

    0. From in the Windows XP vitual machine.
    1. ctrl + r > cmd
    2. diskmgmt.msc
    3. see partitions and free space.

    4. VBoxManage modifyhd –resize 40960
    5. e.g VBoxManage modifyhd /home/user/VirtualBox VMs/espee/expee.vdi –resize 40960

    6. Download gpated.iso
    7. mount in virtualbox manager on CD drive.

    8. reboot, F12 (if needed to boot from CD).
    9. resize C drive.

    10. Boot back to windows, it will run checks, then request reboot.
    11. ctrl + r > cmd
    12. diskmgmt.msc
    13. check space allocation.
    14. Note, you can use the DISKPART tool mentioned in the here/in the link but you cannot merge an active partition with a page file on it.

    Note, you might have to shutdown the virtual machine for the “4. VBoxManage modifyhd” and at other points.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: