From: Bruce Momjian <bruce@momjian.us>
To: Pavan Deolasee <pavan.deolasee@gmail.com>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Patch: Write Amplification Reduction Method (WARM)
Date: Wed, 31 Aug 2016 16:11:38 -0400
Message-ID: <20160831201138.GD31352@momjian.us> (raw)
In-Reply-To: <20160831200329.GC31352@momjian.us>
References: <CABOikdMNy6yowA+wTGK9RVd8iw+CzqHeQSGpW7Yka_4RSZ_LOQ@mail.gmail.com>
<20160831200329.GC31352@momjian.us>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
On Wed, Aug 31, 2016 at 04:03:29PM -0400, Bruce Momjian wrote:
> Why not just remember the tid of chains converted from WARM to HOT, then
> use "amrecheck" on an index entry matching that tid to see if the index
> matches one of the entries in the chain. (It will match all of them or
> none of them, because they are all red.) I don't see a point in
> coloring the index entries as reds as later you would have to convert to
> blue in the WARM-to-HOT conversion, and a vacuum crash could lead to
> inconsistencies. Consider that you can just call "amrecheck" on the few
> chains that have converted from WARM to HOT. I believe this is more
> crash-safe too. However, if you have converted WARM to HOT in the heap,
> but crash during the index entry removal, you could potentially have
> duplicates in the index later, which is bad.
I think Pavan had the "crash durin the index entry removal" fixed via:
> During the second heap scan, we fix WARM chain by clearing HEAP_WARM_TUPLE flag
> and also reset Red flag to Blue.
so the marking from WARM to HOT only happens after the index has been cleaned.
--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ As you are, so once was I. As I am, so you will be. +
+ Ancient Roman grave inscription +
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: bruce@momjian.us, pavan.deolasee@gmail.com
Subject: Re: Patch: Write Amplification Reduction Method (WARM)
In-Reply-To: <20160831201138.GD31352@momjian.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox