Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 15 Mar 2008 15:18:43 +0100
From:      Pawel Jakub Dawidek <pjd@FreeBSD.org>
To:        Kris Kennaway <kris@FreeBSD.org>
Cc:        Alexey Tarasov <me@lexasoft.ru>, current@freebsd.org
Subject:   Re: Disappointing speed with ZFS
Message-ID:  <20080315141843.GB1958@garage.freebsd.pl>
In-Reply-To: <47B0AFE6.6070503@FreeBSD.org>
References:  <9DA6FFCD-11DB-4580-9314-52B0885351D8@lexasoft.ru> <fopmlp$qeh$1@ger.gmane.org> <50186FCD-F67F-4144-BDF1-FB9A7F9AAB64@lexasoft.ru> <47B0AFE6.6070503@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--Clx92ZfkiYIKRjnr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Feb 11, 2008 at 09:28:22PM +0100, Kris Kennaway wrote:
> Alexey Tarasov wrote:
> >I've done similar tests on the other machine, and all looks fine.
> >
> >But why on this machine ZFS works slower than UFS? When I make UFS file=
=20
> >system on the same disk, rtorrent hashing works 10 times faster. And=20
> >while hashing, HDD is used three times intensively with ZFS (noticed by=
=20
> >flashing LED).
> >
> >I have an amd64 Core2Duo processor, 4 Gb of RAM, what is not enough for=
=20
> >ZFS?
> >
> >What kernel tuning can help me?
>=20
> I'd guess this is just related to the ZFS design.  As Ivan says, it=20
> prefers to do all writes sequentially.  This means that reads (as with=20
> reading of hashes) may be very fragmented and require lots of drive=20
> seeking, which will reduce performance a lot.  ZFS does do aggressive=20
> prefetching of data to try and offset this problem, but if your disk=20
> bandwidth is low (e.g. you are not using a fast disk array) then it may=
=20
> not help much (and can also introduce big I/O latency for other operation=
s).
>=20
> As for what can be done about this, I don't know, but you should look=20
> into the general ZFS literature (ZFS support mailing lists, etc).

It may also be because ZFS send FLUSH requests to the disk quite often.
If disk or controller handles those requests slowly, it may case
performance drop when comparing to UFS, which doesn't send FLUSH
requests at all. To verify this, one should try disable FLUSH requests
sending by adding:

	vfs.zfs.cache_flush_disable=3D1

to /boot/loader.conf.

--=20
Pawel Jakub Dawidek                       http://www.wheel.pl
pjd@FreeBSD.org                           http://www.FreeBSD.org
FreeBSD committer                         Am I Evil? Yes, I Am!

--Clx92ZfkiYIKRjnr
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.4 (FreeBSD)

iD8DBQFH29rDForvXbEpPzQRAuRFAJ9X3uxztqKGmcofOxm5+7VaST0MgACgw5pb
bI3u0XVgPM4S786UOjTyAA8=
=sGas
-----END PGP SIGNATURE-----

--Clx92ZfkiYIKRjnr--



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