dongxie8906
dongxie8906
2011-12-13 09:53
浏览 157
已采纳

MSSQL - > MySQL或PostgreSQL数据库复制

I find myself in a situation that someone else must have got stuck in at some point.

Our company runs an in house MSSQL based database, our website then sits on an external server and currently runs MySQL. The problem comes that both databases need to communicate with each other increasingly often.

Our current solution involves SSIS packages but they are tempromental and often slow. We end up very often having to drop tables on our live production server before then rebuilding them from the in house server. Of course this is leading to data inconsistencies so we try and perform these operations outside of peak hours. However, this leads to 24hr delays in some data being transferred from MySQL to MSSQL and then an additional 24hr delay in getting it back to MySQL. None of this is ideal.

What I am looking for is a solution that will allow replication between our in-house MSSQL server and any database that can sit upon a linux box and play nicely with PHP. As I said, we currently run MySQL so we have a preference to any solution that would include that but all other suggestions would be greatfully received.

I've read somewhere that PostgreSQL is a vialbe solution but I am now struggling to find where I read that. I've come accross a few tools that might help such as DBMoto and Slony-I, does anyone have any experience of either in such a situation?

Alternatively, are we simply barking up the wrong tree altogether and should we be trying to integrate MSSQL into our PHP environment?

Any thoughts or suggestions would be gratefully recieved.

Many thanks

Rob

  • 点赞
  • 写回答
  • 关注问题
  • 收藏
  • 邀请回答

2条回答 默认 最新

  • dounue1965
    dounue1965 2011-12-13 10:11
    已采纳

    The best solution that i know and i have used for this kind of job is SymmetricDS .

    SymmetricDS is an asynchronous data replication software package that supports multiple subscribers and bi-directional synchronization.

    点赞 评论
  • douchengfei3985
    douchengfei3985 2011-12-13 11:27

    You can access MSSQL servers from PHP using FreeTDS and the mssql_* family of functions (or classes built thereon, or alternative freetds-using extensions). We use this for our admin application, with a Linux/PHP website talking to a MSSQL database.

    点赞 评论

相关推荐