Cannot deploy VM after upgrade to VCenter 8

Hello,

Opennebula 6.8.2 enterprise.
VCenter 8.0.2

After the update we cannot deploy new virtual machine. The VCenter report an error when cloning TPL, Virtual Machine already exists…

In log VM from opennebula I got :

Mon Mar 4 22:51:15 2024 [Z0][VMM][I]: Command execution failed (exit code: 255): /var/lib/one/remotes/vmm/vcenter/deploy ‘/var/lib/one/vms/243/deployment.0’ ‘CL_RD’ 243 CL_RD
Mon Mar 4 22:51:15 2024 [Z0][VMM][E]: deploy: Deploy of VM 243 on vCenter cluster CL_RD with /var/lib/one/vms/243/deployment.0 failed due to “disk with path TPL-VOC-OL8-INFRA/TPL-VOC-OL8-INFRA.vmdknot found in the vCenter VM"on attempt #0.
Mon Mar 4 22:51:15 2024 [Z0][VMM][I]: Deploy of VM 243 on vCenter cluster CL_RD with /var/lib/one/vms/243/deployment.0 failed due to “disk with path TPL-VOC-OL8-INFRA/TPL-VOC-OL8-INFRA.vmdknot found in the vCenter VM"on attempt #0. [”/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:1519:in `block in reference_disks’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:1502:in `each’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:1502:in `reference_disks’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:1266:in `reference_unmanaged_devices’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:700:in `clone_vm’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:3521:in `block in new_from_clone’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:3520:in `tap’”, “/usr/lib/one/ruby/vcenter_driver/virtual_machine.rb:3520:in `new_from_clone’”, “/var/lib/one/remotes/vmm/vcenter/deploy:92:in `'”]
Mon Mar 4 22:51:15 2024 [Z0][VMM][E]: deploy: Deploy of VM 243 on vCenter cluster CL_RD with /var/lib/one/vms/243/deployment.0 failed due to "disk with path TPL-VOC-OL8-INFRA/TPL-VOC-OL8-INFRA.vmdknot found in the vCenter VM"on attempt #1.

No error in onedb fsck. Everythin seems good …

Help will be appreciate.

thx

Hello,

This error message only occurs when the disk either: doesn’t find the SOURCE attribute path in vCenter, the disk source doesn’t match the template’s definition of the image, or the vCenter key couldn’t be assigned.

Can you check the Image in OpenNebula that is assigned to this VM and check the SOURCE path exists when viewed from vCenter as well? Perhaps during the upgrade somehow the full path to the vmdk file changed, like it got moved or the datastore uuid got changed. It could also be the key changed for the device of the VM. For this reason, it would be good to double check the VCENTER_* attributes for the VM and the image correlate with the correct objects in vCenter.

It may also be helpful to see the VM Template as it appears in from onevm show -x.