Hi LucD,
Correct I connect to the ESXi server to remove the vms. Is the proper way to connect to vCenter and do the remove?
If you remove a VM from the ESXi server and that VM was also known in the vCenter, the VM will be still present in the vCenter, but with the indication "orphaned".
That is what is happening.
Where do you try to recreate the new VM, directly on the ESXi server ?
I try to create the new VM on vCenter.
If yes, you will have to execute the Remove-VM while connected to the vCenter
But my vCenter has multiple esxi hosts and each ESXi host contains vms with the same name. So I don't want to delete all the vms but I want to delete a particual vm contained in host X. http://www.vmware.com/support/developer/PowerCLI/PowerCLI41U1/html/Remove-VM.html doesn't allow to specify a vm for a particual host while connect to a vCenter.
Thanks,
Sagun