Re: [GENERAL][HACKERS]data fragmentation

From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Somasekhar Bangalore <sbangalore(at)zensutra(dot)com>
Cc: Jaime Casanova <el_vigia_ec(at)hotmail(dot)com>, pgsql-general(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org, pgsql-admin(at)postgresql(dot)org, K Harikumar <kharikumar(at)zensutra(dot)com>, Anoop G <ganoop(at)zensutra(dot)com>, Sanjay Rathod <srathod(at)zensutra(dot)com>
Subject: Re: [GENERAL][HACKERS]data fragmentation
Date: 2003-12-16 22:03:14
Message-ID: 20031216220314.GE14503@dcc.uchile.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-general pgsql-hackers

On Fri, Dec 12, 2003 at 09:59:23AM +0530, Somasekhar Bangalore wrote:
> Hi,
>
> I too had the same problem; There was one query which used to take a
> very long time. What I did was, I took a backup of the whole database.
> Reinstalled postgres on a different mount point and restored the data
> back into the new database. Now my queries are running faster. Try it.
> All the very best.

You could instead apply CLUSTER to the affected tables. (I'm assuming you
already apply VACUUM periodically and REINDEX as appropiate)

--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"Everybody understands Mickey Mouse. Few understand Hermann Hesse.
Hardly anybody understands Einstein. And nobody understands Emperor Norton."

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message sachdev 2003-12-17 04:02:31 Re: comparing with oracle
Previous Message scott.marlowe 2003-12-16 21:05:19 Re: Postgresql on software RAID

Browse pgsql-general by date

  From Date Subject
Next Message Rick Gigger 2003-12-16 22:58:27 Re: add column sillyness
Previous Message Alvaro Herrera 2003-12-16 22:01:16 Re: Strange permission problem regarding pg_settings

Browse pgsql-hackers by date

  From Date Subject
Next Message Neil Conway 2003-12-16 22:37:31 Re: [pgsql-hackers-win32] [PATCHES] fork/exec patch
Previous Message Jon Jensen 2003-12-16 21:48:18 Re: Resurrecting pg_upgrade