Re: Optimizing POSTGRESQL config

From: Manfred Koizar <mkoi-pg(at)aon(dot)at>
To: Joanne Formoso <joanneformoso(at)yahoo(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Optimizing POSTGRESQL config
Date: 2003-05-02 14:22:00
Message-ID: l5u4bv4a23rcrk9qpum1dle8ts153ebrv6@4ax.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Fri, 2 May 2003 00:28:34 -0700 (PDT), Joanne Formoso
<joanneformoso(at)yahoo(dot)com> wrote:
>We are using Apache webserver
>together with PHP and PostgreSQL 7.3.2. Our test
>server has the following specs: AMD Athlon 1.2 Gz
>with 128 MB of ram.

Who sold you a 1.2 GHz machine with 128 MB? Next time better buy 600
MHz and 256 MB RAM ;-) So the short answer is: Buy more memory.
OTOH you *can* configure Postgres to run satisfactorily on small
hardware.

>shared_buffers = 11207 # min max_connections*2 or 16, 8KB each

This means almost 90 MB which is way too much for your small machine.
I'd recommend shared_buffers = 1000.

>sort_mem = 32168 # min 64, size in KB

32 MB sort mem together with 90 MB shared memory, so a single sort can
cause your system to start swapping, not to mention Apache and other
processes running on that system...

>fsync = false

Only do this if you don't care for consistency after a crash.

>LC_MESSAGES = 'en_US.iso885915'
>LC_MONETARY = 'en_US.iso885915'
>LC_NUMERIC = 'en_US.iso885915'
>LC_TIME = 'en_US.iso885915'

This may slow down certain kinds of queries, locale C seems to be a
better choice if you have speed in mind. Search the archives for
details.

Servus
Manfred

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message Josh Berkus 2003-05-02 20:18:21 Re: Optimizing POSTGRESQL config
Previous Message A.Bhuvaneswaran 2003-05-02 14:00:30 Re: file plpgsql.so missing