reindexing

Started by Jean-Christian Imbeaultover 23 years ago2 messagesgeneral
Jump to latest
#1Jean-Christian Imbeault
jc@mega-bucks.co.jp

The online docs have this to say about reindexing a whole DB:

Rebuild all system indexes (this will only work in a standalone
backend):

REINDEX DATABASE my_database FORCE;

What does "standalone backend" mean? And how can I use this command to
reindex my DB? I have tried version commands but always get:

ERROR: REINDEX DATABASE: Can be executed only on the currently open
database.

Thanks!

Jc

#2Richard Huxton
dev@archonet.com
In reply to: Jean-Christian Imbeault (#1)
Re: reindexing

On Friday 06 Dec 2002 10:34 am, Jean-Christian Imbeault wrote:

The online docs have this to say about reindexing a whole DB:

Rebuild all system indexes (this will only work in a standalone
backend):

REINDEX DATABASE my_database FORCE;

What does "standalone backend" mean? And how can I use this command to
reindex my DB? I have tried version commands but always get:

ERROR: REINDEX DATABASE: Can be executed only on the currently open
database.

You run a backend manually without anything else being able to connect. See
"man postgres" for details. You'll want to shut down PG, start the backend
with -O -P flags and the database name, reindex and Ctrl-D to finish. Then,
restart PG normally.

HTH

--
Richard Huxton