Re: BUG #16873: CREATE SUBSCRIPTION command hangs (Cross version logical replication) Wait event LibPQWalReceiverRec

From: Andriy Bartash <abartash(at)xmatters(dot)com>
To: abartash(at)xmatters(dot)com, pgsql-bugs(at)lists(dot)postgresql(dot)org
Subject: Re: BUG #16873: CREATE SUBSCRIPTION command hangs (Cross version logical replication) Wait event LibPQWalReceiverRec
Date: 2021-02-19 06:06:28
Message-ID: CAHVFAg9+myQnuptA0TsskW5QUaaU7wjfi8c8dLufC4D5s8r44Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

I am pretty sure, it's not a bug. I've managed to reproduce it and found
that session was blocked on source database.Blocked query:

SELECT DISTINCT t.schemaname, t.tablename

FROM pg_catalog.pg_publication_tables t

WHERE t.pubname IN ('auditstore_publication')

Once I killed a blocker - subscription was created.

On Thu, Feb 18, 2021 at 4:51 PM PG Bug reporting form <
noreply(at)postgresql(dot)org> wrote:

> The following bug has been logged on the website:
>
> Bug reference: 16873
> Logged by: Andriy Bartash
> Email address: abartash(at)xmatters(dot)com
> PostgreSQL version: 13.2
> Operating system: CentOS7
> Description:
>
> Hello
> Establishing logical replication between PG12 and PG13.2 and CREATE
> SUBSCRIPTION command hangs.
> Query bellow shows exact command, how long it's been running and wait
> event.
> Source and target PG clusters are running on different VMs
> SELECT query, xact_start, now(),wait_event FROM pg_stat_activity where
> query
> like 'CREATE SUBSCRIPTION%';
> query
>
> | xact_start |
>
> now | wait_event
>
> ---------------------------------------------------------------------------------------------------------------------+-------------------------------+-------------------------------+-------------------------
> CREATE SUBSCRIPTION "auditstore_subscription"
>
> +| 2021-02-18 23:07:23.814108+00 |
> 2021-02-19 00:16:37.237905+00 | LibPQWalReceiverReceive
> CONNECTION 'host=10.141.0.29 port=5432
> user=auditstore_publisher password=<PWD> dbname=auditstore'+|
>
> | |
> PUBLICATION "auditstore_publication";
>
> | |
>
> |
> (1 row)
>
>

--

*Andriy Bartash*

Database Administrator

xMatters : *Digital Service Availability Platform*

abartash(at)xmatters(dot)com <dpeete(at)xmatters(dot)com>

----------------------------

*Free Forever* <https://www.xmatters.com/free>* | **Meet Flow Designer*
<https://www.xmatters.com/features/flow-designer/>* | **See it in Action*
<https://youtu.be/AqCtonlFDaM>

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Vik Fearing 2021-02-19 08:29:32 Re: BUG #16867: savepoints vs. commit and chain
Previous Message Fujii Masao 2021-02-19 04:02:42 Re: BUG #16867: savepoints vs. commit and chain