Re: Postgres: Queries are too slow after upgrading to PG17 from PG15

From: Merlin Moncure <mmoncure(at)gmail(dot)com>
To: Peter Geoghegan <pg(at)bowt(dot)ie>
Cc: Sajith Prabhakar Shetty <ssajith(at)blackduck(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andrei Lepikhov <lepihov(at)gmail(dot)com>, "pgsql-bugs(at)lists(dot)postgresql(dot)org" <pgsql-bugs(at)lists(dot)postgresql(dot)org>, Todd Cook <cookt(at)blackduck(dot)com>
Subject: Re: Postgres: Queries are too slow after upgrading to PG17 from PG15
Date: 2025-08-21 02:58:41
Message-ID: CAHyXU0y1OK2XzzdgX5by9SML6fqpNtGcqRUPu4Hcjx1sjy82yg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Wed, Aug 20, 2025 at 7:48 PM Peter Geoghegan <pg(at)bowt(dot)ie> wrote:
>
> On Tue, Aug 12, 2025 at 12:46 AM Sajith Prabhakar Shetty
> <ssajith(at)blackduck(dot)com> wrote:
> > I can confirm with full certainty that both VACUUM and ANALYZE were executed on all three instances whose results I shared.
>
> The results that you shared showed "Heap Fetches: 598,916" -- one heap
> fetch per index search (for the problematic index scan).
>
> Perhaps VACUUM ran without being truly effective, due to the removable
> cutoff/horizon being held back by a long running query. Though that
> generally won't happen on a quiescent system -- so it really does look
> like VACUUM hasn't been run.

Try running VACUUM FREEZE. Do you have a way to frame up a dataset
for testing?

merlin

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Dilip Kumar 2025-08-21 03:46:20 Re: BUG #18988: DROP SUBSCRIPTION locks not-yet-accessed database
Previous Message Fujii Masao 2025-08-21 02:11:15 Re: Unexpected Standby Shutdown on sync_replication_slots change