Subject: Re: MAXPARTITIONS (kern/18256)
From: David Laight <email@example.com>
Date: 06/16/2003 21:40:34
On Mon, Jun 16, 2003 at 10:03:18PM +0200, Emmanuel Dreyfus wrote:
> > What you need to do is separate out the size of disklabel that the
> > system can support from the size that can be saved on any given disk.
> > Currently these two numbers are tied hard together.
> I understand why the disklabel maximum size can differ accross disks,
> but I don't understand how it can differ accross archs.
Because some architectures put the disklabel after other items that
must exist on a boot volume in order to make it bootable.
> And for the maximum size supported for a disk: do we have a minimum for
> any disk?
Depends what you mean.....
The disklabel is constrained to fit within a single disk sector (512 bytes),
which restricts you to (IIRC) 22 partitions (MAXMAXPARTITIONS).
However on any given architecture it is limited to MAXPARTITIONS for that
architecture. It is possible that disks with labels that have d_npartitons
larger than MAXPARTITIONS will fail to mount - but I wouldn't guarantee
that is always the case.
If you relabel a disk on a system with a larger MAXPARTITIONS (than the
one one which it was originally labelled) then it is likely that parts
of the disk that shouldn't be written to get corrupted.
It is all a bag of worms, best not opened too far.
David Laight: firstname.lastname@example.org