Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 9 Jan 2013 22:31:19 +0800 (SGT)
From:      Patrick Dung <patrick_dkt@yahoo.com.hk>
To:        freebsd-fs@freebsd.org
Subject:   ZFS sub-optimal performance with default setting
Message-ID:  <1357741879.56011.YahooMailClassic@web190806.mail.sg3.yahoo.com>

next in thread | raw e-mail | index | archive | help
Hi freebsd-fs!

I have my the original question in:
http://archives.postgresql.org/pgsql-performance/2013-01/msg00044.php
But later it was found out the bottleneck seems to be the ZFS with out a fa=
st ZIL.
Please give some advise, thanks.

Details:

Postgresql 9.2.2 (complied by gcc) is installed in FreeBSD 9.1 i386.
The pgsql base directory is in a ZFS dataset.

I have noticed the performance is sub-optimal, but I know the default=20
setting should be the most safest one to be use (concern about data integri=
ty).

a) I use OTRS ticketing system version 3.1, the backend is PostgreSQL.
The user interactive response is not slow (switching web pages or create a =
change).

b) There is a benchmark in the support module of OTRS.
It tested insert,update,select and delete performance.
The response time is slow (>10 sec), except select.

I have done some research on web, with below settings (just one change, not=
 both), the performance returned to normal:

1) Disabled sync in the pgsql dataset in ZFS
zfs set sync=3Ddisabled mydata/pgsql
or=20
2) In
=A0postgresql.conf, set synchronous_commit from on to off

I know the above setting would lead to data loss (e.g.power goes off), any =
comments?

PS:
1) I have tried to use primarycache/secondarycache=3Dmetadata/none, it do n=
ot seem to help.

2)
I have tried the default setting on Linux too:
RHEL 6.3, ext4, stock postgresql 8.x, OTRS 3.1.
The web site is responsive and the benchmark result is more or less the sam=
e as FreeBSD with the 'sync' turned off.

3)
For FreeBSD, same setting with Postgresql on UFS:
The performance is between ZFS (default, sync enabled) and ZFS (sync disabl=
ed).

Thanks,
Patrick



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