File lock error
Describe the bug launch failed: Cannot get image info: qemu-img failed (Process returned exit code: 1) with output: qemu-img: Could not open '/var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2': Failed to get shared "write" lock Is another process using the image [/var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2]?
To Reproduce How, and what happened?
-
multipass launch --name Vcasa307300 --cpus 1 --memory 1G --disk 12G --network name=br0,mode=manual,mac=22:22:32:99:10:0A --cloud-init cloud-init_Vcasa307300.yaml file:///root/convert/root.qcow2
Expected behavior It should launch the VM
Logs Please provide logs from the daemon, see accessing logs on where to find them on your platform.
Additional info
- OS: ubuntu22.04
-
multipass versionmultipass 1.15.0-dev.306+gfa2b29055 -
multipass info -
multipass get local.driverqemu
Additional context Add any other context about the problem here.
Can someone please check it, I need to fix this quickly Already deployed too much VMs , but getting this error for some vm
@vishaldhiman86 Thanks for reporting this.
Already deployed too much VMs , but getting this error for some vm
Do you mean the very same launch command multipass launch --name Vcasa307300 --cpus 1 --memory 1G --disk 12G --network name=br0,mode=manual,mac=22:22:32:99:10:0A --cloud-init cloud-init_Vcasa307300.yaml file:///root/convert/root.qcow2 succeeded sometimes?
Anyway, the error message suggests another process is using the image file in the VM Vcasa67011 folder. Can you try to find out which process is accessing it by running sudo lsof /var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2?
Yes, another process is using this. But if you can see the command which I have executed, there no reference given for that /var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2
@vishaldhiman86 Then can you share more info about the exact behavior of that command? Is that behavior arbitrary? Did you succeed sometimes? In the case of this particular failure, which process is using that? Will closing that process make a difference?
I am deploying multiple hostname using this command with same image i.e. file:///root/convert/root.qcow2
multipass launch --name $HOSTNAME--cpus 1 --memory 1G --disk 12G --network name=br0,mode=manual,mac=22:22:32:99:10:0A --cloud-init cloud-init_Vcasa307300.yaml file:///root/convert/root.qcow2
I have 50 hostnames that I was deploying with image file:///root/convert/root.qcow2 and some of them failed due to the error I mentioned earlier
After that I chose the image from the existing deployed VM eg: /var/snap/multipass/common/data/multipassd/vault/instances/Vcasa6000/root.qcow2 and used that image to deploy the rest of the VM and it was successful./
So I am guessing is there any limitation, or check
please suggest
Yes, another process is using this. But if you can see the command which I have executed, there no reference given for that /var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2
Can you share more info on this part to help us understand which process is using it?
sudo lsof /var/snap/multipass/common/data/multipassd/vault/instances/Vcasa67011/root.qcow2 this command I mentioned before should tell you.
Closing for lack of activity.