Re: Correlation in cost_index()

From: Manfred Koizar <mkoi-pg(at)aon(dot)at>
To: "scott(dot)marlowe" <scott(dot)marlowe(at)ihs(dot)com>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Correlation in cost_index()
Date: 2002-10-04 17:57:47
Message-ID: uujrpu8nkg0994qqqiurtvt6qbhokfq70u@4ax.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, 3 Oct 2002 10:45:08 -0600 (MDT), "scott.marlowe"
<scott(dot)marlowe(at)ihs(dot)com> wrote:
> effective cache size is the default (i.e. commented out)

The default is 1000, meaning ca. 8 MB, which seems to be way too low.
If your server is (almost) exclusively used by Postgres, try setting
it to represent most of your OS cache (as reported by free on Linux).
Otherwise you have to estimate the fraction of the OS cache that gets
used by Postgres.

I'm still trying to get a feeling for how these settings play
together, so I'd be grateful if you report back the effects this has
on your cost estimates.

Caveat: effective_cache_size is supposed to be the number of cache
pages available to one query (or is it one scan?). So if you have
several concurrent queries (or complex queries with several scans),
you should choose a lower value. OTOH if most of your queries operate
on the same data, one query could benefit from pages cached by other
queries ... You have to experiment a little.

Servus
Manfred

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2002-10-04 18:47:47 Re: Pinning a table into memory
Previous Message Bruce Momjian 2002-10-04 17:53:19 Re: any experience with IA-64