From owner-freebsd-doc@FreeBSD.ORG Fri Mar 30 03:23:15 2012 Return-Path: Delivered-To: freebsd-doc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B2A04106566B; Fri, 30 Mar 2012 03:23:15 +0000 (UTC) (envelope-from wblock@wonkity.com) Received: from wonkity.com (wonkity.com [67.158.26.137]) by mx1.freebsd.org (Postfix) with ESMTP id 6BE768FC14; Fri, 30 Mar 2012 03:23:15 +0000 (UTC) Received: from wonkity.com (localhost [127.0.0.1]) by wonkity.com (8.14.5/8.14.5) with ESMTP id q2U3NEDW054487; Thu, 29 Mar 2012 21:23:14 -0600 (MDT) (envelope-from wblock@wonkity.com) Received: from localhost (wblock@localhost) by wonkity.com (8.14.5/8.14.5/Submit) with ESMTP id q2U3NEIv054484; Thu, 29 Mar 2012 21:23:14 -0600 (MDT) (envelope-from wblock@wonkity.com) Date: Thu, 29 Mar 2012 21:23:14 -0600 (MDT) From: Warren Block To: Daniel Gerzo In-Reply-To: Message-ID: References: <20120125.111625.2289296443525755896.hrs@allbsd.org> <7e043215e6cd0f2da324d6599c921fec@rulez.sk> User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.7 (wonkity.com [127.0.0.1]); Thu, 29 Mar 2012 21:23:14 -0600 (MDT) Cc: freebsd-doc@freebsd.org, pjd@freebsd.org Subject: Re: Handbook RAID1 example X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Mar 2012 03:23:15 -0000 On Tue, 27 Mar 2012, Warren Block wrote: > Procedure tested on both 9.0-RELEASE and 8.2-RELEASE. It could stand more > testing. HTML: http://www.wonkity.com/~wblock/gmirror/geom-mirror.html And more testing does show a problem. My tests were all using the smaller drive as the new drive (20G). Create a mirror using that whole drive, copy the data from the 20G allocated space on the original 200G drive. But it doesn't work the other way around. Create a mirror of the full larger drive, and the smaller drive cannot be inserted into it; it can't mirror a 200G drive. The procedure really ought to work with different-sized drives, because that situation is expectable. Telling the users that the disks must be identical is weak. It may still fail because of the presence or absence of a label or other metadata eating one or more sectors even if the drives are identical. Now I'm considering labeling each disk, then using gnop(8) to create a matching-sized device on each. This adds more complexity, and maybe the thing to do is put the whole thing into a shell script. Suggestions welcome.