Subject: Re: disk partitioning
To: Manuel BOUYER <bouyer@antioche.ibp.fr>
From: Bill Studenmund <skippy@macro.stanford.edu>
List: port-i386
Date: 12/05/1996 10:37:42
On Thu, 5 Dec 1996, Manuel BOUYER wrote:

> On Dec 5, Darren Reed wrote
> > Surely by now NetBSD can recognise more than one BSD partition on a disk...
> 
> But this is i386 specific. How do you deal with that on a sparc or a
> pmax (to cite only the archs I use/used) ?
> I this the good way to do this is to increase the number in partitions in a
> disklabel. Perhaps 16 isn't enougth, and we should start on a base of 32,
> or 64 ? (and perhaps this should be moved to tech-kern ?)

Data point: the mac68k port uses MacOS partitioning, and puts one NetBSD
filesystem per partition. We don't have a traditional unix disklabel.

Idea: I've been thinking about increasing the # of partitions too. As I
understand it, the amiga port already has gone to 16 partitions! So the
problem of kernel code supporting #partitions != 8 has been dealt with.

As I understand it, the one problem (which is large) is that the kernel's
idea of # partitions and /dev's idea MUST match, or else you loose BIG
TIME. So kernels from before the change won't work after, and ones from
after won't work with non-updated systems. A royal mess!

But I've got an idea. The kernel can figure out what it should do. Just
have the kernel go out and look on the root file system. /dev/sd1a (or
/dev/wd1a or /dev/whatever1a) will tell us the minor # set up. Thus one
kernel could boot with either type of system.

There are probelms with this scheme, but they aren't big. Mainly, what
happens if we don't find sd1a or wd1a? Well, either we're booting from
wd/sd0a, in which case we just say there's only one drive and as many
partitions as you want, or someone forgot to build devices and we're going
to die soon anyway (we should print out an error).

Oh, the max # of partitions is 22. You can have mre than that, but then a
disklabel won't fit into a 512 byte block (from somewhere in the disklabel
headers).

I'd like us to make this switch!

Take care,

Bill