Tuesday, April 9, 2013

Linux Partitioning Scheme

                
                        There are many reasons for partitioning a large hard disk into several smaller partitions.  For a home user  a single Linux partition (plus swap)  can be a reasonable choice.But for a server installation  multiple partitions provide additional safety and performance benefits,so if you're planning to install a web server of a database server i would recommend six partitions.



let me explain the need for these partition :- 

 /
This is called the root partition; the most important partition, where all the system files are stored.if this partition runs out the system hangs,5 to 10 GB is sufficient in most cases.

 /boot
The partition mounted on /boot/ contains the operating system kernel along with files used during the bootstrap process. For most users, a 250 MB boot partition is sufficient. 

/home
 To store user data separately from system data,you should  create a dedicated partition to holds all of the users' configuration files, all their saved documents and their desktop folder.

/var
The /var directory holds content for a number of applications, including the Apache web server. It also is
used to store downloaded update packages on a temporary basis. Ensure that the partition containing the /var directory has enough space to download pending updates and hold your other content. 

/tmp
Some programs write temporary data files here. Usually, they are quite small. However, if you run computationally intensive jobs, like science or engineering applications, hundreds of megabytes could be required for brief periods of time. In this case, keep /tmp in a different partition than /.

swap
Our need one partition that will be used as Linux swap space. This is space on your hard drive that can be used as virtual memory. Virtual memory allows your computer to run large programs and perform complex tasks even if it does not have enough physical RAM to do the job. (It is a lot slower, but it works.)

 A good rule of thumb is that your swap space should be two or three times as much as the available physical memory (RAM).Currently, the maximum size of a swap partition is architecture-dependent. For i386, m68k, ARM and PowerPC, it is "officially" 2Gb

    Systems with 4GB of ram or less require a minimum of 2GB of swap space
    Systems with 4GB to 16GB of ram require a minimum of 4GB of swap space
    Systems with 16GB to 64GB of ram require a minimum of 8GB of swap space
    Systems with 64GB to 256GB of ram require a minimum of 16GB of swap space




No comments:

Post a Comment