svn commit: r216230 - head/sys/cddl/contrib/opensolaris/uts/common/fs/zfs

Pawel Jakub Dawidek pjd at
Tue Dec 7 09:51:45 UTC 2010

On Mon, Dec 06, 2010 at 11:10:38PM +0200, Alexander Motin wrote:
> On 06.12.2010 22:18, John Baldwin wrote:
> >On Monday, December 06, 2010 2:53:27 pm Pawel Jakub Dawidek wrote:
> >>On Mon, Dec 06, 2010 at 08:35:36PM +0100, Ivan Voras wrote:
> >>>Please persuade me on technical grounds why ashift, a property
> >>>intended for address alignment, should not be set in this way. If your
> >>>answer is "I don't know but you are still wrong because I say so" I
> >>>will respect it and back it out but only until I/we discuss the
> >>>question with upstream ZFS developers.
> >>
> >>No. You persuade me why changing ashift in ZFS, which, as the comment
> >>clearly states is "device's minimum transfer size" is better and not
> >>hackish than presenting the disk with properly configured sector size.
> >>This can not only affect disks that still use 512 bytes sectors, but
> >>doesn't fix the problem at all. It just works around the problem in ZFS
> >>when configured on top of raw disks.
> Both ATA and SCSI standards implemented support for different logical 
> and physical sector sizes. It is not a hack - it seems to be the way 
> manufacturers decided to go. At least on their words. IMHO hack in this 
> situation would be to report to GEOM some fake sector size, different 
> from one reported by device. In any way it is the main visible disk 
> characteristic, independently of what it's firmware does inside.

We can be smarter than that, really. We all know the disk presents 512
bytes sectors only(?) because most of the software out there (including
Windows, I guess) will simply break when they see disk with 4kB sector.
We were trying very hard not to be limited to 512 byte sectors and we
actually succedded: GEOM supports any sector size just fine, most (if
not all) GEOM classes support power of 2 sectors just fine, even our two
main file systems (UFS and ZFS) support !512 sectors. After all this
work do we really don't want to take advantage of it? Maybe other
operating systems can't deal with 4kB sectors, but we can, we were well
prepared for this, why do we want to forget about that?

Pawel Jakub Dawidek             
pjd at                 
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url :

More information about the svn-src-all mailing list