From: | Peter Geoghegan <pg(at)bowt(dot)ie> |
---|---|
To: | Andres Freund <andres(at)anarazel(dot)de> |
Cc: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Subject: | Re: vacuum_defer_cleanup_age inconsistently applied on replicas |
Date: | 2020-04-03 23:18:32 |
Message-ID: | CAH2-Wz=G92OsMyOeskye3D9QbuJjkoO05_7ntn+AGqBnkDf66g@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Apr 3, 2020 at 3:53 PM Andres Freund <andres(at)anarazel(dot)de> wrote:
> GetOldestXmin() applies vacuum_defer_cleanup_age only when
> !RecoveryInProgress(). In contrast to that GetSnapshotData() applies it
> unconditionally.
>
> I'm not actually clear whether including vacuum_defer_cleanup_age on a
> replica is meaningful. But it strikes me as odd to have that behavioural
> difference between GetOldestXmin() and GetSnapshotData() - without any
> need, as far as I can tell?
Did you notice the comments added by Tom in b4a0223d008, which repeat
the claim that it isn't used on standbys? I think that this is
probably just an oversight in bca8b7f1, as you suggested. It's not
that hard to imagine how this oversight might have happened: Hot
standby feedback was introduced, and nobody cared about
vacuum_defer_cleanup_age anymore. It was always very difficult to
tune.
OTOH, I wonder if it's possible that vacuum_defer_cleanup_age was
deliberately intended to affect the behavior of
XLogWalRcvSendHSFeedback(), which is probably one of the most common
reasons why GetOldestXmin() is called on standbys.
--
Peter Geoghegan
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Geoghegan | 2020-04-03 23:25:55 | Re: vacuum_defer_cleanup_age inconsistently applied on replicas |
Previous Message | Alvaro Herrera | 2020-04-03 23:14:03 | Re: [HACKERS] Restricting maximum keep segments by repslots |