Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fo18Q-0001fH-CL for pgsql-admin@arkaria.postgresql.org; Fri, 10 Aug 2018 06:42:54 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fo18O-0001FH-Fl for pgsql-admin@arkaria.postgresql.org; Fri, 10 Aug 2018 06:42:52 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fo18O-0001F9-4W for pgsql-admin@lists.postgresql.org; Fri, 10 Aug 2018 06:42:52 +0000 Received: from hermes.gatewaynet.com ([193.92.121.98]) by makus.postgresql.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1fo18J-0007l8-Vw for pgsql-admin@lists.postgresql.org; Fri, 10 Aug 2018 06:42:50 +0000 Received: from smadev.internal.net (pc131.internal.net [10.9.200.131]) by hermes.gatewaynet.com (8.14.3/8.14.3/Debian-9.4) with ESMTP id w7A6gcjo018800 for ; Fri, 10 Aug 2018 09:42:43 +0300 Received: from smadev.internal.net (smadev [10.9.200.131]) by smadev.internal.net (8.15.2/8.15.2) with ESMTP id w7A6gbYB004746 for ; Fri, 10 Aug 2018 09:42:38 +0300 (EEST) (envelope-from achill@matrix.gatewaynet.com) Subject: Re: Logical Replication in Postgres 10.4 To: pgsql-admin@lists.postgresql.org References: <1533877563199-0.post@n3.nabble.com> From: Achilleas Mantzios Message-ID: <108d3ba4-5a0b-b67c-17eb-4de71124e7df@matrix.gatewaynet.com> Date: Fri, 10 Aug 2018 09:42:37 +0300 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 In-Reply-To: <1533877563199-0.post@n3.nabble.com> Content-Type: multipart/alternative; boundary="------------BF471EDB46E37D50F9D9EC4C" Content-Language: en-US X-Virus-Scanned: clamav-milter 0.98.7 at hermes X-Virus-Status: Clean X-Spam-Status: No, score=-26.0 required=5.0 tests=ALL_TRUSTED,DYN_HAM_COORD, DYN_HAM_IT,DYN_HAM_NAUTICAL,DYN_HAM_SIGNAT1,DYN_SPAM_MED6,HTML_MESSAGE autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on hermes.gatewaynet.com List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk This is a multi-part message in MIME format. --------------BF471EDB46E37D50F9D9EC4C Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit On 10/08/2018 08:06, pavan95 wrote: > Hi all, > > I have a doubt in Logical Replication feature in 10.4. I have 2 servers > where in which I have configured "Logical Replication" between two databases > source and destination. > > *In the Source*: > Before creating publication on publisher I have create 2 tables on both > publisher & subscriber. But only publisher contains data. > > Later, I have create publication for all tables using the below command: > CREATE PUBLICATION mypub FOR ALL TABLES; > > *In the Target*: > In the subscriber server, I have created a subscription for that > publication. > > Suddenly within no time the data got replicated(happy for that). > > The actual problem now aroused. I again went on creating a new table on the > primary but it was not part of my publication(surprised). So it was not > replicated. > > But from the documentation "FOR ALL TABLES" option the futurely created > tables are also part of the replication which was not (3'rd table) in my > case. > > What went wrong? Kindly help me out!!! Did you refresh the subscription ? : ALTER SUBSCRIPTION/|name|/ REFRESH PUBLICATIONWITH ( COPY_DATA ); > Thanks in Advance! > > Regards, > Pavan > > > > -- > Sent from: http://www.postgresql-archive.org/PostgreSQL-admin-f2076596.html > -- Achilleas Mantzios IT DEV Lead IT DEPT Dynacom Tankers Mgmt --------------BF471EDB46E37D50F9D9EC4C Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: 7bit
On 10/08/2018 08:06, pavan95 wrote:
Hi all,

I have a doubt in Logical Replication feature in 10.4.  I have 2 servers
where in which I have configured "Logical Replication" between two databases
source and destination.

*In the Source*:
Before creating publication on publisher I have create 2 tables on both
publisher & subscriber. But only publisher contains data. 

Later, I have create publication for all tables using the below command:
CREATE PUBLICATION mypub FOR ALL TABLES;

*In the Target*:
In the subscriber server, I have created a subscription for that
publication. 

Suddenly within no time the data got replicated(happy for that).

The actual problem now aroused. I again went on creating a new table on the
primary but it was not part of my publication(surprised). So it was not
replicated.

But from the documentation "FOR ALL TABLES" option the futurely created
tables are also part of the replication which was not (3'rd table) in my
case.

What went wrong? Kindly help me out!!!
Did you refresh the subscription ? :
ALTER SUBSCRIPTION name REFRESH PUBLICATION WITH ( COPY_DATA );
Thanks in Advance!

Regards,
Pavan



--
Sent from: http://www.postgresql-archive.org/PostgreSQL-admin-f2076596.html


-- 
Achilleas Mantzios
IT DEV Lead
IT DEPT
Dynacom Tankers Mgmt
--------------BF471EDB46E37D50F9D9EC4C--