Replication and Mirroring together

  • I am planning to setup mirroring and replication on a production database with high safety mode with automatic failover. According to msft document, it only supports published databases. The server which I am currently acts as subscription server for other articles replicating from other node. I want to keep that intact even after failovering these databases. Can i do that by adding @parameter_name = N'-PublisherFailoverPartner' to the distribution agent? Any suggestions?

  • Unfortunately, the only supported HA technology for replication subscribers is clustering. All other techniques that change the server name (mirroring, log shipping, AlwaysOn AGs) are not available for replication subscribers. This is because the replication agents use the actual @@servername to identify the subscriber: the only HA technology that doesn't change the @@servername is clustering.

    -- Gianluca Sartori

  • Gianluca is correct (not that anybody should doubt that!), so for such situations here we have scripts ready that will remove Replication and set it up again with the new Publisher, if such a situation should arise.

  • BrainDonor (4/20/2015)


    Gianluca is correct (not that anybody should doubt that!), so for such situations here we have scripts ready that will remove Replication and set it up again with the new Publisher, if such a situation should arise.

    Thanks guys. As we have to edit the profile settings in the distribution database. Do we have to create seperate distribution servers which are other nodes which are involved in replication but are not mirrored servers.

  • muthyala_51 (4/22/2015)


    BrainDonor (4/20/2015)


    Gianluca is correct (not that anybody should doubt that!), so for such situations here we have scripts ready that will remove Replication and set it up again with the new Publisher, if such a situation should arise.

    Thanks guys. As we have to edit the profile settings in the distribution database. Do we have to create seperate distribution servers which are other nodes which are involved in replication but are not mirrored servers.

    I'm not sure you even need a seperate distribution server. If I recall correctly you can have different distribution databases on the Distributor for each Publisher Server, so one distributor can handle several publishers on several servers. just make sure the Distributor is also registered against the 'DR' Publisher, so you just need to run the scripts to move the Publication.

  • I tested with one distribution database with AG and mirroring. Everything is working as expected before and after mirror failover or AG failover. I think there's no need to create multiple distribution databases.

  • muthyala_51 (4/29/2015)


    I tested with one distribution database with AG and mirroring. Everything is working as expected before and after mirror failover or AG failover. I think there's no need to create multiple distribution databases.

    Excellent, thank you for letting us know.

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply