Author Posts

October 20, 2017 at 11:03 am

I'm searching for a PowerShell script that will automate SQL database mirroring. Michael J. Messano created a nice script years ago but we wanted to get away from using SMO from SQL 2012 R2. I'm not having any luck Googling it. My apologies if this subject has already come up, I'm new here. If it has, just point me in that direction. 🙂 Thanks

October 20, 2017 at 1:58 pm

The configuration we're attempting is a networked SQL 2016 standalone server mirroring to another networked SQL 2016 standalone server without clustering. Setting this up manually using SSMS 2016 causes headaches due to some GUI issues in SSMS 2016. However, using SSMS 2012/2014 to configure mirroring on a SQL 2016 box works like a charm. So we figured we'd try to script it without using SMO. Seems to be a difficult task so far. 🙂