-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
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
Rudimentary support of VPP #290529
base: master
Are you sure you want to change the base?
Rudimentary support of VPP #290529
Conversation
https://s3-docs.fd.io/vpp/23.10/ Signed-off-by: Raito Bezarius <[email protected]>
This is a fairly primitive NixOS module, it does not offer RFC42 because it can be hard to get right on the first try. Your deployment on your baremetal system may vary and may require personal overrides. It offers simple defaults for the hugepages setup and kernel modules stuff. If you want a better NixOS module, please chime in with usecases. Signed-off-by: Raito Bezarius <[email protected]>
This is a very simple NixOS test to assert the fact that the VPP socket is receiving commands as intended and works more or less. In the future, this should properly be extended to real test exchanging packets between a non-VPP system and a VPP system. Signed-off-by: Raito Bezarius <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
super cool :) Just some thoughts on kernel module and libnl version, and one nit regarding a redundant test.
serviceConfig = { | ||
ExecStartPre = [ | ||
"-${pkgs.coreutils}/bin/rm -f /dev/shm/db /dev/shm/global_vm /dev/shm/vpe-api" | ||
"-/run/current-system/sw/bin/modprobe uio_pci_generic" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
be aware that many deployments will use vfio_pci kernel module instead of uio_pci_generic.
Perhaps load them both?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, will do
node.wait_for_unit("multi-user.target") | ||
node.wait_for_unit("vpp.service") | ||
node.succeed("vppctl show version | grep -i nixos") | ||
node.succeed("vppctl show interface | grep -i local0") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
since local0
always exists, this test will never fail.
If VPP is not up, the test on line 35 fails.
I think this line is redundant.
rdma-core | ||
mbedtls_2 | ||
check | ||
libnl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the version of libnl? The Linux Control Plane wants >=3.7.0 for certain operations (like inter-family nexthop, and all MPLS).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3.7.0, we usually have latest released versions, but I can hard assert on the libnl version to offer warnings to users.
I don't see #256601 mentioned anywhere here, which is a PR for the same package/module which seems to have stalled. It seems there is a small number of people who still do want to see this land, at the very least the package (leaving potential users to write their own opinionated service until an unopinionated one hits in upstream). So considering that this PR here is the one that has seen the more recent update and is ahead in the version, would it be possible to get the package part of this factored out (in an up-to-date version if possible) into a separate PR so that at least users have a package to work with until a module (and corresponding tests) hit? As the latter seem to be the parts that attract more review, the package would probably get merged earlier and allow people to get started in the mean time. |
@RaitoBezarius are you still working on this? If not, I might try picking it up. |
Feel free to pick up this. :) |
Description of changes
VPP is a packet processing framework building on the top of existing packet processors facilities like DPDK, XDP or similar.
https://s3-docs.fd.io/vpp/23.10/
TODO:
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.