mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-6170 (VMware root-disk support for managed storage)
This commit is contained in:
parent
21455222e4
commit
06c0486d0b
|
|
@ -1585,7 +1585,13 @@ public class VmwareStorageProcessor implements StorageProcessor {
|
|||
|
||||
// let vmMo.destroy to delete volume for us
|
||||
// vmMo.tearDownDevices(new Class<?>[] { VirtualDisk.class, VirtualEthernetCard.class });
|
||||
vmMo.destroy();
|
||||
|
||||
if (isManaged) {
|
||||
vmMo.unregisterVm();
|
||||
}
|
||||
else {
|
||||
vmMo.destroy();
|
||||
}
|
||||
|
||||
// this.hostService.handleDatastoreAndVmdkDetach(iScsiName, storageHost, storagePort);
|
||||
if (managedIqns != null && !managedIqns.isEmpty()) {
|
||||
|
|
|
|||
|
|
@ -70,6 +70,10 @@ public class BaseMO {
|
|||
return _name;
|
||||
}
|
||||
|
||||
public void unregisterVm() throws Exception {
|
||||
_context.getService().unregisterVM(_mor);
|
||||
}
|
||||
|
||||
public boolean destroy() throws Exception {
|
||||
ManagedObjectReference morTask = _context.getService().destroyTask(_mor);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue