ZFS-lighttpd2-sendfile, too high IO

Mark Blackman mark at exonetric.com
Tue Sep 13 09:56:50 UTC 2011


On 13 Sep 2011, at 10:31, Ivan Voras wrote:
>> 
>> Zfs reads whole 128K blocks (or whatever the filesystem blocksize is) at
>> a time.  It does not read partial blocks from underlying storage. This
>> makes it very expensive to perform many small read accesses if the reads
>> are not subsequently cached in the ARC.
> 
> Yes!
> 
> Which makes it particularly "interesting" if you try to run a database
> on it while forgetting to reset the block size to e.g. 8K before the
> database is initialized - you get 16x more IO than you expected.
> 

Yes, I got this but what can you do if the database has already been 
initialized? I'm guessing the only realistic option is to set the block
size, then copy the database files to a new directory and rename the old
and new directories so the new directory is the database store.

Perhaps you need to use an entirely new dataset?

- Mark


More information about the freebsd-fs mailing list