Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 4 Aug 2005 12:13:12 -0700
From:      Sean Chittenden <sean@gigave.com>
To:        Bruce Walker <bmw@borderware.com>
Cc:        freebsd-performance@freebsd.org
Subject:   Re: changing max_connections in postgresql on FreeBSD 5.4
Message-ID:  <20050804191312.GF70123@sean.gigave.com>
In-Reply-To: <42F25526.5030002@borderware.com>
References:  <b41c755205080410013348d0f@mail.gmail.com> <20050804174508.GA70123@sean.gigave.com> <42F25526.5030002@borderware.com>

next in thread | previous in thread | raw e-mail | index | archive | help
> >>Will more RAM become available to postgresql if I change the
> >>kernel-values mentioned above to half the size?
> >
> >Yes, it will raise the in-kernel limits so that PostgreSQL can
> >allocate more RAM for its user-land cache.
> >
> >You will probably have a better ROI in terms of performance by
> >increasing the kernel's caching parameters as opposed to
> >PostgreSQL's cache.  You need both, don't get me wrong, but there
> >is lots of performance to be gained by increasing the amount of
> >caching the kernel does.  -sc
> 
> Any generally good rules of thumb you could share?  Which kernel
> caching are you referring to (ie disk, ...) ?

Hrm... I'll suggest one tunable:

options         KSTACK_MAX_PAGES=32 # Maximum pages to give the kernel stack

Don't crank it up too far, but 64 seems to be a decent number in my
experience.  I'd pimp more settings, but given that tuning is still
closer to an art than a science (it wouldn't be if someone catalogued
settings for various applications and hardware combinations, but I
digress), I'll suggest having you take a peak at the various NOTES
files and some of the headers, such as: src/sys/amd64/include/param.h.
I've divulged more in the archives, too.  -sc

-- 
Sean Chittenden



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050804191312.GF70123>