利用Azure虚拟机安装Dynamics 365 Customer Engagement之十一:SQL Server配置Always On后D365的配置更改

我是微软Dynamics 365 & Power Platform方面的工程师罗勇,也是2015年7月到2018年6月连续三年Dynamics CRM/Business Solutions方面的微软最有价值专家(Microsoft MVP),欢迎关注我的微信公众号 MSFTDynamics365erLuoYong ,回复367或者20190911可方便获取本文,同时可以在第一间得到我发布的最新博文信息,follow me!

本文主要参考官方文档 Set configuration and organization databases for SQL Server AlwaysOn failover

连接SQL Server副本数据库服务器(我这里是LuoYongSQL2),展开【安全性】>【登录名】,右击选择【新建登录名】

搜索luoyongPrivReportingGroup,记得更改下对象类型和查找位置如下图,点击确定按钮添加。同样的操作为 ReportingGroup 和 SQLAccessGroup 执行一下。

新添加的三个登录名如下:

然后就是每台Dynamics 365服务器需要更改注册表中的连接字符串,使用Regedit打开注册表,导航到HKEY_LOCAL_MACHINESOFTWAREMicrosoftMSCRM,双击名称为 configdb 的键,我这里原来的值是 Data Source=LuoYongSQL1;Initial Catalog=MSCRM_CONFIG;Integrated Security=SSPI 

我修改为: Data Source=LuoYongSQLListener1.luoyong.me;Initial Catalog=MSCRM_CONFIG;Integrated Security=SSPI;multisubnetfailover=true 

然后执行如下SQL:

USE MSCRM_CONFIG
Update Organization set ConnectionString = 'Provider=SQLOLEDB;Data Source=LuoYongSQLListener1.luoyong.me;Initial Catalog=Demo_MSCRM;Integrated Security=SSPI;MultiSubnetFailover=True' where DatabaseName = 'Demo_MSCRM'

重启CRM相关的服务和IIS,对SQL Server执行手工故障转移后进行测试。

原文地址:https://www.cnblogs.com/luoyong0201/p/Install_Dynamics_365_Using_Azure_Virtual_Machines_Part_11th.html