Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tFFKC-00C6dO-Hu for pgsql-general@arkaria.postgresql.org; Sun, 24 Nov 2024 16:19:04 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1tFFKB-008Hs1-0I for pgsql-general@arkaria.postgresql.org; Sun, 24 Nov 2024 16:19:03 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tFFK9-008Hrs-Fj for pgsql-general@lists.postgresql.org; Sun, 24 Nov 2024 16:19:02 +0000 Received: from fout-a4-smtp.messagingengine.com ([103.168.172.147]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1tFFK2-003YXU-8T for pgsql-general@postgresql.org; Sun, 24 Nov 2024 16:19:00 +0000 Received: from phl-compute-10.internal (phl-compute-10.phl.internal [10.202.2.50]) by mailfout.phl.internal (Postfix) with ESMTP id B15B91380146; Sun, 24 Nov 2024 11:18:52 -0500 (EST) Received: from phl-mailfrontend-02 ([10.202.2.163]) by phl-compute-10.internal (MEProxy); Sun, 24 Nov 2024 11:18:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aklaver.com; h= cc:content-transfer-encoding:content-type:content-type:date:date :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm3; t=1732465132; x=1732551532; bh=H5kuK6A5G2PyYLfL4veQQvI1G8WdGG3rleHY3O3s09U=; b= Y3GgQN9/x+VfogRJbeEOUoDb25OZmD5DtVr4Xt3qHi/OUUgR3SwJhv6Aqd8ZIHs+ V6LhJscxtiEs+bGr8twZvh9j3FkxWpsmgeZW7GdMA44ZhDaVing50hEuNOq56phv WbPYWW/urdRROWnm2CEnZXTZhC+JX1oSv7xlMTvyLADK8ClfvGWCzSgDpo14845f lnGQ87blzmh5NaKkOqHNQsnsNZPIQgIMuMSqe/xy8inkoiSXGHqfHwXgMhPQNX20 +fHdo2Uk+M1TmYoLvwyATB+JMfx0UCc0DzKCx6G8sytmffFqChZINQQfm4E6KzLt LenErswX0vwt0rgBYUEIcw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :content-type:date:date:feedback-id:feedback-id:from:from :in-reply-to:in-reply-to:message-id:mime-version:references :reply-to:subject:subject:to:to:x-me-proxy:x-me-sender :x-me-sender:x-sasl-enc; s=fm1; t=1732465132; x=1732551532; bh=H 5kuK6A5G2PyYLfL4veQQvI1G8WdGG3rleHY3O3s09U=; b=Ld+JrnjvYlAxxNkxs GqbKcPV6PA4x5wosQ6PL6PKjVUEAzhuMvEQG5kusekx5O2hccf1JpBvlY8GN6Jge sM2quitd5SzDOU1ul1YeeFIdap1CWYJXFPWEesoaSvFDBxz5P3K9kfSuFMntqUeB CGhlbOIvUem0OoTu8vzrA9dTeLYcJB0YO2E/gAkuHizGuuoU7pTEpNiTu+SlxebJ d/oHwCo/UXpPeJQUoiLB0DpBkcf9pp7VJnzon5IdOq2BbxSRqWjz6Z5lpsVfwf9B UJdluAL1eljRvUOMyYsYNT3sMklDbUPS+AUuoAHFPChSdMWkoWKs/baOExYK4p2A N5OOw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefuddrgeefgdekiecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpggftfghnshhusghstghrihgsvgdpuffr tefokffrpgfnqfghnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnth hsucdlqddutddtmdenucfjughrpefkffggfgfuvfhfhfgjtgfgsehtkeertddtvdejnecu hfhrohhmpeetughrihgrnhcumfhlrghvvghruceorggurhhirghnrdhklhgrvhgvrhesrg hklhgrvhgvrhdrtghomheqnecuggftrfgrthhtvghrnhepleegveekkeekueeigfdtveei leeuhfefudefteekjeffkeejueejheegheegkedtnecuffhomhgrihhnpehpohhsthhgrh gvshhqlhdrohhrghenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhl fhhrohhmpegrughrihgrnhdrkhhlrghvvghrsegrkhhlrghvvghrrdgtohhmpdhnsggprh gtphhtthhopedvpdhmohguvgepshhmthhpohhuthdprhgtphhtthhopehsuhgshhgrshhh uhgurghtrgesghhmrghilhdrtghomhdprhgtphhtthhopehpghhsqhhlqdhgvghnvghrrg hlsehpohhsthhgrhgvshhqlhdrohhrgh X-ME-Proxy: Feedback-ID: i76984098:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 24 Nov 2024 11:18:51 -0500 (EST) Message-ID: <6c498f0e-64f9-449a-9b90-5cd72d00e2ef@aklaver.com> Date: Sun, 24 Nov 2024 08:18:49 -0800 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Questions on Upgrading PostgreSQL from 15.0 to 15.9 and Setting Up Streaming Replication To: Subhash Udata , pgsql-general@postgresql.org References: Content-Language: en-US From: Adrian Klaver In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 11/24/24 08:05, Subhash Udata wrote: > Dear PostgreSQL Community, > > I have a production database setup with a primary server and a standby > server. The database is currently running on *PostgreSQL 15.0*, and I > plan to upgrade both servers to *15.9*. > > I have the following questions regarding the upgrade and replication > process: > > 1. > > *Upgrade and Replication Compatibility*: > > * My plan is to perform a failover, promote the standby server > (currently 15.0) to primary, and then upgrade the old primary > server to version 15.9. > * After upgrading the old primary server to version 15.9, I want > to configure it as a standby server and set up streaming > replication with the new primary server, which will still be > running version 15.0. > * Is it possible to establish streaming replication between these > two versions (*15.0* as primary and *15.9* as standby)? > 2. > > *Efficient Replication Setup*: > > * The production database is around *1TB in size*, and creating > replication using |pg_basebackup| is taking more than 2–3 hours > to complete. > * Is there an alternative method to set up replication without > taking a full backup of the entire cluster but instead using > only the WAL files that have changed on both servers? Why? 15.0 --> 15.9(actually you want the latest release 15.10) is a minor upgrade it involves shutting down the servers installing the new version binaries on each and restarting them. You should read: https://www.postgresql.org/support/versioning/ It would be a good idea to go through the Release Notes here: https://www.postgresql.org/docs/15/release.html To see what changed. > > Your guidance and recommendations on these questions will be greatly > appreciated. > > Thank you for your time and support! > > Best regards, > > Subhash > -- Adrian Klaver adrian.klaver@aklaver.com