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

SRIOV lane, Prevent Resources Leak #719

Merged

Conversation

ormergi
Copy link
Contributor

@ormergi ormergi commented Nov 18, 2020

Sriov lane uses KIND infrastructure.
Using KIND in DinD setups requires setting prow job pod to be privileged and mount /sys/fs/cgroups,
thus it is mandatory to delete the cluster before porw job pod is terminated in order to prevent resources leaks.
kubernetes-sigs/kind#759.
Unlike QEMU VM's based kubevirtci providers where the nodes are VM's and isolated in terms of access to host resources and we dont mount /sys/fs/cgroups/ it is enough to let the prow job pod terminate to cleanup all the resources

At the current sate if for any reasoner sriov lane is interrupted or failed there will be no cluster deletion using kind

This PR ensures that sriov lane job will teardown the KIND cluster that was created inside the prow job pod
gracefully using kind binary in any case.

Sriov lane uses KIND infrastructure.
In order to prevent resources leak it is recommanded
to use 'kind' binary to teardown the cluster [1],
which is what 'make cluster-down' does.

[1] kubernetes-sigs/kind#759

Signed-off-by: Or Mergi <ormergi@redhat.com>
@kubevirt-bot kubevirt-bot added the dco-signoff: yes Indicates the PR's author has DCO signed all their commits. label Nov 18, 2020
@ormergi
Copy link
Contributor Author

ormergi commented Nov 18, 2020

/cc @EdDev @qinqon @dhiller

@qinqon
Copy link
Contributor

qinqon commented Nov 19, 2020

/lgtm
/approve
/hold
/rehearsal

@kubevirt-bot kubevirt-bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Nov 19, 2020
@kubevirt-bot kubevirt-bot added the lgtm Indicates that a PR is ready to be merged. label Nov 19, 2020
@kubevirt-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: qinqon

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

@kubevirt-bot kubevirt-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 19, 2020
@qinqon
Copy link
Contributor

qinqon commented Nov 19, 2020

/rehearsal

@kubevirt-bot kubevirt-bot removed the lgtm Indicates that a PR is ready to be merged. label Nov 19, 2020
@ormergi
Copy link
Contributor Author

ormergi commented Nov 19, 2020

/rehearse

Signed-off-by: Or Mergi <ormergi@redhat.com>
@qinqon
Copy link
Contributor

qinqon commented Nov 19, 2020

/lgtm
/hold cancel

@kubevirt-bot kubevirt-bot added lgtm Indicates that a PR is ready to be merged. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Nov 19, 2020
@kubevirt-bot kubevirt-bot merged commit 796e0b4 into kubevirt:master Nov 19, 2020
@kubevirt-bot
Copy link
Contributor

@ormergi: Updated the job-config configmap in namespace kubevirt-prow at cluster default using the following files:

  • key kubevirt-presubmits.yaml using file github/ci/prow/files/jobs/kubevirt/kubevirt/kubevirt-presubmits.yaml
  • key kubevirtci-presubmits.yaml using file github/ci/prow/files/jobs/kubevirt/kubevirtci/kubevirtci-presubmits.yaml

In response to this:

Sriov lane uses KIND infrastructure.
Unlike QEMU VM's based kubevirtci providers where the nodes are VM's and isolated in terms of access to host resources
it is enough to let the prow job pod terminate to cleanup all the resources, using KIND requires
"gracefully" teardown using kind binary to prevent resurrects leak as suggested at kubernetes-sigs/kind#759.

At the current sate if for any reasoner sriov lane is interrupted or failed there will be no cluster deletion using kind

This PR ensures that sriov lane job will teardown the KIND cluster that was created inside the prow job pod
gracefully using kind binary in any case.

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.

@ormergi ormergi deleted the sriov_lanes_prevent_resources_leak branch October 21, 2021 09:05
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. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. lgtm Indicates that a PR is ready to be merged. size/S
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants