[Novices] Hard Drive Partitioning
Mark
imagineer66 at comcast.net
Sun Feb 20 14:38:08 EST 2005
> Brock Inglehart wrote:
> On Sat, 2005-02-19 at 12:20 -0500, Bruce Smith wrote:
> > > What is the difference between a logical partition and a primary
> > > partition?
> > A hard drive has four primary partitions. You can make one or more
> > secondary partitions that contains more logical partitions.
> That allows
> > more than four total partitions.
>
> Then, when I first installed Suse 9.1, and it saw Windows and
> suggested
> that it make one for Windows, one for the swap file and one for Linux
> that the software just ignored the 4th one?
Not "ignored" so much as unused. When you HD comes it doesn't have any
partitions. You can divide it into UPTO 4 primary partitions. So a HD
can have 1, 2, 3 OR 4 "hard" partitions. I would dare to say that most
Windows HD's have 1 partition that is the size of the whole HD holding
everything. Most Linux systems probably have 2 or 3. System and swap
being the first two with a possible third for user accounts, etc.
In Linux, I don't think the partitions are so critical because Linux
doesn't use drive letters. I suspect the only reason swap still has its
own partition is to make sure swap space never gets mixed with normal
data in any way, shape or form. I'll bow to our resident gurus if they
have a better explanation.
> If so, where did it get used as default?
It didn't get used. Remember you can have upto 4 POSSIBLE partitions
not that the drive starts with any. Think of it as a cake. When the
cake is first presented, it is whole and uncut. The server then chooses
how many pieces and of what size they want to cut it. In a round cake,
usually there are either 6 or 8 wedges. More pieces than that just
makes the cake a mess. You could, however, serve half, quarter, or the
whole cake just as easily. When HD's first came out cutting the HD into
more than 4 pieces made it a mess. The "powers that be" never got
around to changing it, mainly because so few systems have more than 1 or
2 partitions.
> The total of my partitions = drive size.
This is almost always true. You could have unpartitioned, unused space.
This is usually done to "reserve" space for a different OS in the
future. Back to our cake analogy. You could cut half the cake into 3
pieces and save the other half for later.
>Or am I misunderstanding and that 4 "walls" equal 3 sections?
Ta' udder way 'round. :) 3 walls make 4 sections/partitions.
(Technically, the beginning and ending of the drive constitute the other
walls.)
> And where does secondary partitions fall in to this question?
Only one partition is Primary, everything else is secondary. This used
to be significant. The computer needed to know where to find the OS.
Before LILO and Grub, the computer booted whatever was on the Primary
partition. The different boot managers now allow the computer to be
redirected to any partition. (and if I take Bruce's inference correctly,
any DRIVE in the system.)
> Is their a hierarchy here? Primary / secondary / logical?
Formerly, once you got past the Primary, all of the secondary partitions
where "created equal". A logical partition is somewhat different. To
make logical partitions, take any of the secondary partitions and divide
it up into smaller pieces. This was done to increase the number of
partitions beyond four.
For example, I like to have my OS, programs and data all on separate
partitions. If I am only running Windows then the Windows HAS to be on
the primary; programs and data can then be on secondary. Currently, it
looks like this:
Part Type Contents
1 Primary Windows OS
2 Secondary Programs
3 Secondary Data
4 "unmade"
If I want to also boot Linux with only one drive then it might look like
this:
Part Type Contents
1 Primary Windows OS
2 Secondary Linux
3 Secondary Linux swap
4 Secondary
4a Logical programs
4b Logical data
Where the 4th partition is subdivided into two logical partitions? Make
sense?
Hope this helps,
Mark
More information about the Novices
mailing list