-
Notifications
You must be signed in to change notification settings - Fork 132
OCPBUGS-23167: Add performance real time tuned template #954
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| [main] | ||
| summary=Real time profile to override unsupported settings | ||
|
|
||
| [sysctl] | ||
| #Real time kernel doesn't support the following kernel parameters. | ||
| #The openshift-node-performance profile inherits these kernel parameters from the network-latency profile. | ||
| #Therefore, if the real time kernel is detected they will be dropped, meaning won't be applied. | ||
| drop=kernel.numa_balancing,net.core.busy_read,net.core.busy_poll |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -114,6 +114,21 @@ var _ = Describe("[rfe_id:27368][performance]", Ordered, func() { | |
| Expect(strings.TrimSpace(activeProfileName)).To(Equal(tunedExpectedName), "active profile name mismatch got %q expected %q", activeProfileName, tunedExpectedName) | ||
| } | ||
| }) | ||
|
|
||
| It("Tuned profile shouldn't be degraded", func() { | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should not be degraded after what? in this test you check a condition (this part LGTM) but there is no obvious link to how to get to this state. IOW, does this test depend on a specific order? which part of the system creates the conditions we're checking?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. should not be degraded after tuned profile has been applied to the system.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @ffromani Any error in the tuned log causes the state to switch to degraded. This fix removes a typical case - a sysctl that does not exist for the given kernel.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. sure, and what in the test causes any change in the system which could lead to Degraded state? |
||
| for _, node := range workerRTNodes { | ||
| key := types.NamespacedName{ | ||
| Name: node.Name, | ||
| Namespace: components.NamespaceNodeTuningOperator, | ||
| } | ||
| tunedProfile := &tunedv1.Profile{} | ||
| err := testclient.Client.Get(context.TODO(), key, tunedProfile) | ||
| Expect(err).ToNot(HaveOccurred(), "Failed to get the Tuned profile for node %s", node.Name) | ||
| degradedCondition := findCondition(tunedProfile.Status.Conditions, "Degraded") | ||
| Expect(degradedCondition).ToNot(BeNil(), "Degraded condition not found in Tuned profile status") | ||
| Expect(degradedCondition.Status).To(Equal(corev1.ConditionFalse), "Tuned profile is degraded") | ||
| } | ||
| }) | ||
| }) | ||
|
|
||
| Context("Pre boot tuning adjusted by tuned ", func() { | ||
|
|
@@ -1345,3 +1360,13 @@ func makeDevRPSMap(content string) map[string]string { | |
| } | ||
| return devRPSMap | ||
| } | ||
|
|
||
| // Helper function to find a condition in the status.conditions slice by type | ||
| func findCondition(conditions []tunedv1.ProfileStatusCondition, conditionType string) *tunedv1.ProfileStatusCondition { | ||
| for _, condition := range conditions { | ||
| if string(condition.Type) == conditionType { | ||
| return &condition | ||
| } | ||
| } | ||
| return nil | ||
| } | ||
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.
don't we want owner reference in this case? it should be only
no-refwithout the reference (hence the name)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.
This syncs the manifests for this test https://github.com/openshift/cluster-node-tuning-operator/blob/master/test/e2e/performanceprofile/functests-render-command/1_render_command/render_test.go#L115
And it uses no owner references. Probably copy&paste. I believe we should default to having the references most of the time, but I do not think we should fix that as part of this PR.
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.
fair enough