Skip site navigation (1) Skip section navigation (2)

Re: queries are fast after dump->restore but slow again after some days dispite vacuum

From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Felix Scheicher <mandavi(at)web(dot)de>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: queries are fast after dump->restore but slow again after some days dispite vacuum
Date: 2012-07-19 12:38:53
Message-ID: 5007FFDD.5050103@dunslane.net (view raw or flat)
Thread:
Lists: pgsql-performance
On 07/19/2012 07:33 AM, Felix Scheicher wrote:
> Hi, I am running a 9.1 server at Ubuntu. When I upgraded to the current version
> I did a pg_dump followed by pg_restore and found that the db was much faster.
> But slowed down again after two days. I did the dump-restore again and could now
> compare the two (actually identical) databases. This is a query of the old one
> directly after a VACUUM ANALYSE:
...
>
> No matter how much I vacuum or analyse the slow db, I don't get it faster.
> I also checked for dead tuples - there are none.


Try running CLUSTER on the relevant tables and see if it makes a 
difference. If it does you might want to look into using pg_reorg 
periodically.

cheers

andrew

In response to

Responses

pgsql-performance by date

Next:From: Robert HaasDate: 2012-07-19 12:56:51
Subject: Re: [PERFORM] DELETE vs TRUNCATE explanation
Previous:From: Ioannis AnagnostopoulosDate: 2012-07-19 12:24:34
Subject: Re: Index slow down insertions...

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group