Received: from localhost (maia-5.hub.org [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 9A8309FB60A for ; Mon, 9 Jul 2007 17:53:16 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 21878-07 for ; Mon, 9 Jul 2007 17:53:09 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from noel.decibel.org (noel.decibel.org [67.100.216.10]) by postgresql.org (Postfix) with ESMTP id A0E449FBB70 for ; Mon, 9 Jul 2007 17:53:12 -0300 (ADT) Received: by noel.decibel.org (Postfix, from userid 1001) id 9E6EB564CF; Mon, 9 Jul 2007 15:53:11 -0500 (CDT) Received: (hashcash-sendmail, from uid 1001); Mon, 9 Jul 2007 15:53:08 -0500 Date: Mon, 9 Jul 2007 15:53:08 -0500 From: "Jim C. Nasby" To: "Jignesh K. Shah" Cc: Heikki Linnakangas , pgsql-performance@postgresql.org Subject: Re: PostgreSQL publishes first real benchmark Message-ID: <20070709205307.GP39272@nasby.net> References: <46925AD9.9020208@sun.com> <469261EC.7080106@enterprisedb.com> <469274FC.8000506@sun.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="H4SyuGOnfnj3aJqJ" Content-Disposition: inline In-Reply-To: <469274FC.8000506@sun.com> X-Operating-System: FreeBSD 6.1-RELEASE-p10 amd64 X-Distributed: Join the Effort! http://www.distributed.net User-Agent: Mutt/1.5.13 (2006-08-11) X-Hashcash: 1:20:070709:j.k.shah@sun.com::zVecnhNjzRU6oyxJ:00Y66 X-Hashcash: 1:20:070709:heikki@enterprisedb.com::zCKWztnqTm8mMjMs:00000000000000 000000000000000000000000CSRk X-Hashcash: 1:20:070709:pgsql-performance@postgresql.org::TnJeSez3Lc306eXU:00000 0000000000000000000000001v/z X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200707/70 X-Sequence-Number: 25754 --H4SyuGOnfnj3aJqJ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Jul 09, 2007 at 01:48:44PM -0400, Jignesh K. Shah wrote: >=20 > Hi Heikki, >=20 > Heikki Linnakangas wrote: > > > >That's really exciting news! > > > >I'm sure you spent a lot of time tweaking the settings, so let me ask=20 > >you something topical: > > > >How did you end up with the bgwriter settings you used? Did you=20 > >experiment with different values? How much difference did it make? > > >=20 > Background writer is still a pain to get it right.. I say it is a=20 > necessary evil since you are trying to balance it with trying to level=20 > writes to the disks and lock contentions caused by the writer itself to= =20 > the postgresql connections. Our typical problem will arise at the high=20 > number of users where all users are suddenly locked due to the bgwriter= =20 > holding the locks.. Using the hotuser script (which uses pearl/Dtrace=20 > combination) we ran quite a bit of numbers trying to see which ones=20 > results in less overall time spent in PGLock* calls and yet gave good= =20 > uniform writes to the disks. After reaching the published settings, =20 > everynow and then we would try playing with different values to see if=20 > it improves but generally seemed to degrade if changed.. (Of course your= =20 > mileage will vary depending on config, workload, etc). >=20 > Still I believe the locking mechanism needs to be revisited at some=20 > point since that seems to be the one which will eventually limit the=20 > number of users in such a workload. (Specially if you dont hit the right= =20 > settings for your workload) Do you know specifically what locks were posing the problem? I have a theory that having individual backends run the clock sweep limits concurrency and I'm wondering if you were seeing any of that. The lock in question would be BufFreelistLock. --=20 Jim Nasby decibel@decibel.org EnterpriseDB http://enterprisedb.com 512.569.9461 (cell) --H4SyuGOnfnj3aJqJ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.3 (FreeBSD) iD8DBQFGkqAzdO30qud8SkgRAjq3AKDkExYS8/ndi4rfdblETod9lPtziACdFwB+ c2RSUOXpYhMt2zTIHiF7ngQ= =7dV5 -----END PGP SIGNATURE----- --H4SyuGOnfnj3aJqJ--