SunOS 4.x boot disk layout

der Mouse mouse at Rodents.Montreal.QC.CA
Sun Mar 27 17:03:42 CST 2005

>> Normally, yes.  I don't think root _had_ to be the a partition, or
>> swap b, but those certainly were the normal way.  c being the
>> whole-disk partition was, I think, not optional.
> I always wondered why that was (and I think NetBSD wants it the same
> way---I seem to recall setting up the partitions like that on the
> HP/Apollos I have (but that are currently in storage at the moment)).

NetBSD actually doesn't care what the partition table says in the c
partition; the drivers simply ignore the partition table when accessing
the c partition.  I suspect Sun did the same thing, but I wasn't quite
sure enough to come right out and say so.

> It's such an odd arrangement (to me).

The only odd thing, to me, is why it's the third of eight partitions
that's the whole-disk partition.

> -spc (Can't imagine *why* partition C needs to be the whole disk ... )

Compatability, that's about it.  You could define RAW_PART to 7 in
NetBSD and build yourself a system on which partition h is the whole
disk and partition c is a perfectly vanilla partition.  (You could set
RAW_PART to 0 and get partition a as the whole-disk partition, even,
but given the way the ROM bootcode defaults to using the a partition
from the disklabel, that could be, um, confusing.)

Having RAW_PART at all is a rather ugly kludge.  The sane way to do it
is to have separate devices for the whole disk and for the partitions,
somewhat akin to the wedges that have been talked about (in NetBSD - I
think one of the other BSDs already has something of the sort).  But
back when partitioning was first invented, I doubt anyone thought much
about that, and now we're stuck with legacies.

/~\ The ASCII				der Mouse
\ / Ribbon Campaign
 X  Against HTML	       mouse at
/ \ Email!	     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B

More information about the cctech mailing list