Re: BUG #9161: wal_writer_delay is limited to 10s - Mailing list pgsql-bugs

From Clemens Eisserer
Subject Re: BUG #9161: wal_writer_delay is limited to 10s
Date
Msg-id CAFvQSYT65aeC+-KnC7PihZ8GZ6n8OnLLqU1j9weBOV46v-iH3A@mail.gmail.com
Whole thread Raw
In response to Re: BUG #9161: wal_writer_delay is limited to 10s  (Jeff Janes <jeff.janes@gmail.com>)
Responses Re: BUG #9161: wal_writer_delay is limited to 10s
List pgsql-bugs
Hi Jeff,

>> > That only happens if an 8 KB boundary has been crossed.  Depending on
>> > how
>> > big the records are that he is inserting, you can fit a lot of them in 8
>> > KB.   If the records are small, or the table us unlogged so only commit
>> > messages get logged, then you could go many multiples of 10s without
>> > triggering a wake up due to crossing an 8 KB boundary.

Thanks a lot for the in-depth information.
Is the 8KB boundary configureable at compile time?

> /* if we have already flushed that far, consider async commit records */
>
> For this purpose, async commit could mean either commits down with
> synchronous_commit=off, or commits of transactions which touched only
> unlogged tables.  So it writes the same 8kb block as last time (but with new
> data at the logical end of the block) and flushes it.

Ah, that explains why my experiments using unlogged tables also
weren't sucessful in avoiding the frequent writes.

Regards, Clemens

pgsql-bugs by date:

Previous
From: Joshua Yanovski
Date:
Subject: Re: BUG #9227: Error on SELECT ROW OVERLAPS ROW with single ROW argument
Next
From: Tom Lane
Date:
Subject: Re: BUG #9227: Error on SELECT ROW OVERLAPS ROW with single ROW argument