I believe in Hyper-V!

Delete obsolete virtual networks with dependency in VMM 2012 SP1

Few days ago I modified network settings on one of Hyper-V hosts and also migrated two of VMs to another Hyper-V host. After VMs migration and changed network settings on the Hyper-V everything has been working like a charm! After I do that, on the Virtual Machine Manager I noticed that two network adapters are still there regardless of what no longer exist in Hyper-V host. That isn’t a problem, right click on VM Network and Logical Networks, and that’s it, but…!? When I tried to delete obsolete virtual network got error that have dependent resources on that VM Network like in the picture below.

Blog4

In other words; when I migrate VMs from one Hyper-V host to another VMM didn’t “release” VMs from VM Networks. I’m sure that everything what I done, I did in the right way!
When opened View Dependent Resources I saw two migrated VMs and connected checkpoints.

Blog3

The same dependencies are on the Logical Networks

2

In the next couple of hours I tried to figure out how to solve the problem! In the pictures below is few examples what I tried to do.

Tried to delete through PowerShell.

VMnetwork

Tried to change all .xml configuration file related to VMs

Blog1

At the end, what did I do? It’s simple but it’s manual work!

Step 1

Export VMs

Blog2

Step 2

Delete exported VMs through Virtual Machine Manager

deleteVm

Step 3

Remove Virtual Network from the VM Networks and from the Logical Networks

Blog5
Blog6
Blog7
Blog8
Blog9
Blog10

Step 4

Import VMs

Blog11

Blog12

We are done!

Enjoy in day ;)

Romeo

4 Responses to “Delete obsolete virtual networks with dependency in VMM 2012 SP1

  1. Miha Pecnik

    Could’t you just remove the hosts where these VMs were placed?

  2. Pingback: Dell TechCenter

  3. Pingback: Server King » Dell’s Digest for August 12, 2013

Leave a Reply

Your email address will not be published. Required fields are marked *