From owner-freebsd-current@FreeBSD.ORG Mon Dec 5 16:47:54 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 875BE106566C for ; Mon, 5 Dec 2011 16:47:54 +0000 (UTC) (envelope-from phk@phk.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.freebsd.org (Postfix) with ESMTP id 32FDF8FC08 for ; Mon, 5 Dec 2011 16:47:54 +0000 (UTC) Received: from critter.freebsd.dk (critter.freebsd.dk [192.168.61.3]) by phk.freebsd.dk (Postfix) with ESMTP id 587BF5DD7; Mon, 5 Dec 2011 16:47:53 +0000 (UTC) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.14.5/8.14.5) with ESMTP id pB5GlreM057042; Mon, 5 Dec 2011 16:47:53 GMT (envelope-from phk@phk.freebsd.dk) To: Mark Martinec From: "Poul-Henning Kamp" In-Reply-To: Your message of "Mon, 05 Dec 2011 17:43:13 +0100." <201112051743.13483.Mark.Martinec+freebsd@ijs.si> Content-Type: text/plain; charset=ISO-8859-1 Date: Mon, 05 Dec 2011 16:47:53 +0000 Message-ID: <57041.1323103673@critter.freebsd.dk> Cc: freebsd-current@freebsd.org Subject: Re: bsdinstall guided partitioning should 4k-align swap and ufs partitions X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Dec 2011 16:47:54 -0000 In message <201112051743.13483.Mark.Martinec+freebsd@ijs.si>, Mark Martinec wri tes: >Using a guided partitioning install of 9.0-RC2 on a 64GB (virtual) disk >(from a 9.0-RC2 ISO image) results in the following GPT partitioning: > ># gpart show /dev/ada0 >=> 34 134217661 ada0 GPT (64G) > 34 128 1 freebsd-boot (64k) > 162 125828992 2 freebsd-ufs (60G) > 125829154 6709248 3 freebsd-swap (3.2G) > 132538402 1679293 - free - (820M) > >This is most unfortunate for installations using 4kB sectored disks >or SSD disks, [...] This is not a new problem, you face the same issue with RAID5 devices. GEOM defines two provider properties for handling all these cases correctly: stripesize + stripeoffset. If the disk-driver has a 4k drive, or suspects it has a 4k drive ( these properties are advisory only), it should announce that with the stripe* properties on its GEOM provider. GEOM classes are responsible for passing these properties up with whatever adjustments are necessary (for instance modifying the stripeoffset for partitions). The partitioning tools, (All of them!) should examine these two properties and prod the user towards not doing something silly. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.