Re: Report oldest xmin source when autovacuum cannot remove tuples - Mailing list pgsql-hackers

From Scott Ray
Subject Re: Report oldest xmin source when autovacuum cannot remove tuples
Date
Msg-id qOUvBIi7LC3GLKEjACMQAhPnYaE1m7Ta6XbMXN1gOVo3Mh6-Be6o_kQxQeCNXfo-Ywgc8k6myZrco4a41z-r7Dfqro4-nH73cB_tmSOczJk=@scottray.io
Whole thread
Responses Re: Report oldest xmin source when autovacuum cannot remove tuples
List pgsql-hackers
> What I would want to investigate after seeing such a signal is not
> necessarily what happened to be blocking that particular VACUUM
> operation at some earlier point, but what is holding the xid horizon
> back now.  For that purpose, a view exposing the current xid/xmin
> holders seems more useful and less misleading than adding a
> best-effort blocker guess to the VACUUM log.

I've been working on a view like this.  It shows the horizon
contribution for each backend, prepared xact, replication slot, and
HSF walsender, broken down by class.  It also shows - for each
contributor - how the horizon would shift if that holder were
removed.

Shinya said [1] that we could have a view in the future.  We could
have both the logging and the view call a single function that reads
the procArray and other sources to gather the horizon information.  I
think the logging and the view would complement each other.

Should I start another thread?

[1] https://www.postgresql.org/message-id/CAOzEurTNVkvvscKeEOy0WwfzyqO+J_MyXwkjRteJ_zyydteKCQ@mail.gmail.com

--
Scott Ray
Attachment

pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: Unify parallel worker handling for index builds and instrumentation
Next
From: Shinya Kato
Date:
Subject: Re: Report oldest xmin source when autovacuum cannot remove tuples