Re: Pg 8.3 tuning recommendations for embedded low-memory device (for OLPC :-) )

From: Ernesto Quiñones <ernestoq(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Pg 8.3 tuning recommendations for embedded low-memory device (for OLPC :-) )
Date: 2008-09-15 05:01:55
Message-ID: 2ba222580809142201u6d643438o40ec14451dc7b9b2@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I was working in the past with postgres in some machines with only
192mb ram shared with Linux Os (redhat9 and conectiva10) with KDE,
Apache and Postfix, the exact version was 7.4 and pgsql work fine
withput problems and many coneccionts because this machine were a
public web server. The configutation was the default configuration in
Conectiva without changes and all work fine.

Now I am trying to compile Pgsql in some architectures like Via but
now my problem is the OS (Linux of course), I hope to install Pgsql
8.3 in a machine with very little resources like an OLPC (I am trying
to have an AMD Geod in a Mini ITX mainboard).

good luck

2008/9/14 Martin Langhoff <martin(dot)langhoff(at)gmail(dot)com>:
> On Mon, Sep 15, 2008 at 11:55 AM, Martin Langhoff
> <martin(dot)langhoff(at)gmail(dot)com> wrote:
>> ... so RAM allocation for Pg will prob range between 32MB at the
>> lower-end and 128MB/196MB at the 1GB "recommended" RAM.
>
> Assuming a 128MB target, I've been poking and probing with the
> postgresql.conf and the new settings...
>
> - 1/4 of it to shared buffers
> - 45 max connections - matched to a max of 40 apache/php processes
> - 2MB work_mem (some complex queries in Moodle require sorts)
>
> means 32MB shmem and an unlikely maximum of 90MB taken for work_mem.
> There is 6MB left over in my "budget" which I expect will be consumed
> by per-connection overheads. When I start up Pg on this machine,
> ps_mem.py (a nice smap parse-and-summarise tool) tells me a completely
> idle postmaster:
>
> Private + Shared = RAM used Program
> (...)
> 2.9 MiB + 1.0 MiB = 3.9 MiB postmaster (6)
>
> These are the changes I'm making to the default postgresql.conf:
>
> +max_connections = 45
> +## work_mem can also cost up to max_connections * work_mem
> +
> +shared_buffers = 32MB
> +temp_buffers = 8MB
> +max_prepared_transactions = 5
> +work_mem = 2MB
> +maintenance_work_mem = 16MB
> +max_stack_depth = 2MB
> +wal_buffers = 1MB
> +wal_writer_delay = 1000ms
>
> cheers,
>
>
>
> m
> --
> martin(dot)langhoff(at)gmail(dot)com
> martin(at)laptop(dot)org -- School Server Architect
> - ask interesting questions
> - don't get distracted with shiny stuff - working code first
> - http://wiki.laptop.org/go/User:Martinlanghoff
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general
>

--
Inscribete en las listas de APESOL
http://www.apesol.org/listas.php

Visita
http://www.eqsoft.net
Manuales, noticias, foros, etc.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Martin Langhoff 2008-09-15 05:32:50 Re: Pg 8.3 tuning recommendations for embedded low-memory device (for OLPC :-) )
Previous Message Craig Ringer 2008-09-15 04:32:06 Re: [GENERAL] PostgreSQL