Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TsGL3-0008KJ-W2 for pgsql-performance@arkaria.postgresql.org; Mon, 07 Jan 2013 17:18:18 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.72) (envelope-from ) id 1TsGL3-0000O5-FR for pgsql-performance@arkaria.postgresql.org; Mon, 07 Jan 2013 17:18:17 +0000 Received: from makus.postgresql.org ([98.129.198.125]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TsGL2-0000Me-2C for pgsql-performance@postgresql.org; Mon, 07 Jan 2013 17:18:16 +0000 Received: from nm5-vm6.bullet.mail.sg3.yahoo.com ([106.10.148.149]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TsGKx-0006T3-Kx for pgsql-performance@postgresql.org; Mon, 07 Jan 2013 17:18:14 +0000 Received: from [106.10.166.118] by nm5.bullet.mail.sg3.yahoo.com with NNFMP; 07 Jan 2013 17:18:04 -0000 Received: from [106.10.151.250] by tm7.bullet.mail.sg3.yahoo.com with NNFMP; 07 Jan 2013 17:18:02 -0000 Received: from [127.0.0.1] by omp1021.mail.sg3.yahoo.com with NNFMP; 07 Jan 2013 17:18:02 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 752901.34271.bm@omp1021.mail.sg3.yahoo.com Received: (qmail 91517 invoked by uid 60001); 7 Jan 2013 17:18:02 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com.hk; s=s1024; t=1357579082; bh=qZU+BoZgoNQysLS48fCObdtKbNDU+fdP6jyawX0FtRw=; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=dTxcfkEzPZECiLcADc65k3apTcJak/h/l+nxKifLIS1vRbwmokHLXIGIn5ZkaUMz6gmn1NmxBFPpX+ujwJ0qIy4mP9WjexL8tdRrfMMKffk4qNpEDLcqfBAOUvpxiSQaUWHppP56KH8woQQJlpozti/MPVhgp4sWN9fa+N7DEF0= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com.hk; h=X-YMail-OSG:Received:X-Rocket-MIMEInfo:X-Mailer:Message-ID:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=yo7Mq/pg4IcFuiCij1+3p9mhq7+u9v8XTlzmqrtGm41aDmqWq0GXjMLADBFwVCrvY3uBCl6FpyBMNnyPvMFHVZqtjtV2+yRXXyIgv8pkUT9utqMHg610vEmPjzQpfGw8eZqBe25gBKf1LlLDOsAtsb6GKsrqPrdsE/qpgfzEe3E=; X-YMail-OSG: yYTqhz8VM1kw_zn1ybZblo9AYUgt2E4GC8G0dZhOzKg7k8m tagX90LO9krzPX9brGiwDRVEwd3Q5fqkq7ZIqQxekwWo9iWB0UO9UXR3gsfQ G5OHLtXyQNiWgGdqeoYJVoX6WwHvpOYCWpHNfMy8ngncv.1NELT0GZ3QULqL 3BHvGvDSwSBD2iwf9A04jebZKLKh_V_CPRaGCNQNi87XEkMjiayfstKvIOQZ kyNiQLNsAih_9m5b6HVNip9t9wT15fbU1rXqVyfmt69M9tfzzOBAzPRhsNcR OpswZpWFP50jvmnUr3l80f2XwJrIquwq19ITx.AbHZjVNqfmxU2Egz63ZuI5 c6IiU7mpXHo1reKLosF8qzHEboacgCJdiEX8HTikauicB2AGi6TflIWCkRZ7 G_aHgoSjwLVcmzV_.0d08KqhOUzNPjhWptYPz74Wt84qn157vnGUVgbmxU3s Vl0m1KCF_VxV5fAVswKTSjtOM8SE7uUpB1IUygj4SMCPQ8EJboj2bQjsVEug - Received: from [61.15.240.116] by web190804.mail.sg3.yahoo.com via HTTP; Tue, 08 Jan 2013 01:18:02 SGT X-Rocket-MIMEInfo: 001.001, SGksDQoNClVwZGF0ZWQgaW5mb3JtYXRpb24gaW4gdGhpcyBwb3N0Lg0KDQpJIGhhdmUgaW5zdGFsbGVkIFBvc3RncmVzcWwgOS4yLjIgKGNvbXBsaWVkIGJ5IGdjYykgaW4gRnJlZUJTRCA5LjEgaTM4Ni4NClRoZSBwZ3NxbCBiYXNlIGRpcmVjdG9yeSBpcyBpbiBhIFpGUyBkYXRhc2V0Lg0KDQpJCiBoYXZlIG5vdGljZWQgdGhlIHBlcmZvcm1hbmNlIGlzIHN1Yi1vcHRpbWFsLCBidXQgSSBrbm93IHRoZSBkZWZhdWx0IApzZXR0aW5nIHNob3VsZCBiZSB0aGUgbW9zdCBzYWZlc3Qgb25lIHRvIGJlIHVzZSAod2kBMAEBAQE- X-Mailer: YahooMailClassic/15.1.2 YahooMailWebService/0.8.129.483 Message-ID: <1357579082.78674.YahooMailClassic@web190804.mail.sg3.yahoo.com> Date: Tue, 8 Jan 2013 01:18:02 +0800 (SGT) From: Patrick Dung Subject: Re: Sub optimal performance with default setting of Postgresql with FreeBSD 9.1 on ZFS To: pgsql-performance@postgresql.org In-Reply-To: <1357572772.78036.YahooMailClassic@web190801.mail.sg3.yahoo.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="1490027246-1387116424-1357579082=:78674" X-Pg-Spam-Score: 0.8 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-performance Precedence: bulk Sender: pgsql-performance-owner@postgresql.org --1490027246-1387116424-1357579082=:78674 Content-Type: text/plain; charset=us-ascii Hi, Updated information in this post. I have installed Postgresql 9.2.2 (complied by gcc) 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 setting should be the most safest one to be use (without possible data corruption/loss). 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=disabled mydata/pgsql or 2) In postgresql.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=metadata/none, it do not 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 same 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 disabled). Thanks, Patrick --- On Mon, 1/7/13, Patrick Dung wrote: From: Patrick Dung Subject: Sub optimal performance with default setting of Postgresql with FreeBSD 9.1 on ZFS To: pgsql-performance@postgresql.org Date: Monday, January 7, 2013, 11:32 PM Hi, I have installed Postgresql 9.2.2 (complied by gcc) 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 setting should be the most safest one to be use (without possible data corruption/loss). a) I use OTRS ticketing system, 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=disabled mydata/pgsql or 2) In postgresql.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=metadata/none, it do not seem to help. 2) I have tried the default setting on Linux too: RHEL 6.3, stock postgresql 8.x, OTRS 3.1. The web site is responsive and the benchmark result is more or less the same as FreeBSD with the 'sync' turned off. Thanks, Patrick --1490027246-1387116424-1357579082=:78674 Content-Type: text/html; charset=us-ascii
Hi,

Updated information in this post.

I have installed Postgresql 9.2.2 (complied by gcc) 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 setting should be the most safest one to be use (without possible data corruption/loss).

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=disabled mydata/pgsql
or
2) In postgresql.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=metadata/none, it do not 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 same 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 disabled).

Thanks,
Patrick

--- On Mon, 1/7/13, Patrick Dung <patrick_dkt@yahoo.com.hk> wrote:

From: Patrick Dung <patrick_dkt@yahoo.com.hk>
Subject: Sub optimal performance with default setting of Postgresql with FreeBSD 9.1 on ZFS
To: pgsql-performance@postgresql.org
Date: Monday, January 7, 2013, 11:32 PM

Hi,

I have installed Postgresql 9.2.2 (complied by gcc) 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 setting should be the most safest one to be use (without possible data corruption/loss).

a) I use OTRS ticketing system, 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=disabled mydata/pgsql
or
2) In postgresql.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=metadata/none, it do not seem to help.

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

Thanks,
Patrick
--1490027246-1387116424-1357579082=:78674--