Linux logo You have finally taken the great decision.  You are going to install this OS you have heard so many about, Linux! However you want to keep your windows installation untouched as well. In this guide I’ll explain to you how you can partition your hard disk drive in order to make the partitions that you will later need for installing Linux. Specifically if you follow this guide you’ll have to install GRUB in the MBR of your first hard disk.

** It is a good idea to have a back up of your data just in case you do something wrong and accidentally you erase a partition you shouldn’t. As you see the procedure is simple and if you carefully do the changes there will be no problem!

First of all how many partitions are you gonna need and of what type. Generally Linux needs 2 partitions. One for / and one for swap. But what are / and swap? Linux file system is function specific which means that files and folders are organized according to their functionality. For example, all executables are in one folder, all devices in another, all libraries in another and so on. / or ‘root’ is the base of this file system. All the other folders are under this one. Very generally speaking imagine / as C:. Swap is a partition that will be used as virtual memory. If there is no more available RAM a Linux computer will use an area of the hard disk, called swap, to temporarily store data. In other words it is a way of expanding your computers RAM. Of course swap is slower than RAM, but in many cases it does its job. In our example guide we are going to use one more partition. This will be used for /home. /home is the place that all our personal data and configurations are being kept. It is a good idea to make a separate partition for /home because if you have to format your Linux distribution you won’t lose your personal data. They are all kept saved in another partition. So if you reinstall Linux you will retain your initial configuration as well!

Now, how much space we will need for each partition. Of course it depends on how much data we will keep in each one of them. For / about 10GBs are pretty good. Here I have used just 5GBs. Next for /home I have used 2GBs. You can calculate how much personal data you will store and make your decision. Finally swap. Some years ago swap should be the double size of our computers RAM. Nowadays if you have more than 256MB of RAM a swap partition of 512MB is fine.

Finally what type of file system we will need? NTFS? No. FAT32? No again. Linux supports many different file systems, such as ext2, ext3, reiserfs, xfs and others. For our / and /home partitions we will use ext3. It’s very common. And for Swap we will use swap type!

But enough with the theory. Let’s move on to partitioning!

Here I have used ‘Partition Magic 8.05’. However there are many other programs, freeware or not, for this job. The idea is the same.

As you can see in picture 1 my computer has 3 hard disks. We will use one of the two partitions of the third hard disk drive, partition J: As you can see in this picture it is formatted as NTFS (NT File System) and it’s size is 35.126,5MB We won’t use all of it’s space. We choose 'Create a new partition' from the Pick a Task... menu.

The wizard starts and we press ‘Next’

We select the disk where the new partition will be created, in our case it’s the 3rd one.

Then we choose the location of the new partition. After the old partition is the recommended.

And then we choose from which partition we will take the needed space. As I’ve said before I’ll use partition J:.

Now we’ll have to choose the partition size, and File System. I have set its size to 5GB Anything over this is fine. It depends on the distro and on the packages you are going to install later. 10GB is fairly enough. The chosen File System is ext3.

As you can see in the following picture, the new partition is ready and waiting to be applied.

The partition we made here will be used for placing (mounting) the / folder during our Linux installation. Remember that!

Now, we press again 'Create a new partition' and we choose again the 3rd disk.

Again we place the new partition after *: This time it is mentioned as * because we haven’t yet created the previous partition.

After that we select J: partition for resizing and gaining the wanted space.

This will be the partition for /home (remember that also!). Here I have used only 2GBs for storing my personal stuff. If you think you need more space, just add it. Again we choose ext3 File System, and we press 'Next'.

We confirm that our choices are correct and we press 'Finish'.

As we can see, in disk 3 we have one more partition and more operations pending.

We press again 'Create a new partition'. Now we will create the partition used as SWAP.

Again we select disk 3.

The new partition is set to be created after *:

And the space will be taken from partition J.

512MB are enough for the SWAP partition. Its File System should be Linux Swap

Confirm your choices and press 'Finish'.

As you can see, now we have 3 new partitions in disk 3 and 10 operations pending. Ready? Press the 'Apply' button.

And apply changes.

The progress may take a while..

When you see the ‘All operations completed’ message just press 'OK'.

As you can see, disk 3 is now partitioned and waiting for Linux to be installed. (Info on that on a later guide!) Enjoy!

Comments (18)

Subscribe to this comment's feed
...
0
nice,very nice.
waldemar augusto medeiros , April 04, 2007
Next step...
0
Thanks Axel, I was never been able to do my own partition, now I can!!
by the way, what's the next step of installing the linux on the partitioned drive?
and if i have windows on my C drive, is it still possible to do this on C drive without deleting the windows? or should I do this on the other HDD..?

thanks..!!
Moritz , November 05, 2008
...
axel
If you have Windows on your C drive you will NOT install anything on it, or you will lose your data. Choose one of your partitions that is big enough and resize it like I do. As mentioned in the guide above you should have 4 partitions when you're done.

1: your windows partition -> C:
2: Linux ext3 partition -> Here your root partitioned will be mounted under Linux
3: Linux ext3 partition -> Here your home partitioned will be mounted under Linux
4: Linux swap partition -> Partition used for temporary storing data if RAM is full

In the following guide search for "Create custom layout" and read after that how each partition should be mounted during the installation process.

How to install Linux on Windows using qemu

The procedure is almost the same to Ubuntu. If you don't understand tell me to post some additional images on the Ubuntu Installation Guide.

Again, be careful not to write anything on your C: partition or the other partitions you keep your data.
axel , November 05, 2008
Partition problem
0
Hi,

I had an original windows vista installed on my laptop. some how the OS got corrupted and even the boot file went missing. I was planning to make it a dual boot with Linux mint elyssa. While installing I forgot to chose the manual option and therefore the Linux has been installed on the entire 160 GB HDD .... Is there any way that I can make more partitions and shrink the partition of the Linux? Also if that possible can I install a XP and make it dual boot?
It'll be great if you can help.

In Anticipation
With regards

AKS
Aks , December 28, 2008
...
axel
Hi Aks,

you can download gparted livecd and boot your computer from there. This way you can resize the partitions you want. In my How to resize a VirtualBox disk partition guide you can read how gparted livecd works.

If you want to install Windows XP remember that they want to be in the first partition.

If you don't mind losing your Linux installation you can use a Windows XP cd format your disk from it, install XP and then use either partition magic or gparted mentioned above to create the partitions you want.

In case you need more details please use our Linux forum. It's easier to reply there. smilies/smiley.gif

Regards,
axel
axel , December 28, 2008
...
0
Hi,
Currently my laptop have C & D drive (30gb&30gb) and using XP os. I am thinking to make it dual boot with Centos 5.3. How will the partition be and do I just insert Centos CD and start installation to do the dual boot?

Thanks
newbie- , August 12, 2009
...
axel
Hi, the simplest to do is just cut 10gb from drive D and create a new partition. Then boot from the Centos CD and tell it to install in the new partition. I haven't tried Centos before but since it is Red Hat's I believe it the default installation will be just fine for you.
axel , August 14, 2009
Installing Fedora11 on a Windows partition
0
Dear friend,
I am new to fedora and also much keen to use the fedora11 distro.I have thoroughly read your partioning and setup steps for installing fedora in it.
I have also partiioned one of Windows 31Gb partition into 30gb Linuxext3 and 1gb Linuxswap with PartitionMagic8.0.But on booting from fedora livedvd encountered the following problems:
1)It didn't take the Create Custom Layout partitioning scheme
and on selecting the corresponding drive displayed the following error message
THE PARTITIONING SCHEME YOU SELECTED CAUSED THE FOLLOWING CRITICAL ERRORS.
YOU HAVE NOT DEFINED A ROOT PARTITION(/),WHICH IS REQUIRED FOR INSTALLATION OF TO CONTINUE.YOU HAVE NOT CREATED A BOOT PARTITION.
MOREOVER THINGS ARE WORKING NICE WITH Replace Existing Linux Partitioning scheme. But on normal boot from hard drive the FEDORA OPTION IS NOT BEING DISPLAYED HENCE I AM DIRECTLY ENTERING INTO XP.
Please mail me your valuable guide as soon as possible and also kindly give the url where i can learn about merging two partition through PartitionMagic8.0.
Thank You
Soumitra , August 16, 2009
...
axel
Hi Soumitra,

I just got back from vacations. Do you still have problems with partitioning?
axel , August 31, 2009
...
0
Hi Axel,

i have a 250gb hard disk and right now only 2 partitions on my system....one being local disk(csmilies/smiley.gif with 100gb and localdisk(Esmilies/smiley.gif with nother 100gb.....how do i install fedora on the 50gb that is left out and what are /dev/sda1 /dev/sda2 /dev/sda3
Pramod , October 10, 2009
...
axel
Hi Pramod,

In Linux partitions are named differently from Windows. /dev/sda is your first SATA Hard Disk Drive. 1,2,3 are its partitions. Therefore,

/dev/sda1 -> local disk c:
/dev/sda2 -> local disk e:
/dev/sda3 -> your 50GB partition

Start the Fedora installation and tell the installer to use only /dev/sda3 partition to install Fedora. When you are asked where to install Grub choose /dev/sda e.g. the MBR of your HDD.

I hope I made it clear enough. smilies/smiley.gif
axel , October 10, 2009
...
0
Hi Ax,

I have a laptop with preinstalled Vista. The HDD is split in to disks, C and D, each one having around 110 GB. The windows files are stored in C and I store all my personal data in D. I was thinking to create the necessary partitions to install Linux and make it dual boot, taking space from the C drive. Would that be possible to just use some of the free space of the C drive where the Vista are and create new partiotions to install Linux? Even if it works, will Linux be able to see the data stored in the D drive, whose format is NTFS?

Thanks for the help.

Zisis
zisis , October 15, 2009
...
axel
Hi Zisi,

Of course you can resize your C partition. Although I think it would be better to resize the second partition and create two partitions for Linux (one for swap and one for the installation).

Reading and writing in NTFS partitions through Linux is nowadays possible so you won't have any problem with this.
axel , October 16, 2009
just wandering
0
just wandering if you could put a link to the a artical on how to put linux on the partition
nathan , November 26, 2009
...
axel
Hi nathan,

I have written two guides with screenshots on how to install Linux. In Fedora and Ubuntu during the installation, just select to install Linux pointing to the partitions you have just created.

Fedora 12 Installation and Post Installation Guide
Ubuntu 8.10 (Intrepid Ibex) Installation Guide
axel , November 26, 2009
FileSystem
0
Hi,

Info is very useful.But,I have a doubt regarding why should we use extended file system and also what is the difference b/w NTFS and extended file system .As well as b/w ext2 and ext3.
G SRI KRISHNA , October 20, 2011
...
axel
Hi G SRI KRISHNA,

NTFS is a filesystem developed by Microsoft and used on Windows. Linux can't be installed on NTFS although it can read/write on it.

If you want to use Linux you have to create an ext partition. Since this guide is a little old it doesn't include the newest ext4 partition. Anyway nowadays ext4 is the default partition format used by most distributions.
axel , October 21, 2011
Thank you
0
Finally the best installation manual smilies/grin.gif
Slim! , June 27, 2012

Write comment

smaller | bigger
security image
Write the displayed characters

busy

Linux

Login Form

Follow me on...

  • Facebook
  • Twitter
  • Google+: u/0/b/113039112812192417058/
  • Digg
  • Reddit: myguides
  • RSS Feed
  • e-mail

Member Login