Skip site navigation (1) Skip section navigation (2)

Re: VACUUM FULL memory requirements

From: Greg Stark <gsstark(at)mit(dot)edu>
To: David Schnur <dnschnur(at)gmail(dot)com>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: VACUUM FULL memory requirements
Date: 2009-12-14 18:34:01
Message-ID: 407d949e0912141034t57a37fcfqd23082540df0ec85@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-admin
On Mon, Dec 14, 2009 at 5:53 PM, David Schnur <dnschnur(at)gmail(dot)com> wrote:
> Is my understanding of VACUUM v.s. VACUUM FULL correct, actually?  It
> appears to work that way, but the docs are a little vague on whether plain
> VACUUM ever frees actual disk space, or just reclaims it for the DB.

Basically. VACUUM does check to see if there just happens to be some
space at the end of the file it can truncate off but it doesn't go out
of its way to create such space. VACUUM FULL actually moves all the
tuples at the end of the file to earlier free spots. Moving tuples in
Postgres is really really hard because it has to be transaction-safe
and requires exclusive locking.

-- 
greg

In response to

pgsql-admin by date

Next:From: Kevin GrittnerDate: 2009-12-14 18:50:40
Subject: Re: VACUUM FULL memory requirements
Previous:From: David SchnurDate: 2009-12-14 17:53:26
Subject: Re: VACUUM FULL memory requirements

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group