< Back

Add-AzureRmLoadBalancerInboundNatRuleConfig

Tue Jan 29, 2019 9:53 pm

NAME Add-AzureRmLoadBalancerInboundNatRuleConfig



SYNOPSIS

Adds an inbound NAT rule configuration to a load balancer.





SYNTAX

Add-AzureRmLoadBalancerInboundNatRuleConfig [-BackendPort <Int32>] [-DefaultProfile <IAzureContextContainer>] [-EnableFloatingIP]

[-FrontendIpConfiguration <PSFrontendIPConfiguration>] [-FrontendPort <Int32>] [-IdleTimeoutInMinutes <Int32>] -LoadBalancer <PSLoadBalancer>

-Name <String> [-Protocol {Tcp | Udp}] [<CommonParameters>]



Add-AzureRmLoadBalancerInboundNatRuleConfig [-BackendPort <Int32>] [-DefaultProfile <IAzureContextContainer>] [-EnableFloatingIP]

[-FrontendIpConfigurationId <String>] [-FrontendPort <Int32>] [-IdleTimeoutInMinutes <Int32>] -LoadBalancer <PSLoadBalancer> -Name <String>

[-Protocol {Tcp | Udp}] [<CommonParameters>]





DESCRIPTION

The Add-AzureRmLoadBalancerInboundNatRuleConfig cmdlet adds an inbound network address translation (NAT) rule configuration to an Azure load

balancer.





PARAMETERS

-BackendPort <Int32>

Specifies the backend port for traffic matched by a rule configuration.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-DefaultProfile <IAzureContextContainer>

The credentials, account, tenant, and subscription used for communication with azure.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-EnableFloatingIP [<SwitchParameter>]

Indicates that this cmdlet enables a floating IP address for a rule configuration.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-FrontendIpConfiguration <PSFrontendIPConfiguration>

Specifies a list of front-end IP addresses to associate with an inbound NAT rule configuration.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-FrontendIpConfigurationId <String>

Specifies an ID for a front-end IP address configuration.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-FrontendPort <Int32>

Specifies the front-end port that is matched by a rule configuration.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-IdleTimeoutInMinutes <Int32>

Specifies the length of time, in minutes, that the state of conversations is maintained in a load balancer.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-LoadBalancer <PSLoadBalancer>

Specifies a LoadBalancer object. This cmdlet adds an inbound NAT rule configuration to the load balancer that this parameter specifies.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByValue)

Accept wildcard characters? false



-Name <String>

Specifies the name of the inbound NAT rule configuration to add.



Required? true

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



-Protocol <String>

Specifies the protocol that is matched by an inbound NAT rule. The acceptable values for this parameter are: Tcp or Udp.



Required? false

Position? named

Default value None

Accept pipeline input? False

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).



INPUTS

PSLoadBalancer

Parameter 'LoadBalancer' accepts value of type 'PSLoadBalancer' from the pipeline





OUTPUTS

Microsoft.Azure.Commands.Network.Models.PSLoadBalancer







NOTES









Example 1: Add an inbound NAT rule configuration to a load balancer



PS C:\\>$slb = Get-AzureRmLoadBalancer -Name "MyLoadBalancer" -ResourceGroupName "MyResourceGroup"

PS C:\\> $slb | Add-AzureRmLoadBalancerInboundNatRuleConfig -Name "NewNatRule" -FrontendIPConfiguration $slb.FrontendIpConfigurations[0] -Protocol

"Tcp" -FrontendPort 3350 -BackendPort 3350 -EnableFloatingIP



The first command gets the load balancer named MyloadBalancer, and then stores it in the variable $slb.



The second command uses the pipeline operator to pass the load balancer in $slb to Add-AzureRmLoadBalancerInboundNatRuleConfig , which adds an

inbound NAT rule configuration to the load balancer.







RELATED LINKS

Online Version: https://docs.microsoft.com/en-us/powers ... ruleconfig

Get-AzureRmLoadBalancer

Get-AzureRmLoadBalancerInboundNatRuleConfig

New-AzureRmLoadBalancerInboundNatRuleConfig

Remove-AzureRmLoadBalancerInboundNatRuleConfig

Set-AzureRmLoadBalancer

Set-AzureRmLoadBalancerInboundNatRuleConfig