Questions tagged [qcow2]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
1 answer
26 views

Can't Recover Space from qcow2 image without deleting wanted snapshots

I have a virtual machine that started out with 5 snapshots 1,2,3,4,5. I used qemu-img to delete snapshots 1,2,3. Snapshots 4 and 5 are still needed and were not deleted. How can I release the space ...
user avatar
0 votes
0 answers
43 views

What capabilities do you lose when turning off COW on a qcow2 file?

I run a small internal cloud utilizing 3 redundant, live migration capable Ubuntu/Qemu/KVM hosts with ~30 mixed OS VMs. The Pool volumes are BTRFS and before any of you give me crap about it: this is ...
user avatar
  • 151
0 votes
0 answers
41 views

Modifying parent snapshot in QCOW2 internal snapshots tree

Faced one problem and cannot find any info on the net Let's say I have several snapshots on my VM running on .qcow2 image. For example, it has next tree: # virsh snapshot-list my_vm --tree clean | ...
user avatar
  • 1
0 votes
0 answers
38 views

How to "upgrade" an image based on QCOW2?

I have a few VM images based on a minimal QCOW2 image (say release 15.2). Each VM's configuration is stored in a persistent image. Now, when there is a newer QCOW2 image (say release 15.3), how would ...
user avatar
  • 266
1 vote
0 answers
44 views

Mount qcow2 image on boot using fstab

I'm intending to make individual directories snapshotable in order to be able to experiment and rollback. Since there are many such directories and their contents can vary in size, solutions such as ...
user avatar
  • 131
0 votes
0 answers
72 views

Why I can't change qcow2 password via chroot

I have a Linux qcow2 image, and I want to change the root password. I combined qemu-nbd and chroot commands to access the filesystem in this qcow2 file. qemu-nbd --connect=/dev/nbd0 ./linux.qcow2 sudo ...
user avatar
0 votes
1 answer
425 views

Incremental backup qcow2 image with rsync

I use rsync to backup the qcow2 disks of my virtual machines. However, I would like to be able to get an incremental backup so that I don't have to copy the entire disk every time. for now I use rsync ...
user avatar
0 votes
1 answer
177 views

OVA to QCOW2 conversion - Openstack instance dracut initqueue timeout and could not boot

I have a custom OVA built with Centos 7 and trying to convert it to qcow2. I have extracted the files from the OVA and converted the vmdk to qcow2 with following command: qemu-img convert -O qcow2 ...
user avatar
  • 111
-1 votes
1 answer
208 views

How to enable zstd for your qcow2 files [closed]

In QEMU 5.1 zstd compression of your qcow2 files was introduced but I can't find a way to activate it?
user avatar
  • 285
1 vote
0 answers
89 views

Noop convert qcow2 image but keeps internal snapshots

I have a qcow2 image. The image size is 200 GB, but the actual use is only 30 GB. I'm using qemu-img convert -O qcow2 source.qcow2 shrunk.qcow2 to removes sparse space and the images shrinks correctly ...
user avatar
1 vote
0 answers
68 views

State of OCFS2 as KVM storage for QCOW2 format

Using a shared iSCSI SAN all SSD and good cluster aware filesystems are few and far between with Linux. What is the state of OCFS2 with modern Linux kernels and is it considered reliable enough to ...
user avatar
  • 111
0 votes
1 answer
639 views

How do I make a compressed disk image (qcow2 and/or squashfs) from a disk directly?

I have a disk attached to my server and I want to make the disk image of it downloadable on the same server. The disk itself is 500GB but I don't want to have a 500GB disk image for download. I'd like ...
user avatar
2 votes
2 answers
531 views

Terraform Libvirt - How to use local qcow2 file in the hypervisor instead of cloud images?

It seems like the libvirt provider only takes pre-defined cloud images. I create my own base qcow2 image that is local to the hypervisor and wish to use it as source file with terraform libvirtd. Is ...
user avatar
  • 21
0 votes
2 answers
480 views

Migrate ESXi vm to qcow2 with settings preserved?

I have attempted to export a vm in ESXi which produced 3 files: vm_name.ovf (12KB) disk-0-2.vmdk (73KB) disk-1.vmdk (1.2GB) I assumed the larger file (disk-1.vmdk) was the flat file and ...
user avatar
  • 101
0 votes
1 answer
553 views

customize qcow2 ubuntu image fail

I download qcow2 ubuntu 18.04 img from here: https://cloud-images.ubuntu.com/bionic/current/bionic-server-cloudimg-amd64.img I want to add some packages into qcow2 image before use it as a base img ...
user avatar
1 vote
0 answers
154 views

How to check the cache mode of a qcow2 image?

Say I converted an image to writethrough cache mode with this command: qemu-img convert -t writethrough -O qcow2 in-image.qcow2 out-image.qcow2 How can I check/verify the cache mode of the image?
user avatar
  • 598
0 votes
1 answer
2k views

Is there a way to convert qcow2 images to ovf format?

I have one qcow2 image. But, I need image in ovf format. I know there is already one answer here Any way to convert qcow2 to ovf?, but I don't have vCenter installed with me. So, i am looking for any ...
user avatar
  • 3
1 vote
1 answer
329 views

qcow2 image: ERROR refcount block 69 is outside image

I have this backup.qcow2 image which was working fine in my kvm/qemu virtual machine before. When I attach it to another virtual machine, Windows recognizes the disk but fails to read partitions. The ...
user avatar
  • 111
1 vote
1 answer
1k views

Convert QCOW2 to VMDK (Citrix Xen)

Hy everyone, the search function does not come up with a propper solution. I want to convert a old KVM disk QCOW2 to an compatible Ctrix Xen disk e.g. VMDK with that qemu-img converting tool qemu-...
user avatar
  • 11
0 votes
2 answers
118 views

Which file has chaged from one VM-overlay to the next?

I've a base image of a windows10 machine. [win10_base image].qcow2 -- [overlay_with_bug].qcow2 I have a bug of a app which I can reproduce. This bug does alter something on the system. I want to ...
user avatar
0 votes
0 answers
114 views

Trim qcow2 disk

vps disk size does not updates on server when you delete files within vps. For example one vps had 1TB usage, I deleted 800GB in that vps but vps disk size is still 1TB on server.
user avatar
3 votes
1 answer
2k views

Ansible fails at "Gathering hosts" presumably because SSH is slow to connect. Setting `UseDNS no` resolves the issue

I am having what appears to be a DNS related issue that I would appreciate some assistance resolving. I'm using Ansible to provision a Kubernetes cluster on my Proxmox server. The project works in ...
user avatar
2 votes
1 answer
218 views

xfs_db reports high file fragmentation where VM is located, but VM shows almost no fragmentation

I have several libvirt VMs stored on xfs partitions and am using gluster to replicate the storage. The VMs use qcow2 for storage. Some of the partitions where the VMs are located indicate high file ...
user avatar
0 votes
0 answers
39 views

QEMU clarifications and setup optimizations

We are using qemu with kvm acceleration. I wanted to understand the -drive flag, currently we are using it as follows: -drive file=<qcow2 snapshot file> if=virtio I have the following ...
user avatar
  • 121
1 vote
1 answer
72 views

KVM file size issue on RHEL 6.9

I tried to allocate 60GB of additional storage to my Win7 KVM by adding a new disk under 'Hardware Settings' using Add Hardware. But the new disk didn't show up in Win7 so i deleted the Disk using ...
user avatar
  • 11
2 votes
3 answers
9k views

How to move KVM image to another directory/partition?

My storage devices are mounted as follows: $ df -h Filesystem Size Used Avail Use% Mounted on /dev/md2 193G 35G 148G 19% / /dev/md4 492G 73M 466G 1% /mnt My KVM image is ...
user avatar
  • 501
1 vote
1 answer
551 views

How do Centos cloud images map to iso images

Is it possible to figure out which cloud image maps to which iso release for Centos. I would like a Centos 7.3 minimal image, but when I browse the Centos cloud image site I cannot see any references ...
user avatar
  • 901
2 votes
2 answers
5k views

KVM snapshotting. How to see what's inside the qcow2 file?

I use qcow2 file format and create snapshots using a Virt-manager GUI. I assume I have 100GB disk space and 70% is used by VM at this moment. The qcow2-file size is about 70GB. I create a snapshot. ...
user avatar
1 vote
2 answers
7k views

KVM guest qcow2 larger than disk size

I have a Windows 10 VM running on a server that I need to move to another server. The trouble is that the qcow2 file size is too large for the target server. What's odd about this is that the ...
user avatar
1 vote
1 answer
285 views

Cannot upload file to qcow2 image file using guestfish on rhel 7.3

I am trying to write a temp file into a qcow2 image file using guestfish as follows: [root@localhost home]# guestfish --rw -i -a vm.qcow2 upload temp /home/ and faced the following problem: ...
user avatar
0 votes
1 answer
300 views

Is it safe to use overlay as new VM from QCOW2 image for multiple users?

As title states, is it safe to give overlay of same image to multiple different users? From security standpoint, do they have access to other users data? Can any user corrupt/change base image or ...
user avatar
  • 3
2 votes
2 answers
3k views

qemu-img convert CentOS7 vmdk to qcow2 and vice versa error

I'm trying to convert CentOS7 from VMDK to QCOW2 and vice versa using qemu-img convert command. when uploading the new Templates (OVF with the new converted vmdk and KVM template with the new ...
user avatar
  • 31
8 votes
2 answers
18k views

How to repair a broken-resized qcow2 disk image for libvirt/kvm?

Today I wanted to increase the size of a VM, so I did what I always do (have done it before): qemu-img resize diskimage.qcow2 +22GB Then the file broke and the VM does not start any more. I tried ...
user avatar
  • 283
6 votes
2 answers
11k views

How to create a qcow2 file that is not thin provisioned?

When I do the below then the qcow2 file is less than 200KB. # qemu-img create -f qcow2 /var/lib/libvirt/images/urb-dat0.qcow2 10G # du -hsc /var/lib/libvirt/images/urb-dat0.qcow2 196K /var/lib/...
user avatar
1 vote
1 answer
588 views

Is it safe to use fallocate --dig-holes while being modified

Is it safe to use fallocate --dig-holes on a file while it is being modified/written? For example on a QCOW2 image opened by a KVM guest?
user avatar
3 votes
0 answers
727 views

Creating OVF headless with generated vmdk

I am looking to create an OVF file during a nightly build process. I currently have this process creating a qcow2 image, which I convert to vmdk using qemu. qemu-img convert -f qcow2 ${image_name} -O ...
user avatar
  • 31
5 votes
5 answers
15k views

QCOW2 virtual size lowering

I'm trying to get the virtual size of a qcow2 container down so that it can fit in a openstack flavor with 10GB disk. root@node-10:~# qemu-img info zztop.qcow image: zztop.qcow file format: qcow2 ...
user avatar
1 vote
2 answers
2k views

Accessing linux guest OS filesystem in qcow2 image

I'm attaching VM qcow2 image to get access to files which inside: modprobe nbd max_part=63 qemu-nbd -n -c /dev/nbd0 /var/lib/libvirt/images/vm-image.qcow2 scanning for volume groups vgscan: ...
user avatar
  • 137
2 votes
3 answers
2k views

qemu-img: Could not open '/dev/stdin': Could not refresh total sector count: Operation not permitted

I want to transfer block device contents over the network directly into a qcow2 image. I started with a small simulation: [root@okvmh1 default]# dd if=/dev/zero bs=1M count=100 | qemu-img convert -p -...
user avatar
  • 538
0 votes
0 answers
2k views

How slow can be a QCOW2 vm disk (proxmox/KVM) over NFS (dedicated 1Gbit)?

I'm running 3 proxmox 3.4 nodes using NFS shared storage with a dedicated 1GB network switch. root@lnxvt10:~# pveversion pve-manager/3.4-11/6502936f (running kernel: 2.6.32-43-pve) root@lnxvt10:~# ...
user avatar
  • 190
1 vote
1 answer
4k views

(centOS) cloud-init not pulling ssh

Trying to build CentOS 6 qcow2 image with OpenStack guide[http://docs.openstack.org/image-guide/content/centos-image.html]. I'm using "cloud-init" instead of the "/etc/rc.d/rc.local" script but I ...
user avatar
12 votes
1 answer
61k views

How do you create a qcow2 file that is small yet commodious on a Linux server?

I believe that there are qcow2 files that displace a small amount of gigabytes on a server (as verified with a df -h on the physical server) yet allow for lots of space when you log into the virt-...
user avatar
  • 143
0 votes
1 answer
1k views

Edit /etc/resolvconf/resolv.conf.d/base in Centos 7 -- qcow2 image

My qcow2 image uses local nameserver, 192.168.122.1 which is not working for reasons unknown. So, I tried to use guestfish and edit the file /etc/resolv.conf to add nameservers, 8.8.8.8. This doesnt ...
user avatar
1 vote
0 answers
244 views

Boot a qcow2 image in Ganeti

I am very confused on how Ganeti actually boots machines. My problem is quite simple. I have a qcow2 image in a machine and I want to boot it. How can I do it? I don't really understand the idea of ...
user avatar
31 votes
2 answers
108k views

Which is better image format, raw or qcow2, to use as a baseimage for other VMs?

I am using a baseimage and based on that creating many VMs. And now I want to know which is better, qcow2 or raw to use for a baseimage. Moreover, can you please tell me if there is any advantage of ...
user avatar
  • 553
2 votes
1 answer
1k views

How to backup running KVM guest qcow2 disk without LVM?

How to backup running KVM guests, when using qcow2 disks and host system does not use a LVM? Is it even possible without guest shutdown?
user avatar
  • 327
3 votes
5 answers
8k views

KVM virt-clone while the VM is running

Is it possible to clone a running kvm machine without tools like virt-clone? They already have the original vm in production, I cannot shut it down. If I don't care about temporary data corruption (...
user avatar
  • 61
0 votes
2 answers
3k views

How do I make KVM images with LVM partitioning be thinly provisioned with a max growth size?

BACKGROUND: Up to now, I have been provisioning VMs as follows: Create template/gold VM: Create new CentOS 6.6 VM with raw 200GB disk (1 .xml file, 1 .img file) LVM partitioning with: /boot, swap, ...
user avatar
1 vote
1 answer
2k views

Qcow2 images growing far beyond what they should

I am using ubuntu 12.04 and have seen this: https://bugs.launchpad.net/ubuntu/+source/qemu-kvm/+bug/1025244 Our qcow2 images are growing far beyond what they should... with some of them growing to as ...
user avatar
5 votes
1 answer
26k views

Any way to convert qcow2 to ovf?

In our application we are downloading a qcow2 image and after that we are supposed to import that as OVF. So any way to convert qcow2 --> OVF or qcow2 --> vmdk(using qemu-img convert) --> ...
user avatar
  • 167