From: | Simon Riggs <simon(at)2ndquadrant(dot)com> |
---|---|
To: | Jeff Janes <jeff(dot)janes(at)gmail(dot)com> |
Cc: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Pavan Deolasee <pavan(dot)deolasee(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: PANIC in pg_commit_ts slru after crashes |
Date: | 2017-04-18 10:05:50 |
Message-ID: | CANP8+j+Era0AS57QPqL-7pD0mvsg0CoEzPsDvUGSqdCQ49JJjQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 18 April 2017 at 09:51, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
> On 17 April 2017 at 16:33, Jeff Janes <jeff(dot)janes(at)gmail(dot)com> wrote:
>> On Sun, Apr 16, 2017 at 6:59 PM, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
>> wrote:
>>>
>>>
>>>
>>> Jeff, does this patch make the situation better? The fix is rather
>>> simple as it just makes sure that the next XID never gets updated if
>>> there are no 2PC files.
>>
>>
>> Yes, that fixes the reported case when 2PC are not being used.
>
> Thanks Jeff.
>
> I certainly prefer the simplicity of Michael's approach. I'll move to commit.
Minor change to patch.
I've added a recheck in ProcessTwoPhaseBuffer() after we acquire the lock.
If its worth acquiring the lock its worth checking we don't have a race.
--
Simon Riggs http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Attachment | Content-Type | Size |
---|---|---|
2pc-restore-fix.v2.patch | application/octet-stream | 5.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Fabien COELHO | 2017-04-18 10:06:19 | Re: Other formats in pset like markdown, rst, mediawiki |
Previous Message | Masahiko Sawada | 2017-04-18 10:02:07 | Re: Quorum commit for multiple synchronous replication. |