BUG #15064: Deadlock not detected on standby.

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: konst583(at)gmail(dot)com
Subject: BUG #15064: Deadlock not detected on standby.
Date: 2018-02-14 11:08:08
Message-ID: 151860648802.1446.5335127783879034230@wrigleys.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 15064
Logged by: Konstantin Evteev
Email address: konst583(at)gmail(dot)com
PostgreSQL version: 9.5.11
Operating system: Debian GNU/Linux 8 (jessie)
Description:

Hello!
I have found a bug: deadlock not detected on standby.
It is actual for
PostgreSQL 9.5.11 on x86_64-pc-linux-gnu (Debian 9.5.11-1.pgdg80+1),
compiled by gcc (Debian 4.9.2-10) 4.9.2, 64-bit
PostgreSQL 9.4.16 on x86_64-unknown-linux-gnu (Debian 9.4.16-1.pgdg80+1),
compiled by gcc (Debian 4.9.2-10) 4.9.2, 64-bit

And this is not actual for
PostgreSQL 9.6.7 on x86_64-pc-linux-gnu (Debian 9.6.7-1.pgdg80+1), compiled
by gcc (Debian 4.9.2-10) 4.9.2, 64-bit
PostgreSQL 10.2 (Debian 10.2-1.pgdg80+1) on x86_64-pc-linux-gnu, compiled by
gcc (Debian 4.9.2-10) 4.9.2, 64-bit

May be this behavior needed to be backported to older versions

-- on primary
--create table items(item_id int);
--create table options(item_id int, v1 text);

---- 1 st session - primary
begin;
alter table options add v2 int;

---- 2-nd session standby
begin;
select * from items;

---- 1 st session - primary
alter table items add a text;

on standby
select * from options;

deadlock not detected

in versions 9.6 and 10 - it's ok

---------------------------------------
ERROR: deadlock detected
LINE 1: select * from options;
^
DETAIL: Process 25364 waits for AccessShareLock on relation 17388 of
database 17384; blocked by process 25322.
Process 25322 waits for AccessExclusiveLock on relation 17385 of database
17384; blocked by process 25364.
HINT: See server log for query details.
-----------------------------------------
--
Konstantin Evteev.

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2018-02-14 13:19:35 BUG #15065: ActivePerl 5.24.3 breaks PG compilation on Windows
Previous Message Michael Paquier 2018-02-14 06:04:54 Re: Conflicting declarations for b64_encode etc. on Solaris 11.4 Beta