AWCerb
Contributor
Contributor

vCloud Director Unable To Delete Missing VM

Hi guys,

Hopefully someone will have some amazingly simple solution to my current conundrum!

  • We're running vCloud Director 5.1.
  • One of our admins deleted a test VM from a critical vApp in one of our Organizations - directly through vCenter.
  • The deleted VM still shows in the vCD portal, with the status 'Inconsistent State'.
  • We are unable to either delete this ghost reference or alter it in any way.
  • We can no longer create VMs within this vApp, because each time we try, we are greeted with 'Could not find object with moref "vm-543"' - I have checked through our MS SQL backend, and this moref is referring specifically to the test VM that was deleted through vCenter.

Does anyone have any bright ideas on how to get rid of this ghost VM, and thus allow us to create new VMs within this vApp?

Thanks!

0 Kudos
4 Replies
beth22
Enthusiast
Enthusiast

Hi,

There is a table 'VM_INV' in vCD database, finding out date entries with the equivalent MOREF on that table and cleaning it up.

0 Kudos
Exwork
Enthusiast
Enthusiast

Instead of hacking away at the database, (which is not supported) check the "Stranded Items" folder.

Missing VMs should be listed here, so you should be able to purge the already-deleted VM from VCD that way.

0 Kudos
admin
Immortal
Immortal

This will not show the object which is already deleted from vSphere.

0 Kudos
IamTHEvilONE
Immortal
Immortal

Stranded Items is for when an object is "to be deleted" in vcloud director, but we fail to perform the delete task in the appropriate system (vCenter/vShield/NSX).

This is quite the opposite, which is the VM is in a vApp in an Inconsistent state (vCD thinks it's powered on, vSphere doesn't have a power state since it's missing from inventory).

I'll ask around if there is an easy way to fix this.  the key point will be getting the VM into an Off state in vCloud Director, then it should delete without issue.

0 Kudos