public inbox for [email protected]  
help / color / mirror / Atom feed
From: Josh Berkus <[email protected]>
To: Peter Eisentraut <[email protected]>
To: [email protected]
Subject: Re: Section "Routine Reindexing"
Date: Mon, 3 Nov 2003 12:13:15 -0800
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

Peter,

> """
> In some situations it is worthwhile to rebuild indexes periodically with
> the REINDEX command. (There is also contrib/reindexdb which can reindex an
> entire database.) However, PostgreSQL 7.4 has substantially reduced the
> need for this activity compared to earlier releases.
> """

Is this for the main docs, or for the Annotated release notes?

If for the main docs:

<para>
PostgreSQL 7.4 manages deleted nodes from indexes on tables with many deletes 
and/or updates using the Free Space Map (FSM) as it does for the tables 
themselves (this is a new feature).  If your max_fsm_pages setting in 
postgresql.conf is correctly set and you vacuum regularly, there should be no 
need for reindexing for most databases most of the time.
</para>
<para>
If your settings are not correct or if your database usage pattern is one that 
FSM and vaccum cannot cope with, such as huge batch updates, then you will 
need to reindex some or all of your indexes on the updated fields 
periodically.  You can determine this by watching for sluggish index response 
times and index growth out of proportion to the growth of the underlying 
table.  In order to reindex an entire database, see the contrib/reindexdb 
module in the PostgreSQL source code.  Please note that reindex exclusively 
locks each table while processing.
</para>


-- 
Josh Berkus
Aglio Database Solutions
San Francisco




view thread (2+ messages)

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: [email protected]
  Cc: [email protected], [email protected]
  Subject: Re: Section "Routine Reindexing"
  In-Reply-To: <[email protected]>

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

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