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 1pajCu-0003yY-7Q for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Mar 2023 20:19:16 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pajCs-0002BW-0u for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Mar 2023 20:19:14 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pajCr-0002BN-Hz for pgsql-hackers@lists.postgresql.org; Fri, 10 Mar 2023 20:19:13 +0000 Received: from mail-il1-x12e.google.com ([2607:f8b0:4864:20::12e]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1pajCk-0005Lh-S4 for pgsql-hackers@postgresql.org; Fri, 10 Mar 2023 20:19:10 +0000 Received: by mail-il1-x12e.google.com with SMTP id r4so3650975ila.2 for ; Fri, 10 Mar 2023 12:19:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20210112.gappssmtp.com; s=20210112; t=1678479546; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=FJ4fU472mBhRG8NTHjEUIAJH5CzS5klBsCHh8D6UB90=; b=KCiCxSP3fcDh/A6nfTE59NgV3KQbUWC3L8t/6E+cMW/7IoXehqkNDWhfYejocRssMw bDDar55tRPTtQjOawRBw/aFKGGqrDuwXp3ZbIu1WzNYPKF7b5Or9WaX77xasEwRD6vJz 3BwysThPBY2itVksU/lFfI1bIbt3h1LMvNYUfeMqkddyBPA5uZ2nDH3MkiZeuBmAZnyM 6Pf5oQ3KsweJ3lg5L3+CcZr8e0yFdvZUpDE+dwc0Ow5FLYG95ZpGHR+SX/jxyG3eX7eI n2LBV8df8dS/Fl6jpvDm8C9NtwKT3qJy2/25jrzDs4oebZ+K/Hd/bsTcNKMY25OOPfE0 Hopg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678479546; h=in-reply-to: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=FJ4fU472mBhRG8NTHjEUIAJH5CzS5klBsCHh8D6UB90=; b=7TXX2SCj1xqfrVDY3irR9sMjHxjWdAlvyLIyFuyD/98zJJxiu0hFhPk/nzdo7fhqgo 83QAe0/hvzcQO+0WW8MF8VHwGWpPPJi+BjzW7NpcJKTmOgTbRCJ3J7PduCm4jPgdIWvH adYYvv8sv2h/CoP/S0Ao6C3u+1W6afyPB8Vp3v1rA5rvTFNSshMBLWA6bJ389sC9PhS7 P+L/AnZG6/r1fnwf8OswFycFKzdk9G8ZRAp9H0Fv3C1ZBWOn5iEt6qXXgcelv6ygL1zO IUPusnJeZBfI9x8ZiW7hSpaxxPbbJPeM7GGNqJqUFYWMEomdIKSyJK/7ZJKrbw2WY4+6 DboQ== X-Gm-Message-State: AO0yUKX2dZK7EkgGKGlusD0yYeHtX4M0yNy7SsrxufdhbFRwY237nl7i TIhEIVq+tmDa0w15nMGgaFOlFA== X-Google-Smtp-Source: AK7set/1c/gb/AJv4NSo7Y/c5yr4dGfOGl1LYYqu+h/0w9xy6zJe5Ii//oydiJGomAi/7nSz/qD41g== X-Received: by 2002:a05:6e02:b4a:b0:313:fd3c:6439 with SMTP id f10-20020a056e020b4a00b00313fd3c6439mr4108677ilu.23.1678479546111; Fri, 10 Mar 2023 12:19:06 -0800 (PST) Received: from pryzbyj.telsasoft (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id q9-20020a02cf09000000b0039deb26853csm258134jar.10.2023.03.10.12.19.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Mar 2023 12:19:05 -0800 (PST) Received: by pryzbyj.telsasoft (Postfix, from userid 1000) id 8B6A78078ED; Fri, 10 Mar 2023 14:19:04 -0600 (CST) Date: Fri, 10 Mar 2023 14:19:04 -0600 From: Justin Pryzby To: Andres Freund Cc: Melanie Plageman , Kyotaro Horiguchi , tgl@sss.pgh.pa.us, vignesh21@gmail.com, lukas@fittl.com, alvherre@alvh.no-ip.org, magnus@hagander.net, pgsql-hackers@postgresql.org, thomas.munro@gmail.com, m.sakrejda@gmail.com Subject: Re: pg_stat_bgwriter.buffers_backend is pretty meaningless (and more?) Message-ID: References: <20230306.152425.316894602450485455.horikyota.ntt@gmail.com> <20230306.154843.178021884584228317.horikyota.ntt@gmail.com> <20230306190919.ai6mxdq3sygyyths@awork3.anarazel.de> <20230306192409.daz5ivq4mbbr2ye7@liskov> <20230306193404.3btuacgc6um33mt2@awork3.anarazel.de> <20230307181844.hxnlfi3wa5lm7sm2@awork3.anarazel.de> <20230309194301.mjdddcoswgr6xoxa@awork3.anarazel.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230309194301.mjdddcoswgr6xoxa@awork3.anarazel.de> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Mar 09, 2023 at 11:43:01AM -0800, Andres Freund wrote: > On 2023-03-09 06:51:31 -0600, Justin Pryzby wrote: > > On Tue, Mar 07, 2023 at 10:18:44AM -0800, Andres Freund wrote: > > > Hi, > > > > > > On 2023-03-06 15:21:14 -0500, Melanie Plageman wrote: > > > > Good point. Attached is what you suggested. I committed the transaction > > > > before the drop table so that the statistics would be visible when we > > > > queried pg_stat_io. > > > > > > Pushed, thanks for the report, analysis and fix, Tom, Horiguchi-san, Melanie. > > > > There's a 2nd portion of the test that's still flapping, at least on > > cirrusci. > > > > The issue that Tom mentioned is at: > > SELECT :io_sum_shared_after_writes > :io_sum_shared_before_writes; > > > > But what I've seen on cirrusci is at: > > SELECT :io_sum_shared_after_writes > :io_sum_shared_before_writes; > > Seems you meant to copy a different line for Tom's (s/writes/redas/)? Seems so > > https://api.cirrus-ci.com/v1/artifact/task/6701069548388352/log/src/test/recovery/tmp_check/regression.diffs > > Hm. I guess the explanation here is that the buffers were already all written > out by another backend. Which is made more likely by your patch. FYI: that patch would've made it more likely for each backend to write out its *own* dirty pages of TOAST ... but the two other failures that I mentioned were for patches which wouldn't have affected this at all. -- Justin