pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Richard Huxton <dev@archonet.com>
To: Andrus <kobruleht2@hot.ee>
Cc: PFC <lists@peufeu.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Hash join on int takes 8..114 seconds
Date: Fri, 21 Nov 2008 16:32:50 +0000
Message-ID: <4926E2B2.9050202@archonet.com> (raw)
In-Reply-To: <75A918DFCF25470FAF96B3FE3D25A38B@andrusnotebook>
References: <gg1sv3$27fr$1@news.hub.org>
	<49253FE1.3070706@archonet.com>
	<0205611B528C4C2CBA99AFC64E57D6E8@andrusnotebook>
	<op.ukw669uvcigqcu@soyouz>
	<75A918DFCF25470FAF96B3FE3D25A38B@andrusnotebook>

Andrus wrote:
>> - what's the size of the dataset relative to the RAM ?
> 
> Db size is 7417 MB
> relevant table sizes in desc by size order:
> 
>      1        40595 dok                                 2345 MB


>      2         1214 pg_shdepend                         2259 MB
>      6         1232 pg_shdepend_depender_index          795 MB
>      7         1233 pg_shdepend_reference_index         438 MB

These three are highly suspicious. They track dependencies between
system object (so you can't drop function F because trigger T depends on
it).

http://www.postgresql.org/docs/8.3/static/catalog-pg-shdepend.html

You've got 3.5GB of data there, which is a *lot* of dependencies.

Try "SELECT count(*) FROM pg_shdepend".

If it's not a million rows, then the table is bloated. Try (as postgres
or some other db superuser) "vacuum full pg_shdepend" and a "reindex
pg_shdepend".

If it is a million rows, you'll need to find out why. Do you have a lot
of temporary tables that aren't being dropped or something similar?

-- 
  Richard Huxton
  Archonet Ltd



view thread (41+ messages)  latest in thread

Message-ID: <4926E2B2.9050202@archonet.com>
Permalink:  ../4926E2B2.9050202@archonet.com/
Also on:    postgresql.org/message-id/4926E2B2.9050202@archonet.com

 · 

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: dev@archonet.com, kobruleht2@hot.ee, lists@peufeu.com
  Subject: Re: Hash join on int takes 8..114 seconds
  In-Reply-To: <4926E2B2.9050202@archonet.com>

* 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