<div dir="ltr">Hi,<div><br></div><div>There are some problems with the "define" approach in a distributed environment, mainly related with the reuse of ID's.... Also you have to undefine the VMs, etc..</div><div>

<br></div><div>Anyway note that the data is not lost (even in the non-persistent case), as all the files are in the crashed host. Just issue onevm boot, and the VM will be recreated. This is like define the VM but not in libvirt but let OpenNebula handle it.</div>

<div><br></div><div>This very simple script can be easily hooked to the host state, so when you enable a host the VMs running within are onevm-boot'ed if they are in unknown state.</div><div><br></div><div>What do you think? </div>

<div><br></div><div>Cheers</div><div><br></div><div>Ruben</div><div><br></div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Mon, Jul 8, 2013 at 9:40 AM, Pentium100 <span dir="ltr"><<a href="mailto:pentium100@gmail.com" target="_blank">pentium100@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hello,<br><br></div>I am trying out OpenNebula as a replacement for our current system of just using virt-manager to manage the VMs.<br>

<br><br></div><div>We use the VMs as replacements of real server - which means that each VM is unique and should not be deleted (unless, of course, it is no longer needed). There are no multiple virtual servers all doing the same thing - we may have more than one web server for example, but each one serves different sites. So far, OpenNebula seems OK for this - persistent images, the ability to modify a VM and keep the data (two things which may be a problem with OpenStack).<br>



<br></div><div>However, I noticed that the VMs are stared with "virsh create <xml>", thich means that the libvirt domains are transient, and if the host reboots (power failure, hardware failure etc), all VMs that were running on it enter "unknown" state and must be manually recreated. If the image is not persistent, then the data is lost.<br>



<br></div><div>The obvious solution to this would be to use persistent libvirt domains, by using "virsh define <xml>; virsh start <domain>" instead of "virsh create <xml>". That would allow the VMs to survive host restart and optionally to be started together with the host. <br>



<br></div><div>Will this feature be ever supported officially? Or do I just need to modify the relevant files and keep an unofficial version?<br></div></div>
<br>_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@lists.opennebula.org">Users@lists.opennebula.org</a><br>
<a href="http://lists.opennebula.org/listinfo.cgi/users-opennebula.org" target="_blank">http://lists.opennebula.org/listinfo.cgi/users-opennebula.org</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr"><div><div><div>-- </div><div>Join us at OpenNebulaConf2013 in Berlin, 24-26 September, 2013</div></div><div>-- </div></div>Ruben S. Montero, PhD<br>

Project co-Lead and Chief Architect<br>OpenNebula - The Open Source Solution for Data Center Virtualization<br><a href="http://www.OpenNebula.org" target="_blank">www.OpenNebula.org</a> | <a href="mailto:rsmontero@opennebula.org" target="_blank">rsmontero@opennebula.org</a> | @OpenNebula</div>


</div>