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.96) (envelope-from ) id 1w2HAe-0009G6-2u for pgsql-hackers@arkaria.postgresql.org; Mon, 16 Mar 2026 23:16:25 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w2HAd-00E707-2V for pgsql-hackers@arkaria.postgresql.org; Mon, 16 Mar 2026 23:16:23 +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.96) (envelope-from ) id 1w2HAd-00E6zy-1a for pgsql-hackers@lists.postgresql.org; Mon, 16 Mar 2026 23:16:23 +0000 Received: from mail-oo1-xc35.google.com ([2607:f8b0:4864:20::c35]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w2HAa-000000005is-14HR for pgsql-hackers@postgresql.org; Mon, 16 Mar 2026 23:16:22 +0000 Received: by mail-oo1-xc35.google.com with SMTP id 006d021491bc7-67bac077116so2670038eaf.1 for ; Mon, 16 Mar 2026 16:16:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1773702981; cv=none; d=google.com; s=arc-20240605; b=UqLDiXX+n1RU/b6cUJ7MS/jv/329TEy4euzFY2YLLzzBieFnjUaQvur7FqY9ItcIsc Z9h4zeJjSrQpnJHeaoQAarfwNm226drCAF/MBvB9rBhkz0cPQa+KwSzH2bHHjHV2VDvV TukqSk/yhAawVGcF6nFseqS+mF9vYF5xGJaHdShJAF/jE8nrdQg/+/44DVCS8O8csodH 2QPEo2kgRkS8yoBTwXCjJlUa1zLJWO040iVn653y63Kr6dv+3yKxfqLfWIGOSTXXrr8S HDtgrVjo/2GvQOK9Y7SgUhqU70iljXZF3a0e7PwfiaPIsdrP7/P6NDH93314ciVhmv60 UJBw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=+4GGPXOrf1nnxJLV8tdkB7aHOXrzzdR0EzJNK/dCdD4=; fh=bBWFqMM4xay7T5QPi62ZyQr9uL1INvJKTxhbXpHPBuQ=; b=fTZi6ZYGg0dCxThBpOoBo+mBurF84XiKdU69dkfWGqlpm5zEWqgITCCA+AYl4Fxy+V 5Mx2SJMASgv7NTDP/Hfp4WkKs5oCzgH7S/r54VKEvUgoLuIzmwIOj6bwe8E9gqajwgoB xWAzFokJoNxEClIKB2reMULBgy671BOFyD18Cig96hOCJvciab+P/37JQIUjP+A6ZalK +OPvI+RMBRO+3zRaxZ+XVIMqT4laR4YIy8wlaZYXn1nB337hKXNZ/6df8e8YbZNWcz54 /kia1xxNRZC3I3kUmMiAhKafVQlWKKrws8gssb9FaOo/v+QRbtqpVrUOIqK2R0S2FshR RnBA==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1773702981; x=1774307781; darn=postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=+4GGPXOrf1nnxJLV8tdkB7aHOXrzzdR0EzJNK/dCdD4=; b=U5uJaAVjIoEftriEbRxDwqEmOaOI6t39bFtJoZv6vQRjuy98VvNOb6i90xjGp0UA8m 8u0nqCv4sN1FsfBM2uNjbviul8ubbNCs5Hc1lrLvrvuraQWLMXRiGzo+Yncbb8dYYZqB e2DB6wyjrsHeo2FngbNgjT/+kEV6u27lTHNjNg+t5+YzDk+zq9ziRPyMIW715YHWHFtf ez2iMwuk6LDQoMAhUcW8b36GEuGhE8S+cycCtL5LPY2HE4wN7Xta2h6KUGu8EycfJjEV K7gas61HZoxJ/Xa5AbxILytPSeK2XfbagOq82IBUlOF/1ewkeHdDnQwLGUSxU0hsOZDe R0Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773702981; x=1774307781; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=+4GGPXOrf1nnxJLV8tdkB7aHOXrzzdR0EzJNK/dCdD4=; b=i87wa81Jif3UsYCgXo/S+L4xV0VhJ/GiWEgZ7+EDeFi2VhzK06W/sDp11P8lJ8JYaE 8TfaB8fMWc/PG4jBYw0cY081S/sXk7QtgppsdU6lNp7YyajWmeOXAjOokKAc1EnMKqrS 8/FIqfZ0JSFqmYSNI9QF4kE7nwcmHB4vUbEBxhUPC0EUau7mabZY6nSHNFPsehEMRLke EwIpsRvGahHEV6mWhwtCWBSuOiFNGlmRoCwSoi8/vy3YDo4PSDRW6QDrqBkcnF8dLD59 I0V6qFBTlXiTBrAngYJIiy4HLeAiIZ8joYXOD1AfS9EvaGBVFB6iBX35KijPm8iVdup4 yQAA== X-Forwarded-Encrypted: i=1; AJvYcCU4MaE3GgOglF0cDDBRq09poONiSZpByRrubB9cIBQQ4Sdk3vTXQlv/2gyJ3kkUTNXopEfgvDmvoQIPdV/F@postgresql.org X-Gm-Message-State: AOJu0YxFabhBlTSi9qT+nMFMM2jgpWr+D/4ywJmJt9jtYuaKKaDHoFWr 0tUrTluct8jzuMtO8hYTimcpwtkaHgxsV51iL6C2MziHuUOD0A1s4Qz4DRj9rWQ4NWFo2AyhRee 0RwsUFf2lHl54dv5J1VbHO0dXUC/WNwA= X-Gm-Gg: ATEYQzwxVMdlkHlYo/goAaZY2SeN274JeIk2mSuM7jZ1hnaSGjeShezxSeHqBA998CM KP+IOUFfcqkw6YHhg/uYcZrRYX1vqoPbmFcsxGbS1Tit6qo8LWcSa3P8L6GoX8YFj80tCXTUlYn KAPSzrzbtg8yiBtfOsi1AZ4abLJeFoOqJ80uiIgUvz8TAbCWvXlPtrePY3UmuMJsb5DbHvg/RwT nzui4JIyXSI4TNwg1uLHXtoRhqAOaIyVeE4FECm3btN7SO4I5nNQ7j4MGG2J1Hdg9PqXgOK15Eh QRJI4T0asTrGUOTbT2+qPkhvTYPQL/9P1RPLbWGgHA== X-Received: by 2002:a05:6820:1c97:b0:67b:de8a:c3c7 with SMTP id 006d021491bc7-67bde8ac927mr8195861eaf.36.1773702981254; Mon, 16 Mar 2026 16:16:21 -0700 (PDT) MIME-Version: 1.0 References: <2631a3c3-5e60-4a1a-9e20-377024322602@gmail.com> In-Reply-To: From: Fujii Masao Date: Tue, 17 Mar 2026 08:16:08 +0900 X-Gm-Features: AaiRm51ajY3_mumMN76jbUsRzz78VIyhSbncz4JDdAhpQUpL0HBHQSQDjN8Je9Y Message-ID: Subject: Re: Shutdown indefinitely stuck due to unflushed FPI_FOR_HINT record To: Anthonin Bonnefoy Cc: Andres Freund , Alexander Lakhin , PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, Mar 16, 2026 at 6:45=E2=80=AFPM Anthonin Bonnefoy wrote: > > On Mon, Mar 16, 2026 at 6:39=E2=80=AFAM Fujii Masao wrote: > > Since Tomas added GetXLogInsertEndRecPtr() in commit b1f14c96720, > > I updated the patch to use it. Patch attached. > > Barring any objections, I will commit it. > > > > - XLogFlush(GetXLogWriteRecPtr()); > > + XLogFlush(GetXLogInsertEndRecPtr()); > > Thanks for the updated patch! I've run my test script against the > patch and there's no more "xlog flush request xxx is not satisfied" > errors reported. Thanks for the test! I've pushed the patch. > > I excluded the above change from the patch because it seems like a sepa= rate > > issue. I also wonder whether this code could cause an error in XLogFlus= h() > > even when GetXLogWriteRecPtr() is used. > > Ha right, I've mixed Insert and Write and thought that > FinishSyncWorker was also doing a XlogFlush(GetXLogInsertRecPtr()) > when writing the patch. If I try to trigger the partial record issue, > GetXLogWriteRecPtr() points at the end of the WAL page containing the > beginning of the FPI_FOR_HINT, there's no attempt to flush in the > future. So FinishSyncWorker doesn't seem impacted by the issue. Understood. Thanks for the investigation! Regards, --=20 Fujii Masao