Adding IP Address Space to a Peered VNET

Automate the process of un-peering, adding ip space, and re-peering on Azure vnets.

Adding IP Address Space to a Peered VNET

Recently, I had to expand an Azure virtual network (vnet) that had a handful of peered vnets. Unfortunately, it is not possible to add additional address space to a vnet that has active peered networks. All of the peered networks must first be dropped, new address space added, then the peered networks can be re-added.

Of course, the peered networks will become unreachable for however long it takes you to perform these steps. Furthermore, un-peering & re-peering multiple networks can be tricky to manage.

I wrote the following powershell script to automate the entire process and reduce downtime to a 'blip'. ✔