Re: Vacuum statistics

From: Alena Rybakina <lena(dot)ribackina(at)yandex(dot)ru>
To: Андрей Зубков <zubkov(at)moonset(dot)ru>, Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
Cc: Andrei Lepikhov <lepihov(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Alexander Korotkov <aekorotkov(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Jim Nasby <jnasby(at)upgrade(dot)com>, Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>, Kirill Reshke <reshkekirill(at)gmail(dot)com>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, Melanie Plageman <melanieplageman(at)gmail(dot)com>, jian he <jian(dot)universality(at)gmail(dot)com>, Sami Imseih <samimseih(at)gmail(dot)com>, vignesh C <vignesh21(at)gmail(dot)com>, Ilia Evdokimov <ilya(dot)evdokimov(at)tantorlabs(dot)com>
Subject: Re: Vacuum statistics
Date: 2026-03-16 12:07:24
Message-ID: 767d28c9-2ae8-43df-9f2e-3e8785075115@yandex.ru
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi! Thank you for your attention to this patch!

On 16.03.2026 11:34, Андрей Зубков wrote:
> Really it was "revocations", but I'm agree with Andrey that naming
> isn't clear. *_vm_cleared looks better, but talking about naming here
> "vm" meaning is not clear. I think it will be understood as visibility
> map, but it is "mark" really. Maybe "*_pages_marks_cleared" will be
> better?
>
> Also a macro in pgstat.h:733 and pgstat.h:738 still holds "_rev_".
Good catch, fixed.
>
> I think the docs description needs a little correction:
>
> - visible_pages_vm_cleared. I think listing of possible DML operations
>   is not needed here, also it seems a high rate of this counter has no
>   direct relation to the index only scans because we can have very
>   agressive vacuum on a table that will do the opposite. It will hold
>   few pages without visibility marks constantly but with the cost
>   of high visible_pages_vm_cleared rate. My proposition follows:
>
>   Number of times the all-visible bit in the
>    <link linkend="storage-vm">visibility map</link> was cleared for a
>   pages of this table. The all-visible bit of a heap page is cleared
>   every time backend process modifies a page previously marked
>   all-visible by vacuum. Vacuum process must process page once again
>   on the next run. A high rate of change of this counter means that
>   vacuum should re-do its work on this table.
>
> - frozen_pages_vm_cleared:
>
>   Number of times the all-frozen bit in the
>    <link linkend="storage-vm">visibility map</link> was cleared for a
>   pages of this table.  The all-frozen bit of a heap page is cleared
>   every time backend process modifies a page previously marked
>   all-frozen by vacuum. Vacuum process must process page once again on
>   the next freeze run on this table.
I agree, this description is clearer. Fixed.

-----------
Best regards,
Alena Rybakina

Attachment Content-Type Size
v34-0001-Track-table-VM-stability.patch text/plain 15.5 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alena Rybakina 2026-03-16 12:11:06 Re: Vacuum statistics
Previous Message Amit Kapila 2026-03-16 11:54:41 Re: Report bytes and transactions actually sent downtream