<div dir="ltr"><div><div>Hi,<br><br></div>I'm trying to clone a VM from snapshot with the below code. but it is not cloning..<br><br> org.ovirt.engine.sdk.decorators.VM vm2 = api.getVMs().get("testVM");<br>
VM cloneVM = new VM();<br> cloneVM.setName("MyClonedViaAPI");<br> VMSnapshot snap3 = new VMSnapshot(null);<br> snap3 = vm2.getSnapshots().get(UUID.fromString("7799ce3f-a007-415a-84c5-df323e8f440d"));<br>
Action act = new Action();<br> act.setClone(true);<br> act.setVm(cloneVM);<br> snap3.restore(act);<br><br></div><div><div><div>Actually, my original goal is to Clone VM directly from another VM instead of cloning from snapshot.<br>
<br></div><div>Can you help me?<br></div><div>-- <br><div>Thanks & Regards</div>
<div>Tejesh</div>
</div></div></div></div>