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 1uRcli-00EFQU-1Q for pgsql-hackers@arkaria.postgresql.org; Tue, 17 Jun 2025 20:18:54 +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 1uRclg-00CpjP-5i for pgsql-hackers@arkaria.postgresql.org; Tue, 17 Jun 2025 20:18:52 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1uRclf-00CpjG-Ra for pgsql-hackers@lists.postgresql.org; Tue, 17 Jun 2025 20:18:52 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1uRcle-002dnB-0q for pgsql-hackers@postgresql.org; Tue, 17 Jun 2025 20:18:52 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 55HKIUe4870748; Tue, 17 Jun 2025 16:18:30 -0400 From: Tom Lane To: vignesh C cc: Alexander Korotkov , "Hayato Kuroda (Fujitsu)" , Alexander Lakhin , Vitaly Davydov , Amit Kapila , pgsql-hackers , Masahiko Sawada , "tomas@vondra.me" Subject: Re: Slot's restart_lsn may point to removed WAL segment after hard restart unexpectedly In-reply-to: References: <1d12d2-67235980-35-19a406a0@63439497> <1d97ec-6841b600-3-b7b4780@40747246> <28c8bf-68470780-3-51b29480@89454035> <0a617d34-abc3-4090-92a5-ea15d45e36f6@gmail.com> <22860! 7.1750003556@sss.pgh.pa.us> Comments: In-reply-to vignesh C message dated "Tue, 17 Jun 2025 08:24:41 +0530" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <870746.1750191510.1@sss.pgh.pa.us> Date: Tue, 17 Jun 2025 16:18:30 -0400 Message-ID: <870747.1750191510@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk vignesh C writes: > While tracking buildfarm for one of other commits, I noticed this failure: > TRAP: failed Assert("s->data.restart_lsn >= > s->last_saved_restart_lsn"), File: > "../pgsql/src/backend/replication/slot.c", Line: 1813, PID: 3945797 My animal mamba is also showing this assertion failure, but in a different test (recovery/t/040_standby_failover_slots_sync.pl). It's failed in two out of its three runs since ca307d5ce went in, so it's more reproducible than scorpion's report, though still not perfectly so. I suspect that mamba is prone to this simply because it's slow, although perhaps there's a different reason. Anyway, happy to investigate manually if there's something you'd like me to check for. regards, tom lane