pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Fujii Masao <masao.fujii@oss.nttdata.com>
To: Alexander Korotkov <aekorotkov@gmail.com>
To: Anton A. Melnikov <a.melnikov@postgrespro.ru>
Cc: Magnus Hagander <magnus@hagander.net>
Cc: Anton A. Melnikov <aamelnikov@inbox.ru>
Cc: Andres Freund <andres@anarazel.de>
Cc: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: pgsql-hackers@lists.postgresql.org
Subject: Re: May be BUG. Periodic burst growth of the checkpoint_req counter on replica.
Date: Sat, 14 Sep 2024 00:20:46 +0900
Message-ID: <9ea77f40-818d-4841-9dee-158ac8f6e690@oss.nttdata.com> (raw )
In-Reply-To: <CAPpHfdss-+EZHUP_MMNm9wHm43+ZM84ERWZvGO+p-5kH_Qt6og@mail.gmail.com >
References: <99b2ccd1-a77a-962a-0837-191cdf56c2b9@inbox.ru >
<20220907.163946.2214338139097492905.horikyota.ntt@gmail.com >
<84b732cb-2eef-1d4c-e9f3-48514d492f55@inbox.ru >
<20221206184453.ebr4eqwbnwfxl476@awork3.anarazel.de >
<42223bc5-23ad-c129-7779-92df92b21bae@inbox.ru >
<d70ee1d6-06f8-d823-aac5-4e18eac856bb@inbox.ru >
<CAPpHfdtZvVRpQErb_KpbrieROPpo5o2wemAp-jJOVdww2AdQqg@mail.gmail.com >
<7bd1c12b-4219-45bf-88a6-8cacd008dfdc@postgrespro.ru >
<CAPpHfduW_LbrU1JPtEDek5Fj3_=GZRU=qvFMyg7hnky7BLCGVw@mail.gmail.com >
<CABUevExav5-SR0x+G9kBUMV0G8XsvSUfuyyqmYBBJi6VHns6sw@mail.gmail.com >
<CAPpHfdtfDPEy4Pf1n2LvhsQ8ZsE40=OcFf=+U3BAQvfCtdj0MQ@mail.gmail.com >
<3ed0590b-8132-482e-a9e6-bd694e4a48d7@postgrespro.ru >
<CAPpHfduFpdq0dUsF=SmTtYit684JoSQrXvzhA+hap-tCA8Z2cA@mail.gmail.com >
<CAPpHfdss-+EZHUP_MMNm9wHm43+ZM84ERWZvGO+p-5kH_Qt6og@mail.gmail.com >
On 2024/03/14 9:19, Alexander Korotkov wrote:
> On Mon, Mar 11, 2024 at 11:48 AM Alexander Korotkov
> <aekorotkov@gmail.com> wrote:
>>
>> On Mon, Mar 11, 2024 at 5:43 AM Anton A. Melnikov
>> <a.melnikov@postgrespro.ru> wrote:
>>> On 11.03.2024 03:39, Alexander Korotkov wrote:
>>>> Now that we distinguish stats for checkpoints and
>>>> restartpoints, we need to update the docs. Please, check the patch
>>>> attached.
>>>
>>> Maybe bring the pg_stat_get_checkpointer_buffers_written() description in consistent with these changes?
>>> Like that:
>>>
>>> --- a/src/include/catalog/pg_proc.dat
>>> +++ b/src/include/catalog/pg_proc.dat
>>> @@ -5740 +5740 @@
>>> - descr => 'statistics: number of buffers written by the checkpointer',
>>> + descr => 'statistics: number of buffers written during checkpoints and restartpoints',
>>
>> This makes sense. I've included this into the revised patch.
>
> Pushed.
If I understand correctly, restartpoints_timed and restartpoints_done were
separated because a restartpoint can be skipped. restartpoints_timed counts
when a restartpoint is triggered by a timeout, whether it runs or not,
while restartpoints_done only tracks completed restartpoints.
Similarly, I believe checkpoints should be handled the same way.
Checkpoints can also be skipped when the system is idle, but currently,
num_timed counts even the skipped ones, despite its documentation stating
it's the "Number of scheduled checkpoints that have been performed."
Why not separate num_timed into something like checkpoints_timed and
checkpoints_done to reflect these different counters?
Regards,
--
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION
view thread (35+ messages) latest in thread
Message-ID: <9ea77f40-818d-4841-9dee-158ac8f6e690@oss.nttdata.com>
Permalink: ../9ea77f40-818d-4841-9dee-158ac8f6e690@oss.nttdata.com/
Also on: postgresql.org/message-id/9ea77f40-818d-4841-9dee-158ac8f6e690@oss.nttdata.com
copy link · copy postgr.es
reply 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-hackers@postgresql.org
Cc: masao.fujii@oss.nttdata.com, aekorotkov@gmail.com, a.melnikov@postgrespro.ru, magnus@hagander.net, aamelnikov@inbox.ru, andres@anarazel.de, horikyota.ntt@gmail.com, pgsql-hackers@lists.postgresql.org
Subject: Re: May be BUG. Periodic burst growth of the checkpoint_req counter on replica.
In-Reply-To: <9ea77f40-818d-4841-9dee-158ac8f6e690@oss.nttdata.com>
* 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