From 0 to build SQL Server AlwaysOn Part IV (room configure remote node)

From 0 to build SQL Server AlwaysOn Part IV (room configure remote node)

 

The first chapter
http://www.cnblogs.com/lyhabc/p/4678330.html
The second
http://www.cnblogs.com/lyhabc/p/4682028.html
Title III
http: //www.cnblogs .com / lyhabc / p / 4682986.html
Part IV
http://www.cnblogs.com/lyhabc/p/6136227.html
build nondomain win2016 + SQL2016 AlwaysOn
http://www.cnblogs.com/lyhabc/p /6498712.html
SQL Server cluster AG does not start up of interim self-help big move
http://www.cnblogs.com/lyhabc/p/6953255.html

 

 

This one is from zero to build SQL Server AlwaysOn's Title IV, this one began to build the engine room remote node

 

Notes 1

Note that the remote node preferably at least two nodes AG, time or manual failover node will appear in the local arbitration warning that there is a cluster offline danger WSFC

In the case of a remote node only, although Windows2012R2 dynamic arbitration, but, in the case of non-local nodes elegant down, the whole cluster WSFC there may not be any votes

Remote node is also not caused by votes WSFC entire cluster offline! !

 

Notes 2

When a manual failover, update the DNS cache takes 10 minutes, so when a manual failover connection with the listener ip SQL Server will be very slow, because also update the DNS cache

 

 


step

This is still a way of using a step by step description of how to build a computer room AlwaysOn remote node

 

Added remote node machine room name:

 

1, mounted on a remote failover cluster nodes

 

 

2, open the failover cluster manager node on the local machine room to add a node

 

3, verify the configuration

 

 

4, add new nodes to solve different problems OU, simply modify the organizational unit ou, do not need to modify the site site, because if the local and remote room room set up domain site, verify the configuration will be warned in time, of course, be ignored can be corrected

Because it is only a warning Yi Er, ignoring it does not matter

 

 

5, add nodes success

 

6, SQL Server installed on the new node and optimize SQL Server, this ignores the installation and optimization steps

 

7, add a new node to the remote room availability alwayson group, open the properties of the interface alwayson availability, availability group name: AGWMSJXC

 

After adding a remote room you can see the node, the remote node has not coupled to the engine room availability group, which is the current availability group has not identified the remote node room

 

8, VIP add another subnet to the listener, this step, if the group does not have availability availability group listener is enabled then this step can be ignored

If the availability group listener is enabled, you will need two cases

1, remote node network with local computer room is the same, such as are 192.168.1.x, then this step does not need to do

2, remote network nodes with local computer room is not the same, that is, cross-subnet, such as local computer room is 192.168.1.x, off-site computer room is 192.168.10.x, then this step needs to be done

Listener IP now has two, one is the local IP subnet room, a computer room off-site network of IP

 

After adding a new listener vip, Failover Cluster Manager will automatically inside the listener resource offline vip

 

 

 

9, the availability of a new test group, is mainly used to open / open the port 5022 of the local node and the remote node

 

After built in the former AG refresh you will see the remote node JXCA-WMS08 has been automatically coupled to an availability group AGWMSJXC

 

 

10, the database to restore the backup to the remote node JXCA-WMS08, operating on remote nodes JXCA-WMS08, coupled to the database Click on availability group

 

11, remote node is added to complete

 

 

12, manual failover to the remote node primary replica

Note that when only a remote node is configured to verify WSFC arbitration vote that column will appear warning!

After a failover will find listeners online ip ip offline listeners, the local node remote node

 

13、在异地节点上使用异地节点侦听器ip连接SQL Server,并写入测试数据

 

14、把主副本手动故障转移回来本地节点

 

15、用本地节点侦听器ip连接SQL Server,发现刚才对异地节点侦听器ip的数据写入都已经同步过来本地机房节点

 

 

16、添加WSFC集群IP地址资源的异地机房IP,在WSFC管理器里选中群集核心资源下面的服务器名称,右键-》属性

添加一个异地机房的WSFC的vip:192.168.7.130

添加成功之后vip会显示脱机这是因为当前WSFC主节点不在异地机房的节点上,而是本地机房的节点上

 

 

17、把WSFC主节点转移到异地机房的某个节点,然后把本地所有节点都关机

 

这时候把本地机房的所有节点关机

 

现在用异地机房节点的WSFC的vip连接WSFC集群

可以发现WSFC的主节点已经转移到WIN-BDKSOOLDV18这个异地节点上了,而且群集资源还是联机状态

 

18、没有加入域的应用服务器(IIS服务器)如果需要用侦听器名称来连接alwayson集群是不行的,解决方法是修改

应用服务器的hosts文件,写上侦听器名和侦听器ip,这样客户端才能用侦听器名称连接alwayson集群,客户端的webconfig文件

里写侦听器名称,这样即使failover到异地节点也不需要修改应用服务器的webconfig文件,当然应用服务器加入了域就不用了,、

加入了域的应用服务器会自动去查询DC上的DNS管理器找到alwayson的侦听器名称

hosts文件

testaglisten  192.168.10.91
testaglisten  192.168.11.91

 

 

 

提示:实际上第16步不是必须的,你可以不添加WSFC的异地子网的vip,但是当本地机房所有节点关机之后

你就不能用本地的vip:192.168.6.60来连接WSFC集群,也就无法管理WSFC集群

 

 

附上结构图

两个网段,所以会有两个侦听器IP,但是同一个时刻只有一个侦听器IP是联机状态,在WSFC集群管理器里查看

主站点:192.168.6x

DR站点:192.168.7.x

故障转移到DR站点之后

 

 

参考文章:

http://blog.itpub.net/29371470/viewspace-2087672

http://www.tech-coffee.net/understand-failover-cluster-quorum/

Guess you like

Origin www.cnblogs.com/chendian0/p/12109502.html