[one-users] Move an image

Ruben S. Montero rsmontero at opennebula.org
Tue Feb 11 10:59:30 PST 2014

No, you cannot yet :( see [1,2].

However you can do the procedure manually. Let's assume that:

a. You already have a new datastore, ready and available
under /var/lib/one/datastores/<ID>
b. There are no VMs running using the images to be moved


1.- Move the image file to the new place, you can keep the hashed name

mv /var/lib/one/datastores/106/fc0b14ee* /var/lib/one/datastores/<ID>/

2.- Register a new image.You can keep the previous attributes if any (e.g.
DRIVER or CACHE) **but be sure** to include:
     * SOURCE set to point to the new location
     * SIZE set to the original value

This procedure can be easily script'ed if there are too many images.



[1] http://dev.opennebula.org/issues/2417
[2] http://dev.opennebula.org/issues/1696

On Tue, Feb 11, 2014 at 7:40 PM, Nicolas Bélan <nicolas.belan at gmail.com>wrote:

> Hello the list,
> I just want to know if it is possible to "move" a disk image between
> datastore.
> The use case is:
> I have a brand new JBOD, and I want to move  5TB of data from existing
> DS to the new one.
> I do not talk about System DS, but image DS.
> [oneadmin] ll -h
> /var/lib/one/datastores/106/fc0b14ee770a71c5db4ecd4947d13a10
> -rw-r--r-- 1 oneadmin oneadmin 2,8T  6 feb. 10:40
> /var/lib/one/datastores/106/fc0b14ee770a71c5db4ecd4947d13a10
> I can move/rsync/anything the disk, but I would like to re-register it
> like that (without any qemu-img convert) because, I do not want to clone
> it, just store it somewhere else.
> Thank you for any web pointer, I did not find any :-/
> Best regards,
> Nicolas
> _______________________________________________
> Users mailing list
> Users at lists.opennebula.org
> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org

Ruben S. Montero, PhD
Project co-Lead and Chief Architect
OpenNebula - Flexible Enterprise Cloud Made Simple
www.OpenNebula.org | rsmontero at opennebula.org | @OpenNebula
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opennebula.org/pipermail/users-opennebula.org/attachments/20140211/1faa330f/attachment-0002.htm>

More information about the Users mailing list