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 1sRY9g-00GMis-Os for pgsql-hackers@arkaria.postgresql.org; Wed, 10 Jul 2024 14:18:48 +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 1sRY9e-005dNS-Ke for pgsql-hackers@arkaria.postgresql.org; Wed, 10 Jul 2024 14:18:46 +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 1sRY9e-005dNB-9f for pgsql-hackers@lists.postgresql.org; Wed, 10 Jul 2024 14:18:46 +0000 Received: from mail-io1-xd35.google.com ([2607:f8b0:4864:20::d35]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sRY9a-001OyW-NQ for pgsql-hackers@lists.postgresql.org; Wed, 10 Jul 2024 14:18:44 +0000 Received: by mail-io1-xd35.google.com with SMTP id ca18e2360f4ac-80557928673so25502839f.2 for ; Wed, 10 Jul 2024 07:18:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1720621120; x=1721225920; darn=lists.postgresql.org; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=qH6wsNSO/kyMNm76jZsk05uI8d/hIDbhVLRxYQ0N2Fs=; b=gqtZOJVqi3MZywK2FVXIjyiWFMKvnoFSf5MQkBiPT2k8uAxBz5myV70xCOxLqKMny9 mHQ4MUP79i8f0BQ5i6FzpnOhQLnMYfWHqmtdbRYvl+98cBJMuGCfEB2RUn0OvP1UWMsk GWT12kSjEZfbT+01soNvUPYM4/V+BWwVrhZypm99i7412LlN55pOyccG3asBYaka1ouS rAN6lSepltvFYj08NkmBncq6jhh5uhjd9Ppug1taEzkhu5cpfnUZn1hJ/l5WTHf25uyZ uzDwfQ+qgQcc8Gz5a+869DCGZRx2cR36LJqTqWkg10tcv40zPVdTDYBvLRlPyuWZ9dga gGTQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720621120; x=1721225920; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=qH6wsNSO/kyMNm76jZsk05uI8d/hIDbhVLRxYQ0N2Fs=; b=jiw9HUmU8rwQmC1aBceSVQPHTNi0kYbD4aIfVrudSJZ3mJ8eo2vranhTCh5W7FjhFI exa0yS1MN6jSPLU198USW/qg0ifN+p76xnMPvQFlyqp5zvYtNvfuG1eCc/ZfiYccmZVz wdW6Z0BoBNKv+gAW10SiT7AkCEfUAOGKwDhSOjVFO31lndF/KzCv1/4P6ObROmPEQSW9 g7gX8eAIlP9Sr6d7K073rpSLv3jSVea03ACUeHPElvczdpBZHlJdTCcYQZY1fgGvUwAl Uu8E0l2R2G3Gq+wjH99zeaFCnS2SlJJvhUc79rMvRA1LJqHx8yaYK6h+6GGW6pu6OVrU 9Qcw== X-Forwarded-Encrypted: i=1; AJvYcCUXY13wxsnGO/Tlk9gq7PuwYL0RcmsXGuLx+IwV/lO+vg3RzzPIaLv3ehHUFz57r7ATZG+oLtke6EupUXH0uky+j7N4Seb1ELvjC7JgU33WykVX X-Gm-Message-State: AOJu0Yx9/DWZS6xIPwp6oynH24D/c1LE7Dj8v27E/u3Wq3AAaCwDZXtp BaEvcNlK3V5pCts6oCMfiwJmOmcDzEOPGIGkc5GibMOWxut0rQKieQ+AKjZI X-Google-Smtp-Source: AGHT+IF8UFTEq6BVMYw2VIE8a4m/g680QKSV7FqNnp6FhRKOZG3IjaAXi0LKP0u+2JdkTz4V5zoHxA== X-Received: by 2002:a05:6602:1205:b0:803:5e55:b1da with SMTP id ca18e2360f4ac-8035e55b4a6mr388410139f.5.1720621120580; Wed, 10 Jul 2024 07:18:40 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id 8926c6da1cb9f-4c0b1c1374fsm1142153173.136.2024.07.10.07.18.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jul 2024 07:18:40 -0700 (PDT) Date: Wed, 10 Jul 2024 09:18:38 -0500 From: Nathan Bossart To: Robert Haas Cc: Fujii Masao , pgsql-hackers@lists.postgresql.org Subject: Re: Add a GUC check hook to ensure summarize_wal cannot be enabled when wal_level is minimal Message-ID: References: <6e30082e-041b-4e31-9633-95a66de76f5d@oss.nttdata.com> <802ff3d5-fdc7-4b08-9046-2e9fc5fdae0e@oss.nttdata.com> <7c1b48d8-0f08-4733-a4e6-d55f04581db7@oss.nttdata.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Jul 10, 2024 at 10:10:30AM -0400, Robert Haas wrote: > On Wed, Jul 10, 2024 at 1:56 AM Fujii Masao wrote: >> I'm sure this patch is necessary as a safeguard for WAL summarization. >> OTOH, I also think we should apply the patch I proposed earlier >> in this thread, which prevents summarize_wal from being enabled >> when wal_level is set to minimal. This way, if there's >> a misconfiguration, users will see an error message and >> can quickly identify and fix the issue. Thought? > > I interpreted these emails as meaning that we should not proceed with > that approach: > > https://www.postgresql.org/message-id/CAGECzQR2r-rHFLQr5AonFehVP8DiFH+==R2yqdBvunYnwxsXNA@mail.gmail.com > http://postgr.es/m/3253790.1720019802@sss.pgh.pa.us Yeah. I initially thought this patch might be okay, at least as a stopgap, but Jelte pointed out a case where it doesn't work, namely when you have something like the following in the config file: wal_level = 'minimal' summarize_wal = 'true' wal_level = 'logical' I'm not sure that's a dealbreaker for v17 if we can't come up with anything else, but IMHO it at least deserves a loud comment and a plan for a better solution in v18. -- nathan