Skip to content

test: Add ability to switch between cgroupv1 or cgroupv2 for node e2e#7173

Merged
mikebrow merged 1 commit intocontainerd:mainfrom
bobbypage:cgroup_e2e
Jul 21, 2022
Merged

test: Add ability to switch between cgroupv1 or cgroupv2 for node e2e#7173
mikebrow merged 1 commit intocontainerd:mainfrom
bobbypage:cgroup_e2e

Conversation

@bobbypage
Copy link
Copy Markdown
Contributor

For k8s e2e node tests, we want to be able to test both cgroupv1 and
cgroupv2 variants. Currently, the latest version of COS (M97) is running
as cgroupv2 and we would like the add the ability to switch to cgroupv1
for running tests on cgroupv1.

To do this, add a new flag, "CGROUP_MODE" which can be set as v1 or v2.
If the current cgroup configuration does not match the desired config,
the cgroup config will be set via cgroup_helper COS utility, and the
node will be rebooted.

Signed-off-by: David Porter [email protected]

@k8s-ci-robot
Copy link
Copy Markdown

Hi @bobbypage. Thanks for your PR.

I'm waiting for a containerd 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.

Details

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.

@bobbypage bobbypage marked this pull request as draft July 16, 2022 01:32
@bobbypage bobbypage marked this pull request as ready for review July 16, 2022 01:34
@samuelkarp
Copy link
Copy Markdown
Member

/ok-to-test

@bobbypage
Copy link
Copy Markdown
Contributor Author

k/k test-infra changes - kubernetes/test-infra#26831

Comment thread test/e2e_node/gci-init.sh Outdated
Comment thread test/e2e_node/gci-init.sh Outdated
Comment thread test/e2e_node/gci-init.sh Outdated
Comment thread test/e2e_node/gci-init.sh Outdated
Comment thread test/e2e_node/gci-init.sh
@samuelkarp
Copy link
Copy Markdown
Member

I've approved this, but if you rebase on main you should pick up the fix to CI as well.

@bobbypage
Copy link
Copy Markdown
Contributor Author

Thanks, @samuelkarp I have rebased on main.

Copy link
Copy Markdown
Member

@mikebrow mikebrow left a comment

Choose a reason for hiding this comment

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

just a couple questions

Comment thread test/e2e_node/gci-init.sh
Comment thread test/e2e_node/gci-init.sh
For k8s e2e node tests, we want to be able to test both cgroupv1 and
cgroupv2 variants. Currently, the latest version of COS (M97) is running
as cgroupv2 and we would like the add the ability to switch to cgroupv1
for running tests on cgroupv1.

To do this, add a new flag, "CGROUP_MODE" which can be set as v1 or v2.
If the current cgroup configuration does not match the desired config,
the cgroup config will be set via `cgroup_helper` COS utility, and the
node will be rebooted.

Signed-off-by: David Porter <[email protected]>
@bobbypage
Copy link
Copy Markdown
Contributor Author

Thanks @mikebrow for the comments, updated as per you suggestions. PTAL again. Thanks!

Copy link
Copy Markdown
Contributor

@endocrimes endocrimes left a comment

Choose a reason for hiding this comment

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

lgtm

Copy link
Copy Markdown
Member

@mikebrow mikebrow left a comment

Choose a reason for hiding this comment

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

LGTM

@mikebrow mikebrow merged commit f7bba3a into containerd:main Jul 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants