Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop KNI library #674

Closed
AltraMayor opened this issue Jan 30, 2024 · 2 comments
Closed

Drop KNI library #674

AltraMayor opened this issue Jan 30, 2024 · 2 comments
Labels
Production requirement Either the issue is solved, or Gatekeeper doesn't work in production
Milestone

Comments

@AltraMayor
Copy link
Owner

KNI is no longer part of DPDK. We need to find a replacement. Possible candidates suggested in the commit that removed KNI are virtio_user, tap, and XDP drivers.

The positive byproduct of no longer relying on KNI is to address issues #570 and #585.

@AltraMayor AltraMayor added the Production requirement Either the issue is solved, or Gatekeeper doesn't work in production label Jan 30, 2024
@AltraMayor AltraMayor added this to the Version 1.2 milestone Jan 30, 2024
@AltraMayor
Copy link
Owner Author

AltraMayor commented Jan 31, 2024

DPDK's developers implicitly settled with virtio_user. The minutes of the technical board meeting on January 13th, 2021, describe virtio_user as "the most promising interface". Stephen Hemminger reported on virtio_user's superior performance on DPDK's mailing list on January 13th, 2021. The limitations of virtio_user, namely, lack of support for the kernel to change MAC, MTU, RX mode, and admin status are not features needed in Gatekeeper; in fact, Gatekeeper favors turning off these features since the parameters of the virtual NIC must be in line with the underlying physical interfaces in Gatekeeper. Finally, DPDK's manual has a how-to for integrating virtio_user.

The paper VIRTIO-USER: A New Versatile Channel for Kernel-Bypass Networks describes the design and evaluation of virtio_user. Virtio is a standardized interface originally designed to improve access to virtual devices by virtual machines. virtio_user leverages this standard to reach higher performance and reuse the kernel modules that implement the standard.

AltraMayor added a commit that referenced this issue Mar 1, 2024
DPDK dropped its KNI library at version 23.11.
This commit replaces DPDK's KNI library with virtio-user.

This commit closes #481, closes #570, closes #585, closes #674.
AltraMayor added a commit that referenced this issue Mar 1, 2024
DPDK dropped its KNI library at version 23.11.
This commit replaces DPDK's KNI library with virtio-user.

This commit closes #481, closes #570, closes #585, closes #674.
@AltraMayor
Copy link
Owner Author

Pull request #678 replaced DPDK's KNI library with virtio-user. This transition brings many benefits, such as

  1. closing issues closes Avoid duplicate #define of KNI_FIFO_COUNT_MAX #481, Running tcpdump on kni interfaces brings BGP sessions down #570, and PANIC in rd_fill_getroute_reply #585;
  2. simplifying the code of the CPS block. Pull request cps: replace DPDK's KNI library with virtio-user #678 dropped 1,422 lines while adding back only 656 lines;
  3. eliminating the need to call fork() to set the parameters of the KNI interfaces which eliminates the need for the CPS parameter num_attempts_kni_link_set; and
  4. dropping CPS' ELF library since the kernel automatically loads and unloads the kernel modules associated with Virtio.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Production requirement Either the issue is solved, or Gatekeeper doesn't work in production
Projects
None yet
Development

No branches or pull requests

1 participant