iovisor / gobpf

Go bindings for creating BPF programs.
Apache License 2.0
2.15k stars 314 forks source link

We need an example of tc program #292

Open masibw opened 3 years ago

masibw commented 3 years ago

Hi. Thanks for creating good oss. I know commit messages of #76 said about how to create tc(traffic control) program. But, I think it's not satisfactory and should write to docs or examples. How about writing an example of simple tc ?

devkoriel commented 3 years ago

Yes I agree, we need example. For XDP, we can use AttachXDP method easily but I cannot find the one for TC.

Manxiaxia commented 3 years ago

Thanks for the post. Before reading it, I have no idea how to attach the ebpf program to tc hook at all using this library. The commit messages you included helps a lot.

I also agree that it will be the best to provide an example. Maybe at least mention more about TC in the document since there is no method such as AttachXDP available.