Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm having problems delete an unknown (orphaned) VM from an ESX 3.5 host.

When I attempt to right click the VM I get the following error "Object reference not set to an instance of an object".

Steps taken so far. 1. Removed the host from the cluster 2. Removed the host from vCenter 3. Rebooted the host 4. Edited the file vmInventory.xml & cleared the file 5. Restarted services - mgmt-vmware restart

Can anyone think of anything else that I can do to resolve this issue?

Thanks guys.

share|improve this question
Log a call with VMWare? – Chopper3 Jan 20 '10 at 15:01
Did this occur when you deleted a VM from the datastore before you removed the VM from inventory? – Chadddada Apr 7 '11 at 15:18

If this host is a member of a Vcenter as you seem to imply that it is you may need to reboot the Vcenter to clear it out, it could be that the vcenter itself is whatis holding the VM there and not the host which is what would clear the machine by restarting the management services.

share|improve this answer

Check if the VM shows up on the host itself, rather than the vcenter, by connecting directly to the host as root. You should also try deleting from here, if it's listed. If it's not listed, the issue is definitely on the vcenter.

Double-check that your account has all the permissions necessary in vcenter, including ability to delete a VM and delete from the datastores. This error can crop up if you only have partial delete permissions.

Also, disable all your client plugins in VI Client, restart the client, then try again. If that fails, see if you can delete from the web console on the host machine.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.