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-15235: cnf-tests: move to rhel 9 #2139

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

Tal-or
Copy link
Contributor

@Tal-or Tal-or commented Dec 30, 2024

  • move all builder to rhel9
  • move cnf-tests image to rhel9
  • replace libhugetlbfs ,which is not present in rhel9, with a local tool for allocating hugepages (more details in the commits)

Signed-off-by: Talor Itzhak [email protected]

Copy link
Contributor

openshift-ci bot commented Dec 30, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Tal-or
Once this PR has been reviewed and has the lgtm label, please assign yuvalk for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found 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

@Tal-or Tal-or changed the title cnf-tests: move to rhel 9 CNF-15235: cnf-tests: move to rhel 9 Dec 30, 2024
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Dec 30, 2024
@openshift-ci-robot
Copy link
Collaborator

@Tal-or: This pull request references CNF-15235 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.19.0" version, but no target version was set.

In response to this:

  • move all builder to rhel9
  • move cnf-tests image to rhel9
  • replace libhugetlbfs ,which is not present in rhel9, with a local tool for allocating hugepages (more details in the commits)

Signed-off-by: Talor Itzhak [email protected]

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 openshift-eng/jira-lifecycle-plugin repository.

@Tal-or
Copy link
Contributor Author

Tal-or commented Dec 30, 2024

/cc @SchSeba @yanirq

@openshift-ci openshift-ci bot requested review from SchSeba and yanirq December 30, 2024 17:26
@Tal-or
Copy link
Contributor Author

Tal-or commented Dec 30, 2024

WORKDIR $TOOL_PATH

RUN go build -mod=vendor -o /hugepages-allocator

# build latency-test's runner binaries
FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.22-openshift-4.18 AS builder-latency-test-runners
Copy link
Member

Choose a reason for hiding this comment

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

are we keeping this as rhel8 ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Nope. my bad

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually yes, this is the standard Dockerfile not the Dockerfile.openshift I wasn't sure whether we want to change images here as well, because the cnf-tests image is centos7 based

Copy link
Member

Choose a reason for hiding this comment

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

I must say I am not sure who use this file but if you can please update everything to rhel 9 base.

I don't think this dockerfile really work as we build stuff on rhel 8 and 9 but put everything inside a centos7 image...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

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.

nice work!!!

I left a few comments :)

WORKDIR $TOOL_PATH

RUN go build -mod=vendor -o /hugepages-allocator

# build latency-test's runner binaries
FROM registry.ci.openshift.org/ocp/builder:rhel-8-golang-1.22-openshift-4.18 AS builder-latency-test-runners
Copy link
Member

Choose a reason for hiding this comment

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

I must say I am not sure who use this file but if you can please update everything to rhel 9 base.

I don't think this dockerfile really work as we build stuff on rhel 8 and 9 but put everything inside a centos7 image...

cnf-tests/Dockerfile.openshift Outdated Show resolved Hide resolved
cnf-tests/pod-utils/hugepages-allocator/main.go Outdated Show resolved Hide resolved
cnf-tests/pod-utils/hugepages-allocator/main.go Outdated Show resolved Hide resolved
cnf-tests/pod-utils/hugepages-allocator/main.go Outdated Show resolved Hide resolved
cnf-tests/pod-utils/hugepages-allocator/main.go Outdated Show resolved Hide resolved
Tal-or added 8 commits January 1, 2025 10:43
Align oc binary and pull it from ocp 4.19

Signed-off-by: Talor Itzhak <[email protected]>
The `libhugetlbfs` is not available on rhel-9

Signed-off-by: Talor Itzhak <[email protected]>
Some of the tests running under cnf-tests are using the
`libhugetlbfs` for allocating hugepages.

`libhugetlbfs` has been removed from rhel9,
so instead we introduce a small program named
hugepages-allocator that will be used by the tests
for hugepages allocations.

The program built like any other tool we already
have in cnf-tests and the binary delivered as
part of the final image.

Signed-off-by: Talor Itzhak <[email protected]>
Same tests are runnning for both images so we should
have the tool in both images to be able to run the same tests.

Signed-off-by: Talor Itzhak <[email protected]>
Align `Dockerfile` with `Dockerfile.openshift` and use
the same builder images based on rhel9

Signed-off-by: Talor Itzhak <[email protected]>
Change the test to use the tool
instead of libhugetlbfs library

Signed-off-by: Talor Itzhak <[email protected]>
@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 1, 2025

related to #openshift/release#60244

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 just a small change in the regular dockerfile :)

@@ -59,7 +73,7 @@ RUN yum install -y numactl-devel make gcc && \
cp hwlatdetect /hwlatdetect && \
cp cyclictest /cyclictest

FROM quay.io/openshift/origin-oc-rpms:4.16 AS oc
FROM quay.io/openshift/origin-oc-rpms:4.19 AS oc

# Final image
FROM centos:7
Copy link
Member

Choose a reason for hiding this comment

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

I think you need to update this one also

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was on purpose actually, if we're changing to rhel9 then both Dockerfile and Dockerfile.openshift are identical. So one can be deleted

@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 1, 2025

/retest

1 similar comment
@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 1, 2025

/retest

@zeeke
Copy link
Member

zeeke commented Jan 2, 2025

Can you please update also:

These defaults are needed to use this PR's changes during tests.

Also, it should fix the test:

CNF Features e2e integration tests: [It] [tuningcni] tuningcni over macvlan should be able to create pod with sysctls over macvlan 

as if flakes because of the cnf-tests image size. See

@zeeke
Copy link
Member

zeeke commented Jan 2, 2025

/retest

1 similar comment
@SchSeba
Copy link
Member

SchSeba commented Jan 5, 2025

/retest

@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 5, 2025

  > Enter [It] should be able to create pod with bond interface over macvlan interfaces - /go/src/github.com/openshift-kni/cnf-features-deploy/cnf-tests/testsuites/e2esuite/bond/bond.go:36 @ 01/05/25 10:58:16.77
  [FAILED] Unexpected error:
      <wait.errInterrupted>: 
      timed out waiting for the condition
      {
          cause: <*errors.errorString | 0xc000110730>{
              s: "timed out waiting for the condition",
          },
      }
  occurred

@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 5, 2025

/retest

Copy link
Contributor

openshift-ci bot commented Jan 5, 2025

@Tal-or: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-ci-tests 3303b48 link true /test e2e-aws-ci-tests

Full PR test history. Your PR dashboard.

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-sigs/prow repository. I understand the commands that are listed here.

@Tal-or
Copy link
Contributor Author

Tal-or commented Jan 6, 2025

depends on: openshift/release#60333

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
jira/valid-reference Indicates that this PR references a valid Jira ticket of any type.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants