From owner-freebsd-hackers@FreeBSD.ORG Wed Nov 11 00:14:07 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 834481065670 for ; Wed, 11 Nov 2009 00:14:07 +0000 (UTC) (envelope-from psteele@maxiscale.com) Received: from server505.appriver.com (server505c.appriver.com [98.129.35.7]) by mx1.freebsd.org (Postfix) with ESMTP id 4C0C28FC1E for ; Wed, 11 Nov 2009 00:14:07 +0000 (UTC) X-Policy: GLOBAL - maxiscale.com X-Primary: psteele@maxiscale.com X-Note: This Email was scanned by AppRiver SecureTide X-ALLOW: psteele@maxiscale.com ALLOWED X-Virus-Scan: V- X-Note: Spam Tests Failed: X-Country-Path: UNITED STATES->UNITED STATES->UNITED STATES X-Note-Sending-IP: 98.129.23.14 X-Note-Reverse-DNS: ht01.exg5.exghost.com X-Note-WHTLIST: psteele@maxiscale.com X-Note: User Rule Hits: X-Note: Global Rule Hits: 112 113 114 115 119 120 131 217 X-Note: Mail Class: ALLOWEDSENDER X-Note: Headers Injected Received: from [98.129.23.14] (HELO ht01.exg5.exghost.com) by server505.appriver.com (CommuniGate Pro SMTP 5.2.14) with ESMTPS id 16246017 for freebsd-hackers@freebsd.org; Tue, 10 Nov 2009 17:14:10 -0600 Received: from mbx03.exg5.exghost.com ([169.254.1.164]) by ht01.exg5.exghost.com ([98.129.23.14]) with mapi; Tue, 10 Nov 2009 17:14:05 -0600 From: Peter Steele To: "freebsd-hackers@freebsd.org" Date: Tue, 10 Nov 2009 17:14:02 -0600 Thread-Topic: Converting a bootable USB stick in to bootable CD-ROM Thread-Index: AcpiW321VLM7ZSDpSgCcl8Q5E1Vn6A== Message-ID: <7B9397B189EB6E46A5EE7B4C8A4BB7CB3394F75B@MBX03.exg5.exghost.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Converting a bootable USB stick in to bootable CD-ROM X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Nov 2009 00:14:07 -0000 I posted this on the -questions list but didn't get any replies. I have a F= reeBSD image that I install on USB sticks to build new systems. When the st= ick boots it automatically clones itself on the system's hard drive, creati= ng partitions and other configuration parameters that are programmed into t= he stick's cloning logic. I want to create a similar mechanism using a boot= able CD-ROM. The biggest difference in the process of course is that the CD= -ROM itself is read-only so clearly there needs to be an mfsroot involved i= n the process. I looked at how the FreeBSD Live CD is setup and the loader.= conf file has these lines: mfsroot_load=3D"YES" mfsroot_type=3D"mfs_root" mfsroot_name=3D"/boot/mfsroot" along with the file /boot/mfsroot.gz and no /etc/fstab. The fstab on my USB= stick version has root mounted as /etc/da0s1a and clearly that isn't going= to work. I changed my core BSD image accordingly, duplicating the mfsroot = settings in my loader.conf. I used the command below to create the iso file from the BSD image I prepar= ed. mkisofs -R -no-emul-boot -o /tmp/bsd.iso -b boot/cdboot /bsd When this iso is copied to a CD, it does boot. However, it doesn't seem to = be picking up the mfsroot config and complains that the system is running f= rom on a read-only file system, which of course is what I'm trying to avoid= . I assume I simply have the boot config setup wrong. I essentially want the = same kind of thing that's done for BSD Live. Can anyone point me to the rig= ht info for setting up this kind of bootable BSD CD?