-
Notifications
You must be signed in to change notification settings - Fork 3k
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
cmd/cleanup: Fix cleanup of generic XDP programs #25117
Conversation
The 'cilium cleanup' command wasn't actually removing XDP programs attached to the generic hook point. This was causing issues when an XDP test in ginkgo was immediatly followed by the upgrade test. The upgrade test would run 'cilium cleanup' and remove everything except for the XDP programs. That would isolate the Cilium-managed nodes from the outside network (both SSH and intra-cluster connectivity). Obviously, this works when we change the Cilium configuration to disable XDP. There we have some logic to remove any leftover XDP programs on agent startup. Comparing that logic with the 'cilium cleanup' logic, we can see that the difference is that the agent removes XDP programs explicitely for each hook point (generic and driver). Let's do the same. This fix was tested manually on a setup with Cilium's generic XDP programs installed. Fixes: 6ed1fe5 ("cilium: Remove attached bpf_xdp upon "cilium cleanup"") Signed-off-by: Paul Chaignon <[email protected]>
/test Job 'Cilium-PR-K8s-1.27-kernel-net-next' failed: Click to show.Test Name
Failure Output
Jenkins URL: https://jenkins.cilium.io/job/Cilium-PR-K8s-1.27-kernel-net-next/132/ If it is a flake and a GitHub issue doesn't already exist to track it, comment Then please upload the Jenkins artifacts to that issue. |
For my own edification, the code in the xdp loader that cleans these up is here. |
The
cilium cleanup
command wasn't actually removing XDP programs attached to the generic hook point. This was causing issues when an XDP test in ginkgo was immediately followed by the upgrade test. The upgrade test would runcilium cleanup
and remove everything except for the XDP programs. That would isolate the Cilium-managed nodes from the outside network (both SSH and intra-cluster connectivity).Obviously, this works when we change the Cilium configuration to disable XDP. There we have some logic to remove any leftover XDP programs on agent startup. Comparing that logic with the
cilium cleanup
logic, we can see that the difference is that the agent removes XDP programs explicitly for each hook point (generic and driver). Let's do the same.This fix was tested manually on a setup with Cilium's generic XDP programs installed.
Fixes: #19735.
Fixes: #24687.