Resize a Windows Partition with the Ubuntu Live CD
Some Microsoft Windows users want to install Ubuntu "for real", while also maintaining their MS Window's too. They want to dual boot, but they only have one hard drive with one partition that is fully consumed by Microsoft Window's "c-drive". They wish they could shrink their current partition to make room for Ubuntu's partitions. This article will show you step by step how to do exactly this.Download the Ubuntu 7.04 ISO:
Burn it to a CD. Here's a free program for burning an ISO in Windows:
You won't be able to shrink your c partition to a size less than the size of the files it contains. So, remove any unnecessary files you really don't want to remain. Also, just to be safe, make a backup of any important files.
After you've backup all your important files, boot from the Ubuntu CD then follow these instructions:
- Open the Synaptic Package Manager by navigating from your "System" menu: System | Administration | Synaptic Package Manager.
- Click the "Search" button and type "qtparted" into the search box, then click the search button below.
- You'll see an alphabetical listing of packages. Right click on the first "qtparted" package, and select "Mark for Installation".
- Now click the "Apply" button. "qtparted" will be downloaded and installed.
Change Root Password
- From Ubuntu's "System" menu, open the "Users and Groups" manager: System | Administration | Users and Groups
- Click on the "root" user, and then click the properties button.
- Highlight the contents of "User Password" text-box and then over-type it with the first password that comes to your mind.
- Highlight the contents of "Confirmation" text-box and then over-type it with the same password you chose in the previous step.
- Click the "OK" button.
- From Ubuntu's Applications menu, open a terminal: Applications | Accessories | Terminal
- At the command prompt, type "su" followed by the <enter> key (no quotes).
- Now type the new root password you created previously, and press the <enter> key.
- Last, type "qtparted" (no quotes) and press the <enter> key. This will launch qtparted's graphical user interface. Oh and don't close this terminal session; doing so will close qtparted's GUI.
Locate your c-drive in qtparted
- Maximize qtparted so we can see everything better. If you don't see qtparted, look down at your task bar, it may be minimized or behind another window.
- In the left pane, you should see a tree control listing all the physical hardrives install in your machine. Click on the first one; for me, its "/dev/hda".
- Now, in the right pane, you should see a list of partitions for the drive you selected. For me, the very first partition listed happens to be my c-drive, but its not label "c-drive"; ubuntu calls it "/dev/hda1".
- Write down that name Ubuntu is calling your c-drive ("/dev/hda1" in my case).
Unmount the Windows C drive
Qtparted won't allow us to resize this partition until we have unmounted it.
- Start a new Terminal (don't attempt to use the one that is currently on your task bar).
- Type "su" and then hit <enter>.
- Type in the root password we created, and the press <enter>.
- View the /proc/mounts file to see where Ubuntu is currently mounting our c-drive. Type "cat /proc/mounts" (no quotes) and press <enter>.
- Find the partition name your wrote down in the text outputed to the terminal. For me, I see "/dev/hda1" two lines above where my cursor is blinking. It indicates that /dev/hada1 is currently mounted at /media/disk.
- Now unmount your partition using the umount command (notice its not "unmount"). For me, I type: "umount /media/disk" then <enter> (no quotes).
Resize the Partition
Ok, we've covered all the preliminaries.
- Click back over to qtparted (resting on your task bar).
- In the right pane, right-click on the partition you want to resize and select "Resize" from the context menu.
- Enter the new size you want the partition to be. It must be larger than the space currently occupied with files. The partition I'm resizing is currently "114463.09" (so its around 114 gigs). I personally use Ubuntu exclusively, so I don't need much room for Windows, but I'm going to be generous and give it around 25 gigs ("25600").
- Click the "OK" button.
- From qtparted's "File" menu, select "Confirm". For me, after confirming, it took about 5 or 6 minutes to resize.
- When qtparted completes, the "OK" button will become enabled. Click it and exit qtparted. Your partition is resized!
Now, if you want to test that everything is ok, you can now restart Ubuntu, and take out the CD when it prompts you: System | Quit | Restart. For me, MS Windows realized that something was different, and it came up to a blue screen (not of death, thankfully) that did a "chkdisk". After this, it rebooted again (automatically) and loaded right up. I checked the size of the drive in "My Computer" and in "Computer Management" and all changes went through successfully.
Tell others about
About the Author
Comments? Questions? Email Here