Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mgBhs-0007gd-11 for pgsql-general@arkaria.postgresql.org; Thu, 28 Oct 2021 20:09:00 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mgBhq-0002xE-Je for pgsql-general@arkaria.postgresql.org; Thu, 28 Oct 2021 20:08:58 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mgBhq-0002x5-9z for pgsql-general@lists.postgresql.org; Thu, 28 Oct 2021 20:08:58 +0000 Received: from momjian.us ([72.94.173.45]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mgBhm-0003Ti-Vq for pgsql-general@lists.postgresql.org; Thu, 28 Oct 2021 20:08:57 +0000 Received: from bruce by momjian.us with local (Exim 4.92) (envelope-from ) id 1mgBhl-0001SK-T2; Thu, 28 Oct 2021 16:08:53 -0400 Date: Thu, 28 Oct 2021 16:08:53 -0400 From: Bruce Momjian To: Ron Cc: pgsql-general@lists.postgresql.org Subject: Re: Incremental backup Message-ID: <20211028200853.GA1020@momjian.us> References: <4ad9560c-d6f7-3f74-b577-cf72c93195d0@aklaver.com> <68943e88-7d6b-edb3-90b5-782b9fb5fcbd@gmail.com> <57f54e84-c5f2-84fe-6e65-de5f4ddfdd47@aklaver.com> <995bab59-10e3-eaa9-2b93-afb0474595cd@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Oct 28, 2021 at 02:23:39PM -0500, Ron wrote: > On 10/28/21 2:06 PM, Adrian Klaver wrote: > > On 10/28/21 11:48, Ron wrote: > > > On 10/28/21 1:00 PM, Adrian Klaver wrote: > > > > On 10/28/21 10:51, Ron wrote: > > > > > > > > > Not doable in Postgresql because WAL files are global to cluster. > > > I've read multiple times that will not be changed. > > > > Yet somehow logical replication does it: > > > > https://www.postgresql.org/docs/14/logical-replication-architecture.html > > > > " > > Logical replication is built with an architecture similar to physical > > streaming replication (see Section 27.2.5). It is implemented by > > “walsender” and “apply” processes. The walsender process starts logical > > decoding (described in Chapter 49) of the WAL and loads the > > Scans the (global) WAL data for only the that portion from the relevant > database? > > If so, definitely not the same as having per-database WAL files. > > Just as importantly, replication is not, and never will be, a substitute for > backups. Uh, for replication slots, we don't send the entire WAL stream to the subscriber: https://www.postgresql.org/docs/14/logical-replication.html Logical replication of a table typically starts with taking a snapshot of the data on the publisher database and copying that to the subscriber. Once that is done, the changes on the publisher are sent to the subscriber as they occur in real-time. The subscriber applies the data in the same order as the publisher so that transactional consistency is guaranteed for publications within a single subscription. This method of data replication is sometimes referred to as transactional replication. -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com If only the physical world exists, free will is an illusion.