Skip to contentSkip to conversation

qemu-img: Could not open '....qcow2': Could not read snapshots: File too large

Qemu-devel Kis Gellert 2 participants 2 messages Dec 7, 2015

lore
Share & tools
lore
#0 lore raw

Today one of my virtual machines failed starting. Previously , I might made a snapshot while VM running.

I got this error in virt-manager:

Error starting domain: internal error: process exited while connecting to monitor: 2015-12-07T08:48:16.006513Z qemu-system-x86_64: -drive file=/home/g1ra/kvmware/centosnfs.qcow2,if=none,id=drive-ide0-0-0,format=qcow2: Could not read snapshots: File too large

Traceback (most recent call last):

File "/usr/share/virt-manager/virtManager/asyncjob.py", line 89, in cb_wrapper

callback(asyncjob, *args, **kwargs)

File "/usr/share/virt-manager/virtManager/asyncjob.py", line 125, in tmpcb

callback(*args, **kwargs)

File "/usr/share/virt-manager/virtManager/libvirtobject.py", line 83, in newfn

ret = fn(self, *args, **kwargs)

File "/usr/share/virt-manager/virtManager/domain.py", line 1423, in startup

self._backend.create()

File "/usr/lib64/python2.7/site-packages/libvirt.py", line 1029, in create

if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self)

libvirtError: internal error: process exited while connecting to monitor: 2015-12-07T08:48:16.006513Z qemu-system-x86_64: -drive file=/home/g1ra/kvmware/centosnfs.qcow2,if=none,id=drive-ide0-0-0,format=qcow2: Could not read snapshots: File too large

Quoted 1 line

From the terminal , I got same error for all qemu-img

    g1ra@d7520:~/kvmware$ qemu-img info centosnfs.qcow2                                                                                                                                                             

qemu-img: Could not open 'centosnfs.qcow2': Could not read snapshots: File too large

g1ra@d7520:~/kvmware$ qemu-img snapshot -l centosnfs.qcow2

qemu-img: Could not open 'centosnfs.qcow2': Could not read snapshots: File too large

#1 lore raw

Am 07.12.2015 um 10:07 hat Kis Gellert geschrieben:

Quoted 2 lines

Today one of my virtual machines failed starting. Previously , I might made a snapshot while VM running.

Never access disk images from more than one process at the same time (except if all of them are read-only), it causes corruption. The proper way of taking a snapshot of a running VM is the qemu monitor (i.e. in your case through libvirt).

Your best bet for recovering at least some data is using either a hex editor or tests/qemu-iotests/qcow2.py from the qemu source tree to update the number of snapshots to 0 and then use qemu-img convert to copy the data out.

Kevin