pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Rod Taylor <pg@rbt.ca>
To: Puddle <rotaecho@yahoo.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: max_connections / shared_buffers /
Date: Fri, 24 Jun 2005 15:24:05 -0400
Message-ID: <1119641045.45024.73.camel@home> (raw)
In-Reply-To: <20050624185431.56684.qmail@web32807.mail.mud.yahoo.com>
References: <20050624185431.56684.qmail@web32807.mail.mud.yahoo.com>


> 1.) shared_buffers I see lot of reference to making
> this the size of available ram (for the DB).  However,
> I also read to make it the size of pgdata directory.  

> 2.) effective_cache_size - from what I read this is
> the 'total' allowed memory for postgresql to use
> correct? So, if I am willing to allow 1GB of memory
> should I make this 1GB?

shared_buffers in your case should be about 10000. It is not taken on a
per connection basis, but is global for that cluster. Perhaps your
memory analysis tool is fooling with you?

effective_cache_size is what you want to set to the amount of ram that
you expect the kernel to use for caching the database information in
memory. PostgreSQL will not allocate this memory, but it will make
adjustments to the query execution methods (plan) chosen.

> 3.) max_connections, been trying to figure 'how' to
> determine this #.  I've read this is buffer_size+500k
> per a connection.  

> ie.  128mb(buffer) + 500kb = 128.5mb per connection?

Max connections is the number of connections to the database you intend
to allow.

Shared_buffers must be of a certain minimum size to have that number of
connections, but the 10k number above should cover any reasonable
configurations.

> work_mem and max_stack_depth set to 4096
> maintenance_work_mem set to 64mb

Sort_mem and vacuum_mem became work_mem and maintenance_work_mem as
those terms better indicate what they really do.

> Thanks for any help on this.  I'm sure bombardment of
> newbies gets old :)

That's alright. We only request that once you have things figured out
that you, at your leisure, help out a few others.


-- 




Message-ID: <1119641045.45024.73.camel@home>
Permalink:  ../1119641045.45024.73.camel@home/
Also on:    postgresql.org/message-id/1119641045.45024.73.camel@home

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: pg@rbt.ca, rotaecho@yahoo.com
  Subject: Re: max_connections / shared_buffers /
  In-Reply-To: <1119641045.45024.73.camel@home>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox