Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 1 May 2011 13:36:27 +0200
From:      Alexander Leidinger <Alexander@Leidinger.net>
To:        "Emil Smolenski" <am@raisa.eu.org>
Cc:        freebsd-fs@freebsd.org, dfr@FreeBSD.org, jhb@FreeBSD.org
Subject:   Re: [ZFS] Booting from zpool created on 4k-sector drive
Message-ID:  <20110501133627.00006616@unknown>
In-Reply-To: <op.vn2iid1qk84lxj@arrow>
References:  <op.vn2iid1qk84lxj@arrow>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 21 Dec 2010 15:29:01 +0100 "Emil Smolenski" <am@raisa.eu.org>
wrote:

> Hello,
> 
> There is a hack to force zpool creation with minimum sector size
> equal to 4k:
> 
> # gnop create -S 4096 ${DEV0}
> # zpool create tank ${DEV0}.nop
> # zpool export tank
> # gnop destroy ${DEV0}.nop
> # zpool import tank
> 
> Zpool created this way is much faster on problematic 4k sector
> drives which lies about its sector size (like WD EARS). This hack
> works perfectly fine when system is running. Gnop layer is created
> only for "zpool create" command -- ZFS stores information about
> sector size in its metadata. After zpool creation one can export the
> pool, remove gnop layer and reimport the pool. Difference can be seen
> in the output from the zdb command:
> 
> - on 512 sector device (2**9 = 512):
> % zdb tank |grep ashift
> ashift=9
> 
> - on 4096 sector device (2**12 = 4096):
> % zdb tank |grep ashift
> ashift=12
> 
> This change is permanent. The only possibility to change the value
> of ashift is: zpool destroy/create and restoring pool from backup.
> 
> But there is one problem: I cannot boot from such pool. Error message:
> 
> ZFS: i/o error - all block copies unavailable
> ZFS: can't read MOS
> ZFS: unexpected object set type 0

FYI: I can boot successfully from a ZFS v28 pool which was created like
this in a GPT partition (tested with 9-current).

Bye,
Alexander.

-- 
http://www.Leidinger.net    Alexander @ Leidinger.net: PGP ID = B0063FE7
http://www.FreeBSD.org       netchild @ FreeBSD.org  : PGP ID = 72077137



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20110501133627.00006616>