From owner-freebsd-questions@FreeBSD.ORG Sun Jun 5 05:32:07 2011 Return-Path: Delivered-To: questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0FB231065673 for ; Sun, 5 Jun 2011 05:32:07 +0000 (UTC) (envelope-from rsimmons0@gmail.com) Received: from mail-vw0-f54.google.com (mail-vw0-f54.google.com [209.85.212.54]) by mx1.freebsd.org (Postfix) with ESMTP id B11278FC0A for ; Sun, 5 Jun 2011 05:32:06 +0000 (UTC) Received: by vws18 with SMTP id 18so3023533vws.13 for ; Sat, 04 Jun 2011 22:32:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:reply-to:to:subject:date:user-agent :references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=Coe0aRoTq3NLTNTGz2cNXZwPzNYu/bLJWcvF3ILIubU=; b=iHDx95EXDdP5sDLMyabHujRoWBGTsBu0XYYsh0lrFX3JvHc8J5iE+XXmu9tIofvj+b r7BdPKdTHpL6t3FLYjAAalIY1lEGetVD6B7Ge7m3/pABzvMPIw7osrkxZl3IsDgMjRE4 0hFWTXPzN/70zTaqf9/5UmBxCFx+SqVFUvvYo= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:reply-to:to:subject:date:user-agent:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=kXFWHJbj+AFzKLQ1bT8+rCCLUwDlxGtg//MSzvfP8VXyBG2eHHgz9yYqMsQDHnwDgu NR4vExIWEGTK7jZ3z6JZYO3HpVoLzRpjda0xvmy8FT7eBil4zjfUmzVE6BuCD6jRJM0I c+oX5gJ6xRaNnU4uvP1+a0i+e3U0sOGGjV6Zs= Received: by 10.52.106.196 with SMTP id gw4mr5032606vdb.83.1307251925809; Sat, 04 Jun 2011 22:32:05 -0700 (PDT) Received: from skynet.localnet (pool-108-28-47-226.washdc.fios.verizon.net [108.28.47.226]) by mx.google.com with ESMTPS id l18sm688981vby.14.2011.06.04.22.32.05 (version=SSLv3 cipher=OTHER); Sat, 04 Jun 2011 22:32:05 -0700 (PDT) From: Robert Simmons To: questions@freebsd.org Date: Sun, 5 Jun 2011 01:32:03 -0400 User-Agent: KMail/1.13.6 (Linux/2.6.38-8-generic; KDE/4.6.3; i686; ; ) References: <4DEAAE54.1050508@locolomo.org> <20110605044021.GA2213@tinyCurrent> <20110605065944.4cab117a.freebsd@edvax.de> In-Reply-To: <20110605065944.4cab117a.freebsd@edvax.de> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201106050132.04159.rsimmons0@gmail.com> Cc: Subject: Re: Partitioning with gpart or old style slices? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rsimmons0@gmail.com List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Jun 2011 05:32:07 -0000 On Sunday, June 05, 2011 12:59:44 AM Polytropon wrote: > On Sun, 5 Jun 2011 06:40:22 +0200, Matthias Apitz wrote: > > Since some time I'm as well using gpart(8) to setup new systems with the > > following sequence: > > > > # gpart create -s mbr ad4 # Init the disk with an MBR > > # gpart add -t freebsd ad4 # Create a BSD container > > # gpart create -s bsd ad4s1 # Init with a BSD scheme > > # gpart add -t freebsd-ufs -s 1G ad4s1 # 1GB for / > > # gpart add -t freebsd-swap -s 2G ad4s1 # 2GB for swap > > # gpart add -t freebsd-ufs -s 2G ad4s1 # 2GB for /var > > # gpart add -t freebsd-ufs -s 1G ad4s1 # 1GB for /tmp > > # gpart add -t freebsd-ufs ad4s1 # all rest for /usr > > # gpart set -a active -i 1 ad4 > > Just a side question that may be interesting for addition > in a new Handbook section: > > When you use the "old" method, you can leave out the slicing > step, creating a "dangerously" (haha) dedicated disk for > use with FreeBSD. Would this also work with gpart by omitting > the "gpart create -s bsd ad4s1" step and then refering to > ad4 instead of ad4s1 in the "gpart add -t freebsd-ufs/swap" > steps? Yes, that would be the equivalent, but if you do that, you might as well use GPT. The reason you would want to use MBR is to dual boot with another OS that only understands MBR. If you are using certain newer 64bit versions of Windows, they understand GPT boot, so the whole BSD inside MBR vs. BSD dedicated is becoming moot in my opinion. A good reference if you must dual boot is: http://msdn.microsoft.com/en-us/windows/hardware/gg463525 Also, at the bottom of this page is a list of OSs and GPT support: http://en.wikipedia.org/wiki/GUID_Partition_Table > > But the result is not ready for boot after install the kernel and > > system; I allways have to go again with the sysinstall(8) tool to set > > the 'A' flag; don't know what I'm missing (and the man page is not very > > instructive on this); thanks > > I agree about the manpage; "gpart set -a attrib -i index [-f > flags] geom" is mentioned in the synopsis, but there's no > further mentioning of the -a option and its parameters. > Maybe (haven't tested!) "gpart set -a active -i 1 ad4s1" > is equivalent to setting the "A" flag using sysinstall? After reexamining the man page I think I see where it could be made more clear. The Examples section at the bottom should be changed into sections, one for MBR with BSD inside, one for BSD dedicated, one for GPT, and one for VTOC8. Or at minimum add that you _must_ install bootcode if you wish to boot from the disk. From the confusion above it seems that people think that "gpart create -s GPT ad0" installs the bootcode, which it does not (replace the GPT in my example with MBR, BSD etc).