From owner-freebsd-questions@FreeBSD.ORG Mon Mar 26 19:32:43 2007 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 39E9816A403 for ; Mon, 26 Mar 2007 19:32:43 +0000 (UTC) (envelope-from kdk@daleco.biz) Received: from ezekiel.daleco.biz (southernuniform.com [66.76.92.18]) by mx1.freebsd.org (Postfix) with ESMTP id D4C3E13C465 for ; Mon, 26 Mar 2007 19:32:42 +0000 (UTC) (envelope-from kdk@daleco.biz) Received: from archangel.daleco.biz ([69.27.149.254]) by ezekiel.daleco.biz (8.13.8/8.13.1) with ESMTP id l2QJWcrk086333; Mon, 26 Mar 2007 14:32:40 -0500 (CDT) (envelope-from kdk@daleco.biz) Message-ID: <46081FD1.8010604@daleco.biz> Date: Mon, 26 Mar 2007 14:32:33 -0500 From: Kevin Kinsey User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.8.1.2pre) Gecko/20070221 SeaMonkey/1.1 MIME-Version: 1.0 To: Olivier Regnier References: <4607E8C0.9050608@steelbox.org> In-Reply-To: <4607E8C0.9050608@steelbox.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: Making Customized Bootable FreeBSD 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: Mon, 26 Mar 2007 19:32:43 -0000 Olivier Regnier wrote: > Hello, > > After 3 hours, i made my bootable FreeBSD CD/Floppies. Actually, i > finished my install.cfg but i have a problem because i don't understand > the final step : > I'm not sure I do either, but I'm willing to attempt to help. Bearing in mind IANAE, I *think* this is what you're seeing: > # mkdir /img > # cd $CHROOTDIR/R/cdrom/disk1/floppies Should be self-explanatory; $CHROOTDIR should be set in the environment if you are doing "make release".... > /* Get mfsroot.gz from mfsroot.flp */ > # vnconfig /dev/vn0c mfsroot.flp > # mount /dev/vn0c /img > # cp /img/mfsroot.gz . > # umount /img > # vnconfig -u /dev/vn0c Create a "memory disk" from the floppy image "mfsroot.flp", mount it, copy the "mfsroot.gz" to the current working dir, unmount it and destroy the "memory disk". > /* Unzip mfsroot.gz to get mfsroot */ > # gunzip mfsroot.gz Obvious, I hope. > /* Put your config file in mfsroot */ > # vnconfig /dev/vn0c mfsroot > # mount /dev/vn0c /img > # cp install.cfg /img/. > # umount /img > # vnconfig -u /dev/vn0c > /* (If you 'gzip mfsroot' here, you can use that for bootable > mfsroot.flp for floppies) */ > Mount the unzipped "mfsroot" file in a memory disk, cp your install.cfg to this memory disk, unmount it and destroy the memory disk. (Note of concern ... I don't see this getting moved back to anywhere were it will do some good before moving to the next step. Where did you get these instructions?) > /* Put mfsroot in kernel so that it will read it when boot time */ > # vnconfig /dev/vn0c boot.flp > # mount /dev/vn0c /img > # cp /img/kernel.gz . > # gunzip kernel.gz > # write_mfs_in_kernel -f kernel mfsroot > /* write_mfs_in_kernel can be found at /usr/src/release. Compile it if > you haven't. */ > > # gzip kernel > # cp kernel.gz /img/. > # umount /img > # vnconfig -u /dev/vn0c > Mount the "boot.flp" image in a memory disk, grab the kernel, unzip it, add the altered "mfsroot" to the kernel using the write_mfs_in_kernel program/script, zip up the new kernel, copy it to the image and unmount said image. I'm concerned though about this documentation; for one thing vnconfig is deprecated (except for 4.X releases, which are, uh, deprecated), and "write_mfs_in_kernel" was "nuked" from CVS **8 years ago** by the venerable jkh himself, so I have to wonder, "Where did this 'how-to' come from?" You may need someone more familiar with the modern RELENG system to help with this.... Kevin Kinsey -- Fortune favors the lucky.