LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Virtualization and Cloud (http://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/)
-   -   Image files on qcow2 format with KVM (http://www.linuxquestions.org/questions/linux-virtualization-and-cloud-90/image-files-on-qcow2-format-with-kvm-4175439597/)

benelux.j 12-01-2012 11:43 AM

Image files on qcow2 format with KVM
 
Hi all,
my KVM, on Centos 6.3, make all virtual machines with .img disk files format.
I would like that KVM is able to make file on .qcow2 format like standard setting.

Is possible, i need to change qemu.conf or other file?

jefro 12-01-2012 02:23 PM

I usually start off with building a qcow blank disk and then use it. One could use convert tools also to try to change it from one form or the other. In some cases a pre-allocated drive is better. Sometimes the grow process isn't in time with installers or loaders or such.

dyasny 12-01-2012 11:38 PM

.qcow2 or .img doesn't matter, it's just the suffix, not the actual file format.

benelux.j 12-02-2012 05:10 AM

thank ;)
 
Quote:

Originally Posted by dyasny (Post 4841033)
.qcow2 or .img doesn't matter, it's just the suffix, not the actual file format.

Many thanks, now is all clear :)

jorton 12-03-2012 11:18 AM

Qemu-img
 
KVM was built from Qemu. It should still have the qemu-img program available to convert the format... AND add compression if you desire (-c opt)

I use qemu not KVM but this should work for you.

qemu-img convert -c -O qcow2 jinix.img jinix.qcow


All times are GMT -5. The time now is 08:38 PM.