From owner-freebsd-fs@FreeBSD.ORG Tue Apr 24 06:49:15 2012 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2A60D106564A for ; Tue, 24 Apr 2012 06:49:15 +0000 (UTC) (envelope-from peter.maloney@brockmann-consult.de) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.10]) by mx1.freebsd.org (Postfix) with ESMTP id AF5B28FC15 for ; Tue, 24 Apr 2012 06:49:14 +0000 (UTC) Received: from [10.3.0.26] ([141.4.215.32]) by mrelayeu.kundenserver.de (node=mreu3) with ESMTP (Nemesis) id 0ME88h-1SRq5D1fhv-00HNKT; Tue, 24 Apr 2012 08:49:08 +0200 Message-ID: <4F964CE3.1080908@brockmann-consult.de> Date: Tue, 24 Apr 2012 08:49:07 +0200 From: Peter Maloney User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120312 Thunderbird/11.0 MIME-Version: 1.0 To: freebsd-fs@freebsd.org References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Provags-ID: V02:K0:FZZp5Einy0uj8vqnOh+JQPS9SCkBG6QpI9Pkhf8U3An KnHW1CU1eyAUn0dBmlXNjxAkFGpuREc4y4w/Yu2kByebc7tIii X/XNsjcIMEPm+qqkLXZE3OC1gzEQlF5jnQaIv1C7nhTZ8O9wQe gASu7n8uSxUI0CCGdL52SmyDjCrOs1dJJUVPQEGYC1pd48tTiT V2e9iVgGGbesS/DM8B5Apc0nDqWjxMRYF25/nAkDzYIDvJOYLU CQ1tB2WpYop6l4T0J9YzwnBPT6EG/beu2u0skGeelOqEE/XP3f VGDQ1HeOXBgbuWlhIgpreqdkou3vOTq4H+t78Cslz7NdeK243i +BzpoNPZOVV2OAb9jbEEjPBXcUtlYDd19qIcD+RZH Subject: Re: Increasing ZFS Disk Sizes X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Apr 2012 06:49:15 -0000 On 04/24/2012 05:22 AM, Tim Gustafson wrote: > Hi, > > I've got a 9.0-RELEASE system that's installed using the hand mfsroot > installer. My gpart tables look like this: > > => 34 976773101 ada0 GPT (465G) > 34 128 1 freebsd-boot (64k) > 162 33554432 2 freebsd-swap (16G) > 33554594 943218541 3 freebsd-zfs (449G) > > => 34 976773101 ada1 GPT (465G) > 34 128 1 freebsd-boot (64k) > 162 33554432 2 freebsd-swap (16G) > 33554594 943218541 3 freebsd-zfs (449G) > > I'd like to increase the size of the freebsd-zfs partition. I was > thinking of "breaking" my mirror, like this: > > zpool detach tank ada0p3 > > and then swapping out one of the disks with a blank 2TB disk, and then running: > > gpart create -s gpt ada0 > gpart add -b 34 -s 64k -t freebsd-boot ada0 > gpart add -s 16G -t freebsd-swap -l swap0 ada0 > gpart add -t freebsd-zfs -l disk0 ada0 > gpart bootcode -b /mnt2/boot/pmbr -p /mnt2/boot/gptzfsboot -i 1 ada0 Add "-a 2048" to align for better write performance (especially on SSDs and 4k sector disks) (most disks I find do equally well with alignment of 4, but some disks (eg. the new Seagate Green 3TB ones) have TERRIBLE write performance if the first partition starts before 2048. gpart create -s gpt ada0 gpart add -b 34 -s 64k -t freebsd-boot ada0 gpart add -a 2048 -s 16G -t freebsd-swap -l swap0 ada0 gpart add -a 2048 -t freebsd-zfs -l disk0 ada0 gpart bootcode -b /mnt2/boot/pmbr -p /mnt2/boot/gptzfsboot -i 1 ada0 (and if you have problems with partitions being slightly the wrong size, use -s instead of [giga]bytes) And the zfs side of things looks fine, as Matthew also said.