Subject: Re: Two NetBSDs on one (i386) drive
To: David Laight <>
From: Rick Byers <>
List: tech-kern
Date: 12/20/2001 11:50:31
On Wed, 19 Dec 2001, David Laight wrote:

> > Exactly!  That is why I think having more than one NetBSD partition could
> > cause problems and confusion.  I still don't understand the need for being
> > able to boot from more than one NetBSD partition on the same disk (since
> > you could just use one boot partition, one bootloader and different
> > root/data partitions for the seperate systems).
> OK, so how do I tell the bootloader to pull in a different filesystem,
> and how does the kernel find its root filesystem.
> (Maybe I'll boot netbsd again and re-read the man page.)

From the bootloader prompt you can type in the location of the kernel you
want to boot, i.e. "boot wd0f:/netbsd".  I believe the kernel will (by
default) use the filesystem it was booted from as its root.

I admit having to type the path of a kernel isn't nearly as nice as just
selecting a partition from the bootselect code, but I think this indicates
an area for improvement in the bootloader.  I don't see any reason why we
couldn't have a fancier bootloader which could present the user with a
menu of choices, or allow them to type their own commands (like now).  As
I understand it, by the time we've loaded the NetBSD bootloader we've got
a lot more room to move around.

> Anyway I now have another mbr_bootsel code that will pass the start sector
> through to the next level.  It is also smaller again, and can get some of
> the error retry loops back (since it is none-destructive).
> (editing that code makes my brain explode - and I haven't trashed a boot
> block yet)

Cool.  I'm definantly not suggesting that being able to have two NetBSD
partitions is necessarily a bad thing.  I can see how it would look
attractive, especially for people familiar with highly i386 oriented OSes
(Windows, Linux etc.).  I'm just suggesting you explore the possibility of
having two copies of NetBSD installed inside of one i386 partition as it
should be a lot easier and less confusing.

To support multiple NetBSD partitions I think we'd have to go with Darren
Reed's suggestion of device names that include the partition (i.e.
wd0s1a).  That kind of seems like a good idea to me anyway...