Sql-server – Replication for Mirrored server

sql serversql-server-2012

I have 3 SQL servers running SQL Server 2012 Standard Edition, called A , B and C. Server B is a mirror of server A. There is transactional replication between server A and Server C.

How can I ensure replication continues to C regardless of which server is the primary server in the mirrored pair?

Best Answer

The -PublisherFailoverPartner option should help you out in your case. I am assuming you want to have replication running irrespective of database running on principal/mirror server.

Below links have your issue covered and has all the details on how to configure it.

http://blogs.lessthandot.com/index.php/datamgmt/dbprogramming/replication-and-mirroring-setup/

https://www.pythian.com/blog/how-to-configure-transactional-replication-mirroring-failover/

https://msdn.microsoft.com/en-us/library/ms151799.aspx

Test it out in your test environment before implementing it on PROD.