firedancer-io/firedancer

Consider xdp multiprog support

Opened this issue · 0 comments

On Linux, only a single XDP program can be installed on each interface.

Firedancer assumes that the net tile XDP program is the only one running on the machine.
While FD can peacefully coexist with the Linux kernel net stack (IPVS, sockets, etc), it cannot coexist with other XDP programs.

Reasons why people might want to run other XDP programs is for load generation, high performance firewalling, or traffic monitoring.

The "standard" solution is this rather ugly pattern:
https://github.com/xdp-project/xdp-tools/blob/master/lib/libxdp/protocol.org

In short, it defines a standard where multiple XDP programs can be compiled into one.
Internally, it uses a dispatcher program that calls into each actual program.
The spec also defines how different Linux processes can cooperatively add and remove their XDP programs on-the-fly without having to be aware of each other.