On Mon, 2005-12-05 at 16:30, Ed L. wrote:
> On Monday December 5 2005 3:17 pm, Tom Lane wrote:
> > There isn't any particularly good reason to be resizing
> > shared_buffers on the fly anyway; much easier to let the
> > kernel adapt the size of its disk cache instead. Best
> > practice for shared_buffers is to set it somewhere in the
> > range of 10K to 50K and forget it.
>
> Oh, how I wish it were so on these boxes. However, HP gurus tell
> me that OS dynamic buffer caches larger than ~800MB +/- slop
> have diminishing returns due to contention between vhand and
> others. Therefore, to most effectively take advantage of a big
> multi-cluster box with gobs of RAM for DB caching, it seems to
> me I need to specifically allocate the available RAM among the
> DB clusters. [This is a pain and I'd much rather the OS did it
> for me.] Of course, we don't know how many clusters we'll have
> and of what size when we start. Thus, the need for resizing the
> DB caches as new clusters come online. Does that make sense?
What OS are you running? In the case of Linux, you're usually better
off letting the kernel handle the caching, although there are times when
giving a fair bit of it to postgresql can help.
Have you actually benchmarked your setup with most memory used as kernel
cache versus most allocated amongst, say, 10 to 20 backends to get a
feel for whether the HP gurus really were right?
Never take anyone's word as the truth until you've tested it for
yourself and proven it one way or another.