cluster-api-provider has no logic for handling hugepages configuration.
What we want:
Cluster API provider should expose logic for adding a created machine having hugepages settings by adding a field for the hugepages in the machine spec.
This means that when you create a machine set you can decide that all the machines will be created with hugepages configuration.
The UI behavior to auto configure high performance VMs with the `existing` policy is not supported.
How to test?
1. Create a machine set with the auto pinning policy, for example:
2. Verify that 1 machine is created and added with the provided hugepages provided. In RHV you can see it under the VM's custom properties.
3. scale to 2 replicas and make sure that another machine is created and added with the same hugepages configuration.
Negative test suggestion:
- Try to run it with unsupported values(other than 2048 or 1048576).
ocp - 4.8.0-0.nightly-2021-04-24-175929
1) create machineset with 2048 hugepages - verify before that there is enough space in the host
( vi /sys/kernel/mm/hugepages/hugepages-2048kB/nr_hugepages)
2) verify that machine created in rhv with custom property - 2048kb
3) scale to 2 replicas and make sure that another machine is created and added with the same hugepages configuration.
4) create machineset with unsupported values hugepages -for example -20
failed to create machine: error creating oVirt instance: The machine `hugepages` custom property must be one of the following options: 2048, 1048576. The value: 20 is not valid
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.