Re: Simulating Clog Contention

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Simulating Clog Contention
Date: 2012-01-28 20:32:15
Message-ID: CAMkU=1w6vUHMG5gjSaR_xtK43WpB6awDfXN5Rb9ca2C0MgGmxw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 27, 2012 at 1:45 PM, Jeff Janes <jeff(dot)janes(at)gmail(dot)com> wrote:
> On Thu, Jan 12, 2012 at 4:31 AM, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
>
>> The following patch adds a pgbench option -I to load data using
>> INSERTs, so that we can begin benchmark testing with rows that have
>> large numbers of distinct un-hinted transaction ids. With a database
>> pre-created using this we will be better able to simulate and thus
>> more easily measure clog contention. Note that current clog has space
>> for 1 million xids, so a scale factor of greater than 10 is required
>> to really stress the clog.
>
> Running with this patch with a non-default scale factor generates the
> spurious notice:
>
> "Scale option ignored, using pgbench_branches table count = 10"
>
> In fact the scale option is not being ignored, because it was used to
> initialize the pgbench_branches table count earlier in this same
> invocation.
>
> I think that even in normal (non-initialization) usage, this message
> should be suppressed when the provided scale factor
> is equal to the pgbench_branches table count.

The attached patch does just that. There is probably no reason to
warn people that we are doing what they told us to, but not for the
reason they think.

I think this change makes sense regardless of the disposition of the
thread topic.

Cheers,

Jeff

Attachment Content-Type Size
pgbench_scale.patch application/octet-stream 1.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Heikki Linnakangas 2012-01-28 20:44:32 Re: 16-bit page checksums for 9.2
Previous Message Kohei KaiGai 2012-01-28 19:20:58 Re: [v9.2] Add GUC sepgsql.client_label