| From: | Kirill Reshke <reshkekirill(at)gmail(dot)com> |
|---|---|
| To: | Melanie Plageman <melanieplageman(at)gmail(dot)com> |
| Cc: | Alexander Lakhin <exclusion(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Andrey Borodin <x4mmm(at)yandex-team(dot)ru>, Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com>, Xuneng Zhou <xunengzhou(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
| Subject: | Re: eliminate xl_heap_visible to reduce WAL (and eventually set VM on-access) |
| Date: | 2026-01-30 09:23:07 |
| Message-ID: | CALdSSPgdBeyQpQ+Q3GebN=QL00RYH7HCbSWR+KDs=dvj-fNYpQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, 29 Jan 2026 at 20:16, Melanie Plageman
<melanieplageman(at)gmail(dot)com> wrote:
>
> On Thu, Jan 29, 2026 at 8:39 AM Kirill Reshke <reshkekirill(at)gmail(dot)com> wrote:
> >
> > Thanks Alexander!
> > This is a good and detailed report, I was able to reproduce this.
>
> Thanks to both of you for looking into it!
>
> > I have added some logs to my copy of postgres with your patch and I
> > think problem causing this test to fail is this sequence:
> >
> > 1) Autovacuum starts, does its deeds, and acquiring xid = 118518
>
> So, in this scenario, is the issue that autovacuum runs before vacuum
> freeze? If so, we can change the table DDL to:
>
> create table test_vac_unmodified_heap(a int) with (autovacuum_enabled = false);
>
> which would prevent the autovacuum from running.
Hi!
Yes I did try this, but it does not help, because autovacuum runs on
catalog relations, still causing fail.
> Unless there is some other way for one of the other tests to hold
> OldestXmin back to before the xid of the insert. But I don't see how.
>
> > 2) insert into test_vac_unmodified_heap values (1); executes and
> > commits with xid = 118519 (from my log)
> > 3) vacuum freeze starts and computes cutoff xid = 118518, because
> > oldest xmin is 118518 from (1)
> >
> > *and we cannot freeze tuple*
>
> - Melanie
--
Best regards,
Kirill Reshke
On Thu, 29 Jan 2026 at 20:16, Melanie Plageman
<melanieplageman(at)gmail(dot)com> wrote:
>
> On Thu, Jan 29, 2026 at 8:39 AM Kirill Reshke <reshkekirill(at)gmail(dot)com> wrote:
> >
> > Thanks Alexander!
> > This is a good and detailed report, I was able to reproduce this.
>
> Thanks to both of you for looking into it!
>
> > I have added some logs to my copy of postgres with your patch and I
> > think problem causing this test to fail is this sequence:
> >
> > 1) Autovacuum starts, does its deeds, and acquiring xid = 118518
>
> So, in this scenario, is the issue that autovacuum runs before vacuum
> freeze? If so, we can change the table DDL to:
>
> create table test_vac_unmodified_heap(a int) with (autovacuum_enabled = false);
>
> which would prevent the autovacuum from running.
>
> Unless there is some other way for one of the other tests to hold
> OldestXmin back to before the xid of the insert. But I don't see how.
>
> > 2) insert into test_vac_unmodified_heap values (1); executes and
> > commits with xid = 118519 (from my log)
> > 3) vacuum freeze starts and computes cutoff xid = 118518, because
> > oldest xmin is 118518 from (1)
> >
> > *and we cannot freeze tuple*
>
> - Melanie
--
Best regards,
Kirill Reshke
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Andrey Borodin | 2026-01-30 09:25:03 | Re: eliminate xl_heap_visible to reduce WAL (and eventually set VM on-access) |
| Previous Message | Ashutosh Bapat | 2026-01-30 09:22:13 | Re: Improvements and refactoring in shmem.c |