pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Kevin Grittner <kgrittn@ymail.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: brin index vacuum versus transaction snapshots
Date: Thu, 30 Jul 2015 17:01:40 -0300
Message-ID: <20150730200140.GV2441@postgresql.org> (raw)
In-Reply-To: <185774103.1833212.1437507758024.JavaMail.yahoo@mail.yahoo.com>
References: <185774103.1833212.1437507758024.JavaMail.yahoo@mail.yahoo.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

Kevin Grittner wrote:
> If you run `make installcheck` against a cluster with
> default_transaction_isolation = 'repeatable read' you get one
> failure:

I am tempted to say that we should just disallow to run vacuum on a
table containing a brin index in a transaction-snapshot transaction.
It is possible to silence the problem by checking for vacuum flags, but
(without testing) I think there will be a problem because the snapshot
is acquired too early and it is possible for concurrent transactions to
insert tuples in the table that the summarizing scan will not see, which
will cause the index to become effectively corrupt.

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (20+ messages)  latest in thread

Message-ID: <20150730200140.GV2441@postgresql.org>
Permalink:  ../20150730200140.GV2441@postgresql.org/
Also on:    postgresql.org/message-id/20150730200140.GV2441@postgresql.org

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: alvherre@2ndquadrant.com, kgrittn@ymail.com
  Subject: Re: brin index vacuum versus transaction snapshots
  In-Reply-To: <20150730200140.GV2441@postgresql.org>
  References: <185774103.1833212.1437507758024.JavaMail.yahoo@mail.yahoo.com> <20150730200140.GV2441@postgresql.org>

* 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