Re: Redesigning checkpoint_segments

From: David Steele <david(at)pgmasters(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Redesigning checkpoint_segments
Date: 2015-02-05 22:45:29
Message-ID: 54D3F289.2080505@pgmasters.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2/5/15 4:53 PM, Josh Berkus wrote:
>> Actually, perhaps we should have a boolean setting that just implies
>> min=max, instead of having a configurable minimum?. That would cover all
>> of those reasons pretty well. So we would have a "max_wal_size" setting,
>> and a boolean "preallocate_all_wal = on | off". Would anyone care for
>> the flexibility of setting a minimum that's different from the maximum?
> I do, actually. Here's the case I want it for:
>
> I have a web application which gets all of its new data as uncoordinated
> batch updates from customers. Since it's possible for me to receive
> several batch updates at once, I set max_wal_size to 16GB, roughtly the
> side of 8 batch updates. But I don't want the WAL that big all the time
> because it slows down backup snapshots. So I set min_wal_size to 2GB,
> roughly the size of one batch update.
>
> That's an idiosyncratic case, but I can imagine more of them out there.
>
> I wouldn't be opposed to min_wal_size = -1 meaning "same as
> max_wal_size" though.

+1 for min_wal_size. Like Josh, I can think of instances where this
would be good.

--
- David Steele
david(at)pgmasters(dot)net

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Dan Langille 2015-02-05 22:53:42 HEADS UP: PGCon 2015 major schedule changes
Previous Message Josh Berkus 2015-02-05 21:53:33 Re: Redesigning checkpoint_segments