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 1mNHN4-0004Dd-4v for pgsql-general@arkaria.postgresql.org; Mon, 06 Sep 2021 16:21:22 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1mNHN2-0002CY-Qx for pgsql-general@arkaria.postgresql.org; Mon, 06 Sep 2021 16:21:20 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mNHN2-0002CQ-I7 for pgsql-general@lists.postgresql.org; Mon, 06 Sep 2021 16:21:20 +0000 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mNHMz-0004oE-JC for pgsql-general@lists.postgresql.org; Mon, 06 Sep 2021 16:21:19 +0000 Received: by mail-wr1-x429.google.com with SMTP id u9so10562063wrg.8 for ; Mon, 06 Sep 2021 09:21:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cybertec-at.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :user-agent:mime-version:content-transfer-encoding; bh=eiZk0DE+VnOBY4xtj18lkgotarxE5Xe2QfW5mGmYa4s=; b=HdFisfcTwrPBiqNNYepWfHkaSe6Zbx8mIg7IFzUuA7uiLMZH13SOLhFCacrJI0uHl2 ybaVU4yhUKErcW3m61JzdxZ5cWjTE4Z+cOlYHqweU5nN1SMF2sKs0DTcmGsvUuEfmN1E ax+rVrdyX2TbPCdBuO/QsYlRPGXB85bJKGY4rlXuV+TQzTGefC4xGxiIha5l3tJ9RJjn 17UaRmEAoTyaB7wf+hreCDPY/Kk0QmNn7Cfm0MZAEgFFACZPRn43+8LWwlUA7OLN4g07 lrJ41bGvPpN8jVpTqLNqAQs68synQEAwuP7PY/Q9jsTjPDp/EkoxG/Urvo9JlFy0YgfH NywQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:user-agent:mime-version:content-transfer-encoding; bh=eiZk0DE+VnOBY4xtj18lkgotarxE5Xe2QfW5mGmYa4s=; b=pHkuCoTpK38zgKRSNybo32/TbvCEvs46qxvp9gLlCzWM5U0yfZ/gfaWQtAS+dfrop4 kup/pc3bdquyEOHTH+8a9DMcK8nVtyAEW6RNy5E/YCImLXF6b1euwZLoUVFWRpovcHV4 HBAx0qXlgSR7doNcviploRv30VvIUFdiUUjvV0NaGCkqc7mRGJhPtWsIbANg0+KQoWSk JjD3s3dC8WSfIxB1sJfxSowPhsv3rcUYpwEh8ec6CtqzEVuL9z6R3INrpL9pKrbV5ffw B6TMvuQ1BJrr7xEmK/IrAT7IlnWNZwfNSVQNJTgYSLmSKrD1OLUwq6bkL9ovH+pa6r6z Re0g== X-Gm-Message-State: AOAM5328i7ZwO8bIqc7GykZOrVwENRwMcQGOzNv9Gl/17r6A54wnpyqJ FwkfTReFzWQY5dTBc28hHN9hdQ== X-Google-Smtp-Source: ABdhPJzQS18OX5MytetUflTYyvlf/UfTDAzv4Tk5aYydrVSk0LlOIs4VUM+QwREswJiX/082j5fjcw== X-Received: by 2002:adf:d1ab:: with SMTP id w11mr13947593wrc.372.1630945275243; Mon, 06 Sep 2021 09:21:15 -0700 (PDT) Received: from localhost.localdomain (dynamic-e2fcj9ch68fod91kp-pd01.res.v6.highway.a1.net. [2001:871:5c:9bf4:adfc:f0e1:43e0:ed39]) by smtp.gmail.com with ESMTPSA id g5sm8239484wrq.80.2021.09.06.09.21.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 06 Sep 2021 09:21:14 -0700 (PDT) Message-ID: <2767fd7e5750d00fababa51a187b262e64d337da.camel@cybertec.at> Subject: Re: Behavior change in PostgreSQL 14Beta3 or bug? From: Laurenz Albe To: Tom Lane Cc: Peter Geoghegan , "Daniel Westermann (DWE)" , "pgsql-generallists.postgresql.org" Date: Mon, 06 Sep 2021 18:21:13 +0200 In-Reply-To: <3065647.1630943989@sss.pgh.pa.us> References: <6fb7ffe9f584cb76e5c7aadc83d7562009224cb8.camel@cybertec.at> <3065647.1630943989@sss.pgh.pa.us> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.40.4 (3.40.4-1.fc34) MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Mon, 2021-09-06 at 11:59 -0400, Tom Lane wrote: > Laurenz Albe writes: > > It is not an incompatibility that warrants a mention in the release notes, > > but perhaps somthing in > > https://www.postgresql.org/docs/14/indexes-index-only-scans.html > > and/or > > https://www.postgresql.org/docs/14/routine-vacuuming.html#VACUUM-FOR-VISIBILITY-MAP > > could be added that recommends that people should consider frequent > > VACUUM with "index_cleanup = on" for best performance with index-only scans. > > If enough pages would change their all-visible state to make a significant > difference in index-only scan performance, VACUUM should not be skipping > the cleanup.  If it is, the threshold for that is too aggressive. > > Assuming that that choice was made appropriately, I think the advice you > propose here will just cause people to waste lots of cycles on VACUUM > runs that have only marginal effects. #define BYPASS_THRESHOLD_PAGES 0.02 /* i.e. 2% of rel_pages */ So up to an additional 2% of all pages can have the all-visible bit unset with "index_cleanup = auto". That is probably not worth worrying, right? Yours, Laurenz Albe