From owner-freebsd-questions@FreeBSD.ORG Tue Jan 31 18:40:56 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2C83116A420 for ; Tue, 31 Jan 2006 18:40:56 +0000 (GMT) (envelope-from kdk@daleco.biz) Received: from ezekiel.daleco.biz (southernuniform.com [66.76.92.18]) by mx1.FreeBSD.org (Postfix) with ESMTP id 10D7B43D46 for ; Tue, 31 Jan 2006 18:40:52 +0000 (GMT) (envelope-from kdk@daleco.biz) Received: from [192.168.2.2] ([69.27.149.254]) by ezekiel.daleco.biz (8.13.1/8.13.1) with ESMTP id k0VIdj8I064652; Tue, 31 Jan 2006 12:40:06 -0600 (CST) (envelope-from kdk@daleco.biz) Message-ID: <43DFAEE7.7020609@daleco.biz> Date: Tue, 31 Jan 2006 12:39:35 -0600 From: Kevin Kinsey User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.12) Gecko/20060127 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Xn Nooby References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: Standard way of updating 6.x ? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 31 Jan 2006 18:40:56 -0000 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 involved, 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 bad. 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 understanding 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": http://www.onlamp.com/pub/a/bsd/2003/08/28/FreeBSD_Basics.html HTH, Kevin Kinsey -- Everyone is a genius. It's just that some people are too stupid to realize it.