pg.ddx.io pgsql-committers@postgresql.org mailing list archivehelp / color / mirror / Atom feed
pgsql: Don't MultiXactIdIsRunning when in recovery 3+ messages / 1 participants [nested] [flat]
* pgsql: Don't MultiXactIdIsRunning when in recovery @ 2015-05-18 20:44 Alvaro Herrera <alvherre@alvh.no-ip.org> 0 siblings, 0 replies; 3+ messages in thread From: Alvaro Herrera @ 2015-05-18 20:44 UTC (permalink / raw) To: pgsql-committers Don't MultiXactIdIsRunning when in recovery In 9.1 and earlier, it is possible for index_getnext() to try to examine a heap buffer for possible HOT-prune when in recovery; this causes a problem when a multixact is found in a tuple's Xmax, because GetMultiXactIdMembers refuses to run when in recovery, raising an error: ERROR: cannot GetMultiXactIdMembers() during recovery This can be solved easily by having MultiXactIdIsRunning always return false when in recovery, which is reasonable because a HOT standby cannot acquire further tuple locks nor update/delete tuples. (Note: it doesn't look like this specific code path has a problem in 9.2, because instead of doing HeapTupleSatisfiesUpdate directly, heap_hot_search_buffer uses HeapTupleIsSurelyDead instead. Still, there may be other paths affected by the same bug, for instance in pgrowlocks, and the multixact code hasn't changed; so apply the same fix throughout.) Apply this fix to 9.0 through 9.2. In 9.3 the multixact code has been changed completely and is no longer subject to this problem. Per report from Marko Tiikkaja, https://www.postgresql.org/message-id/54EB3283.2080305@joh.to Analysis by Andres Freund Branch ------ REL9_2_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/97ff2a5645227d73c222373832ffb3bf9470ca73 Modified Files -------------- src/backend/access/transam/multixact.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 3+ messages in thread
* pgsql: Don't MultiXactIdIsRunning when in recovery @ 2015-05-18 20:44 Alvaro Herrera <alvherre@alvh.no-ip.org> 0 siblings, 0 replies; 3+ messages in thread From: Alvaro Herrera @ 2015-05-18 20:44 UTC (permalink / raw) To: pgsql-committers Don't MultiXactIdIsRunning when in recovery In 9.1 and earlier, it is possible for index_getnext() to try to examine a heap buffer for possible HOT-prune when in recovery; this causes a problem when a multixact is found in a tuple's Xmax, because GetMultiXactIdMembers refuses to run when in recovery, raising an error: ERROR: cannot GetMultiXactIdMembers() during recovery This can be solved easily by having MultiXactIdIsRunning always return false when in recovery, which is reasonable because a HOT standby cannot acquire further tuple locks nor update/delete tuples. (Note: it doesn't look like this specific code path has a problem in 9.2, because instead of doing HeapTupleSatisfiesUpdate directly, heap_hot_search_buffer uses HeapTupleIsSurelyDead instead. Still, there may be other paths affected by the same bug, for instance in pgrowlocks, and the multixact code hasn't changed; so apply the same fix throughout.) Apply this fix to 9.0 through 9.2. In 9.3 the multixact code has been changed completely and is no longer subject to this problem. Per report from Marko Tiikkaja, https://www.postgresql.org/message-id/54EB3283.2080305@joh.to Analysis by Andres Freund Branch ------ REL9_1_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/2360eea3be67fb9650067817a4e50fc2f1b8cff7 Modified Files -------------- src/backend/access/transam/multixact.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 3+ messages in thread
* pgsql: Don't MultiXactIdIsRunning when in recovery @ 2015-05-18 20:44 Alvaro Herrera <alvherre@alvh.no-ip.org> 0 siblings, 0 replies; 3+ messages in thread From: Alvaro Herrera @ 2015-05-18 20:44 UTC (permalink / raw) To: pgsql-committers Don't MultiXactIdIsRunning when in recovery In 9.1 and earlier, it is possible for index_getnext() to try to examine a heap buffer for possible HOT-prune when in recovery; this causes a problem when a multixact is found in a tuple's Xmax, because GetMultiXactIdMembers refuses to run when in recovery, raising an error: ERROR: cannot GetMultiXactIdMembers() during recovery This can be solved easily by having MultiXactIdIsRunning always return false when in recovery, which is reasonable because a HOT standby cannot acquire further tuple locks nor update/delete tuples. (Note: it doesn't look like this specific code path has a problem in 9.2, because instead of doing HeapTupleSatisfiesUpdate directly, heap_hot_search_buffer uses HeapTupleIsSurelyDead instead. Still, there may be other paths affected by the same bug, for instance in pgrowlocks, and the multixact code hasn't changed; so apply the same fix throughout.) Apply this fix to 9.0 through 9.2. In 9.3 the multixact code has been changed completely and is no longer subject to this problem. Per report from Marko Tiikkaja, https://www.postgresql.org/message-id/54EB3283.2080305@joh.to Analysis by Andres Freund Branch ------ REL9_0_STABLE Details ------- http://git.postgresql.org/pg/commitdiff/850e1a566eb68b32df240c49843ac498603a11c8 Modified Files -------------- src/backend/access/transam/multixact.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) -- Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-committers ^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2015-05-18 20:44 UTC | newest] Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2015-05-18 20:44 pgsql: Don't MultiXactIdIsRunning when in recovery Alvaro Herrera <alvherre@alvh.no-ip.org> 2015-05-18 20:44 pgsql: Don't MultiXactIdIsRunning when in recovery Alvaro Herrera <alvherre@alvh.no-ip.org> 2015-05-18 20:44 pgsql: Don't MultiXactIdIsRunning when in recovery Alvaro Herrera <alvherre@alvh.no-ip.org>
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