Re: Making a disk image created with virt-install qcow2 format from the start

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Stephan wrote:
> Hi,
> 
> I've been creating images with virt-install (thanks by the way!)
> 
> I was just wondering, is there a way to specify the disk image file type
> when you create the machine? I can convert it using tools from qemu, but
> it's an extra step and I'd prefer to have the images as qcow2 from the
> start if possible.
> 
> I'm doing this:
> 
> sudo mkdir /vservers/edi1-whatever1/ && sudo virt-install --hvm
> --accelerate --os-type=linux --os-variant=debianEtch --arch=x86_64
> --bridge=br0 --ram=256 --vcpus=4 --check-cpu --vnc --name=edi1-whatever1
> --file=/vservers/edi1-whatever1/disk0.qcow2 --file-size=8
> --cdrom=/dev/cdrom --debug
> 
> but the file isn't the right format:
> 
> file disk0.qcow2 
> disk0.qcow2: x86 boot sector; partition 1: ID=0x83, active, starthead 1,
> startsector 63, 15952482 sectors; partition 2: ID=0x5, starthead 0,
> startsector 15952545, 819315 sectors
> 
> instead of something like this:
> 
> file disk0.qcow2 
> disk0.qcow2: Qemu Image, Format: Qcow , Version: 2
> 
> Is there a way to specify the image type using virt-install? I've read the
> man file and looked on the Internet, but can't find the answer. Sorry if
> this is an easy question.
> 

There isn't a way to do so as of yet. But as a workaround, rather than
converting the image after the fact, you could use qemu-img to create
the qcow file ahead of time, and just point virt-manager at it with the
--file option, and it should all work.

Thanks,
Cole

_______________________________________________
et-mgmt-tools mailing list
et-mgmt-tools@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/et-mgmt-tools

[Index of Archives]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux