Migration from OpenNebula to Proxmox 5.x

Discussion in 'Proxmox VE: Installation and configuration' started by Valentin Ionescu, Apr 22, 2019.

Tags:
  1. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    Hello,

    I need to migrate from OpenNebula to Proxmox VE. Given that they both use KVM in the back, it should be pretty easy. Even if we have to recreate the VMs, that shouldn’t be too big of a deal. The problem is that the disks (.qcow2 or .raw, depending on how old is the machine created) are encrypted and we have no idea how to decrypt them in order to recreate the VMs on a Proxmox VE server. We know which encrypted disk is associated with which VM, the problem is that we can’t recreate them in Proxmox VS (for example, the VM DBS-22 has the disks “DBS-22-os.raw” -> 9f36f2a95b2f930727b503ecccdb6a29 and “DBS-22-data1.raw” -> 558f8cedebc39ce11f7d22b9fa111b1c on the storage server Cube07 : the encrypted or hashed string is what we are seeing on the Cube storage, while the name appears in template in OpenNebula).

    Has anyone migrated from OpenNebula to any other platform before and has gone through similar stuff? Does anybody have any idea how to add the disks in other Hypervisor without decrypting them?

    Your help is greatly appreciated.
     
  2. spirit

    spirit Well-Known Member

    Joined:
    Apr 2, 2010
    Messages:
    3,311
    Likes Received:
    131
    By encrypted, do you mean really encrypted at block level on the storage ? (maybe with luks ? where is the encryption key ?)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    I don't think that it's encrypted at block level. I don't have an encryption key.
     
  4. spirit

    spirit Well-Known Member

    Joined:
    Apr 2, 2010
    Messages:
    3,311
    Likes Received:
    131
    ok,
    so when you said
    "
    We know which encrypted disk is associated with which VM, the problem is that we can’t recreate them in Proxmox VS (for example, the VM DBS-22 has the disks “DBS-22-os.raw” -> 9f36f2a95b2f930727b503ecccdb6a29 and “DBS-22-data1.raw” -> 558f8cedebc39ce11f7d22b9fa111b1c"

    It's simply that you don't known what is the correct filename ?

    maybe can you do a "ps -aux" on your opennebula node, and check qemu process.
    you should see real filename path, and maybe it's possible to find the name of the vm somewhere in the qemu command line too ?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    the real filename path for a qemu process is: upload_2019-4-23_10-19-50.png

    where from /var/lib/one/datastores/168/789ac20a57c5ca7d745d443c33f913b6 - 168 is the ID of the datastore and from /var/lib/one//datastores/131/1349/ - 1349 is the ID for the VM
     
  6. spirit

    spirit Well-Known Member

    Joined:
    Apr 2, 2010
    Messages:
    3,311
    Likes Received:
    131
    ok, so you only need to recreate a vm 1349 on proxmox (with same configuration),
    then you can import this disk on proxmox with the "qm importdisk" command

    qm importdisk <vmid> <source> <storage>

    ex: qm importdisk 1349 789ac20a57c5ca7d745d443c33f913b6 youproxmoxstoragename


    (qm importdisk need to be launch on your proxmox node, so you need to copy files from openbula (vm offline), or shared them through nfs for example)
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  7. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    Hello,

    Sorry for the late response and thank you for your solution but there is a problem.
    I have an identical VM on my Proxmox and after the import the hard disk is not bootable.
    /mnt/pve/Array3-NFS1# qm importdisk 103 9055c0eb00a190a455ff9adaf838b52b Array3-NFS1 --format qcow2
    Formatting '/mnt/pve/Array3-NFS1/images/103/vm-103-disk-2.qcow2', fmt=qcow2 size=34359738368 cluster_size=65536 preallocation=metadata lazy_refcounts=off refcount_bits=16
    (100.00/100%)

    No fail logs.

    This is the test VM that I have on both Virtualization Solutions
     
  8. spirit

    spirit Well-Known Member

    Joined:
    Apr 2, 2010
    Messages:
    3,311
    Likes Received:
    131
    Are you sure that you have selected in vm option "bootorder", the correct disk ? (don't known if you have multiple disks, but I'm seeing "-2.qcow2")
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  9. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    I have only one disk.
     
  10. spirit

    spirit Well-Known Member

    Joined:
    Apr 2, 2010
    Messages:
    3,311
    Likes Received:
    131
    is it a linux or windows vm ?

    does it have a grub or another bootloader ? or maybe does it been install in uefi mode on opennebula ?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  11. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    It is not installed in uefi mode on opennebula. It is a linux VM.
     
  12. Valentin Ionescu

    Valentin Ionescu New Member

    Joined:
    Apr 5, 2019
    Messages:
    7
    Likes Received:
    0
    Hello,

    After a long time i figured it out.

    The disks are not encrypted. The names are generated by OpenNebula without the .qcow2 or .raw termination.
    You just have to take the disk and change the name to the disk in Proxmox and start the VM.

    Thank you for your assistance.
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice