vCenter compute resource associate VMs

Problem:
I go to Infrastructure > compute ressources > computeressourceXXX > Associate VMs
when I click on the Associate VMs button, all the vms in katello are assigned to this compute ressource even thought I have 3 diferents compute ressource and not all my vms are in the one in clicked…

The only way to make it work is to cluck on each single vm, and then click the associate button… I couldn’t find a way to do it with hammer :’(

Expected outcome:
only assign the vm in this compute ressource

Foreman and Proxy versions:
katello_repositories_version: 3.8
katello_repositories_environment: release
foreman_repositories_environment: release
foreman_repositories_version: 1.19
katello_repositories_pulp_version: 2.16

Foreman and Proxy plugin versions:

Other relevant data:
No special logs detected

Nobody has an idea on this?
What is the rake console command to the same thing?
Sometimes the following work: hammer host update --id 205 --compute-resource example.com
but iften we got : InvalidVmConfig: Invalid virtual machine configuration.

Thanks in advance
Mike

Hi,

sorry to keep you without reply.
I believe you tagged the topic inapropriatelly.

You are most likely hitting a VMware issue, which has been fixed by https://github.com/theforeman/foreman/pull/6722. It will get to release 1.23

If you would like to, it should not be a big problem to send you a patch for your version.

Ondřej

1 Like

Hi,
Thanks for your answer,
Indeed it would be nice to have a patch :slight_smile:
Regards
Mike

Here is a patch of cherry-picked commit (git format-patch)

If you need an assistance with applying, let me know, I will try to ask around.
But it has no assets/dependencies changes, so easy apply of the diff and restarting the server should be sufficient.

Ondřej
patch.tgz (796 Bytes)