Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 Dec 2002 12:13:55 -0500
From:      Jake Burkholder <jake@locore.ca>
To:        "Daniel C. Sobral" <dcs@newsguy.com>
Cc:        Ruslan Ermilov <ru@FreeBSD.ORG>, current@FreeBSD.ORG, re@FreeBSD.ORG, Warner Losh <imp@FreeBSD.ORG>, Doug Barton <dougb@FreeBSD.ORG>, Peter Wemm <peter@FreeBSD.ORG>
Subject:   Re: [REPORT] Upgrade from 4.0-RELEASE to 5.0-CURRENT
Message-ID:  <20021201121355.A26595@locore.ca>
In-Reply-To: <3DEA2774.DCE1CACD@newsguy.com>; from dcs@newsguy.com on Sun, Dec 01, 2002 at 01:15:00PM -0200
References:  <20021201150303.GA6369@sunbay.com> <3DEA2774.DCE1CACD@newsguy.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Apparently, On Sun, Dec 01, 2002 at 01:15:00PM -0200,
	Daniel C. Sobral said words to the effect of;

> There I go reply to all... <sigh>
> 
> IIRC, we never supported upgrade to 4.0 or 4.1 from anybut but the
> *latest* version in the 3.x series. I sure hope we adopt the same policy
> here.

Agree, I don't see any use in supporting upgrades without going through
4.x-STABLE first.

Jake

> 
> Ruslan Ermilov wrote:
> > 
> > [
> >  current@ Cc:'ed because it'll be useful to a number of upgraders.
> >  dougb@ Cc:'ed to be aware of possible mergemaster(8) problems.
> >  imp@ Cc:'ed to be aware of incorrect UPDATING instruction.
> >  peter@ Cc:'ed to LOL about foot-shooting with anti-foot-shooting.
> >  re@ Cc:'ed to consider approving the attached patches.
> > ]
> > 
> > Hi!
> > 
> > Following is the report from my attempt to upgrade 4.0-RELEASE
> > system to 5.0-CURRENT.  First, I'd like to say that I succedded
> > in it:
> > 
> > FreeBSD  4.0-RELEASE FreeBSD 4.0-RELEASE #0: Mon Mar 20 22:50:22 GMT 2000     root@monster.cdrom.com:/usr/src/sys/compile/GENERIC  i386
> > FreeBSD  5.0-CURRENT FreeBSD 5.0-CURRENT #0: Sun Dec  1 13:52:37 GMT 2002     ru@:/usr/obj/ru/mnt/usr/src/sys/GENERIC  i386
> > 
> > 4.0-RELEASE system was installed on a spare disk by newfs'ing the
> > `a' partition and extracting the `bin' distribution on top of it
> > from the 4.0-RELEASE 1st CD, thanks again to Charlie Brewster
> > <ecliptica.ww@virgin.net> for sending me one.
> > 
> > The /etc/make.conf's contents was a mere NOPROFILE=YES.
> > 
> > Buildworld was attempted under a non-root account.  The installed
> > make(1) did not pass the regression tests, and this required a patch
> > to src/Makefile (attach #1) to survive; the patch allows one to
> > build and use the new make(1) under non-root, without the need to
> > overwrite /usr/bin/make.  (This patch, with Warner's suggestion
> > incorporated, is currently considered by re@ for approval.)
> > 
> > Other than that, both buildworld and buildkernel of the GENERIC
> > kernel went just fine.
> > 
> > The next step was to install the new kernel and modules, as outlined
> > in UPDATING.
> > 
> > As a prerequisite step (following the instructions from UPDATING)
> > I've created the /boot/device.hints file, and attempted to
> > installkernel.  This failed with ``You must activate /boot/device.hints
> > in loader.conf.'' from kern.post.mk because 4.0 does not have
> > /boot/defaults/loader.conf.  (Rather than creating it by hands, I
> > took another approach, see below.)
> > 
> > As was documented in rev. 1.219 of UPDATING, after installing a
> > kernel (which I did not yet succeded in), it is highly recommended
> > to install new loader(8), and generally, upgrade /boot.
> > 
> > WARNING!  The relevant instruction from UPDATING,
> > 
> >         cd src/sys/boot ; make install
> > 
> > will NOT work as is on most of old systems -- if run as is, make(1)
> > will use stuff from /usr/share/mk which may be incompatible with
> > sys/boot/ makefiles.  Adding the -m `pwd`/../../share/mk did not
> > help either because now make(1) was attempting to run 4.0's install(1)
> > which does not understand the new -b option (INSTALLFLAGS=-b in
> > sys/boot/i386/loader/Makefile), in particular.  Another problem
> > with 4.0 install(1) is that it removes source files by default,
> > while new versions of install(1) (4.3-STABLE and onwards) copy it
> > by default, so if you attempted to run it as is, it will wipe out
> > some already built stuff from /usr/obj, making the next installworld
> > attempt to fail.
> > 
> > To overcome this, I needed to use the installworld environment [with
> > an up-to-date src/share/mk/ and install(1)] to install sys/boot/.
> > Fortunately, we have the SUBDIR_OVERRIDE knob in Makefile.inc1 that
> > was helpful here.
> > 
> > So, my next attempt was to run, from src/, the following command:
> > 
> >         make installworld SUBDIR_OVERRIDE=sys/boot
> > 
> > This would upgrade /boot, and (as part of the upgrade) install
> > /boot/defaults/loader.conf that is needed for installkernel to
> > proceed (see above).  Unfortunately, this has failed to pass the
> > `installcheck' anti-foot-shooting check from Makefile.inc1, which
> > installworld depends on:
> > 
> > 1.  smmsp user was missing from /etc/passwd and /etc/group
> > 2.  installed 4.0 kernel did not have the sigaction(2) syscall
> > 
> > I've attempted to overcome 1) as suggested by UPDATING, by running
> > the ``mergemaster -p'' (from src/usr.sbin/mergemaster/).  This did
> > not work well because mergemaster(8) attempted to use stat(1) which
> > is not present in 4.0.  OK, it was trivial (in my case) to update
> > /etc/master.passwd and /etc/group by hands and run ``pwd_mkdb -p
> > /etc/master.passwd'' afterwards.
> > 
> > I couldn't overcome 2) for obvious reason -- I was in the middle
> > of attempting to install a new kernel!  Isn't this itself a sort
> > of foot-shooting?  :-)
> > 
> > The solution was to make the `installcheck' a no-op by:
> > 
> >         make installworld SUBDIR_OVERRIDE=sys/boot \
> >             -DNO_SENDMAIL DISTDIR=
> > 
> > After this, ``make installkernel'' succeeded, but I noticed another
> > glitch.  installkernel, as coded in Makefile.inc1, uses user's PATH
> > and hence /usr/bin/install (4.0 version) that deletes source files
> > by default.  So, if you attempt to installkernel for the second
> > time, it will fail.  The tiny patch to fix this is in attach #2.
> > 
> > After rebooting with the new kernel in single user mode, ``make
> > installworld'' went fine and finally, I've merged the rest of etc/
> > and just proceeded into multi-user mode by pressing ^D.
> > 
> > Thanks for listening so far!  :-)
> > 
> > re@'s (or anyone else with re@'s permission), feel free to commit
> > these patches if you see any profit here, as I won't be able to
> > in the next 17 hours.
> > 
> > Cheers,
> > --
> > Ruslan Ermilov          Sysadmin and DBA,
> > ru@sunbay.com           Sunbay Software AG,
> > ru@FreeBSD.org          FreeBSD committer,
> > +380.652.512.251        Simferopol, Ukraine
> > 
> > http://www.FreeBSD.org  The Power To Serve
> > http://www.oracle.com   Enabling The Information Age
> > 
> >   ------------------------------------------------------------------------
> >          Name: p1
> >    p1    Type: Plain Text (text/plain)
> >      Encoding: quoted-printable
> > 
> >          Name: p2
> >    p2    Type: Plain Text (text/plain)
> >      Encoding: quoted-printable
> > 
> >    Part 1.2Type: application/pgp-signature
> 
> -- 
> Daniel C. Sobral			(8-DCS)
> dcs@newsguy.com
> dcs@freebsd.org
> capo@linux.bsdconspiracy.net
> 
> 	"Fundamentalist Debianites, core children of the Linuxen....
>         sounds like it could come from the Book of Mormon, or Tolkien on 
> 	a bad day..."
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-current" in the body of the message

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




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