Since ages qemu is locking the image files (I think since 18.04) and that seems to block the command here.
IIRC Read-only readers can flag their open calls to skip that (e.g. qemu-img has an option --force-share). Not sure what virt-clone uses here, but whatever it is needs the similar treatment. @IBM IMHO this isn't a new bug or has this worked before (recently) and now fails? If you run this regularly please let us know when this started to fail. Changing to src:virt-manager which contains virt-clone but leaving the actual initial triage to JFH/Andrewc ** Package changed: linux (Ubuntu) => virt-manager (Ubuntu) -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/1873887 Title: virt-clone fails on a suspended (paused) guest, whereas documentation claims the clone should be successful. Status in Ubuntu on IBM z Systems: Incomplete Status in virt-manager package in Ubuntu: New Bug description: Guest XML virt-clone fails on a suspended (paused) guest, whereas documentation claims the clone should be successful. ---uname output--- Linux T257KVX 5.4.0-21-generic #25-Ubuntu SMP Sat Mar 28 13:10:00 UTC 2020 s390x s390x s390x GNU/Linux Machine Type = Type: 8562 Model: A00, LT2 ---Debugger--- A debugger is not configured ---Steps to Reproduce--- 1. Create a guest 2. Suspend it by running the following: virsh suspend <guest> 3. Verify that the guest has paused. 4. Attempt to clone it: virt-clone -o <suspended_guest> -n <new_guest> --auto-clone Observe the error: ERROR Couldn't create storage volume '<new_guest>.qcow2': 'internal error: Child process (/usr/bin/qemu-img convert -f qcow2 -O qcow2 -o compat=1.1,lazy_refcounts /guestimages/<suspended_guest>.qcow2 /guestimages/<new_guest>.qcow2) unexpected exit status 1: qemu-img: Could not open '/guestimages/<suspended_guest>.qcow2': Failed to get shared "write" lock Is another process using the image [/guestimages/<suspended_guest>.qcow2]? ' Even though the virt-clone --help documentation claims the following: General Options: -o ORIGINAL_GUEST, --original ORIGINAL_GUEST Name of the original guest; The status must be shut off or paused. And when one tries to clone a running guest, they are given the following message: ERROR Domain with devices to clone must be paused or shutoff. It is worth noting that this operation is successful on a guest that is shutdown *Additional Instructions for Ali Haider ali.hai...@ibm.com Joe Muro joem...@us.ibm.com: -Post a private note with access information to the machine that the bug is occuring on. VERSIONING: Host OS: Ubuntu 20.04 ibvirtd -V libvirtd (libvirt) 6.0.0 To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu-z-systems/+bug/1873887/+subscriptions -- Mailing list: https://launchpad.net/~kernel-packages Post to : kernel-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~kernel-packages More help : https://help.launchpad.net/ListHelp