From: Laurenz Albe <laurenz.albe@cybertec.at>
To: James Pang <jamespang886@gmail.com>
To: pgsql-admin@lists.postgresql.org
Subject: Re: select statements have many shared_blks_dirtied and written
Date: Tue, 20 Feb 2024 09:34:03 +0100
Message-ID: <645a24ea6ca6055a0f81ea5927ba0a08e15157c2.camel@cybertec.at> (raw)
In-Reply-To: <CAHgTRfftPv9NmWBxfxCZMZAL3_bxP8HthyNbZxXKHN=Uagt3jg@mail.gmail.com>
References: <CAHgTRfftPv9NmWBxfxCZMZAL3_bxP8HthyNbZxXKHN=Uagt3jg@mail.gmail.com>
On Tue, 2024-02-20 at 16:20 +0800, James Pang wrote:
> We have several sql "select ... from ... where ..." ,from pg_stat_statements,
> we found the select sql has many shared_blks_dirtied, shared_blks_written.
> is it by "hint bits" updates ? when checkpoint just completed, we saw many
> wal_fpi , wal_bytes with this select sql too.
Yes, that are probably hint bits.
One way to avoid that is to VACUUM the table after a bulk load, that
will set hint bits.
Yours,
Laurenz Albe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-admin@postgresql.org
Cc: laurenz.albe@cybertec.at, jamespang886@gmail.com, pgsql-admin@lists.postgresql.org
Subject: Re: select statements have many shared_blks_dirtied and written
In-Reply-To: <645a24ea6ca6055a0f81ea5927ba0a08e15157c2.camel@cybertec.at>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox