Re: Huge memory consumption during vacuum (v.8.0)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>
Cc: Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Huge memory consumption during vacuum (v.8.0)
Date: 2005-01-30 07:04:30
Message-ID: 258.1107068670@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Oleg Bartunov <oleg(at)sai(dot)msu(dot)su> writes:
> On Sun, 30 Jan 2005, Tom Lane wrote:
>> I'm confused. The log trace you showed us before appeared to be from
>> a non-FULL vacuum, but here you're saying it's VACUUM FULL. Which is
>> it ... or did you change?

> Yes, first time I tried vacuum from withing psql, next time I decided
> to run vacuumdb and seems changed option.

Um. Well, a VACUUM FULL is going to build in-memory data structures
that represent *all* of the usable free space in a table. I don't
actually think that VACUUM FULL is useful on an enormous table ... you
want to keep after it with routine plain VACUUMs, instead.

Another possibility is to use CLUSTER or a rewriting ALTER TABLE to
shrink the space, but be aware that this requires a transient second
copy of the table and indexes.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Oleg Bartunov 2005-01-30 07:10:34 Re: Huge memory consumption during vacuum (v.8.0)
Previous Message Tom Lane 2005-01-30 06:58:40 Re: Allowing VACUUM to time out when waiting for locks?