Re: Lost replication slots after pg_upgrade. - Mailing list pgsql-admin

From John DeSoi
Subject Re: Lost replication slots after pg_upgrade.
Date
Msg-id 3CC0BC49-3376-4CDA-A133-C0A142BC6A88@pgedit.com
Whole thread Raw
In response to Re: Lost replication slots after pg_upgrade.  (Julien Rouhaud <rjuju123@gmail.com>)
Responses Re: Lost replication slots after pg_upgrade.  (Nikhil Shetty <nikhil.dba04@gmail.com>)
List pgsql-admin
> On Feb 8, 2022, at 2:08 AM, Julien Rouhaud <rjuju123@gmail.com> wrote:
>
> Because pg_upgrade modifies your primary instance in such a way that a standby
> can't simply keep replicating from it.

Would it work as expected if before pg_upgrade on the standby:

alter subscription my_subscription disable;
alter subscription my_subscription set (slot_name = NONE);

And then after pg_upgrade:

alter subscription my_subscription enable;

I have not tried it yet, but I thought this would be the simplest option.

John DeSoi, Ph.D.





pgsql-admin by date:

Previous
From: Axel Rau
Date:
Subject: Re: restarting logical replication after upgrading standby
Next
From: Nikhil Shetty
Date:
Subject: Re: Lost replication slots after pg_upgrade.