Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Feb 2002 18:35:50 -0600
From:      "Mike Meyer" <mwm-dated-1014597350.d952f8@mired.org>
To:        "Crist J. Clark" <cjc@FreeBSD.ORG>
Cc:        rene@xs4all.nl, questions@FreeBSD.ORG
Subject:   Re: building multiple ( 2+ or more) kernels for easy switching?
Message-ID:  <15474.61286.290485.620755@guru.mired.org>
In-Reply-To: <20020219161104.G48401@blossom.cjclark.org>
References:  <48552002@toto.iv> <15474.58551.91350.65768@guru.mired.org> <20020219161104.G48401@blossom.cjclark.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Crist J. Clark <cjc@FreeBSD.ORG> types:
> On Tue, Feb 19, 2002 at 05:50:15PM -0600, Mike Meyer wrote:
> > rene@xs4all.nl types:
> > > Hi. I'm running 4.5-STABLE, and would like to know if it's possible to have 2 or 
> > > more kernel configuration files built (using /usr/src% make buildkernel
> > > KERNCONF=file) after one-another, and then installing whichever I need at a
> > > certain time using /usr/src% make installkernel KERCONF=file..
> > 
> > Yup, it's real easy. Just list all the config files on the KERNCONF
> > line like so:
> > 
> > KERNCONF=GURU GENERIC
> > 
> > You can list more than two, and you don't have to build GENERIC if you
> > don't want to. The first one listed - in this case GURU - will be the
> > one installed by "installkernel".
> That's the problem with this method. You have to do mess with the
> installkernel to keep them from clobbering each other.

It's not really much of a problem, because the only one that gets
clobbered is the one that's going to boot by default. I.e., you do

	make kernel

and it builds them all and installs your default kernel. You want to
install another kernel to boot for a while, you do

	make installkernel KERNCONF=ALTERNATE

and it will install the alternate one, and put the old one in
kernel.conf.

> I like to just leave,
> 
>   KERNCONF?=	CUSTOM
> 
> In my make.conf(5), and then do,
> 
>   # make kernel
>   # make kernel KERNCONF=GENERIC INSTKERNNAME=kernel.GENERIC -DNO_MODULES
> 
> This installs the CUSTOM kernel in /kernel (as well as the modules)
> and then builds GENERIC and installs it in /kernel.GENERIC (and is
> also nice enough to save the old one in /kernel.GENERIC.old).

I think we've got different goals here. I want them built, and
available to install should I need it. I don't want it available to
boot all the time. Actually, I also install GENERIC on my test machine
over the net, but that's another issue. I'm not sure which of the two
cases is true for rene.

Just out of curiosity, have you tried setting "KERNCONF?= CUSTOM GENERIC"
along with "MODULES_WITH_WORLD=yes", and then done:

# make kernel
# make installkernel KERNCONF=GENERIC INSTKERNNAME=kernel.GENERIC

to see if it would work?

	Thanx,
	<mike
--
Mike Meyer <mwm@mired.org>			http://www.mired.org/home/mwm/
Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?15474.61286.290485.620755>