# How to move VMs (persistent & non-persistent) between Opennebula systems

**URL:** <https://forum.opennebula.io/t/how-to-move-vms-persistent-non-persistent-between-opennebula-systems/3335>\
**Category:** Product Support\
**Created:** [November 23, 2016, 2:56pm UTC](https://forum.opennebula.io/t/how-to-move-vms-persistent-non-persistent-between-opennebula-systems/3335 "2016-11-23T14:56:54Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![jojo](https://yyz1.discourse-cdn.com/flex031/user_avatar/forum.opennebula.io/jojo/32/4953_2.png) [@jojo](https://forum.opennebula.io/u/jojo)\
**Post date:** [November 30, 2016, 10:46am UTC](https://forum.opennebula.io/t/how-to-move-vms-persistent-non-persistent-between-opennebula-systems/3335/4 "2016-11-30T10:46:14Z")

</div>

Hi, you could use the image import function for your vms disks, like described here (first export/just copy all of them to some disk that you could literally carry to the site with the 5.2 installation):

> [@Can I import and re-use VM images from an already existing datastore?](https://forum.opennebula.io/t/can-i-import-and-re-use-vm-images-from-an-already-existing-datastore/566/2):
>
> Hello, if both machines are in a cluster, you cold migrate the VMs. Otherwise you could create a new VM and replace the disk file (never tried that). I once created a qcow file and imported it as a new image and created a template for it. AFAIK there is no export/import function. Copying the datastore might fail - I assume, that the database is not updated with records for the VM. Regards, marc.

what you still need would be a script that exports and imports your vm definitions.  
and therefore I think that importing directly into the database is not the way to go!

i would write some script that is exporting all the vms definitions to “one template files” in text format.  
so you would have one template file for each vm.  
certainly you would have to add the correct names of the images (in the new 5.2 store) also to these template files.

on the new site you then would have to instantiate every template.

with some helper scripts this should be doable.

what do you think? still quite tedious right?  
best  
Jojo

---

_[View the full topic](https://forum.opennebula.io/t/how-to-move-vms-persistent-non-persistent-between-opennebula-systems/3335)._
