Cannot delete azure virtual wan

Gert Fich Kjerslev 1 Reputation point


I have a vwan that I want to delete. First I tryed to delete the virtual connection network, then the hub and then the vwan. But this is not possble.

get-AzVirtualNetworkPeering : The Resource 'Microsoft.Network/virtualNetworks/VM-vnet' under resource group 'VNet-RG' was not found.

Remove-AzVirtualWan : Operation returned an invalid status code 'BadRequest'

StatusCode: 400

ReasonPhrase: Bad Request

ErrorCode: InUseVirtualWanCannotBeDeleted

ErrorMessage: Cannot proceed with the operation because Virtual WAN has references. The WAN is referenced by 2 Virtual Hubs and 0 VPN Sites.

Azure Virtual WAN
Azure Virtual WAN
An Azure virtual networking service that provides optimized and automated branch-to-branch connectivity.
127 questions
0 comments No comments
{count} votes

8 answers

Sort by: Most helpful
  1. Leon Laude 85,216 Reputation points


    Microsoft Azure is experiencing issues with the Azure Resource Manager (ARM) currently, your issue might be bacause of this.

    More information here:

    Best regards,

    0 comments No comments

  2. Didier Van Hoye 1 Reputation point

    Hi, I can confirm that the ARM issues are causing problems on this front right now. I cannot even edit a VPN site setting. That fails immediately. I have deleted VWANs before and that should indeed work on the condition all depending resources are gone. The error indicated there are still to HUBS associated with the VWAN. Did removing those succeed at all?

    0 comments No comments

  3. Leon Laude 85,216 Reputation points

    The issue appears to be have been resolved now:

    0 comments No comments

  4. suvasara-MSFT 9,891 Reputation points


    This might be due to the resource lock that is added due to dependency on the another resource. Try deleting the dependent/attached network connections to this VWAN.

    0 comments No comments

  5. Gert Fich Kjerslev 1 Reputation point

    I can now delete the Virtual network connection but not the hub... I get an error that the like is not here??