VM creation failed and can't unlock/delete

voarsh

Active Member
Nov 20, 2020
218
20
38
29
I created a VM and it became interrupted, I think because the NFS behaved weirdly and I can't unlock/delete the VM. It doesn't exist apparently but I can see it stuck in this state.

Any ideas how I can remove it? I also see a VM drive that I can't delete on the storage because it's linked to the VM.


pvesm path Seagate1TBBox1Bay10:161/vm-161-disk-0.qcow2
/mnt/pve/Seagate1TBBox1Bay10/images/161/vm-161-disk-0.qcow2
I then removed this location.
 
Last edited:
What do qm unlock <vmid> and qm destroy <vmid> report exactly? Also, since you have deleted the qcow2 file manually, "destroy" might fail because of that. But since you already deleted it, it should be enough to just delete the config in /etc/pve/qemu-server/<vmid>.conf - as a last effort though, it is never recommended to mess with these files if you don't know what you're doing.
 
What do qm unlock <vmid> and qm destroy <vmid> report exactly? Also, since you have deleted the qcow2 file manually, "destroy" might fail because of that. But since you already deleted it, it should be enough to just delete the config in /etc/pve/qemu-server/<vmid>.conf - as a last effort though, it is never recommended to mess with these files if you don't know what you're doing.
Yes, usually if I can't delete a drive, I attach it to another VM, detach the disk and then remove it that way.
In this case, it's working as expected, so, that's good.
Thanks.

1615556182438.png