Using the *real* sector/block size of a mass storage device for ZFS

Freddie Cash fjwcash at gmail.com
Sat Feb 8 16:28:32 UTC 2014


On Feb 8, 2014 2:03 AM, "Johan Hendriks" <joh.hendriks at gmail.com> wrote:
>
> Op zaterdag 8 februari 2014 heeft Berend de Boer <berend at pobox.com> het
> volgende geschreven:
>
> > >>>>> "Dustin" == Dustin Wenz <dustinwenz at ebureau.com <javascript:;>>
> > writes:
> >
> >     Dustin> Am I correct in assuming that it is absolutely impossible
> >     Dustin> to convert an existing ashift:9 vdev to ashift:12? Some of
> >     Dustin> my pools are approaching 1PB in size; transferring the
> >     Dustin> data off and back again would be inconvenient.
> >
> > I thought you could do it one disk at a time (if you have a redundant
> > pool).
> >
> > But maybe not.
> >
> > --
> > All the best,
> >
> > Berend de Boer
>
>
> No that is not possible.
> The ashift is set when the pool is created, hence the fact that you only
> need the gnop method at pool creation time. If you add a vdev to the pool
> you do not need the gnop method anymore because you can not change it.
> You can align the disk so it has a 4 k alignement. But that is not the
> ashift of the pool

Correction: the ashift is set at the vdev level, when the vdev is created.
You only need to use the gnop method on a single disk in a vdev as zfs uses
the largest ashift of all drives in the vdev. And you need to do it anytime
you add a new vdev to a pool.

I believe there's a sysctl in FreeBSD 10 where you can set the minimum
ashift level so you don't need to use the gnop method.


More information about the freebsd-fs mailing list