-
Notifications
You must be signed in to change notification settings - Fork 85
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
can't run xdp_dump #60
Comments
[root@node01 xdp_dump]# clang -v |
Sounds like your |
https://github.com/dropbox/goebpf/tree/master/examples/xdp/xdp_dump In this example, only TCP related data will be obtained. Is there an example of obtaining IP layer or Ethernet layer data |
There is no such example. goebpf/examples/xdp/xdp_dump/ebpf_prog/xdp_dump.c Lines 127 to 128 in 8a0799a
Up to somewhere goebpf/examples/xdp/xdp_dump/ebpf_prog/xdp_dump.c Lines 80 to 86 in 8a0799a
|
When I move the code to the specified location according to what you said, an error is reported, It seems that there are variables that are not defined, I don't understand C language. Can you give me a complete code |
use of undeclared identifier evt |
[root@node01 xdp_dump]# go build
github.com/dropbox/goebpf
In file included from ../../../map.go:13:0:
./bpf_helpers.h:957:15: error: expected declaration specifiers or '...' before 'sizeof'
static_assert(sizeof(__u8) == 1, "wrong_u8_size");
^
./bpf_helpers.h:957:34: error: expected declaration specifiers or '...' before string constant
static_assert(sizeof(__u8) == 1, "wrong_u8_size");
^
./bpf_helpers.h:958:15: error: expected declaration specifiers or '...' before 'sizeof'
static_assert(sizeof(__u16) == 2, "wrong_u16_size");
^
./bpf_helpers.h:958:35: error: expected declaration specifiers or '...' before string constant
static_assert(sizeof(__u16) == 2, "wrong_u16_size");
^
./bpf_helpers.h:959:15: error: expected declaration specifiers or '...' before 'sizeof'
static_assert(sizeof(__u32) == 4, "wrong_u32_size");
^
./bpf_helpers.h:959:35: error: expected declaration specifiers or '...' before string constant
static_assert(sizeof(__u32) == 4, "wrong_u32_size");
^
./bpf_helpers.h:960:15: error: expected declaration specifiers or '...' before 'sizeof'
static_assert(sizeof(__u64) == 8, "wrong_u64_size");
^
./bpf_helpers.h:960:35: error: expected declaration specifiers or '...' before string constant
static_assert(sizeof(__u64) == 8, "wrong_u64_size");
^
[root@node01 xdp_dump]#
The text was updated successfully, but these errors were encountered: