Re: postgresql meltdown on PlanetMath.org

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Stark <gsstark(at)mit(dot)edu>
Cc: Aaron Krowne <akrowne(at)vt(dot)edu>, Sean Chittenden <sean(at)chittenden(dot)org>, pgsql-performance(at)postgresql(dot)org
Subject: Re: postgresql meltdown on PlanetMath.org
Date: 2003-03-17 16:11:05
Message-ID: 6661.1047917465@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

Greg Stark <gsstark(at)mit(dot)edu> writes:
> Is there any easy way to check an existing table for lost free space?

contrib/pgstattuple gives a pretty good set of statistics. (I thought
VACUUM VERBOSE printed something about total free space in a table,
but apparently only VACUUM FULL VERBOSE does. Maybe should change
that.)

> Is there any way vauum could do this check and print a warning suggesting
> using vaccuum full and/or increasing fsm parameters if it finds such?

In CVS tip, a whole-database VACUUM VERBOSE gives info about the free
space map occupancy, eg

INFO: Free space map: 224 relations, 450 pages stored; 3776 total pages needed.
Allocated FSM size: 1000 relations + 20000 pages = 178 KB shared mem.

If the "pages needed" number is drastically larger than the allocated
FSM size, you've got a problem. (I don't think you need to panic if
it's just a little larger, though. 10X bigger would be time to do
something, 2X bigger maybe not.)

regards, tom lane

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Chris Sutton 2003-03-17 17:12:32 Re: postgresql meltdown on PlanetMath.org
Previous Message Greg Stark 2003-03-17 15:58:39 Re: postgresql meltdown on PlanetMath.org