Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Oct 2001 22:53:29 +0100
From:      Mark Drayton <mark.drayton@izr.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Upgrading to 4.4
Message-ID:  <20011015225329.C36840@drex.staff.izr.com>
In-Reply-To: <20011015173327.E4944@acadia.ne.mediaone.net>; from leblanc%2Bfreebsd@acadia.ne.mediaone.net on Mon, Oct 15, 2001 at 05:33:27PM -0400
References:  <Pine.OSF.3.95.1011015143523.11638F-100000@isua5.iastate.edu> <20011015154852.D4944@acadia.ne.mediaone.net> <20011015222132.B36840@drex.staff.izr.com> <20011015173327.E4944@acadia.ne.mediaone.net>

next in thread | previous in thread | raw e-mail | index | archive | help
Louis LeBlanc (leblanc+freebsd@acadia.ne.mediaone.net) wrote:
> On 10/15/01 10:21 PM, Mark Drayton sat at the `puter and typed:
> > Louis LeBlanc (leblanc+freebsd@acadia.ne.mediaone.net) wrote:
> > > On 10/15/01 02:37 PM, legg@iastate.edu sat at the `puter and
> > > typed:
> > > > [upgrading using cvsup]
> > > 
> > > [installing world before kernel]
> > 
> > Sorry to be finicky, but this is potentially a very dangerous way of
> > upgrading. IMHO the safest way is follows:
> > 
> > make buildworld
> > make buildkernel
> > make installkernel
> > (reboot)
> > make installworld
> > mergemaster
> > (reboot)
> 
> Actually, you really should installworld before building the kernel.
> I have never had trouble with this, and this follows the suggestions I
> have seen on this list in the last 2 or 3 months.  That is how I
> upgraded from 4.3 to 4.4 with not a single hitch, hangup, or
> hesitation.

Well, okay. Each to their own etc.

> > You should build a new kernel then reboot to ensure the new kernel
> > works. It's easy to recover from a broken kernel but not from a
> > system that won't work because the world is too new for the kernel
> > (which could happen if you install world before kernel).
> 
> That is what my suggestion does.  If you use the command: make
> buildworld && make installworld
> 
> The second part will only happen if the first succeeds.  You can
> continue that to: make buildworld && make installworld && reboot with
> the same effect.  If the build fails, the install won't happen.  If
> the install fails, there will be no reboot.

No, 'make installworld' will run if the build process returns 0. Just
becuase the build process returns 0 doesn't mean you will have a world
that will run without problems. If any of your system binaries (mount
etc) are broken becuase of a goofed make.conf or any other reason you're
going to be left with a sorry loking system.

If you build a broken kernel you only need to do 'boot /kernel.old'
(warning: may be paraphrased) at the boot prompt and you've got your old
kernel back.

> You ever sit and watch the screen while buildworld went on?  Talk
> about a cure for insomnia.

Yes, too many times...

> > When you know the new kernel is okay you can get on with installing
> > the new world and mergemastering.
> 
> And how would you tell if your kernel is ok other than a successful
> build and a reboot?  Like I said, the '&&' says if that one succeeded,
> to this.

Again, a zero exit code doesn't guarantee a working
kernel/system/binary. The point is if you can fall back on an old kernel
very easily. It's (damn near) impossible to fall back on an old world if
the new one is broken.

> Mergemaster may be required to boot the new kernel if there are some
> new config or default files.  Better to do that before rebooting the
> kernel.

Unlikely. The kernel has finished 'booting' before the filesystems are
even mounted.

I don't care which way you build world; IMHO mine (and the handbooks[1])
method takes as few risks as possible.

[1] http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/makeworld.html

Cheers,

-- 

Mark Drayton

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?20011015225329.C36840>