Deadlock in multiple CIC.
Jeff Janes <jeff.janes@gmail.com>
From: Jeff Janes <jeff.janes@gmail.com>
To: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2017-12-26T05:31:02Z
Lists: pgsql-hackers
Attachments
- CIC_deadlock.patch (text/x-patch) patch
c3d09b3bd23f5f6 fixed it so concurrent CIC would not deadlock (or at least not as reliably as before) by dropping its own snapshot before waiting for all the other ones to go away. With commit 8aa3e47510b969354ea02a, concurrent CREATE INDEX CONCURRENTLY on different tables in the same database started deadlocking against each other again quite reliably. I think the solution is simply to drop the catalog snapshot as well, as in the attached. reported by Jeremy Finzel here: https://www.postgresql.org/message-id/flat/CAMa1XUhHjCv8Qkx0WOr1Mpm_R4qxN26EibwCrj0Oor2YBUFUTg%40mail.gmail.com#CAMa1XUhHjCv8Qkx0WOr1Mpm_R4qxN26EibwCrj0Oor2YBUFUTg@mail.gmail.com Cheers, Jeff
Commits
-
Better fix for deadlock hazard in CREATE INDEX CONCURRENTLY.
- 82acf3eb7db9 9.5.13 landed
- 7490ce725edd 9.4.18 landed
- 94a898f69c83 10.4 landed
- 69e3a548e99f 9.6.9 landed
- 1dec82068b3b 11.0 landed
-
Add more temporary debug logging, in 9.4 branch only.
- eef1a609adfd 9.4.18 landed
-
Add temporary debug logging, in 9.4 branch only.
- e55380f3b601 9.4.18 landed