containernetworking / plugins

Some reference and example networking plugins, maintained by the CNI team.
Apache License 2.0
2.24k stars 789 forks source link

Why don't we set egress limit in pod's network namespace but use ifb ? #857

Closed kangclzjc closed 1 year ago

kangclzjc commented 1 year ago

I see that in bandwidth plugin, we set an ifb and limit bandwidth of this ifb, but I have done a test that I enter into pod's network namespace and set tbf qdisc to the 'eth0' interface. In this way, we can limit pod's egress traffic and we don't need to set up an ifb in host network namespace. I am not sure if there is any concern that we use ifb in host network namespace instead of set egress limit to pod's eth0 in pod's network namespace ?