Re: how to set environment to run example?

Gary Lin

On Tue, May 28, 2019 at 07:32:33PM -0700, forrest0579@... wrote:
Hi all,
What kind of network topology should I set up to make runnable and what user-case this example represent for?
The script does nothing really meaningful but demostrates how to use

It redirects all traffic from one network interface to another, so you
need a machine with at least two XDP-enabled network interfaces. When you
send a packet from eth0 of Machine B to eth0 of Machine A, the script
swaps the src IP and dst IP of the incoming packets and sends them out
through eth1 of Machine A, so the packets will flow like this:

(Machine A) (Machine B)
[ eth0 ]<------[ eth0 ]
| ^
v |
[ eth1 ] ---------+

The script also counts the number of packet processed per second as a
rough performance measurement for XDP_REDIRECT, so you can generate a
huge volume of traffic with the programs like trafgen in Machine B to
do the test.


Gary Lin

PS: I have the same question about too

Thanks for helping me!

Join to automatically receive all group messages.