From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Michael Paquier <michael.paquier@gmail.com>
To: Jason Petersen <jason@citusdata.com>
Cc: PostgreSQL mailing lists <pgsql-bugs@postgresql.org>
Subject: Re: Concurrent ALTER SEQUENCE RESTART Regression
Date: Tue, 25 Apr 2017 15:17:39 -0400
Message-ID: <16ed823b-44e4-dc51-3da9-a3d66b71ed5c@2ndquadrant.com> (raw)
In-Reply-To: <CAB7nPqRev_wK4k39hQBpQZRQ17v29guxfobnnmTYT_-hUU67BA@mail.gmail.com>
References: <D992B4C2-8F80-4DE0-8348-6E0696C3F967@citusdata.com>
<CAB7nPqRUXMvo5xy9cLFyhuHErN9WVCckuKaUbJpxPGBzxqVFdw@mail.gmail.com>
<CAB7nPqRev_wK4k39hQBpQZRQ17v29guxfobnnmTYT_-hUU67BA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
On 4/25/17 00:26, Michael Paquier wrote:
> So things are broken for sequences since commit 1753b1b0 (adding Peter
> in CC) that has changed the way sequence metadata is handled. The
> failure happens in CatalogTupleUpdate() which uses
> simple_heap_update() that caller can only use if updates are
> concurrent safe. But since 1753b1b0 that is not true as the sequence
> is locked with AccessShareLock.
I think you are confusing locking the sequence versus locking the
pg_sequence catalog. The error is coming from CatalogTupleUpdate() on
pg_sequence, which is locked using RowExclusiveLock, which is what we
use for most DDL commands doing catalog changes.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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-bugs@postgresql.org
Cc: peter.eisentraut@2ndquadrant.com, michael.paquier@gmail.com, jason@citusdata.com
Subject: Re: Concurrent ALTER SEQUENCE RESTART Regression
In-Reply-To: <16ed823b-44e4-dc51-3da9-a3d66b71ed5c@2ndquadrant.com>
References: <D992B4C2-8F80-4DE0-8348-6E0696C3F967@citusdata.com> <CAB7nPqRUXMvo5xy9cLFyhuHErN9WVCckuKaUbJpxPGBzxqVFdw@mail.gmail.com> <CAB7nPqRev_wK4k39hQBpQZRQ17v29guxfobnnmTYT_-hUU67BA@mail.gmail.com> <16ed823b-44e4-dc51-3da9-a3d66b71ed5c@2ndquadrant.com>
* 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