Open YaoZengzeng opened 2 months ago
cc @Okabe-Rintarou-0 would you like to take it :)
sure. /assign
maybe we need to lookup all the keys of bpf map in bpf/deserialization_to_bpf_map/deserialization_to_bpf_map.c. bpf supports traversing the keys.
I am working on this, we can get all elements with a linked list
What would you like to be added:
"/debug/bpf/*" should output the underlying actual eBPF info, including the contents of the map and prog, in a human-readable way to facilitate troubleshooting the problem.
Why is this needed:
Now we have
/debug/config_dump/ads
and/debug/config_dump/workload
output the config content cached in Kmesh daemon.At the same time, we have
/debug/bpf/ads
, but its output is exactly the same as/debug/config_dump/ads
.Now we hope that
/debug/bpf/*
could output the information about the underlying eBPF.Due to various reasons, the config in Kmesh daemon cache and the actual eBPF may not be completely consistent. If we can get human-readable eBPF info, it will be more helpful for us to troubleshooting.
This is also an important part of the
kmeshctl
, used to obtain the real eBPF info of each node.