Set-AzLoadBalancerOutboundRuleConfig
Sets an outbound rule configuration for a load balancer.
Note
This is the previous version of our documentation. Please consult the most recent version for up-to-date information.
Syntax
Set-AzLoadBalancerOutboundRuleConfig
-LoadBalancer <PSLoadBalancer>
-Name <String>
[-AllocatedOutboundPort <Int32>]
-Protocol <String>
[-EnableTcpReset]
[-IdleTimeoutInMinutes <Int32>]
-FrontendIpConfiguration <PSResourceId[]>
-BackendAddressPool <PSBackendAddressPool>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzLoadBalancerOutboundRuleConfig
-LoadBalancer <PSLoadBalancer>
-Name <String>
[-AllocatedOutboundPort <Int32>]
-Protocol <String>
[-EnableTcpReset]
[-IdleTimeoutInMinutes <Int32>]
-FrontendIpConfiguration <PSResourceId[]>
-BackendAddressPoolId <String>
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Set-AzLoadBalancerOutboundRuleConfig cmdlet sets an outbound rule configuration for an Azure load balancer.
Examples
Example 1: Modify the outbound rule configuration on a load balancer
PS C:\>$slb = Get-AzLoadBalancer -ResourceGroupName "MyResourceGroup" -Name "MyLoadBalancer"
PS C:\>$slb | Add-AzLoadBalancerOutboundRuleConfig -Name "NewRule" -Protocol "Tcp" -FrontendIPConfiguration $slb.FrontendIpConfigurations[0] -BackendAddressPool $slb.BackendAddressPools[0] -IdleTimeoutInMinutes 5
PS C:\>$slb | Set-AzLoadBalancerOutboundRuleConfig -Name "NewRule" -Protocol "Tcp" -FrontendIPConfiguration $slb.FrontendIpConfigurations[0] -BackendAddressPool $slb.BackendAddressPools[0] -IdleTimeoutInMinutes 10
The first command gets the load balancer named MyLoadBalancer, and then stores it in the $slb variable. The second command uses the pipeline operator to pass the load balancer in $slb to Add-AzLoadBalancerOutboundRuleConfig, which adds an outbound rule configuration to it. The third command passes the load balancer to Set-AzLoadBalancerOutboundRuleConfig, which saves and updates the outbound rule configuration.
Parameters
The number of outbound ports to be used for NAT.
| Type: | Int32 |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
A reference to a pool of DIPs. Outbound traffic is randomly load balanced across IPs in the backend IPs.
| Type: | PSBackendAddressPool |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
A reference to a pool of DIPs. Outbound traffic is randomly load balanced across IPs in the backend IPs.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Prompts you for confirmation before running the cmdlet.
| Type: | SwitchParameter |
| Aliases: | cf |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The credentials, account, tenant, and subscription used for communication with Azure.
| Type: | IAzureContextContainer |
| Aliases: | AzContext, AzureRmContext, AzureCredential |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Receive bidirectional TCP Reset on TCP flow idle timeout or unexpected connection termination. This element is only used when the protocol is set to TCP.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The Frontend IP addresses of the load balancer.
| Type: | PSResourceId[] |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
The timeout for the TCP idle connection
| Type: | Int32 |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
The reference of the load balancer resource.
| Type: | PSLoadBalancer |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Name of the outbound rule.
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Protocol - TCP, UDP or All
| Type: | String |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Shows what would happen if the cmdlet runs. The cmdlet is not run.
| Type: | SwitchParameter |
| Aliases: | wi |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |