Re: BUG #17198: Planning time too high when execute query on standby cluster - Mailing list pgsql-bugs

From Magnus Hagander
Subject Re: BUG #17198: Planning time too high when execute query on standby cluster
Date
Msg-id CABUevEzbzujPzywH-FiKabk=o5eW1i74Zq80Z9oywO0k04SQ-A@mail.gmail.com
Whole thread Raw
In response to BUG #17198: Planning time too high when execute query on standby cluster  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #17198: Planning time too high when execute query on standby cluster  (Andriy Bartash <Andriy.Bartash@everbridge.com>)
List pgsql-bugs
On Tue, Sep 21, 2021 at 8:42 AM PG Bug reporting form
<noreply@postgresql.org> wrote:
>
> The following bug has been logged on the website:
>
> Bug reference:      17198
> Logged by:          Andriy Bartash
> Email address:      abartash@xmatters.com
> PostgreSQL version: 12.8
> Operating system:   CentOS7
> Description:
>
> We have physical standby and noticed that some queries have Planning time
> very high (2-10 sec). Same queries on Primary cluster have Planning time 4-6
> msec
> Tried to run ANALYZE <table>, but it didn't help.
> Also noticed that RC (?) was bloated objects (table either index)

Do you have wal_log_hints or checksums enabled on your system? If not,
try running a VACUUM on the primary (not analyze), and see if that
helps.

Situations like this can happen due to hint bits not being updated on
the standby side, and not being included in the replication.

-- 
 Magnus Hagander
 Me: https://www.hagander.net/
 Work: https://www.redpill-linpro.com/



pgsql-bugs by date:

Previous
From: Puneet Sharma
Date:
Subject: Re: BUG #17189: Index not created when primary key created
Next
From: Jaime Casanova
Date:
Subject: Re: BUG #17189: Index not created when primary key created