From owner-freebsd-questions@FreeBSD.ORG Sun Aug 15 23:06:22 2010 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E3E2106564A for ; Sun, 15 Aug 2010 23:06:22 +0000 (UTC) (envelope-from djr@pdconsec.net) Received: from ipmail06.adl6.internode.on.net (ipmail06.adl6.internode.on.net [150.101.137.145]) by mx1.freebsd.org (Postfix) with ESMTP id 102A48FC14 for ; Sun, 15 Aug 2010 23:06:21 +0000 (UTC) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: At4GABIOaEyWZcBC/2dsb2JhbACTNY4CuHaFOwSMSw Received: from goliath.pdconsec.net (HELO smtp.pdconsec.net) ([150.101.192.66]) by ipmail06.adl6.internode.on.net with SMTP; 16 Aug 2010 08:36:19 +0930 Received: from mail1.pdconsec.net ([192.168.1.41] helo=mail1.pdconsec.net) with IPv4:25 by smtp.pdconsec.net; 16 Aug 2010 09:06:17 +1000 Received: from smtp.pdconsec.net ([192.168.1.32] RDNS failed) by mail1.pdconsec.net with Microsoft SMTPSVC(6.0.3790.4675); Mon, 16 Aug 2010 09:05:05 +1000 Received: from [10.14.6.41] ([150.101.192.69] helo=[10.14.6.41]) with IPv4:10025 by smtp.pdconsec.net; 16 Aug 2010 09:06:17 +1000 Message-ID: <4C6872A1.70703@pdconsec.net> Date: Mon, 16 Aug 2010 09:05:05 +1000 From: David Rawling User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.8) Gecko/20100802 Thunderbird/3.1.2 MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <4C68708A.905@gmail.com> In-Reply-To: <4C68708A.905@gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 15 Aug 2010 23:05:05.0741 (UTC) FILETIME=[4CAB37D0:01CB3CCE] Subject: Re: ZFS Question X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Aug 2010 23:06:22 -0000 On 16/08/2010 8:56 AM, Depo Catcher wrote: > Hi, I'm building a new file server. Right now I'm on FreeBSD 6.4/UFS2 and > going to go to 8.1 with ZFS. > > Right now I have 3 disks, but one of them has data on it. I'd like to setup > a RaidZ but have a question on how to do this: > Basically, I need to setup a mirror with the two empty drives, copy the data > over and then add the third. Is that even possible? That kind of expansion cannot be done with FreeBSD ZFS (yet - I believe it was being worked on in OpenSolaris and it would have filtered to FreeBSD). Once the pool uses a given RAID level, I believe that's set in stone. What might work is this - paraphrased because I'm not 100% sure of the specific commands: * Create a large (multiple GB) file on your existing disk - let's assume that's /disk1/file0 (dd if=/dev/zero of=/disk1/file0 bs=1024 count=104857600 would be 100GB) * Create a 3 disk RAIDZ1 pool using /dev/disk2, /dev/disk3 and /disk1/file0 (zpool create tank raidz1 ...) * Delete the file (the pool will be degraded) * Copy data to the degraded pool * Replace the missing disk file with /dev/disk1 (zpool replace?) * Scrub the pool for consistency checks (then reset the counters so you can track the current state. You'll want a backup just in case, though, so is there perhaps a case for getting 1 more disk and building the set clean? That way the old disk becomes a backup. Dave. -- David Rawling PD Consulting And Security Mob: +61 412 135 513 Email: djr@pdconsec.net