New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Bug OCPBUGS-13301: add support for cpu partitioning on site config #1441
feat: Bug OCPBUGS-13301: add support for cpu partitioning on site config #1441
Conversation
Hi @eggfoobar. Thanks for your PR. I'm waiting for a openshift-kni member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@imiller0 Would love feedback on the deprecation warning, not sure if you feel it's too much. Was of two minds if it made sense to only apply it if both |
/ok-to-test |
@serngawy @sabbir-47 can you please review |
faaea65
to
d459d1a
Compare
@@ -16,6 +16,7 @@ metadata: | |||
agent-install.openshift.io/install-config-overrides: '{"networking":{"networkType":"OVNKubernetes"}}' | |||
argocd.argoproj.io/sync-wave: "1" | |||
ran.openshift.io/ztp-gitops-generated: '{}' | |||
ran.openshift.io/ztp-warning/field-deprecation/cpuset: siteConfig.clusters[].node[].cpuset will be deprecated after OCP 4.15, please use siteConfig.clusters[].cpuPartitioningMode for OCP versions >= 4.13 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cpuPartitioningMode does not exist in the install-config-overrides but the warning annotation get generated ?
I think warning annotation get generated if the cpuSet is used otherwise no need for it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, since we won't know the version the customer chooses for openshift, figured if they include a cpuset
we notify them that for 4.13 onwards they need to switch over to the new method.
@@ -273,3 +336,49 @@ func mergeJsonCommonKey(mergeWith, mergeTo, key string) (string, error) { | |||
} | |||
return string(newJson), nil | |||
} | |||
|
|||
func applyWorkloadPinningInstallConfigOverrides(clusterSpec *Clusters) (result string, err error) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I understand this func to replace the use of getWorkloadManifest is that correct ? if yes we need to remove the machineConfig OR the machineConfig for workload will till remain ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The siteConfig tool (binary) can be used to deploy clusters on prior releases as well. This new feature shows up in 4.13, so if the user is deploying a 4.12 cluster they will need the MachineConfig, but if they are deploying 4.13 they need this annotation (and do not need the MachineConfig)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe that if the user leaves "cpuset" out of their config we will automatically leave out the workload partitioning manifests. We will need to update the documentation to note that in 4.13+ the user specifies cpuPartitioningMode and not cpuset.
const ( | ||
deprecationCR = "AgentClusterInstall" | ||
deprecationField = "cpuset" | ||
deprecationMessage = "siteConfig.clusters[].node[].cpuset will be deprecated after OCP 4.15, please use siteConfig.clusters[].cpuPartitioningMode for OCP versions >= 4.13" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
better to have min message like "cpuset is deprecated instead use cpuPartitioningMode"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I minimized it but left the version information since we won't know which version the user chooses, would that be okay?
The ci job required the commit message to start with ztp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Along with the changes to siteConfig generator, we need to update the reference siteconfigs to make use of the cpuPartitioningMode instead of cpuset. The PerformanceProfile in the reference configurations already set the cpu appropriately so only the SiteConfig CRs need to be updated.
https://github.com/openshift-kni/cnf-features-deploy/blob/master/ztp/gitops-subscriptions/argocd/example/siteconfig/example-sno.yaml
And the 3NC and standard clusters in the same directory.
d459d1a
to
1c3ae55
Compare
add new flag for cpu partitioning mode add deprecation warning for situations where cpuset is defined for nodes Signed-off-by: ehila <ehila@redhat.com>
Signed-off-by: ehila <ehila@redhat.com>
1c3ae55
to
68d1df9
Compare
/retest |
Signed-off-by: ehila <ehila@redhat.com>
3667534
to
b914c52
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: eggfoobar, imiller0, serngawy The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@eggfoobar can we remove the hold? |
yup! We should be good to remove it. /unhold |
/cherry-pick release-4.13 |
@imiller0: #1441 failed to apply on top of branch "release-4.13":
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@eggfoobar: Jira Issue OCPBUGS-13301: Some pull requests linked via external trackers have merged: The following pull requests linked via external trackers have not merged: These pull request must merge or be unlinked from the Jira bug in order for it to move to the next state. Once unlinked, request a bug refresh with Jira Issue OCPBUGS-13301 has not been moved to the MODIFIED state. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/jira refresh |
@imiller0: Jira Issue OCPBUGS-13301: All pull requests linked via external trackers have merged: Jira Issue OCPBUGS-13301 has been moved to the MODIFIED state. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
add new flag for cpu partitioning mode
add deprecation warning for situations where cpuset is defined for nodes
/hold
/cc @imiller0