How to get free YouTube subscribers, likes and views?
Get Free YouTube Subscribers, Views and Likes

Configure SQL AG Listener on Azure

Follow
Abhijeet Srivastava

Here is the PowerShell script for setting up AG Listener. Please replace the variables as shown in the video.

$ClusterNetworkName = "MyClusterNetworkName" # the cluster network name (Use GetClusterNetwork on Windows Server 2012 of higher to find the name)
$IPResourceName = "ClusterIPResourceName" # the IP Address resource name
$ClusterCoreIP = "n.n.n.n" # the IP Address of the Cluster IP resource. This is the static IP address for the load balancer you configured in the Azure portal.
[int]$ClusterProbePort = nnnnn # The probe port from the WSFCEndPointprobe in the Azure portal. This port must be different from the probe port for the availability group listener probe port.

ImportModule FailoverClusters

GetClusterResource $IPResourceName | SetClusterParameter Multiple @{"Address"="$ClusterCoreIP";"ProbePort"=$ClusterProbePort;"SubnetMask"="255.255.255.255";"Network"="$ClusterNetworkName";"EnableDhcp"=0}

posted by Fisone07