Skip to content

Removal of nodes fails when they are a PVE HA Resource #70

Description

@CO-lhageman

Describe the bug

When adding a k8s node to the HA manager as a resource, it can't delete that node once it is time to delete the VM because: Error removing host "co-pvetest-d1-pool2-tvmmt-5dcdf": failed to remove the machine: failed to create a task: 500 unable to remove VM 103 - used in HA resources and purge parameter not set.
There is a "purge" parameter in the API that removes the VMs from the job configs (like Backup, HA etc.) but that does not seem to be set.

We need to add VMs to the HA manager to use the dynamic CRS which dynamically moves VMs according to Host CPU and Memory usage.

To Reproduce

Steps to reproduce the behavior:

  1. Create a k8s cluster node with this driver
  2. add the node to the HA manager inside PVE
  3. remove the node from rancher
  4. Failure

Expected behavior

I would expect to be able to set the purge parameter so I can remove these VMs.
It would also be great if VMs could automatically be added to HA once they are created so I don't have to do that manually.

Versions

  • Rancher Machine Driver: v1.2.0-rc2
  • Proxmox VE: 9.1.9
  • Rancher: 2.13.3

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions