Skip site navigation (1) Skip section navigation (2)

Re: Getting Slow

From: Greg Smith <gsmith(at)gregsmith(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Re: Getting Slow
Date: 2007-06-07 19:26:58
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-performance
On Thu, 7 Jun 2007, Joe Lester wrote:

> Memory: 4GB RAM
> shared_buffers = 10000
> work_mem = 2048
> effective_cache_size = 30000

With these parameters, your server has 80MB dedicated to its internal 
caching, is making query decisions assuming the operating system only has 
240MB of memory available for its caching, and is only allowing individual 
clients to have a tiny amount of memory to work with before they have to 
swap things to disk.  You're not giving it anywhere close to enough memory 
to effectively work with a 5GB database, and your later reports show 
you're barely using 1/2 the RAM in this system usefully.

Multiply all these parameters by 10X, restart your server, and then you'll 
be in the right ballpark for a system with 4GB of RAM.  There might be 
some other tuning work left after that, but these values are so far off 
that until you fix them it's hard to say what else needs to be done.  See for more 
information on this topic.

* Greg Smith gsmith(at)gregsmith(dot)com Baltimore, MD

In response to

pgsql-performance by date

Next:From: Greg SmithDate: 2007-06-07 19:42:41
Subject: Re: VERY slow queries at random
Previous:From: Andrew SullivanDate: 2007-06-07 19:20:25
Subject: Re: reclaiming disk space after major updates

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group