pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alan Stange <stange@rentec.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: unused item pointers?
Date: Tue, 23 Aug 2005 00:42:09 -0400
Message-ID: <28371.1124772129@sss.pgh.pa.us> (raw)
In-Reply-To: <430A8F30.7050706@rentec.com>
References: <430A8F30.7050706@rentec.com>

Alan Stange <stange@rentec.com> writes:
> INFO: "tbltimeseries": found 8610108 removable, 26165807 nonremovable 
> row versions in 5744789 pages
> DETAIL: 0 dead row versions cannot be removed yet.
> There were 235555635 unused item pointers.
> 0 pages are entirely empty.

The item pointers themselves are not very interesting --- at 4 bytes
apiece, they're only accounting for 2% of the table space.  However
the fact that there are nearly 10x more unused than used ones suggests
that this table is suffering a pretty serious bloat problem.  Assuming
constant-width rows in the table, that implies something like 90% of
the space in the table is unused.  (contrib/pgstattuple might be useful
to confirm this estimate.)

VACUUM FULL, or perhaps better CLUSTER, would get you out of that.  And
yes, you will need to vacuum more often afterwards if you want to keep
the bloat under control.

			regards, tom lane



view thread (3+ messages)  latest in thread

Message-ID: <28371.1124772129@sss.pgh.pa.us>
Permalink:  ../28371.1124772129@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/28371.1124772129@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: tgl@sss.pgh.pa.us, stange@rentec.com
  Subject: Re: unused item pointers?
  In-Reply-To: <28371.1124772129@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox