From: ktm@rice.edu <ktm@rice.edu>
To: Anne Rosset <arosset@collab.net>
Cc: pgsql-performance@postgresql.org <pgsql-performance@postgresql.org>
Subject: Re: Deterioration in performance when query executed in multi threads
Date: Wed, 1 May 2013 09:12:36 -0500
Message-ID: <20130501141236.GG27807@aart.rice.edu> (raw)
In-Reply-To: <9A6B86D66BD3C2438AFACFA09354890F20A2DF6D@EXCH01.sp.corp.collab.net>
References: <9A6B86D66BD3C2438AFACFA09354890F20A2DF6D@EXCH01.sp.corp.collab.net>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-performance>
On Wed, May 01, 2013 at 02:05:06PM +0000, Anne Rosset wrote:
> Hi all,
> We are running a stress test that executes one select query with multiple threads.
> The query executes very fast (10ms). It returns 100 rows. I see deterioration in the performance when we have multiple threads executing the query. With 100 threads, the query takes between 3s and 8s.
>
> I suppose there is a way to tune our database. What are the parameters I should look into? (shared_buffer?, wal_buffer?)
>
> Thanks for your help,
> Anne
Try a connection pooler like pgbouncer to keep the number of simultaneous queries
bounded to a reasonable number. You will actually get better performance.
Regards,
Ken
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: ktm@rice.edu, arosset@collab.net
Subject: Re: Deterioration in performance when query executed in multi threads
In-Reply-To: <20130501141236.GG27807@aart.rice.edu>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox