Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 9CA80133798E for ; Sun, 1 May 2011 08:20:24 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 58216-10 for ; Sun, 1 May 2011 11:20:17 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-fx0-f46.google.com (mail-fx0-f46.google.com [209.85.161.46]) by mail.postgresql.org (Postfix) with ESMTP id A1DF51337B47 for ; Sun, 1 May 2011 08:20:15 -0300 (ADT) Received: by fxm17 with SMTP id 17so3250031fxm.19 for ; Sun, 01 May 2011 04:20:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:date:message-id:subject:from:to :content-type; bh=0Rri0pK2n0NlrQwnDUa0x37+qEozF0f87Vb3Q8K67Fs=; b=fdaaWdUEpEPMKtp3LfRcKwIiF4nSLHTPjArUx5em2uwsNv1VRYGz8SMhAGjIvWJZC8 1YxYmzmhNCZTPT+S3K1jCK7opicAyFCfghWHIEzJMWtuIx5hIGReVHkz5UVx7ALYdD+y PVU0M/djSfd0ccio8hreMau1JFYCBzArM5YlI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=DSBMJeNUlBcdupETFxqRq/POuOcmIELDLUS5J1UKtMJY/sbi1DXF1JCGipc5g+CJuQ iPGymlB2iYDrBgLYXGbJfJ2XSp8eoPNP8I8mk5SWDmxvyyzBL82ej/YRknj8f7dHZo5t L78vMjWy4w7s1R4IGZWX2YyZyhL9CZEvh7Ib4= MIME-Version: 1.0 Received: by 10.223.103.13 with SMTP id i13mr2304687fao.50.1304248815139; Sun, 01 May 2011 04:20:15 -0700 (PDT) Received: by 10.223.98.88 with HTTP; Sun, 1 May 2011 04:20:15 -0700 (PDT) Date: Sun, 1 May 2011 12:20:15 +0100 Message-ID: Subject: Option shared_buffers in PostgreSQL From: Javier Reyes To: pgsql-admin@postgresql.org Content-Type: multipart/alternative; boundary=20cf3054a6e5533b1404a23517cd X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.887 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RFC_ABUSE_POST=0.001, T_TO_NO_BRKTS_FREEMAIL=0.01 X-Spam-Level: X-Archive-Number: 201105/1 X-Sequence-Number: 37438 --20cf3054a6e5533b1404a23517cd Content-Type: text/plain; charset=ISO-8859-1 Hello. I have a server with 4GB of RAM and PostgreSQL 9.0.3 on Centos 5. I'm using pgbench and pgbench-tools to measure performance, using two pgbench-tools queries: select and tpc-b. With default settings of postgresql.conf and select query, I get the following results: Scale: 1, 10, 100, 1000. Transactions per second: 10000, 8800, 7500, 100. (the number of records of the table is scale*100000) I've only increased the option shared_buffer to 256MB (previously had 32 MB) and I get the following results: Scale: 1, 10, 100, 1000. Transactions per second: 10000, 8000, 3200, 30 I don't understand why when the scale is 100 or more in the second benchmark, the performance is so low compared to the first test. The only thing I have done was increase the memory. I've thrown every test twice and the results were similar. In an earlier test, the memory configuration was: shared_buffers = 512 MB maintenance_work_mem = 8MB effective_cache_size = 1GB work_mem = 2MB And the results were similar, even slightly worse. For that reason, I did tests changing options one by one, to know what was the cause of poor performance. And "the winner" is shared_buffers... Thanks. --20cf3054a6e5533b1404a23517cd Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hello.

I have a server with 4GB of RAM and PostgreSQL 9.0.3 on Cento= s 5. I'm using pgbench and pgbench-tools to measure performance, using = two pgbench-tools queries: select and tpc-b.

With default settings o= f postgresql.conf and select query, I get the following results:

Scale: 1, 10, 100, 1000.
Transactions per second: 10000, 8800, 7500,= 100.

(the number of records of the table is scale*100000)

I&= #39;ve only increased the option shared_buffer to 256MB (previously had 32 = MB) and I get the following results:

Scale: 1, 10, 100, 1000.
Transactions per second: 10000, 8000, 3200,= 30

I don't understand why when the scale is 100 or more in the = second benchmark, the performance is so low compared to the first test. The= only thing I have done was increase the memory.

I've thrown every test twice and the results were similar. In an ea= rlier test, the memory configuration was:

shared_buffers =3D 512 MB=
maintenance_work_mem =3D 8MB
effective_cache_size =3D 1GB
work_m= em =3D 2MB

And the results were similar, even slightly worse. For that reason, I d= id tests changing options one by one, to know what was the cause of poor pe= rformance. And "the winner" is shared_buffers...

Thanks. --20cf3054a6e5533b1404a23517cd--