Subject Re: Large Firebird 1.5 database
Author russellbelding
Sean, thanks for your comments.

--- In firebird-support@yahoogroups.com, "Leyne, Sean" <Sean@B...>
wrote:
> Russell,
>
> > Is it surprising that 200 connections consumes 2000Mb of memory or
> > 10Mb per user?
>
> To my mind, yes!
>
> Not necessarily exceptional, but this is the first time that I ever
> recall hearing that someone ran "out of memory". {I've used FB/IB
since
> 1995}
>
>
> > By way of example I have measured my app's memory consumption at
the
> > FB server (delphi 6, IBO, FB 1.5.1 SuperServer, Win 2K
workstation as
> > server) using Task manager's "mem usage" for process fbserver.
>
> FYI, task manager is not always the best tool to measure memory
usage.

OK. Is there a better option?
>
>
> > At rest with no connections fbserver uses 3040Kb.
> > 1 bare connection causes fbserver to use 5704Kb more.
> > 2 bare connections cause fbserver to use 2096Kb more.
> > 3 bare connections cause fbserver to use 920Kb more.
> > 4 bare connections cause fbserver to use 544Kb more.
> > A "bare connection" means on a client PC I open my app, and a
minimal
> > datamodule. fbserver seems to share memory?
> >
> > My app, usually operates on "matters".
> > Opening a matter causes fbserver to use 1000Kb.
> >
> > A user may have many matters open. So assuming fbserver
stabilises at
> > 600Kb per connection (I have not tried more than 4 connections
yet)
> > and 1000Kb per matter then N users with M matters open such that
> > 600N + 1000M = 2000000 will consume 2Gb.
>
> I believe that your methodology is invalid, you have measured/tested
> "start up" conditions not real world -- long term usage.

Yes I have measured startup conditions, not after N minutes use. I am
assuming, perhaps incorrectly, that the fbserver memory consumption
will not drop below these numbers. Would they be the floor? This
would not be the floor is, as work was done, fbserver released some
memory. I do not know fbserver internals so I'm guessing.

>
> Your 1000KB for 1 matter, could easily be the memory usage for 10
> matters. It depends on the number of database pages which have been
> loaded into cache to satisfy the search and read request.
>
> With Superserver, the memory footprint will eventually "nearly"
flatten
> out, regardless of the number of connections. When you consider
that
> the single largest memory usage is for the page cache, which will
> eventually reach its preset limit/maximum size.
>
OK. You are telling me things I do not know, thanks. Is there a
source for such information?

Kind regards

Russell
>
> Sean