From: | Andres Freund <andres(at)2ndquadrant(dot)com> |
---|---|
To: | pgsql-bugs(at)postgresql(dot)org |
Cc: | Valentine Gogichashvili <valgog(at)gmail(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com> |
Subject: | Re: BUG #6661: out-of-order XID insertion in KnownAssignedXids |
Date: | 2012-06-08 11:40:45 |
Message-ID: | 201206081340.45246.andres@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
Hi All,
On Friday, June 08, 2012 12:42:00 PM Andres Freund wrote:
> On Friday, June 08, 2012 12:25:25 PM Valentine Gogichashvili wrote:
> > unfortunately I did not manage to keep the snapshot of the database, that
> > had this issue.
Ok, after some playing I could reproduce the issue:
master:
S1: CREATE FUNCTION insertone() RETURNS void LANGUAGE plpgsql AS $$BEGIN
INSERT INTO data(data) VALUES (random()); EXCEPTION WHEN division_by_zero THEN
RAISE NOTICE 'huh'; END;$$;
S1: BEGIN;
S1: SELECT insertone() FROM generate_series(1, 1000); --subxid overflow
S2: BEGIN;
S2: SELECT insertone(); --allocate xid
standby:
pg_basebackup
LOG: 00000: consistent recovery state reached at 0/5C0001C0
LOG: 00000: recovery snapshot waiting for non-overflowed snapshot or until
oldest active xid on standby is at least 4752 (now 3750)
master:
S1: commit:
S3: checkpoint;
standby:
before patch:
crash in assert/elog
after:
LOG: 00000: recovery snapshots are now enabled
So I can confirm the above patch fixes at least that bug.
Andres
--
Andres Freund http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Craig Ringer | 2012-06-08 13:56:13 | Re: BUG #6678: error in connecting to Pgadmin |
Previous Message | mitzanu | 2012-06-08 10:55:50 | BUG #6679: Can't connect via JDBC Driver |