{"id":37969,"date":"2022-03-16T09:00:42","date_gmt":"2022-03-16T01:00:42","guid":{"rendered":"https:\/\/www.casbay.com\/guide\/?post_type=kb&p=37969"},"modified":"2022-09-08T19:47:07","modified_gmt":"2022-09-08T11:47:07","slug":"windows-10-vbox-vm-to-kvm-virtualisation","status":"publish","type":"kb","link":"https:\/\/www.casbay.com\/guide\/kb\/windows-10-vbox-vm-to-kvm-virtualisation","title":{"rendered":"Quick Guide On Converting VirtualBox VM to KVM in Windows 10 For KVM Virtualisation"},"content":{"rendered":"\t\t
In this guide, we will be going through how to convert your VirtualBox VM which uses the \u201c.vdi\u201d extension to KVM which uses \u201c.qcow2\u201d. This is a guide for people who wish to switch over to KVM virtualisation without creating a whole new virtual machine all over again.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t Firstly, open your command prompt and locate your VirtualBox directory using the cd command.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t In my case, it’s in my D drive.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t To clone and convert the file, run the following command in your command prompt.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t Here is an example of my command.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t You will be seeing a similar output as followed in your command prompt.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t You will be able to see an image file in the directory you had cloned into. The raw image file will be much larger in comparison with your \u201c.vdi\u201d file.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t This final step requires you to use the qemu-ing command, kindly refer to this\u00a0link<\/a> if you do not have the command installed, else skip this step if you already have it installed and proceed with the guide.<\/p> Run the following command for the \u201c.img\u201d to \u201c.qcow2\u201d conversion.<\/p>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\tStep 1: Open CMD and locate your VirtualBox directory.<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
cd your_directory\\Oracle\\VirtualBox<\/pre>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
cd D:\\Oracle\\VirtualBox<\/pre>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t
Step 2: Clone and convert your VDI file into a raw image file.<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
VboxManage clonehd \u201cabsolutepath\/filename_of_existing_vdi_file.vdi\u201d \u201cabsolutepath\/filename.img\u201d -format raw<\/pre>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
VBoxManage clonehd \u201cD:\\Oracle\\VirtualBox VMs\\Ubuntu\\Ubuntu.vdi\u201d \u201cD:\\Oracle\\VirtualBox VMs\\Ubuntu\\Ubuntu.img\u201d -format raw<\/pre>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
0%\u202610%\u202620%\u202630%\u202640%\u202650%\u202660%\u202670%\u202680%\u202690%\u2026100%\nClone medium created in format \u2018raw\u2019. UUID: afdb24d-1a3c-4276-9251-bf2616f9b75e<\/pre>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t
Step 3: Converting image file into the \".qcow2\" file which is the file type for KVM.<\/h2>\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t