< Back

Set-AzureRmVirtualNetworkGateway

Tue Jan 29, 2019 9:58 pm

NAME Set-AzureRmVirtualNetworkGateway



SYNOPSIS

Updates a virtual network gateway.





SYNTAX

Set-AzureRmVirtualNetworkGateway [-AsJob] [-Asn <UInt32>] [-DefaultProfile <IAzureContextContainer>] [-DisableActiveActiveFeature]

[-EnableActiveActiveFeature] [-GatewayDefaultSite <PSLocalNetworkGateway>] [-GatewaySku {Basic | Standard | HighPerformance | UltraPerformance |

VpnGw1 | VpnGw2 | VpnGw3}] [-PeerWeight <Int32>] -RadiusServerAddress <String> -RadiusServerSecret <SecureString> -VirtualNetworkGateway

<PSVirtualNetworkGateway> [-VpnClientAddressPool <System.Collections.Generic.List`1[System.String]>] [-VpnClientProtocol {SSTP | IkeV2}]

[-VpnClientRevokedCertificates <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSVpnClientRevokedCertificate]>]

[-VpnClientRootCertificates <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSVpnClientRootCertificate]>] [-Confirm]

[-WhatIf] [<CommonParameters>]





DESCRIPTION

The Set-AzureRmVirtualNetworkGateway cmdlet updates a virtual network gateway.





PARAMETERS

-AsJob [<SwitchParameter>]

Run cmdlet in the background



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-Asn <UInt32>

Specifies the virtual network gateway Autonomous System Number (ASN) that is used to set up Border Gateway Protocol (BGP) sessions inside

IPsec tunnels.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

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



-DisableActiveActiveFeature [<SwitchParameter>]

Disables the active-active feature.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-EnableActiveActiveFeature [<SwitchParameter>]

Enables the active-active feature.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-GatewayDefaultSite <PSLocalNetworkGateway>

Specifies the default site to use for force tunneling. If a default site is specified, all internet traffic from the gateway's Virtual Private

Network (VPN) is routed to that site.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-GatewaySku <String>

Specifies the stock keeping unit (SKU) of the virtual network gateway. The acceptable values for this parameter are:



- Basic



- Standard



- HighPerformance



- VpnGw1



- VpnGw2



- VpnGw3



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-PeerWeight <Int32>

Specifies the weight added to routes learned over BGP from this virtual network gateway



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-RadiusServerAddress <String>

P2S External Radius server address.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-RadiusServerSecret <SecureString>

P2S External Radius server secret.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-VirtualNetworkGateway <PSVirtualNetworkGateway>

Specifies the virtual network gateway object to base modifications off of. You can use the Get-AzureRmVirtualNetworkGateway cmdlet to get the

virtual network gateway object.



Required? true

Position? named

Default value None

Accept pipeline input? True (ByValue)

Accept wildcard characters? false



-VpnClientAddressPool <System.Collections.Generic.List`1[System.String]>

Specifies the address space that this cmdlet uses to allocate VPN client IP addresses from. This should not overlap with virtual network or

on-premise ranges.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-VpnClientProtocol <System.Collections.Generic.List`1[System.String]>

A list of P2S VPN client tunneling protocols



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-VpnClientRevokedCertificates <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSVpnClientRevokedCertificate]>

Specifies a list of revoked VPN client certificates. A VPN client presenting a certificate that matches one of these is removed.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-VpnClientRootCertificates <System.Collections.Generic.List`1[Microsoft.Azure.Commands.Network.Models.PSVpnClientRootCertificate]>

Specifies a list of VPN client root certificates to use for VPN client authentication. Connecting VPN clients must present certificates

generated from one of these root certificates.



Required? false

Position? named

Default value None

Accept pipeline input? True (ByPropertyName)

Accept wildcard characters? false



-Confirm [<SwitchParameter>]

Prompts you for confirmation before running the cmdlet.



Required? false

Position? named

Default value False

Accept pipeline input? False

Accept wildcard characters? false



-WhatIf [<SwitchParameter>]

Shows what would happen if the cmdlet runs. The cmdlet is not run.



Required? false

Position? named

Default value False

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

PSVirtualNetworkGateway

Parameter 'VirtualNetworkGateway' accepts value of type 'PSVirtualNetworkGateway' from the pipeline





OUTPUTS

Microsoft.Azure.Commands.Network.Models.PSVirtualNetworkGateway







NOTES





* Keywords: azure, azurerm, arm, resource, management, manager, network, networking



Example 1: Set the goal state a virtual network gateway



PS C:\\>$Gateway = Get-AzureRmVirtualNetworkGateway -ResourceGroupName "ResourceGroup001" -Name "Gateway001"

PS C:\\> Set-AzureRmVirtualNetworkGateway -VirtualNetworkGateway $Gateway -Asn 1337



The first command gets a virtual network gateway named Gateway01 that belongs to resource group ResourceGroup001 and stores it to the variable

named $Gateway



The second command sets the goal state for the virtual network gateway stored in variable $Gateway. The command also sets the ASN to 1337.







RELATED LINKS

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

Get-AzureRmVirtualNetworkGateway

New-AzureRmVirtualNetworkGateway

Remove-AzureRmVirtualNetworkGateway

Reset-AzureRmVirtualNetworkGateway

Resize-AzureRmVirtualNetworkGateway