Created attachment 31233 [details] The bug fix patch. bpf(BPF_PROG_LOAD, ...) fails with ENOSPC if the provided log_buf is too small (https://man7.org/linux/man-pages/man2/bpf.2.html): > log_size size of the buffer pointed to by log_buf. If the > size of the buffer is not large enough to store all verifier > messages, -1 is returned and errno is set to ENOSPC. Current implementation only allows max 8192 chars for log. However, as the log is not being used in the function, we could simply ignore the log by setting log_level to zero. This patch will fix the bug.
Comment on attachment 31233 [details] The bug fix patch. Thank you for the bug report and the patch submission. I've updated the commit message with a bit more detail, and merged this into our 23.02 branch so that it'll be included in 23.02.4 when released. We'll keep this ticket open briefly while we look at some additional log changes on our master branch. thanks again, - Tim commit eafacf30d90c24ea48144671944a88953513070a Author: Nuri Jung <jnooree@snu.ac.kr> AuthorDate: Fri Jul 14 19:20:33 2023 +0900 Ignore log from bpf(BPF_PROG_LOAD, ...) If the log buffer is too short for the verifier messages, bpf() will fail with ENOSPC. Since the log itself is current unused, it's simpler to disable logging here at present. Bug 17210.