Subject | Config for mostly-readonly DB? |
---|---|
Author | Kjell Rilbe |
Post date | 2005-02-21T09:28:51Z |
Hi,
I have a DB with:
- A rather wide master table containing about 1 million records.
- A small child table with 1-5 records for each master record. Most
masters have only one child, five children is unusual. This table is
only used for where-coditions when selecting records from the master.
- A small lookup table (three columns). This is used to produce output
with cleartexts for master columns containing codes. This table contains
*all* code/cleartext lists so the lookup makes use of an extra code list
name field to determine which code list to use. In other words, when
producing output with cleartexts for N columns, there will be N joins
from the master to this table.
- A small "order history" table that simply holds an order number and a
PK from the master. Every time a user does a select from the master, the
application will also insert the selected PK:s into this table along
with that user's order number.
I need to make the selects and "order history" inserts as fast as
possible. These will use up to hundreds or even thousands of where
conditions based on multiple master columns and the single child table
column. The most common case will probably be 10-100 criteria on 1-3
columns. Most of the columns are very selective, but not all.
How should I configure my DB?
It will be running on a Windows 2003 Server, Pentium 4 without
hyperthreading, 1 Gbyte RAM, single 7200 rpm harddisk. The only other
application is IIS + an ISAPI + my server application. These consume no
more than 100 Mbyte RAM.
Page size 16384? Small pages are good with a lot of concurrent
transactions to avoid having to wait for locks while large pages are
good to improve read/write performance when locks aren't a problem.
Correct? (My DB operations are currently completely serialized.)
Page buffers? Is this the same as the firebird.conf setting
"DefaultDbCachePages"? If Page buffers = 0 in the DB, will it use the
DefaultDbCachePages setting instead?
SortMemBlockSize?
SortMemUpperLimit?
Anything else?
Thanks,
Kjell
--
--------------------------------------
Kjell Rilbe
Adressmarknaden AM AB
E-post: kjell.rilbe@...
Telefon: 08-761 06 55
Mobil: 0733-44 24 64
I have a DB with:
- A rather wide master table containing about 1 million records.
- A small child table with 1-5 records for each master record. Most
masters have only one child, five children is unusual. This table is
only used for where-coditions when selecting records from the master.
- A small lookup table (three columns). This is used to produce output
with cleartexts for master columns containing codes. This table contains
*all* code/cleartext lists so the lookup makes use of an extra code list
name field to determine which code list to use. In other words, when
producing output with cleartexts for N columns, there will be N joins
from the master to this table.
- A small "order history" table that simply holds an order number and a
PK from the master. Every time a user does a select from the master, the
application will also insert the selected PK:s into this table along
with that user's order number.
I need to make the selects and "order history" inserts as fast as
possible. These will use up to hundreds or even thousands of where
conditions based on multiple master columns and the single child table
column. The most common case will probably be 10-100 criteria on 1-3
columns. Most of the columns are very selective, but not all.
How should I configure my DB?
It will be running on a Windows 2003 Server, Pentium 4 without
hyperthreading, 1 Gbyte RAM, single 7200 rpm harddisk. The only other
application is IIS + an ISAPI + my server application. These consume no
more than 100 Mbyte RAM.
Page size 16384? Small pages are good with a lot of concurrent
transactions to avoid having to wait for locks while large pages are
good to improve read/write performance when locks aren't a problem.
Correct? (My DB operations are currently completely serialized.)
Page buffers? Is this the same as the firebird.conf setting
"DefaultDbCachePages"? If Page buffers = 0 in the DB, will it use the
DefaultDbCachePages setting instead?
SortMemBlockSize?
SortMemUpperLimit?
Anything else?
Thanks,
Kjell
--
--------------------------------------
Kjell Rilbe
Adressmarknaden AM AB
E-post: kjell.rilbe@...
Telefon: 08-761 06 55
Mobil: 0733-44 24 64