Migrating Windows Server 2012 from VMDK to Opennebula

Hi,

I have migrated a VMWare VM (VMDK) to Opennebula. When I start the VM all seems fine, but for some reason doesn’t detect the Hard Drive. When I start the VM says that the disk is readonly, and when I go to CMD with the diskutility it shows no disk.

I’ve been doing my research and seems that may be related to virtio-drivers. So, I’ve created a “CDROM image” with the virtio-drivers ISO, an small empty datablock as this article says but can’t figure out how can I tell the template to use “virtio” as network device:

http://opennebula.org/opennebula-for-virtual-desktops/

And I also don’t know how to install those virtio-drivers. Booting from Windows and entering advanced options? Booting directly from this “virtio-drivers iso”?

This is my Windows Server 2012 VM config:

User template
DESCRIPTION = "WindowsServer2012R2_AD"
HYPERVISOR = "kvm"
LOGO = "images/logos/windows8.png"
Template
AUTOMATIC_DS_REQUIREMENTS = "“CLUSTERS/ID” @> 0"
AUTOMATIC_REQUIREMENTS = "(CLUSTER_ID = 0) & !(PUBLIC_CLOUD = YES)"
CONTEXT = [
DISK_ID = “2”,
NETWORK = “YES”,
SSH_PUBLIC_KEY = “”,
TARGET = “hdb” ]
CPU = "2"
DISK = [
CLONE = “NO”,
CLONE_TARGET = “SYSTEM”,
CLUSTER_ID = “0”,
DATASTORE = “default”,
DATASTORE_ID = “1”,
DEV_PREFIX = “hd”,
DISK_ID = “0”,
DISK_SNAPSHOT_TOTAL_SIZE = “0”,
DISK_TYPE = “FILE”,
DRIVER = “raw”,
IMAGE = “virtio_drivers_windows”,
IMAGE_ID = “28”,
IMAGE_STATE = “2”,
IMAGE_UNAME = “admin”,
LN_TARGET = “SYSTEM”,
READONLY = “YES”,
SAVE = “NO”,
SIZE = “149”,
SOURCE = “/var/lib/one//datastores/1/3c70f0a87ee1b15a1e694f5bb955571a”,
TARGET = “hda”,
TM_MAD = “ssh”,
TYPE = “CDROM” ]
DISK = [
CLONE = “YES”,
CLONE_TARGET = “SYSTEM”,
CLUSTER_ID = “0”,
DATASTORE = “default”,
DATASTORE_ID = “1”,
DEV_PREFIX = “vd”,
DISK_ID = “1”,
DISK_SNAPSHOT_TOTAL_SIZE = “0”,
DISK_TYPE = “FILE”,
DRIVER = “qcow2”,
IMAGE = “WindowsServer2012R2_AD”,
IMAGE_ID = “23”,
IMAGE_STATE = “2”,
IMAGE_UNAME = “marcel”,
LN_TARGET = “SYSTEM”,
ORIGINAL_SIZE = “48128”,
READONLY = “NO”,
SAVE = “NO”,
SIZE = “91136”,
SOURCE = “/var/lib/one//datastores/1/cd17c014f2eff689a5f38e136370a367”,
TARGET = “vda”,
TM_MAD = “ssh”,
TYPE = “FILE” ]
GRAPHICS = [
LISTEN = “0.0.0.0”,
PORT = “5941”,
TYPE = “VNC” ]
MEMORY = "5120"
TEMPLATE_ID = "26"
VCPU = "2"
VMID = “41”

Thanks.

Hi Marcel!
I haven’t done this kind of migration but you may find useful this link: https://platform9.com/support/migrate-a-windows-vm-from-vsphere-to-kvm/

You could use the first four steps. It seems that the article suggests instalingl the virtio drivers in the VMDK, uninstalling the VMWare tools and finally convert it to QCOW, that way it has all the drivers when the VM boots.

Cheers!

Thanks for that link, it was the solution to my problem.

After goig through all the steps (except the “Step 5 – Install Cloudbase”, of course) the import to Opennebula was successful.

Awesome!,
maybe it’s possible a different way but if any user has the same issue, it’s great to know that this worked for you.

Cheers!

Let me ask you about the other way…

What about installing “virtio-drivers” when deploying a Windows ISO directly from Opennebula?

Thanks again.

Hi Mistral!
that option is absolutely fine.

If you create a VM from scratch, I mean if you’re installing the Windows VM, you can provide a CDROM with the Windows ISO, and another resource with the ISO containing the virtio-drivers. Then when you install the VM you have the drivers needed by the installer and you can browse them.

This post explains this method so you can test it: How to create Windows VM?

Cheers!

That’s cool, thanks again!