Subject: Re: Config File / Kernel Building
To: None <>
From: None <>
List: current-users
Date: 04/23/1996 11:44:31
#   Can anyone give me a REAL good reason why Unix users have to put up with
#   this crap?  Why can't NetBSD do the following:

#   - Once booted off xxxa where xxx is some disk, if xxxb exists, make that
#     the initial swap space (with appropriate behavior if booting miniroot).

You're making an assumption that root is, in fact, xxxa.  If my kernel makes
such an assumption, I'm going to be rather upset.  In fact, I might want
my kernel on xxxh and my swap on xxxg.  Or something else.

#   - Once the user says "swapon xxyz", just do it!

How about not even enabling a swap partition until explicitly told to do
so?  As an option, of course...

#   I see no reason for the behavior of a user-initiated "swapon" to depend on
#   what was configured.  About the only argument I can see for the current
#   behavior is the off chance that someone has non-swap on xxxb.  Perhaps we
#   can have a "swap superblock" that contains some signature that the kernel
#   checks for before it will use a partition as swap?

Swaps don't have/need superblocks; why not check for the existence of a
filesystem superblock on the partition, which would undeniably mark it as

How about this?  From the initial boot sequence:

WARNING:  xxxb is type FFS			/* or whatever */
swap device? _					/* prompt */

And from swapon:

swapon: xxxb is type FFS; swap not enabled.

Again, this could be added as an option, probably as a sysconf() flag
of some sort.

By the way, relying on the disk label to handle the filesystem type seems
really bogus; it's the equivalent of what most systems used to do in
having a mount table in each of kernel space and user-land.  If I want
to make a filesystem on disk from a brand new partition, the system has
no business looking at the disk label and telling me "You can't do that
because it's not declared as a type X filesystem".  If it's present on
the disk label, it should be taken as a suggestion so that newfs xxnp
will do The Right Thing, but a "-fstype X" kind of option should override
that suggestion.

...or Did I Miss Something Here? [TM] :-)

BSD -> Solaris: It could be worse.
UNIX -> NT: It's worse.