New-SCLoadBalancerRoleConfiguration

Creates a load balancer role configuration.

Syntax

New-SCLoadBalancerRoleConfiguration -LBManagerIPAddress <String>
 [-NatIPExemptions <System.Collections.Generic.List`1[System.String]>] [-VMMServer <ServerConnection>]
 [-VipPools <System.Collections.Generic.List`1[Microsoft.SystemCenter.VirtualMachineManager.StaticIPAddressPool]>]
 [<CommonParameters>]

Description

The New-SCLoadBalancerRoleConfiguration cmdlet creates a load balancer role configuration in Virtual Machine Manager (VMM).

Examples

Example 1: Create a load balancer role configuration

PS C:\> $IpPool1 = Get-SCStaticIPAddressPool -Name "Private VIP Logical Network"
PS C:\> $IpPool2 = Get-SCStaticIPAddressPool -Name "Public VIP Logical Network"
PS C:\> $NetworkService = Get-SCNetworkService -Name "NC"
PS C:\> $FabricRole =  Get-SCFabricRole -Type LoadBalancer -NetworkService $NetworkService 
PS C:\> $NatIPExemptions = @() 
PS C:\> $FabricRoleConfiguration = New-SCLoadBalancerRoleConfiguration -LBManagerIPAddress "10.20.20.254" -NatIPExemptions $NatIPExemptions -VipPools @($IpPool1, $IpPool2)

The first two commands get IP pools from the private and public VIP logical networks by using the Get-SCStaticIPAddressPool cmdlet.

The third command gets the network service named NC by using the Get-SCNetworkService cmdlet.

The fourth command gets the load balancer fabric role from the network service by using the Get-SCFabricRole cmdlet.

The fifth command creates an array variable named $NatIPExemptions.

The final command creates a load balancer configuration object that has the SLBM VIP address 10.20.20.254 and the VIP pools.

Parameters

-LBManagerIPAddress

Specifies the load balancer manager virtual IP address.

Type:String
Required:True
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-NatIPExemptions

Specifies the NatIPExempltions subnets list.

Type:System.Collections.Generic.List`1[System.String]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a VMM server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-VipPools

Specifies the list of VIP pools that are published to the load balancer manager. The VIP pools are used for NAT and load balancing.

Type:System.Collections.Generic.List`1[Microsoft.SystemCenter.VirtualMachineManager.StaticIPAddressPool]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False