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 1qhOLj-002NZf-1C for pgsql-bugs@arkaria.postgresql.org; Sat, 16 Sep 2023 06:00:11 +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 1qhOLf-007JS6-P5 for pgsql-bugs@arkaria.postgresql.org; Sat, 16 Sep 2023 06:00:07 +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 1qhOLf-007JP2-F1 for pgsql-bugs@lists.postgresql.org; Sat, 16 Sep 2023 06:00:07 +0000 Received: from mail-lj1-x231.google.com ([2a00:1450:4864:20::231]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1qhOLc-005OHM-3t for pgsql-bugs@lists.postgresql.org; Sat, 16 Sep 2023 06:00:06 +0000 Received: by mail-lj1-x231.google.com with SMTP id 38308e7fff4ca-2bfc8c02e82so42378761fa.0 for ; Fri, 15 Sep 2023 23:00:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1694844003; x=1695448803; darn=lists.postgresql.org; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=C373R562JL6vZEQwr8pjNcfPH5HKKtEhnzKl+TZ4H/s=; b=EtTjFpBQMA98pCqMNPDGnnmqpGoLgXfrwBNwIdyPbFvAH+xop76EUDCzdPDGFNIZp7 QlZgBf4NbmdW03yN9Q7n3HDRe+kXntrjiLMVybIMSivWg4fhwm8/mu0pDHsjQhy8K3Bv zu3KKiv42MlF7NlYps6qZRYmIACJdGU5LFAyaya2e61ziIgSm8lwZ/c8hmAIpqavc5jN SDeG+xpw6Kg71ID0N3x/SpDLSzcfNWHNmOIFKOd3/++M2kzDXKkRijV/HIWfw6J50vbt vhfWI5PH0hq1ueTb4HB79IOQk8X9skQTJ1Y+nRSMqVw4AWzK7K6pSKobmvru57KkMcvb m/Fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1694844003; x=1695448803; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=C373R562JL6vZEQwr8pjNcfPH5HKKtEhnzKl+TZ4H/s=; b=oFsKtE9jUr40WSRsQSr6kfrbdfvYkNdiTf6Ih5fZimxUZLfsC4YhHJsVZJ8uDH+nDA 9wRfuvukXsa/AVHxPM4oLfXpdqdOY3Fl6Kn2JSkhvYN+uSjeyRV7J62nWco4gLiL/Q4Q h4Tewf71uGk1YjPJKk+7VVoshthFEhjf4tDMPEkksYwGY2pwEkiAXovLKN1PsPr2BUoj fUEifYMylX1DgNRKOr2XgavxdC9Tgo544Vc3e/vg5Y10S5mCSxTnU+LhYQTjeIJZs0Tg L3uc9goJYTptSOklYpzNS2E8q14WaWMzWL25COxDdRDdmL1PrTDM8botPDCNedRCr/0/ 3c/A== X-Gm-Message-State: AOJu0YwsHhXPe2MR4vAW+6B8h3FmPhg04o3xo3sJP7qlLJbbuSvdGXzL dJS9o9yBVMt24VQ4X197Iv8= X-Google-Smtp-Source: AGHT+IF9kthj/1Ek9oYTAyd1vzBCIgjIQI+d7ginfTpOan/WN/QXBR5Q2sj9wtHjO2Dc8lgCOeBYpw== X-Received: by 2002:a05:6512:928:b0:500:a3be:1ab6 with SMTP id f8-20020a056512092800b00500a3be1ab6mr2453631lft.6.1694844002718; Fri, 15 Sep 2023 23:00:02 -0700 (PDT) Received: from [1.0.0.7] ([178.155.20.111]) by smtp.gmail.com with ESMTPSA id q20-20020a19a414000000b00502db9993d9sm889278lfc.206.2023.09.15.23.00.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 15 Sep 2023 23:00:01 -0700 (PDT) Message-ID: Date: Sat, 16 Sep 2023 09:00:00 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Subject: Re: BUG #17928: Standby fails to decode WAL on termination of primary Content-Language: en-US To: Thomas Munro , Michael Paquier Cc: Sergei Kornilov , Noah Misch , Tom Lane , Kyotaro Horiguchi , pgsql-bugs@lists.postgresql.org, Fujii Masao References: From: Alexander Lakhin 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 Hello, 16.09.2023 03:20, Thomas Munro wrote: > On Sat, Sep 16, 2023 at 12:03 PM Michael Paquier wrote: >>> [1] https://github.com/macdice/postgres/commits/fix-12 >> Hmm. What was the test that failed? > $ make -s -C src/test/recovery/ check PROVE_TESTS=t/039* > t/039_end_of_wal.pl .. 4/? > # Failed test 'xlp_magic zero' > # at t/039_end_of_wal.pl line 312. > > not ok 5 - xlp_magic zero > > Where the log should say "invalid magic number 0000" I see: > > 2023-09-16 12:13:07.331 NZST [156812] LOG: record with incorrect > prev-link 0/16B60C0 at 0/16B6120 > > It has to do with initial WAL position after initdb, because I get > this only on Debian, on REL_12_STABLE (with the commit listed above on > my public fix-12 branch) and only with --with-icu, but not without it, > and I can't repro it on my other local OSes. I tried to reproduce the failure on Debian 9, 10, 11, but not succeeded yet. Though I got another error on Debian 9: t/039_end_of_wal.pl .. Dubious, test returned 25 (wstat 6400, 0x1900) No subtests run ... cat src/test/recovery/tmp_check/log/regress_log_039_end_of_wal could not find match in header access/xlog_internal.h It looks like the construction "@{^CAPTURE}" used in scan_server_header() is not supported by Perl 5.24, which is included in Debian stretch: https://perldoc.perl.org/variables/@%7B%5ECAPTURE%7D I replaced it with @match = ($1); and that worked for me. Also, I observed that "wal_log_hints = on" in extra.config, which I use via "TEMP_CONFIG=extra.config make check-world" makes the test fail too, though check-world passes fine without the new test. Maybe that's not an issue, and probably there are other parameters, which might affect this test, but I'm somewhat confused by the fact that only this test breaks with it. Best regards, Alexander