Thanks for your work, this script works perfectly.
I changed it a little bit so I can disable backups for certain disks of a VM. In my case I didn't want to backup a disk where I store games on, as it would take forever and use a lot of space, but backup the rest of the VM. So with the following entry, a vdisk will not be backed up if it's named nobak.img. This part can be added after the .img / .qcow code around line 971.
# -----------------------------------------------------------
# check if filename is "nobak.img" and if so don't create a backup of this vdisk
# -----------------------------------------------------------
if [ "$new_disk" == "nobak.img" ]; then
echo "warning: $disk of $vm is not backed up because it is named nobak.img"
continue
fi