Wisdom of merging 100s of Oracle instances into one instance

Posted by hoytster on Stack Overflow See other posts from Stack Overflow or by hoytster
Published on 2010-03-08T23:48:37Z Indexed on 2010/03/08 23:51 UTC
Read the original article Hit count: 392

Our application runs on the web, is mostly an inquiry tool, does some transactions. We host the Oracle database. The app has always had a different instance of Oracle for each customer. A customer is a company which pays us to provide our service to the company's employees, typically 10,000-25,000 employees per customer. We do a major release every few years, and migrating to that new release is challenging: we might have a team at the customer site for a couple weeks, explaining new functionality and setting up the driving data to suit that customer.

We're considering going multi-client, putting all our customers into a single shared Oracle 11g instance on a big honkin' Windows Server 2008 server -- in order to reduce costs. I'm wondering if that's advisable.

There are some advantages to having separate instances for each customer. Tell me if these are bogus, please. In my rough guess about decreasing importance:

  • Our customers MyCorp and YourCo can be migrated separately when breaking changes are made to the schema. (With multi-client, we'd be migrating 300+ customers overnight!?!)

  • MyCorp's data can be easily backed up and (!!!) restored, without affecting other customers.

  • MyCorp's data is securely separated from their competitor YourCo's data, without depending on developers to get the code right and/or DBAs getting the configuration right.

  • Performance is better because the database is smaller (5,000 vs 2,000,000 rows in ~50 tables).

  • If MyCorp's offices are (mostly) in just one region, then the MyCorp's instance can be geographically co-located there, so network lag doesn't hurt performance. We can provide better service to global clients, for the same reason.

  • In MyCorp wants to take their database in-house, then we can easily export their instance, to get MyCorp their data.

  • Load-balancing is easier because instances can be placed on different servers (this is with a web farm).

  • When a DEV or QA instance is needed, it's easier to clone the real instance and anonymize the data, because there's much less data.

  • Because they're small enough, developers can have their own instance running locally, so they can work on code while waiting at the airport and while in-flight, without fighting VPN hassles.

Q1: What are other advantages of separate instances?

We are contemplating changing the database schema and merging all of our customers into one Oracle instance, running on one hefty server.

Here are advantages of the multi-client instance approach, most important first (my WAG). Please snipe if these are bogus:

  • Less work for the DBAs, since they only need to maintain one instance instead of hundreds. Less DBA work translates to cheaper, our main motive for this change.

  • With just one instance, the DBAs can do a better job of optimizing performance. They'll have time to add appropriate indexes and review our SQL.

  • It will be easier for developers to debug & enhance the application, because there is only one schema and one app (there might be dozens of schema versions if there are hundreds of instances, with a different version of the app for each version of the schema). This reduces costs too. The alternative is having to start every debug session with (1) What version is this customer running and (2) Let's struggle to recreate the corresponding development environment, code and database. (We need a Virtual Machine that includes the code AND database instance for each patch and release!)

  • Licensing Oracle is cheaper because it's priced per server irrespective of heft (or something -- I don't know anything about the subject).

  • The database becomes a viable persistent store for web session data, because there is just one instance.

  • Some database operations are easier with one multi-client instance, like finding a participant when they're hazy about which customer they (or their spouse, maybe) works for: all the names are in one table. Reporting across customers is straightforward.

Q2: What are other advantages of having multiple clients in one instance?

Q3: Which approach do you think is better (why)? Instance per customer, or all customers in one instance?

I'm concerned that having one multi-client instance makes migration near-impossible, and that's a deal killer...

... unless there is a compromise solution like having two multi-client instances, the old and the new. In that case case, we would design cross-instance solutions for finding participants, reporting, etc. so customers could go from one multi-client instance to the next without anything breaking.

THANKS SO MUCH for your collective advice! This issue is beyond me -- but not beyond the collective you. :)

  • Hoytster

© Stack Overflow or respective owner

Related posts about Oracle

Related posts about multiple-instances