From: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com> |
---|---|
To: | Simon Riggs <simon(at)2ndquadrant(dot)com> |
Cc: | Bruce Momjian <bruce(at)momjian(dot)us>, Rahila Syed <rahilasyed(dot)90(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Compression of full-page-writes |
Date: | 2014-06-02 12:44:27 |
Message-ID: | CAHGQGwEEFYYq=MTsv9-irdpy8+DWxyLABvfS5KeYZ49DGuiqYg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, May 29, 2014 at 7:21 PM, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
> On 29 May 2014 01:07, Bruce Momjian <bruce(at)momjian(dot)us> wrote:
>> On Wed, May 28, 2014 at 04:04:13PM +0100, Simon Riggs wrote:
>>> On 28 May 2014 15:34, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>>>
>>> >> Also, compress_backup_block GUC needs to be merged with full_page_writes.
>>> >
>>> > Basically I agree with you because I don't want to add new GUC very similar to
>>> > the existing one.
>>> >
>>> > But could you imagine the case where full_page_writes = off. Even in this case,
>>> > FPW is forcibly written only during base backup. Such FPW also should be
>>> > compressed? Which compression algorithm should be used? If we want to
>>> > choose the algorithm for such FPW, we would not be able to merge those two
>>> > GUCs. IMO it's OK to always use the best compression algorithm for such FPW
>>> > and merge them, though.
>>>
>>> I'd prefer a new name altogether
>>>
>>> torn_page_protection = 'full_page_writes'
>>> torn_page_protection = 'compressed_full_page_writes'
>>> torn_page_protection = 'none'
>>>
>>> this allows us to add new techniques later like
>>>
>>> torn_page_protection = 'background_FPWs'
>>>
>>> or
>>>
>>> torn_page_protection = 'double_buffering'
>>>
>>> when/if we add those new techniques
>>
>> Uh, how would that work if you want to compress the background_FPWs?
>> Use compressed_background_FPWs?
>
> We've currently got 1 technique for torn page protection, soon to have
> 2 and with a 3rd on the horizon and likely to receive effort in next
> release.
>
> It seems sensible to have just one parameter to describe the various
> techniques, as suggested. I'm suggesting that we plan for how things
> will look when we have the 3rd one as well.
>
> Alternate suggestions welcome.
Is even compression of double buffer worthwhile? If yes, what about separating
the GUC parameter into torn_page_protection and something like
full_page_compression? ISTM that any combination of settings of those parameters
can work.
torn_page_protection = 'FPW', 'background FPW', 'none', 'double buffer'
full_page_compression = 'no', 'pglz', 'lz4', 'snappy'
Regards,
--
Fujii Masao
From | Date | Subject | |
---|---|---|---|
Next Message | ash | 2014-06-02 12:52:06 | Re: Re-create dependent views on ALTER TABLE ALTER COLUMN ... TYPE? |
Previous Message | Fujii Masao | 2014-06-02 12:34:10 | Re: Spreading full-page writes |