Thursday, July 24, 2014

Azure - Deleting VNet

Trying to delete a Virtual Network in Azure

Powershell command:
Note this removes all Virtual Networks from your active Azure Subscription
Remove-AzureVNetConfig

But then:
Remove-AzureVNetConfig : BadRequest : Cannot delete or modify virtual network while in use 'xxxxx'.

I do not have Virtual Machines as I removed them all. But then I noticed the VNetwork has a Gateway assigned to it.

So remove the gateway before removing the VNetwork.


Delete the Gateway


By the way, the Powershell command for deleting a VNet Gateway:
Remove-AzureVNetGateway -VNetName "SPAutoVNet"


3 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. Thank you for your post. This is excellent information. It is amazing and wonderful to visit your site. This idea is mind blowing. I think everyone should know such information like you have described on this post. Thank you for sharing this explanation.
    oracle training in chennai

    oracle training institute in chennai

    oracle training in bangalore

    oracle training in hyderabad

    oracle training

    oracle online training

    hadoop training in chennai

    hadoop training in bangalore

    ReplyDelete