SQL Clone
SQLServerCentral is supported by Redgate
Log in  ::  Register  ::  Not logged in

Get your favorite SSC scripts directly in SSMS with the free SQL Scripts addin. Search for scripts directly from SSMS, and instantly access any saved scripts in your SSC briefcase from the favorites tab.
Download now (direct download link)

6 Steps to setting up Replication with Mirroring

By Jacob Golden,

I spent hours looking for information on how to setup transactional replication with updatable subscribers while also using database mirroring. I found some articles that were very helpful but also very confusing.


In the provided script I describe the six steps to successfully setup replication when using mirroring. I like to split the script up into six independent scripts so I can run each of them on the proper servers, so that is where I would start. Once you determine which servers are your distributor, your principal publisher, your mirror publisher and subscriber, the comments section of each script will help you determine where to run them. Just be sure to pay special attention to the variables in each script so you can insert your own values. And as always, you should be aware of the potential performance impact of starting the initial snapshot in production during business hours.


FYI: The script assumes that you already have mirroring setup properly and have tested failover.


Helpful Article I Read:


Total article views: 3921 | Views in the last 30 days: 1
Related Articles

SQL 2005 Disaster Recovery Scripts: To Setup and Remove Mirroring

Two sets of scripts to help setup mirroring or remove mirroring - handy during disaster recovery exe...


Setup of DataBase Mirroring

Setup of DataBase Mirroring


Connection Strings: Database Mirroring Failover Partner Setup & Sample Backup/Restore Preparation Script

  After having setup my first SQL 2008 R2 Enterprise (build level 10.50.1702) database mirror as Hi...



Trying to setup mirroring


Database Mirroring Setup

This great tutorial shows how to set up database mirroring across two instances in a virtual environ...