Standard way of updating 6.x ?

Kevin Kinsey kdk at
Tue Jan 31 10:40:56 PST 2006

Xn Nooby wrote:

>Is there a suggested method for updating a newly installed FreeBSD
>6.0system?  I have found several websites with similar but differing
>methods, often somehow specific to the author's configuration.  What I usually do
>first is install from a CD and get a bare-bones system bootable.  What I
>would like to do after that is update the kernel, system programs, user
>programs, and packages.  I usually end up using cvsup, portsnap, and
>portupgrade with varying levels of success.
>What I would really like is a fool-proof method that works everytime, if
>there is such a thing.  For example, rebuilding things at the lowest layer
>first, and working my way up.  I was following a websites tutorial
>yesterday, and was confronted with a "stale imagemagic dependency", where I
>chose to "force" an override.  I didn't know if I was doing some wrong or
>not, and it seemed to work, but I would rather not have to force anything,
>if possible.
>Previously I had posted the steps I was using, and several people made
>annotations which I was able to integrate, but I was mostly curious if there
>wasn't some standard way. I am trying to use portsnap, since it seems much
>faster than cvsup, but the handbook doesn't seem to have portsnap integrated
>in to the rebuild steps yet (it is in the appendix I think).
>There seems to be updates steps for 4.x and 5.x, but not yet 6.x, or maybe I
>just have found them yet.

The standard way for upgrading the base system is described in
the handbook, and uses cvsup along with the 'buildworld', 'buildkernel'
'installkernel' and 'installworld' targets to make(1).  A reboot is 
and any files under /etc/ that have changed must be updated with
mergemaster(8), which, although quite "automated", is in no way
"automagic" IMHO.  But, then, I'm probably not well-read/experienced
enough with it.  I would suggest that it is "fool proof", inasmuch as nobody
slips a finger during a CVS commit --- all bets are off when the source is

This method applies equally well to 4.X, 5.X and 6.X and higher systems.
I have this scripted for use on most of my servers, although I've split
the steps in two as I prefer to control when a host is rebooted.  It
can be done "fully automatic" in my experience, if you don't care when
the machine gets rebooted.

Incidentally, "kernel" and "system programs", as you mention, would
probably qualify as "base system" in FreeBSD lingo.  "User programs"
and "packages" are equivalent to "ports" or "packages", or "ports/packages",
or "3rd party software" in FBSD-speak.  It's a minor point, but 
this can go a long way toward understanding the documentation.

>There seems to be a lot of ways to update your system right now.

There are several ways to update "ports", that is, 3rd-party software
that is not part of the "base" system, but there is really one way that
is "approved" by the docs for the FreeBSD base [not counting "old style"
usage of "make" --- the fact is, "Unix" is about "tools, not policy", and
that's the real reason why there are a lot of ways to "foo();" ]...

I have used both "portupgrade" and "portmanager" for upgrading
ports/packages; both these programs do an awful lot of work for you, but
occasionally situations may develop within the ports tree that cause
either to have slight difficulties.  Both of them take quite a little while
on a system with lots of installed ports/packages, and I must admit
that more than once I have fixed an issue with ports/packages in a
less-than-perfect way (much as is common in "MS land").

Dru Lavigne wrote an excellent article on using "portupgrade":


Kevin Kinsey

Everyone is a genius.  It's just that some people are too stupid to
realize it.

More information about the freebsd-questions mailing list