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

Re: proposal: Set effective_cache_size to greater of .conf value, shared_buffers

From: "Kevin Grittner" <kgrittn(at)mail(dot)com>
To: "Josh Berkus" <josh(at)agliodbs(dot)com>,pgsql-hackers(at)postgresql(dot)org
Subject: Re: proposal: Set effective_cache_size to greater of .conf value, shared_buffers
Date: 2013-01-10 17:26:06
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Josh Berkus wrote:

> The, shared_buffers, wal_buffers, and effective_cache_size (and possible
> other future settings) can be set to -1. If they are set to -1, then we
> use the figure:
> shared_buffers = available_ram * 0.25
> (with a ceiling of 8GB)
> wal_buffers = available_ram * 0.05
> (with a ceiling of 32MB)
> effective_cache_size = available_ram * 0.75
> (with a floor of 128MB)
> If they are set to an amount, then we use the amount they are set to.
> It would be nice to also automatically set work_mem, maint_work_mem,
> temp_buffers, etc. based on the above, but that would be considerably
> more difficult and require performance testing we haven't done yet.

My starting point for work_mem is usually:

work_mem = available_ram * 0.25 / max_connections

Like everything else, I might adjust from there, but it seems like
a sane starting point. Of course, one could easily argue for a
lower percentage or exclusion of some number of maint_work_mem


pgsql-hackers by date

Next:From: Andrew DunstanDate: 2013-01-10 17:31:07
Subject: Re: pg_dump --pretty-print-views
Previous:From: Tom LaneDate: 2013-01-10 17:09:15
Subject: Re: pg_dump --pretty-print-views

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