[3512] in Release_7.7_team

home help back first fref pref prev next nref lref last post

Re: CORRECTION: Odd error from Partition Magic

daemon@ATHENA.MIT.EDU (Greg Hudson)
Thu Sep 19 01:26:03 2002

From: Greg Hudson <ghudson@MIT.EDU>
To: William Cattey <wdc@mit.edu>
Cc: dalmeida@mit.edu, release-team@mit.edu, jmhunt@mit.edu
In-Reply-To: <69D4A14D-CB8D-11D6-B548-000393995C5C@mit.edu>
Content-Type: text/plain
Content-Transfer-Encoding: 7bit
Date: 19 Sep 2002 01:26:00 -0400
Message-Id: <1032413160.8324.15.camel@error-messages.mit.edu>
Mime-Version: 1.0

On Thu, 2002-09-19 at 01:05, William Cattey wrote:
> Something ghudson said in person, was that the Linux kernel would only 
> handle 4 partitions, even in an extended partition, and so the way to 
> create many partitions was to have multiple extended partitions.

Well, as far as Linux is concerned, anyway.  Anyone who wants to verify
this claim need only look as far as (on a Linux box)
/usr/src/linux-2.4.18-10/fs/partitions/msdos.c, line 153, in the
extended_partition() function.

> It may be that the rules governing partition tables changed since the 
> 1998 edition of my favorite PC reference, _Upgrading_and_Repairing_PC's_ 
> by Scott Mueller, but here's what he says about partitioning:

"The rules" are kind of vague; there's no standards body to consult
here.  The passage you quote describes the rules as far as DOS is
concerned, which is different from the rules as far as Linux is
concerned, and potentially also different from Solaris/x86 or the
Windows NT line or SCO or *BSD or whatever else you might run on a PC.

All of these systems are somewhat compatible with each other, in that
they understand and use the same format of partition table records.  But
they may disagree on details.

The book's text is also confusing:
> > You can create only one extended DOS partition on a single drive,
> > meaning that there will never be more than two entries in the master
> > partition table devoted to FAT drives.
[...]
> > You can create up to 23 volumes out of a single extended DOS partition
> > (assuming you have already created a primary DOS partition, which
> > brings the total to 24).
But:
> > The master partition table's entry for the extended DOS partition
> > contains a reference to the first volume's extended partition
> > table.  This table in turn contains a reference detailing the
> > location of the second volume's table.  This chain continues,
> > linking all the volumes in the extended DOS partition to the 
> > master partition table.

The first two excerpt suggest a four-entry primary table, of which only
two entries are ever used, where the second entry points to a 23-entry
extended table.  But the third excerpt suggests a chain along the lines
of what sfdisk creates, which DOS will follow for at most 23 links.  (23
is, of course, the number of drive letters remaining after you allocate
A: and B: to floppy drives and C: to the primary hard drive.)

> But it sounds like the DOS
> Has been mis-understood by the Linux folk as:

I don't think you can really conclude that from the information you
have.  The only thing I can conclude is that your book contains some
vague and poorly written text.

> 	Four partitions, any bootable, any can be Extended.
> 	An Extended partition can contain up to 4 partitions, any bootable, 
> any can be Extended.

The concept of "bootable" in the partition table really only applies to
the default master boot record, which simply boots off the first
partition in the primary table which has the "active" bit sets.  More
sophisticated boot loaders like lilo and grub pay no attention to the
active bit.


home help back first fref pref prev next nref lref last post