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 1jfVlx-0000NM-4X for pgsql-general@arkaria.postgresql.org; Sun, 31 May 2020 21:45:37 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jfVlw-0001ql-13 for pgsql-general@arkaria.postgresql.org; Sun, 31 May 2020 21:45:36 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jfVlv-0001qe-PW for pgsql-general@lists.postgresql.org; Sun, 31 May 2020 21:45:35 +0000 Received: from portal-smtp-out.hot.ee ([194.126.101.125]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jfVls-0003nO-I0 for pgsql-general@postgresql.org; Sun, 31 May 2020 21:45:34 +0000 Received: from localhost (localhost [127.0.0.1]) by vm-hot-relay10.estpak.ee (Postfix) with ESMTP id 389C11773; Mon, 1 Jun 2020 00:45:32 +0300 (EEST) X-Virus-Scanned: Debian amavisd-new at vm-hot-relay10.estpak.ee Received: from portal-smtp-out.hot.ee ([127.0.0.1]) by localhost (vm-hot-relay10.estpak.ee [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 8yI4AkgoXgbG; Mon, 1 Jun 2020 00:45:30 +0300 (EEST) Received: from mail.hot.ee (hot-relayhost1.estpak.ee [213.180.2.79]) by vm-hot-relay10.estpak.ee (Postfix) with ESMTP id 024D515D9; Mon, 1 Jun 2020 00:45:29 +0300 (EEST) Received: from dell2 (66-63-196-88.sta.estpak.ee [88.196.63.66]) (Authenticated sender: kobruleht2) by HOT-Relayhost1.estpak.ee (Postfix) with ESMTPSA id 49ZsL04tLzz2Yp; Mon, 1 Jun 2020 00:45:27 +0300 (EEST) Message-ID: <21E8CC88FA0044708D91626126C82ADE@dell2> From: "Andrus" To: "pgsql-general" , "Adrian Klaver" References: <26EC9619620649D1B55C9C95811E4ADB@dell2> <16e57e3f-5c26-fd55-d42a-f030c8550952@aklaver.com> <102C5FA16F1549659B393B6A824B561F@dell2> <9a3e15d5-774e-a0fd-6dd5-f2405c7ec304@aklaver.com> In-Reply-To: <9a3e15d5-774e-a0fd-6dd5-f2405c7ec304@aklaver.com> Subject: Re: How to start slave after pg_basebackup. Why min_wal_size and wal_keep_segments are duplicated Date: Mon, 1 Jun 2020 00:45:17 +0300 MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="windows-1257"; reply-type=response Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal Importance: Normal X-Mailer: Microsoft Windows Live Mail 16.4.3528.331 X-MimeOLE: Produced By Microsoft MimeOLE V16.4.3528.331 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Hi! >> Will wal_keep_segments keep segments also if named replication slot is >> lot used ? >Well if you are using a replication slot there is no point in using >wal_keep_segments. Slots where created in, part at least, so you did not >have to guess at a wal_keep_segments number. I dont use slot. >To really answer this we will need to see the exact commands you are >using and the sequence they are done in. Replication server is created using /etc/init.d/postgresql stop mv /var/lib/postgresql/12/main /var/lib/postgresql/12/mainold pg_basebackup --write-recovery-conf -D /var/lib/postgresql/12/main chmod --recursive --verbose 0700 /var/lib/postgresql/12/main chown -Rv postgres:postgres /var/lib/postgresql/12/main /etc/init.d/postgresql start Andrus.