vmware / vmware/pyvmomi

Admission control doesn't set failover resource percent correctly.

Open
#516 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

question
Dominant language
Python
Stars
2.3k
Forks
763
PR merge metrics
No merged PRs in 30d

Description

I am using the below code set Admission control on my HA enabled cluster.

    acp_spec = vim.cluster.FailoverResourcesAdmissionControlPolicy()
    acp_spec.cpuFailoverResourcesPercent = 27
    acp_spec.memoryFailoverResourcesPercent = 32

    #Prepare spec
    ha_config = cluster.configurationEx.dasConfig
    ha_config.admissionControlPolicy = acp_spec
    ha_config.admissionControlEnabled = True

    # Update cluster with spec.
    spec = vim.cluster.ConfigSpecEx()
    spec.dasConfig = ha_config
    _wait_for_task(cluster.ReconfigureComputeResource_Task(spec, True))

This doesn't seem to work fine. Regardless of the values I pass for cpuFailoverResourcesPercent and memoryFailoverResourcesPercent they are being set at 25%.

I am using a 4 node ESX 6.0 cluster registered with a 6.5 vCenter.

Any help will be highly appreciated.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the vim.cluster admission-control objects and the ReconfigureComputeResource_Task call shown in the report. Reproduce the configuration on the stated ESX 6.0 and vCenter 6.5 setup, then compare the requested CPU and memory percentages with the values returned after reconfiguration; done means determining whether the bindings preserve the requested values or documenting the external limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.