Re: Deadline-Based Vacuum Delay - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Deadline-Based Vacuum Delay
Date
Msg-id 4550.1167461316@sss.pgh.pa.us
Whole thread Raw
In response to Re: Deadline-Based Vacuum Delay  (Chris Browne <cbbrowne@acm.org>)
Responses Re: Deadline-Based Vacuum Delay
List pgsql-hackers
Chris Browne <cbbrowne@acm.org> writes:
> How you get the work to spread consistently across 6 hours is a
> challenge; personally, my preference would generally be to try to get
> the work done ASAP, so the goal seems a tad off to me...

I think the context for this is that you have an agreed-on maintenance
window, say extending from 2AM to 6AM local time, and you want to get
all your vacuuming done in that window without undue spikes in the
system load (because you do still have live users then, just not as many
as during prime time).  If there were a decent way to estimate the
amount of work to be done then it'd be possible to spread the work
fairly evenly across the window.  What I do not see is where you get
that estimate from --- especially since you probably have more than one
table to vacuum in your window.

The other problem is that "vacuum only during a maintenance window"
doesn't seem all that compelling a policy anyway.  We see a lot of
examples of tables that need to be vacuumed much more often than once
a day.  So I'd rather put effort into making sure that vacuum can be run
in the background even under high load, instead of designing around a
maintenance-window assumption.
        regards, tom lane


pgsql-hackers by date:

Previous
From: "Jonah H. Harris"
Date:
Subject: Re: WITH support
Next
From: Tom Lane
Date:
Subject: Re: TODO: GNU TLS