Skip to content

Adding a VM to a vm-host group is racy #3575

@jcpowermac

Description

@jcpowermac

/kind bug

What steps did you take and what happened:

Adding the feature for vm-host topology within the openshift installer, capv:

  • Creates virtual machine
  • Power on virtual machine
  • Configures cluster's vm-host group with vm

The problem occurs between the power on and the time it takes to add the
vm to the vm-host group, then a potential vmotion to the correct ESXi host.

The virtual machine could be in the wrong vsphere topology at the time for the CCM to init the
node and the node has incorrect topology region and zone labels.

What did you expect to happen:

  • Creates virtual machine
  • Configure vCenter cluster vm-host group with vm
  • Power on virtual machine

Anything else you would like to add:

Already have a resolution, will add this issue to the PR.

Environment:

  • Cluster-api-provider-vsphere version: v1.12.0-rc.0.0.20250203113257-38f6b67f9b7d

https://github.com/openshift/installer/blob/e3cbeafe717594ac0f619212c207963217869624/cluster-api/providers/vsphere/go.mod#L9

  • Kubernetes version: (use kubectl version):
  • OS (e.g. from /etc/os-release):

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugCategorizes issue or PR as related to a bug.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions