Re: Parition Slices

Richard Gooch (rgooch@atnf.csiro.au)
Sun, 7 Mar 1999 12:02:20 +1100


Adam Sulmicki writes:
> Richard Gooch writes:
>
> ->> I did took there a brief look, and I see something like:
> ->>
> ->> | /dev/hda /dev/ide/hd/c0b0t0u0
> ->> | /dev/hdb /dev/ide/hd/c0b0t1u0
> ->>
> ->> But I still don't see how does it make sure that it does the "Right Thing"
> ->> and that the /dev/hdaX won't get renamed to some other id when there
> ->> appears a new parition/slice.
> ->
> ->The intent with devfs is to append "s#" for BSD slice numbers to solve
> ->this problem. The normal (primary&extended) partitions use "p#" (with
> ->the existing partition number scheme). So in the end, you could have
> ->"c#b#t#u#p#s#".
>
> You seem to be suggesting to use the same ID for primary and extended
> paritions.

Erm, yes and no.

> I'm kind of afraid that this approch could cause the "ID"s to jump if I
> slightly modify layout of the disk, am I wrong?

Well, yes, but not in the way you describe.

> Say I have :
>
> primary 1 p1
> primary 2 p2
> extended
> ext 1 p4
> ext 2 p5
> primary 4 p3

No, you have 4 main partitions, which may be either "primary" or
"extended". They are numbered 1 to 4. Changing a primary to an
extended does not change the partition numbers for the main
partitions.

The subpartitions within extended partitions are called logical
partitions, and they start counting from 5. There is the potential for
these to be renumbered, if you change a primary partition to an
extended partition (where there is another extended partition after
it). The logical partitions in the second extended partition will be
renumbered.

So, the only problem you should have is if you create *two* extended
partitions and populate them both. While this is a potential problem,
I don't think it really matters because there isn't much point to
having multiple extended partitions. A single extended partition can
hold plenty of logical partitions.

Regards,

Richard....

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/