views:

146

answers:

2

What's the best way to maintain a multiple databases across several platforms (Windows, Linux, Mac OS X and Solaris) and keep them in sync with one another? I've tried several different programs and nothing seems to work!

+2  A: 

I think you should ask yourself why you have to go through the hassle of maintaining multiple databases across several platforms and have them in sync with one another. Sounds like there's a lot of redundancy there. Why not just have one instance of that database, since I'm sure it can be made accessible (e.g. via SOA approach) to multiple apps on multiple platforms anyway?

cruizer
I told the higher ups that that was the best thing to do, but they say that it would be more expensive and labor intensive to do that, so I get stuck doing all this work to maintain the databases. Yes, I do realize that they are wrong and it would be easier to maintain one database.
Iwasakabukiman
is there any particular reason why they insist on having multiple copies of the database on multiple platforms? like, are these copies occasionally disconnected from one another, that's why they insist on having separate instances of it?
cruizer
A: 

Why go through the hassle? Management claims it's more expensive?

Here's how to prove them wrong.

Pick one database, call it the "master" or "system of record".

Write scripts to export data from the master and load it into your copies. If you have a nice database (MySQL, SQL/Server, Oracle or DB2) there are nice tools to do this replication for you. If you have a mixture of databases, you'll have to resort to exporting changed data and reloading changed data. The idea is that this is a 1-way copy: master to replicants.

Fix each application, one at a time, to do updates in the master database only. Since each application has a JDBC (or ODBC or whatever) connection to a database, it can just as easily be a connection to the master database.

Once you've fixed the applications to update only the master, the replicas are worthless. Management can insist that it's cheaper to have them. And there they are -- clones of the master database -- just what management says you must have.

Your life is simpler because the apps are only updating the system of record. They're happy because you have all the cloned databases lying around.

S.Lott