Skip to content

Latest commit

 

History

History
142 lines (110 loc) · 3.39 KB

SqlAGListeners.adoc

File metadata and controls

142 lines (110 loc) · 3.39 KB

DSC Resource 'SqlAGListeners'

SqlAGListeners is used to configure the listener for an Always On Availability Group.

Source

DSC Resource

Documentation

Requirements
  • Target machine must be running Windows Server 2012 or later.

  • Target machine must be running SQL Server Database Engine 2012 or later.

  • Target machine must have access to the SQLPS PowerShell module or the SqlServer PowerShell module.

  • Requires that the Cluster name Object (CNO) has been delegated the right Create Computer Object in the organizational unit (OU) in which the Cluster Name Object (CNO) resides.

Table 1. Attributes of category 'SqlAGListeners'
Parameter Attribute DataType Description Allowed Values

Values

Mandatory

Hashtable[]

List of SQL availability groups listeners.

Table 2. Attributes of category 'SqlAGListeners'
Parameter Attribute DataType Description Allowed Values

InstanceName

Key

String

The SQL Server instance name of the primary replica.

ServerName

Required

String

The host name or fully qualified domain name (FQDN) of the primary replica.

Name

Required

String

The name of the availability group listener, max 15 characters.

This name will be used as the Virtual Computer Object (VCO).

Enure

String

Determines whether the alias should be added (Present) or removed (Absent).

  • Present (default)

  • Absent

AvailabilityGroup

Key

String

The name of the availability group to which the availability group listener is or will be connected.

IpAddress

Stringp[]

The IP address used for the availability group listener, in the format 192.168.10.45/255.255.252.0.

If using DHCP, set to the first IP-address of the DHCP subnet, in the format 192.168.8.1/255.255.252.0. Must be valid in the cluster-allowed IP range.

Port

UInt16

The port used for the availability group listener.

DHCP

Bool

If DHCP should be used for the availability group listener instead of static IP address.

  • True

  • False

Example
SqlAGListeners:
  Values:
    - Name: AGTestListener1
      InstanceName: INSTANCE1
      AvailabilityGroup: AGTest1
      ServerName: SQL1
      IpAddress: 192.168.10.240
      Port: 1433
    - Name: AGTestListener2
      InstanceName: INSTANCE2
      AvailabilityGroup: AGTest2
      ServerName: SQL1
      IpAddress: 192.168.10.241
      Port: 4000