-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Description
I'm trying to create a new IKEV2 IPSec tunnel using the following MS article:
https://docs.microsoft.com/en-us/azure/vpn-gateway/vpn-gateway-ipsecikepolicy-rm-powershell
I get to the part where I execute the following command:
New-AzVirtualNetworkGatewayConnection -Name Azure-WEU-US01-IPSec-VPN -ResourceGroupName $RG1 -VirtualNetworkGateway1 $vnetgw1 -LocalNetworkGateway2 $lngw1 -Location $Location1 -ConnectionType IPsec -UsePolicyBasedTrafficSelectors $True -IpsecPolicies $ipsecpolicy6 -SharedKey 'XXXXXXXXXXXXX'
But then get the following parsing error:
New-AzVirtualNetworkGatewayConnection : Cannot parse the request.
StatusCode: 400
ReasonPhrase: Bad Request
ErrorCode: InvalidRequestFormat
ErrorMessage: Cannot parse the request.
Additional details:
Code: InvalidJson
Message: Could not find member 'trafficSelectorPolicies' on object of type 'VirtualNetworkGatewayConnectionProperties'. P
ath 'properties.trafficSelectorPolicies', line 75, position 30.
OperationID : 95142eb8-7da3-467e-8686-30de8cdeb19d
At line:1 char:1
- New-AzVirtualNetworkGatewayConnection -Name $Connection16 -ResourceGr ...
-
- CategoryInfo : CloseError: (:) [New-AzVirtualNetworkGatewayConnection], NetworkCloudException
- FullyQualifiedErrorId : Microsoft.Azure.Commands.Network.NewAzureVirtualNetworkGatewayConnectionCommand
This is the second connection I'm trying to create. The first one around 2-3 months ago was successful and did not present this error. Is there a bug in the current Azure CLI?