Re: Need help in setting optimal configuration for a huge - Mailing list pgsql-performance

From Dennis Bjorklund
Subject Re: Need help in setting optimal configuration for a huge
Date
Msg-id Pine.LNX.4.44.0510231200490.11189-100000@zigo.dhs.org
Whole thread Raw
In response to Need help in setting optimal configuration for a huge database.  (Kishore B <kishorebh@gmail.com>)
List pgsql-performance
On Sun, 23 Oct 2005, Kishore B wrote:

> We need to insert into the bigger table almost for every second , through
> out the life time. In addition, we receive at least 200,000 records a day at
> a fixed time.
>
> We are facing a* critical situation because of the performance of the **
> database**.* Even a basic query like select count(*) from bigger_table is
> taking about 4 minutes to return.

Count(*) like that always scans the full table, but 4 minutes still sound
like a lot.  How often do you vacuum? Could it be that the disk is full of
garbage due to not enough vacuum?

A query like this can help find bloat:

 SELECT oid::regclass, reltuples, relpages FROM pg_class ORDER BY 3 DESC;

I assume to do updates and deletes as well, and not just inserts?

--
/Dennis Björklund


pgsql-performance by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: prepared transactions that persist across sessions?
Next
From: "Steinar H. Gunderson"
Date:
Subject: Re: Materializing a sequential scan