You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It fails to load epf-lsm program. Error: the BPF_PROG_LOAD syscall failed. Verifier output: func#0 @0 number of funcs in func_info doesn't match number of subprogs verification time 13 usec stack depth 0 processed 0 insns (limit 1000000) max_states_per_insn 0 total_states 0 peak_states 0 mark_read 0
Here is the log used by strace bpf(BPF_PROG_LOAD, {prog_type=BPF_PROG_TYPE_LSM, insn_cnt=192, insns=0x561ac794b510, license="GPL", log_level=0, log_size=0, log_buf=NULL, kern_version=KERNEL_VERSION(5, 11, 0), prog_flags=0, prog_name="sb_mount", prog_ifindex=0, expected_attach_type=BPF_LSM_MAC, prog_btf_fd=10, func_info_rec_size=8, func_info=0x561ac77b82f0, func_info_cnt=2, line_info_rec_size=16, line_info=0x561ac77b87f0, line_info_cnt=69, attach_btf_id=32269, attach_prog_fd=0}, 144) = -1 EINVAL (Invalid argument)
I searched the linux kernel 5.11.0 and found the error is raising when eBPF verifier trying to compare attr->func_info_cnt and env->subprog_cnt but I don't understand why.
I also want to know which library is used to load ebpf program
The text was updated successfully, but these errors were encountered:
Could you post your kernel config? It should be available in /proc/config or /proc/config.gz. I'm usually testing lockc with the newest kernels coming in openSUSE Tumbleweed, but we will try to test with Ubuntu 21.04 soon.
I also want to know which library is used to load ebpf program
We are using Aya (https://github.com/aya-rs/aya) for loading eBPF programs. So far we are using it in a bit unusual way, where we still keep eBPF programs in C and we use Aya only for loading them from the userspace. But we plan to rewrite eBPF programs in Rust in the future.
Environment: ubuntu 21.04 kernel 5.11.0
Error: the BPF_PROG_LOAD syscall failed. Verifier output: func#0 @0 number of funcs in func_info doesn't match number of subprogs verification time 13 usec stack depth 0 processed 0 insns (limit 1000000) max_states_per_insn 0 total_states 0 peak_states 0 mark_read 0
Here is the log used by strace
bpf(BPF_PROG_LOAD, {prog_type=BPF_PROG_TYPE_LSM, insn_cnt=192, insns=0x561ac794b510, license="GPL", log_level=0, log_size=0, log_buf=NULL, kern_version=KERNEL_VERSION(5, 11, 0), prog_flags=0, prog_name="sb_mount", prog_ifindex=0, expected_attach_type=BPF_LSM_MAC, prog_btf_fd=10, func_info_rec_size=8, func_info=0x561ac77b82f0, func_info_cnt=2, line_info_rec_size=16, line_info=0x561ac77b87f0, line_info_cnt=69, attach_btf_id=32269, attach_prog_fd=0}, 144) = -1 EINVAL (Invalid argument)
I searched the linux kernel 5.11.0 and found the error is raising when eBPF verifier trying to compare attr->func_info_cnt and env->subprog_cnt but I don't understand why.
The text was updated successfully, but these errors were encountered: