Subject | Re: [Firebird-Java] Understanding memory for each connection under classic architecture |
---|---|
Author | Mark Rotteveel |
Post date | 2010-02-07T09:58:12Z |
> I need to tune an application using Jaybird 2.1.6/Firebird 2.1 classic inThis is a totally different question than the one you asked on Firebird-support. This question is one that can better be directed to Firebird-support as it is about the general behaviour of Firebird and has nothing to do with the Java/Jaybird side of things.
> a tomcat application on a 6gig RHEL 5 box.
>
> When I run 'top' on the server, each fb_inet_server process created via
> Jaybird takes around 32meg of VIRT memory and I would like to understand what
> goes into this memory footprint.
>
> 1) The buffers are set to 2048 (gfix -buffers 2048). This means each
> connection should take 8 meg (2048 x 4k page = 8meg).
>
> 2) The TempCacheLimit (formerly SortMemCacheLimit) is not set in
> firebird.conf, so the default should be 8meg. This means each connection should
> take an additional 8meg.
>
> I am not specifying any connection parameters in the Jaybird connection
> string. So all told, it looks like each connection should take 16meg. Why
> then is each connection actually taking 32meg? What am I missing?
To answer your question:
1) In general 2048 pages of buffer is considered too much for a classic server. The default is 75 and more pages should only be used if you really need it, otherwise it is better to let the OS filesystem cache handle the caching.
The cache and sortspace is not the only things that take memory in a Firebird process. Think about the data needed to process the statement, connection details, the data actually materialized from the database to send to the client, etc.
Mark
--
GRATIS für alle GMX-Mitglieder: Die maxdome Movie-FLAT!
Jetzt freischalten unter http://portal.gmx.net/de/go/maxdome01