[SOLVED] Unreferenced disks after migrating from VMWare; Unable to delete them

KMJ

Member
Jul 10, 2021
25
2
8
63
After successfully migrating from VMWare to Proxmox I have some unreferenced disks on the storage, I am unable to delete:

e.g.:

vm 1077 uses vm-1077-disk-1 in hardware pane. No other disks showing up

The ZFS storage shows:

vm-1077-disk-0
vm-1077-disk-1

trying to remove disk-0 says:

Cannot remove image, a guest with VMID '1077' exists!
You can delete the image from the guest's hardware pane

But no was to see disk-0 on the guest hardware pane.

Tried to migrate the vm to another node, but this moves disk-0 with the vm.

I have this for 10 or 12 VMs, others are fine.

Any help is greatly appreciated.
 
run
Code:
qm rescan --vmid ID
to add all disks on the storage to the vm config as 'unused' now you should be able to delete them from the hardware pane
 
Wow, Thank you!

root@vmh21:~# qm rescan --dryrun
NOTE: running in dry-run mode, won't write changes out!
rescan volumes...
VM 19241 add unreferenced volume 'vmdata-noenc:vm-19241-disk-0' as 'unused0' to config
VM 1077 add unreferenced volume 'vmdata-noenc:vm-1077-disk-0' as 'unused0' to config
VM 91211 add unreferenced volume 'vmdata-noenc:vm-91211-disk-0' as 'unused0' to config
VM 91211 add unreferenced volume 'vmdata-noenc:vm-91211-disk-1' as 'unused1' to config
VM 1929 add unreferenced volume 'vmdata-noenc:vm-1929-disk-0' as 'unused0' to config