Date: Fri, 03 Feb 2012 15:59:33 +0000 From: Pete French <petefrench@ingresso.co.uk> To: dmagda@ee.ryerson.ca, petefrench@ingresso.co.uk Cc: freebsd-stable@freebsd.org Subject: Re: Sector size of a zvol Message-ID: <E1RtLXx-0000h9-2H@dilbert.ingresso.co.uk> In-Reply-To: <01775b9823b5bacb14d03315a6321d61.squirrel@webmail.ee.ryerson.ca>
next in thread | previous in thread | raw e-mail | index | archive | help
> Try the following from the zfs(1M) man page: > > zfs create [-ps] [-b blocksize] [-o property=value] ... -V size volume > [...] > -b blocksize > > Equivalent to -o volblocksize=blocksize. If this option is > specified in conjunction with -o volblocksize, the resulting > behavior is undefined. Yes, thats the parameter I have been playing around with - whether you set it with -b or -o volblocksize, the zvol still presents itself as being 512 bytes. This is what is puzzling me. Quick example: # zfs create -V 1G -b 512 tank/test1 # zfs create -V 1G -b 4k tank/test2 # zfs create -V 1G tank/test3 # zfs get volblocksize tank/test1 tank/test2 tank/test3 NAME PROPERTY VALUE SOURCE tank/test1 volblocksize 512 - tank/test2 volblocksize 4K - tank/test3 volblocksize 8K - # diskinfo /dev/zvol/tank/test* /dev/zvol/tank/test1 512 1073741824 2097152 0 0 /dev/zvol/tank/test2 512 1073741824 2097152 0 0 /dev/zvol/tank/test3 512 1073741824 2097152 0 0 As you can see, the blocksize is being set properly in the volume, but in the actial device it's always 512. Now the reason behind this was to share out a 4k block sizes iscsi target, and I have subsequently discovered that I can set that parameter on istgt which should mitigate the effect, but I still think it is odd. cheers, -pete.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1RtLXx-0000h9-2H>