Skip site navigation (1) Skip section navigation (2)

Re: [PERFORMANCE] how to set wal_buffers

From: Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec>
To: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: [PERFORMANCE] how to set wal_buffers
Date: 2009-08-25 20:16:40
Message-ID: 3073cc9b0908251316y4684b1f3kddcf629a183af366@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-performance
On Sun, Aug 23, 2009 at 5:26 PM, Jeff Janes<jeff(dot)janes(at)gmail(dot)com> wrote:
>>>
>>> One problem is as you note.  How is the average user supposed to know
>>> what is the size of the redo that is generated by a typical
>>> transaction?
>>>
>>
>> one way is if there is a way to know how many blocks have been written
>> by postgres (even a total is usefull because we can divide that per
>> pg_stat_database.xact_commits), maybe
>> pg_stat_bgwriter.buffers_checkpoint can give us an idea of that?
>
> No, you want the amount of WAL data written, not the tablespace data written,
> which is what pg_stat_bgwriter gives you.  Just look at how fast your pg_xlogs
> are being archived and turned over to determine that WAL volume (unless you
> have archive_timeout set).

mmm... what about turning log_checkpoint on and look at the recycled
segments number...
(recycled_segments * wal_segment_size) / number of xact commited in that period

do that for some days at the same (hopefully peak) hours...

>
> maybe the code bracketed by the probes
> TRACE_POSTGRESQL_WAL_BUFFER_WRITE_DIRTY* should be counted
> and reported under one of the stat tables.
>

+1, at least could be useful for some of us that do not have dtrace

-- 
Atentamente,
Jaime Casanova
Soporte y capacitación de PostgreSQL
Asesoría y desarrollo de sistemas
Guayaquil - Ecuador
Cel. +59387171157

In response to

pgsql-performance by date

Next:From: Matthew WakelingDate: 2009-08-26 14:07:45
Subject: Re: Fwd: How to create a multi-column index with 2 dates using 'gist'?
Previous:From: Sam MasonDate: 2009-08-25 11:57:50
Subject: Re: How to create a multi-column index with 2 dates using 'gist'?

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group