-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Open
Labels
Network - Virtual NetworkService AttentionThis issue is responsible by Azure service team.This issue is responsible by Azure service team.bugThis issue requires a change to an existing behavior in the product in order to be resolved.This issue requires a change to an existing behavior in the product in order to be resolved.customer-reported
Description
Description
Problem:
When associating an existing VNet with an IPAM pool using Azure Virtual Network Manager, I receive the following error for all subnets:
Invalid configuration on subnet /subscriptions/xxxxx-xxxxxx-xxxxxx-xxxxx/resourceGroups/xxxxxxx/providers/Microsoft.Network/virtualNetworks/xxxxxxxxx/subnets/xxxxxxx; cannot populate both address prefix and address prefixes.
Root cause:
My subnets (created using PowerShell, Az module, or ARM) have a single address range, and therefore only populate the addressPrefix property (singular), not the required addressPrefixes array property. However, Network Manager IPAM requires only the addressPrefixes property to be present.
Expected behavior:
- I should be able to update an existing subnet so that only the
addressPrefixesproperty is present (with one or more ranges), removingaddressPrefixentirely, to be compatible with Network Manager/IPAM. - Or, the backend should automatically accept or convert single-range
addressPrefixsubnets for IPAM/network manager association.
Repro steps:
- Create a VNet and subnet with a single address range (e.g. using PowerShell or ARM/Bicep).
- Attempt to associate the VNet with a Virtual Network Manager IPAM Pool.
- Observe the error above.
- Attempt to update the subnet to use
addressPrefixesvia PowerShell/CLI/Bicep; observe that the property is not updated, oraddressPrefixremains.
What I tried:
- PowerShell:
Set-AzVirtualNetworkSubnetConfigwith-AddressPrefixes - Az CLI:
az network vnet subnet update --address-prefixes - ARM/Bicep: Deploying subnet with only
addressPrefixes - All of these either keep or re-add
addressPrefixfor single-range subnets.
Blocking impact:
- Cannot migrate/associate existing VNets to Network Manager IPAM pools if subnets use
addressPrefix - Manual workaround (e.g. via REST PATCH or resource deletion/recreation) is risky and not supported
Ask:
- Please provide a supported way to update subnets so that only
addressPrefixesis present (even for single-range subnets) - Or, update the backend to allow both
addressPrefixandaddressPrefixesduring transition, or auto-convert as needed
Thanks!
Issue script & Debug output
No error is thrown. the error is logical.Environment data
Name Value
---- -----
PSVersion 7.5.2
PSEdition Core
GitCommitId 7.5.2
OS Microsoft Windows 10.0.26100
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0Module versions
ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Script 5.1.1 Az.Accounts {Add-AzEnvironment, Clear-AzConfig, Clear-AzContext, Clear-AzDefault…}
Script 7.18.0 Az.Network {Add-AzApplicationGatewayAuthenticationCertificate, Add-AzApplicationGatewayBackendAddressPool, Add-AzApplicationGatewayBackendHttpSetting, Add-AzApplicationGatewa…Error output
No error is thrown. the error is logical.walkerk1980 and pschonfeld
Metadata
Metadata
Assignees
Labels
Network - Virtual NetworkService AttentionThis issue is responsible by Azure service team.This issue is responsible by Azure service team.bugThis issue requires a change to an existing behavior in the product in order to be resolved.This issue requires a change to an existing behavior in the product in order to be resolved.customer-reported