Re: Automatic free space map filling

From: Hannu Krosing <hannu(at)skype(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Csaba Nagy <nagy(at)ecircle-ag(dot)com>, "Matthew T(dot) O'Connor" <matthew(at)zeut(dot)net>, Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Christopher Browne <cbbrowne(at)acm(dot)org>, postgres hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Automatic free space map filling
Date: 2006-05-03 11:34:08
Message-ID: 1146656049.3824.28.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Ühel kenal päeval, R, 2006-03-03 kell 11:37, kirjutas Tom Lane:
> Alvaro Herrera <alvherre(at)commandprompt(dot)com> writes:
> > 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.
>
> > This is perfectly doable, it only needs enough motivation from a
> > knowledgeable person.
>
> Bruce and I were discussing this the other day; it'd be pretty easy to
> make plain VACUUM start a fresh transaction immediately after it
> finishes a scan heap/clean indexes/clean heap cycle.

Do you mean the full (scan heap/clean indexes/clean heap) cycle or some
smaller cycles inside each step ?

If you mean the full cycle, then it is probably not worth it, as even a
single 'clean index' pass can take hours on larger tables.

> The infrastructure
> for this (in particular, session-level locks that won't be lost by
> closing the xact) is all there. You'd have to figure out how often to
> start a new xact ... every cycle is probably too often, at least for
> smaller maintenance_work_mem settings ... but it'd not be hard or
> involve any strange changes in system semantics.

-----------
Hannu

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Jim Buttafuoco 2006-05-03 13:10:19 drop database command blocking other connections
Previous Message Fabien COELHO 2006-05-03 08:46:02 bug? non working casts for domain