cancel
Showing results for 
Search instead for 
Did you mean: 

Two databases running under the same engine instance

Former Member
4,024

Hi

I have 2 databases, one is ~30gb and contains all the relational data and one is ~300gb and contains only one table with blobs.

Currently I am running these DBs both in the same engine instance, is this a good idea? What advantages or disadvantages to this setup are there?

Thanks! Ivan

Accepted Solutions (1)

Accepted Solutions (1)

Former Member

When running two DBs on one engine you must consider cache concurrency factor. Two DB share same memory and blobs data can push out OLTP DB datapages from DB cache. Of course, it depends from your DBs usage scenario.

Answers (3)

Answers (3)

justin_willey
Participant

It does depend very much on the circumstances; as Dmitri says, running on the same engine allows resources to be shared intelligently However one downside is that an assertion on one database (hopefully a very rare event) will stop both databases. On 32bit systems one can sometimes improve performance with two engines because more memory overall can be allocated to two separate processes than to a single process.

VolkerBarth
Contributor
0 Kudos

Really? I've been not aware of that rule, always thought that all user processes share a 2 GB address space (unless booted with /3G and the like...).

justin_willey
Participant
0 Kudos

Yes - but the amount available to any single process is (I believe) limited by the amount of contiguous memory available when the process starts, and I have seen this down around the 1.2G mark - even when there is plenty more available.

I could easily be wrong on this - so I welcome comments!

justin_willey
Participant
0 Kudos

In your case it sounds like the two database are used by the same front end - so it may not matter that both would be stopped by a problem with one of them.

0 Kudos

32-bit processes are limited to 2G RAM per process, not per computer :).

VolkerBarth
Contributor
0 Kudos

Thanks for the correction - per process is what I really meant:

AFAIK, all Win32 processes do have 4 GB of address space, but by default only 2 GB are available for user space. - IMHO, that would mean one process would not limitate another one's address space...

I won't recommend running databases on separate engines as they'll be competing for resources (primarily RAM). Single engine hosting 2 databases can manage resources in a more intelligent fashion :).

VolkerBarth
Contributor

I guess there's not much too tell without you giving more information on your goals and your sysrem requirements.

For a general discussion on the different architectures (putting tables into separate machines vs. database servers vs. separate databases on the same database server vs. same database...) there's a blog article series "Multi-Tenant Database Architecture" from Chris Kleisath that might help: It deals with splitting application data for different tenants and shows the pros and cons of each alternative. Though I'm aware that "multi-tenant" is not your particular concern I guess you might still make use of the information. I'd consider parts 3 and 4 primarily.