Re: Proposal for 9.1: WAL streaming from WAL buffers

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Stefan Kaltenbrunner <stefan(at)kaltenbrunner(dot)cc>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Proposal for 9.1: WAL streaming from WAL buffers
Date: 2010-06-15 05:16:38
Message-ID: 4C170CB6.4060904@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 15/06/10 07:47, Fujii Masao wrote:
> On Tue, Jun 15, 2010 at 12:02 AM, Tom Lane<tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Fujii Masao<masao(dot)fujii(at)gmail(dot)com> writes:
>>> Walsender tries to send WAL up to xlogctl->LogwrtResult.Write. OTOH,
>>> xlogctl->LogwrtResult.Write is updated after XLogWrite() performs fsync.
>>
>> Wrong. LogwrtResult.Write tracks how far we've written out data,
>> but it is only (known to be) fsync'd as far as LogwrtResult.Flush.
>
> Hmm.. I agree that xlogctl->LogwrtResult.Write indicates the byte position
> we've written. But in the current XLogWrite() code, it's updated after
> XLogWrite() calls issue_xlog_fsync(). No?

issue_xlog_fsync() is only called if the caller requested a flush by
advancing WriteRqst.Flush.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2010-06-15 05:23:32 Re: InvalidXLogRecPtr in docs
Previous Message Takahiro Itagaki 2010-06-15 05:09:54 GUC category cleanup (was: vacuum_defer_cleanup_age)