* Unable to run eBPF program that uses maps
@ 2019-10-07 8:15 Radu Stoenescu
2019-10-07 8:36 ` Toke Høiland-Jørgensen
0 siblings, 1 reply; 2+ messages in thread
From: Radu Stoenescu @ 2019-10-07 8:15 UTC (permalink / raw)
To: xdp-newbies
I'm running this Ubuntu: Linux anemie 5.0.0-31-generic #33~18.04.1-Ubuntu SMP
I've cloned and compiled the Linux kernel - the same version and
config as of my machine's.
When trying to run the xdp_redirec_map sample program from samples/bpf I get:
sudo ./xdp_redirect_map 2 1
#=> failed to create map 0 (tx_port): 1 Operation not permitted
I read that, on certain systems, the default limit of locked memory
might pose problems, and I mitigated that as seen below:
ulimit -a
core file size (blocks, -c) 0
data seg size (kbytes, -d) unlimited
scheduling priority (-e) 0
file size (blocks, -f) unlimited
pending signals (-i) 31231
max locked memory (kbytes, -l) 1024
max memory size (kbytes, -m) unlimited
open files (-n) 1024
pipe size (512 bytes, -p) 8
POSIX message queues (bytes, -q) 819200
real-time priority (-r) 0
stack size (kbytes, -s) 8192
cpu time (seconds, -t) unlimited
max user processes (-u) 31231
virtual memory (kbytes, -v) unlimited
file locks (-x) unlimited
What else can I try?
Regards
--
Radu Stoenescu
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Unable to run eBPF program that uses maps
2019-10-07 8:15 Unable to run eBPF program that uses maps Radu Stoenescu
@ 2019-10-07 8:36 ` Toke Høiland-Jørgensen
0 siblings, 0 replies; 2+ messages in thread
From: Toke Høiland-Jørgensen @ 2019-10-07 8:36 UTC (permalink / raw)
To: Radu Stoenescu, xdp-newbies
Radu Stoenescu <radu.stoe@gmail.com> writes:
> I'm running this Ubuntu: Linux anemie 5.0.0-31-generic #33~18.04.1-Ubuntu SMP
>
> I've cloned and compiled the Linux kernel - the same version and
> config as of my machine's.
>
> When trying to run the xdp_redirec_map sample program from samples/bpf I get:
>
> sudo ./xdp_redirect_map 2 1
> #=> failed to create map 0 (tx_port): 1 Operation not permitted
>
> I read that, on certain systems, the default limit of locked memory
> might pose problems, and I mitigated that as seen below:
>
> ulimit -a
>
> core file size (blocks, -c) 0
> data seg size (kbytes, -d) unlimited
> scheduling priority (-e) 0
> file size (blocks, -f) unlimited
> pending signals (-i) 31231
> max locked memory (kbytes, -l) 1024
Is this run as your regular user? The limit will be reset in the sudo
environment that loads the program; so you'll need to set it as root (so
something like `sudo -i; ulimit -l 1024; ./xdp_redirect_map 2 1`)
-Toke
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-10-07 8:36 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-10-07 8:15 Unable to run eBPF program that uses maps Radu Stoenescu
2019-10-07 8:36 ` Toke Høiland-Jørgensen
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.