Skip to content
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

cnf-tests: Add numa tests with multiple interfaces #1590

Merged

Conversation

gkopels
Copy link

@gkopels gkopels commented Aug 2, 2023

Test cases uses a set SriovNetworkNodePolicies and performance profile to control NUMA node placement in test.
This test creates a pod with sriov interface on NUMA node 1 with the sriov interface in NUMA node 0. The excludeTopology is set to True. THe pod is expected to be deployed.

@openshift-ci openshift-ci bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Aug 2, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 2, 2023

Hi @gkopels. 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 /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

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.

@openshift-ci openshift-ci bot requested review from SchSeba and serngawy August 2, 2023 09:34
@gkopels gkopels force-pushed the add-numa-true-same-node branch 2 times, most recently from aa80665 to 2fc780a Compare August 2, 2023 09:35
@zeeke
Copy link
Member

zeeke commented Aug 2, 2023

/ok-to-test

@openshift-ci openshift-ci bot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Aug 2, 2023
Test cases uses a set SriovNetworkNodePolicies and performance profile
to control NUMA node placement in test. This test creates a pod with
sriov interface on NUMA node 1 with the sriov interface in NUMA node 0.
The excludeTopology is set to True. THe pod is expected to be deployed.
@gkopels gkopels force-pushed the add-numa-true-same-node branch from 2fc780a to 39ad6b8 Compare August 2, 2023 10:07
@gkopels gkopels changed the title cnf-tests: Add numa true on different node WIP: cnf-tests: Add numa true on different node Aug 3, 2023
@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 3, 2023
@gkopels gkopels force-pushed the add-numa-true-same-node branch 3 times, most recently from 82a15e7 to 060a3dc Compare August 3, 2023 10:32
@gkopels gkopels changed the title WIP: cnf-tests: Add numa true on different node cnf-tests: Add numa tests with multiple interfaces Aug 3, 2023
@openshift-ci openshift-ci bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 3, 2023
Copy link
Member

@zeeke zeeke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left few minor comments. Overall PR looks good to me

"testNuma1NIC1ExcludeTopoplogyFalse", ipam, false)

createSriovNetworkAndPolicyForNumaAffinityTest(8, numa1DeviceList[0], "#4-7",
"test-numa-1-nic2-exclude-topology-true-", testingNode.Name,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit:

Suggested change
"test-numa-1-nic2-exclude-topology-true-", testingNode.Name,
"test-numa-1-nic1-exclude-topology-true-", testingNode.Name,

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed

@@ -62,39 +67,52 @@ var _ = Describe("[sriov] NUMA node alignment", Ordered, func() {
sriovDevices, err := sriovCapableNodes.FindSriovDevices(testingNode.Name)
Expect(err).ToNot(HaveOccurred())

numa0Device, err := findDeviceOnNUMANode(testingNode, sriovDevices, "0")
numa0DeviceList, err = findDevicesOnNUMANode(testingNode, sriovDevices, "0")
Expect(err).ToNot(HaveOccurred())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Better to assert on device list length

Suggested change
Expect(err).ToNot(HaveOccurred())
Expect(len(numa0DeviceList)).To(BeNumerically(">=", 1))
Expect(err).ToNot(HaveOccurred())

Same for NUMA1

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed

Expect(err).ToNot(HaveOccurred())
By("Using NUMA0 device " + numa0Device.Name)
By("Using NUMA0 device1 " + numa0DeviceList[0].Name)
By("Using NUMA0 device2 " + numa0DeviceList[1].Name)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, move it in the if len(numa0DeviceList) > 1 { body

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved

g.Expect(err).ToNot(HaveOccurred())
g.Expect(actualPod.Status.QOSClass).To(Equal(corev1.PodQOSGuaranteed))
g.Expect(actualPod.Status.Phase).To(Equal(corev1.PodFailed))
g.Expect(actualPod.Status.Message).To(ContainSubstring("Resources cannot be allocated with Topology locality"))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please, assert on Status.Reason

Suggested change
g.Expect(actualPod.Status.Message).To(ContainSubstring("Resources cannot be allocated with Topology locality"))
g.Expect(actualPod.Status.Reason).To(Equal("TopologyAffinityError"))

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

changed

@gkopels gkopels force-pushed the add-numa-true-same-node branch from 060a3dc to 3b3d999 Compare August 6, 2023 10:57
@gkopels gkopels force-pushed the add-numa-true-same-node branch 2 times, most recently from 64b3907 to 66fd322 Compare August 7, 2023 10:01
@gkopels gkopels force-pushed the add-numa-true-same-node branch from 66fd322 to 2e4e43a Compare August 7, 2023 14:30
@zeeke
Copy link
Member

zeeke commented Aug 7, 2023

/approve
LGTM

@SchSeba there are some pushes after your comment. Please, have a look

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 7, 2023
@zeeke
Copy link
Member

zeeke commented Aug 7, 2023

/override ci/prow/e2e-gcp-ovn

ci/prow/e2e-gcp-ovn failures are not related to this PR

  [FAIL] [rfe_id:27368][performance] Network latency parameters adjusted by the Node Tuning Operator [It] [test_id:28467][crit:high][vendor:[email protected]][level:acceptance] Should contain configuration injected through the openshift-node-performance profile
  /go/src/github.com/openshift-kni/cnf-features-deploy/vendor/github.com/openshift/cluster-node-tuning-operator/test/e2e/performanceprofile/functests/1_performance/performance.go:1383
  [FAIL] [tuningcni] tuningcni over macvlan [It] pods with sysctl's over macvlan should be able to ping each other
  /go/src/github.com/openshift-kni/cnf-features-deploy/cnf-tests/testsuites/e2esuite/security/tuning.go:93
  [FAIL] [tuningcni] tuningcni over bond [It] pods with sysctls over bond should be able to ping each other
  /go/src/github.com/openshift-kni/cnf-features-deploy/cnf-tests/testsuites/e2esuite/security/tuning.go:137

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 7, 2023

@zeeke: Overrode contexts on behalf of zeeke: ci/prow/e2e-gcp-ovn

In response to this:

/override ci/prow/e2e-gcp-ovn

ci/prow/e2e-gcp-ovn failures are not related to this PR

 [FAIL] [rfe_id:27368][performance] Network latency parameters adjusted by the Node Tuning Operator [It] [test_id:28467][crit:high][vendor:[email protected]][level:acceptance] Should contain configuration injected through the openshift-node-performance profile
 /go/src/github.com/openshift-kni/cnf-features-deploy/vendor/github.com/openshift/cluster-node-tuning-operator/test/e2e/performanceprofile/functests/1_performance/performance.go:1383
 [FAIL] [tuningcni] tuningcni over macvlan [It] pods with sysctl's over macvlan should be able to ping each other
 /go/src/github.com/openshift-kni/cnf-features-deploy/cnf-tests/testsuites/e2esuite/security/tuning.go:93
 [FAIL] [tuningcni] tuningcni over bond [It] pods with sysctls over bond should be able to ping each other
 /go/src/github.com/openshift-kni/cnf-features-deploy/cnf-tests/testsuites/e2esuite/security/tuning.go:137

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.

Copy link
Member

@SchSeba SchSeba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Aug 9, 2023
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 9, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: gkopels, SchSeba, zeeke

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@zeeke
Copy link
Member

zeeke commented Aug 10, 2023

/override ci/prow/e2e-gcp-ovn

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Aug 10, 2023

@zeeke: Overrode contexts on behalf of zeeke: ci/prow/e2e-gcp-ovn

In response to this:

/override ci/prow/e2e-gcp-ovn

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants