From owner-freebsd-fs@FreeBSD.ORG Wed Mar 2 23:28:08 2011 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AA5931065676 for ; Wed, 2 Mar 2011 23:28:08 +0000 (UTC) (envelope-from james-freebsd-fs2@jrv.org) Received: from mail.jrv.org (rrcs-24-73-246-106.sw.biz.rr.com [24.73.246.106]) by mx1.freebsd.org (Postfix) with ESMTP id 6B58B8FC15 for ; Wed, 2 Mar 2011 23:28:08 +0000 (UTC) Received: from kremvax.housenet.jrv (kremvax.housenet.jrv [192.168.3.124]) by mail.jrv.org (8.14.4/8.14.4) with ESMTP id p22NS5uG089971; Wed, 2 Mar 2011 17:28:07 -0600 (CST) (envelope-from james-freebsd-fs2@jrv.org) Authentication-Results: mail.jrv.org; domainkeys=pass (testing) header.from=james-freebsd-fs2@jrv.org DomainKey-Signature: a=rsa-sha1; s=enigma; d=jrv.org; c=nofws; q=dns; h=message-id:date:from:user-agent:mime-version:to:cc:subject: references:in-reply-to:content-type:content-transfer-encoding; b=vKQT+efpa2KltR/y0Zu+58Fl8Msyz3IkQuBdtWfYCrxYTCLJ5LpFyYxHvhPSXRxym CdbhhsTCHZned/NUZIfkFpCgkq8+mPv0NhcSgB3FxIdi4H97Jzj6ZCYkM1wtJLHTImt Ik/6QFzbGe6sd0mBBTio5CHf+wLAiWqPavrbMwk= Message-ID: <4D6ED285.6010105@jrv.org> Date: Wed, 02 Mar 2011 17:28:05 -0600 From: "James R. Van Artsdalen" User-Agent: Thunderbird 2.0.0.24 (Macintosh/20100228) MIME-Version: 1.0 To: Emil Smolenski References: <4D6AAC9A.4000602@jrv.org> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: freebsd-fs@freebsd.org Subject: Re: [ZFS] Booting from zpool created on 4k-sector drive 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: Wed, 02 Mar 2011 23:28:08 -0000 Emil Smolenski wrote: > James asks about disk replacement scenario. In this case you cannot > use device with greater sector size than 2**ashift of the existing > vdev as replacement: > > # diskinfo -v md0 |grep sectorsize > 512 # sectorsize > # zpool create test0 md0 > # zdb test0 |grep ashift > ashift=9 > # diskinfo -v md1.nop |grep sectorsize > 4096 # sectorsize > # zpool replace test0 md0 md1.nop > cannot replace md0 with md1.nop: devices have different sector alignment I was thinking of the capacity of the drive as a problem, not the sector sizes. I wrongly thought gnop consumed space on the drive (like gmirror) and this might make it hard to replace an ashift=12 disk with a 512-byte-sector disk. But this is not the case. It might be a good idea now to start using the gnop trick to force vdev's to use ashift=12 in case disks begin advertising themselvess as 4096-byte-sector.