Symptoms
Most cases occur when a VM has been migrated from an old VHS/Parallels version (like VHS6 OR earlier), or even another third platform that handles the same disk types.
When you try to backup a VM you could get an error equal to or similar to this message "Cannot store dirty bitmaps in qcow2 v2 files", where it seems like it is facing with the version of the disk, in this case involving qcow2 format.
Cause
The root cause of this inconvenience that avoids performing a backup of a VM is commonly that the compatibility level of the virtual instance is too old to be processed by the current VHS environment.
Resolution
This is the procedure to identify and update the VM to be able to run backups properly.
1) Identify if a VM is incompatible with executing the following (you should know the UUID of the VM).
1.1) To know the UUID of the VM:
# prlctl list -a
or by using virsh tool:
# virsh list --all --uuid --name
1.2) Once you got it, you should use it to get the disk info of the VM:
Example:
# qemu-img info /vz/vmprivate/<VM_UUID>/harddisk1.hdd -U | grep compat
651942cf-744c-4a41-970a-bb6a5c8092e8
compat: 0.10
* Important: if "compat" value (version) is older than 1.1 you may continue with this procedure, otherwise this procedure won't work.
2) Stop the VM (only applicable for VMs that are running - for all others, skip to the next step):
# prlctl stop <VM>
3) Go to the VM's folder where the disk is stored:
3.1) You can discover it by executing:
Example:
# prlctl list -if 651942cf-744c-4a41-970a-bb6a5c8092e8 | grep Home
Home: /vz/vmprivate/651942cf-744c-4a41-970a-bb6a5c8092e8/
3.2) Then, go to the path and confirm the disk's name:
# cd /vz/vmprivate/651942cf-744c-4a41-970a-bb6a5c8092e8/
root@demo:/vz/vmprivate/651942cf-744c-4a41-970a-bb6a5c8092e8
# ls
cloud-config.iso config.pvs config.pvs.backup harddisk1.hdd
4) Convert the disk found to the compatible format version:
# qemu-img convert -f qcow2 -O qcow2 -o compat=1.1 harddisk1.hdd harddisk1-new.hdd
5) Now switch the names between both files and test the VM working:
# mv harddisk1.hdd harddisk1-old.hdd
# mv harddisk1-new.hdd harddisk1.hdd
# prlctl start 651942cf-744c-4a41-970a-bb6a5c8092e8
6) Lastly, if the VM is working properly, you should be able to perform a backup successfully:
# prlctl backup 651942cf-744c-4a41-970a-bb6a5c8092e8
Optionally, if all works as expected you could remove the "harddisk1-old.hdd" from the step 5.
Diagnostic steps:
You may get this error message at libvirt logs of the VM:
{"id":"libvirt-408840","error":{"class":"GenericError","desc":"Can't make bitmap '{ff14c999-a3cd-4bd8-b9b7-673f4fecf3e5}' persistent in 'drive-scsi0-0-0-0': Cannot store dirty bitmaps in qcow2 v2 files"}}
Related Ticket(s):
# 402289