From owner-freebsd-questions@FreeBSD.ORG Wed Dec 31 10:43:36 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3AE7D8D0 for ; Wed, 31 Dec 2014 10:43:36 +0000 (UTC) Received: from ms-10.1blu.de (ms-10.1blu.de [178.254.4.101]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id EA03D676F8 for ; Wed, 31 Dec 2014 10:43:35 +0000 (UTC) Received: from [93.104.1.100] (helo=unixarea.DDR.dd) by ms-10.1blu.de with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1Y6GkR-0006X8-9F for freebsd-questions@freebsd.org; Wed, 31 Dec 2014 11:43:27 +0100 Received: from unixarea.DDR.dd (localhost [127.0.0.1]) by unixarea.DDR.dd (8.14.9/8.14.3) with ESMTP id sBVAhP71002465 for ; Wed, 31 Dec 2014 11:43:25 +0100 (CET) (envelope-from guru@unixarea.de) Received: (from guru@localhost) by unixarea.DDR.dd (8.14.9/8.14.3/Submit) id sBVAhOGn002464 for freebsd-questions@freebsd.org; Wed, 31 Dec 2014 11:43:24 +0100 (CET) (envelope-from guru@unixarea.de) X-Authentication-Warning: unixarea.DDR.dd: guru set sender to guru@unixarea.de using -f Date: Wed, 31 Dec 2014 11:43:24 +0100 From: Matthias Apitz To: freebsd-questions@freebsd.org Subject: makefs && gpart Message-ID: <20141231104324.GA2450@unixarea.DDR.dd> Reply-To: Matthias Apitz Mail-Followup-To: Matthias Apitz , freebsd-questions@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline X-Operating-System: FreeBSD 11.0-CURRENT r269739 (i386) User-Agent: Mutt/1.5.23 (2014-03-12) X-Con-Id: 51246 X-Con-U: 0-guru X-Originating-IP: 93.104.1.100 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 31 Dec 2014 10:43:36 -0000 Hello, I have a small question re/ makefs && gpart: There is a script src/release/i386/make-memstick.sh to create an image from a full directory tree; the tree is result of make installworld DESTDIR=/tree make installkernel DESTDIR=/tree the script mainly does: ... makefs -B little -o label=FreeBSD_Install ${2} ${1} if [ $? -ne 0 ]; then echo "makefs failed" exit 1 fi rm ${1}/etc/fstab unit=$(mdconfig -a -t vnode -f ${2}) if [ $? -ne 0 ]; then echo "mdconfig failed" exit 1 fi gpart create -s BSD ${unit} gpart bootcode -b ${1}/boot/boot ${unit} gpart add -t freebsd-ufs ${unit} mdconfig -d -u ${unit} As you can see, it does makefs first, and after this it creates the gpart structure in the image (i.e. in its memory file system). Why is this in this order and where exactly starts the file system created by makefs? Thanks matthias -- Matthias Apitz, guru@unixarea.de, http://www.unixarea.de/ +49-170-4527211 1989-2014: The Wall was torn down so that we go to war together again. El Muro ha sido derribado para que nos unimos en ir a la guerra otra vez. Diese Grenze wurde aufgehoben damit wir gemeinsam wieder in den Krieg ziehen.