Re: Automatic free space map filling - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Automatic free space map filling
Date
Msg-id 20060303150517.GC5865@surnet.cl
Whole thread Raw
In response to Re: Automatic free space map filling  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: Automatic free space map filling
List pgsql-hackers
Bruce Momjian wrote:
> Alvaro Herrera wrote:
> > Csaba Nagy wrote:
> > 
> > > Now when the queue tables get 1000 times dead space compared to their
> > > normal size, I get performance problems. So tweaking vacuum cost delay
> > > doesn't buy me anything, as not vacuum per se is the performance
> > > problem, it's long run time for big tables is.
> > 
> > So for you it would certainly help a lot to be able to vacuum the first
> > X pages of the big table, stop, release locks, create new transaction,
> > continue with the next X pages, lather, rinse, repeat.
> 
> But what about index clearing?  When do you scan each index?

At the end of each iteration (or earlier, depending on
maintenance_work_mem).  So for each iteration you would need to scan the
indexes.

Maybe we could make maintenance_work_mem be the deciding factor; after
scanning the indexes, do the release/reacquire locks cycle.

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Automatic free space map filling
Next
From: Martijn van Oosterhout
Date:
Subject: Re: Automatic free space map filling