From owner-svn-doc-all@FreeBSD.ORG Thu May 1 17:21:50 2014 Return-Path: Delivered-To: svn-doc-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 21D5CDBF; Thu, 1 May 2014 17:21:50 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0DD3115E0; Thu, 1 May 2014 17:21:50 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s41HLnED057799; Thu, 1 May 2014 17:21:49 GMT (envelope-from dru@svn.freebsd.org) Received: (from dru@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s41HLnl8057798; Thu, 1 May 2014 17:21:49 GMT (envelope-from dru@svn.freebsd.org) Message-Id: <201405011721.s41HLnl8057798@svn.freebsd.org> From: Dru Lavigne Date: Thu, 1 May 2014 17:21:49 +0000 (UTC) To: doc-committers@freebsd.org, svn-doc-all@freebsd.org, svn-doc-head@freebsd.org Subject: svn commit: r44732 - head/en_US.ISO8859-1/books/handbook/cutting-edge X-SVN-Group: doc-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-doc-all@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: "SVN commit messages for the entire doc trees \(except for " user" , " projects" , and " translations" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 01 May 2014 17:21:50 -0000 Author: dru Date: Thu May 1 17:21:49 2014 New Revision: 44732 URL: http://svnweb.freebsd.org/changeset/doc/44732 Log: Editorial review of Tracking for Multiple Machines. Sponsored by: iXsystems Modified: head/en_US.ISO8859-1/books/handbook/cutting-edge/chapter.xml Modified: head/en_US.ISO8859-1/books/handbook/cutting-edge/chapter.xml ============================================================================== --- head/en_US.ISO8859-1/books/handbook/cutting-edge/chapter.xml Thu May 1 15:44:23 2014 (r44731) +++ head/en_US.ISO8859-1/books/handbook/cutting-edge/chapter.xml Thu May 1 17:21:49 2014 (r44732) @@ -2408,24 +2408,25 @@ Building everything.. When multiple machines need to track the same source tree, - it is a waste of disk space, network bandwidth, and CPU cycles + it is a waste of disk space, network bandwidth, and CPU cycles to have each system download the sources and rebuild everything. The solution is to have one machine do most of the work, while - the rest of the machines mount that work via NFS. This section - outlines a method of doing so. - - - Preliminaries + the rest of the machines mount that work via NFS. This section + outlines a method of doing so. For more information about using + NFS, refer to . First, identify a set of machines which will run the same - set of binaries, known as a build set. + set of binaries, known as a build set. Each machine can have a custom kernel, but will run the same userland binaries. From that set, choose a machine to be the - build machine that the world and kernel + build machine that the world and kernel are built on. Ideally, this is a fast machine that has - sufficient spare CPU to run make buildworld - and make buildkernel. Select a machine to - be the test machine, which will test + sufficient spare CPU to run make buildworld + and make buildkernel. + + Select a machine to + be the test machine, which will test software updates before they are put into production. This must be a machine that can afford to be down for an extended period of time. It can be the build @@ -2433,14 +2434,12 @@ Building everything.. All the machines in this build set need to mount /usr/obj and - /usr/src from the same machine, and at - the same point. Ideally, those directories are on two - different drives on the build machine, but they can be NFS - mounted on that machine as well. For multiple build sets, + /usr/src from the build machine via + NFS. For multiple build sets, /usr/src should be on one build machine, - and NFS mounted on the rest. + and NFS mounted on the rest. - Finally, ensure that /etc/make.conf + Ensure that /etc/make.conf and /etc/src.conf on all the machines in the build set agree with the build machine. That means that the build machine must build all the parts of the base system @@ -2448,51 +2447,40 @@ Building everything.. each build machine should have its kernel name set with KERNCONF in /etc/make.conf, and the build machine - should list them all in KERNCONF, listing + should list them all in its KERNCONF, listing its own kernel first. The build machine must have the kernel - configuration files for each machine in /usr/src/sys/arch/conf - if it is going to build their kernels. - - - - The Base System + configuration files for each machine in its /usr/src/sys/arch/conf. On the build machine, build the kernel and world as - described in , but do not - install anything. After the build has finished, go to the - test machine, and install the built kernel. If this machine - mounts /usr/src and - /usr/obj via NFS, enable the network and - mount these directories after rebooting to single user mode. - The easiest way to do this is to boot to multi-user, then run - shutdown now to go to single user mode. - Once there, install the new kernel and world and run + described in , but do not + install anything on the build machine. Instead, install the built kernel + on the test machine. On the test machine, mount + /usr/src and + /usr/obj via NFS. Then, run + shutdown now to go to single-user mode in order to + install the new kernel and world and run mergemaster as usual. When done, reboot to - return to normal multi-user operations for this - machine. + return to normal multi-user operations. After verifying that everything on the test machine is working properly, use the same procedure to install the new software on each of the other machines in the build set. - - - - Ports - The same ideas can be used for the ports tree. The first - critical step is to mount /usr/ports from - the same machine to all the machines in the build set. Then, - configure /etc/make.conf properly to - share distfiles. Set DISTDIR to a common + The same methodology can be used for the ports tree. The first + step is to share /usr/ports via + NFS to all the machines in the build set. To + configure /etc/make.conf to + share distfiles, set DISTDIR to a common shared directory that is writable by whichever user root is mapped to by - the NFS mounts. Each machine should set - WRKDIRPREFIX to a local build directory. - Finally, if the system is to build and distribute packages, - set PACKAGES to a directory similar to + the NFS mount. Each machine should set + WRKDIRPREFIX to a local build directory, if + ports are to be built locally. + Alternately, if the build system is to build and distribute + packages to the machines in the build set, + set PACKAGES on the build system to a directory similar to DISTDIR. -