From 0ec6852cfb6231f35563c272c3cb23fe5ea46d1e Mon Sep 17 00:00:00 2001 From: Nataliia Solomko Date: Mon, 20 Oct 2025 14:21:26 +0300 Subject: [PATCH] vpp: T938: Delete 'sample-rate' from vpp sflow CLI and add 'header-bytes' --- docs/vpp/configuration/sflow.rst | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/docs/vpp/configuration/sflow.rst b/docs/vpp/configuration/sflow.rst index c28e517b..2ecb0f7d 100644 --- a/docs/vpp/configuration/sflow.rst +++ b/docs/vpp/configuration/sflow.rst @@ -26,13 +26,16 @@ This will enable sFlow on the specified interface. You can repeat this command f sFlow collects statistics only for traffic *received* on the interface. If you want to monitor traffic *sent* on the interface, you need to enable sFlow on the corresponding interface in the opposite direction. -Optionally, you can specify the sampling rate for the interface using the following command: +Optionally, you can specify the number of bytes from each packet that should be included in the sFlow sample using the following command: .. cfgcmd:: - set vpp sflow sample-rate + set vpp sflow header-bytes -This will set the sampling rate for the specified interface. The default sampling rate is 1, which means that every packet is sampled. A higher sampling rate means that fewer packets are sampled, which can reduce the amount of data sent to the sFlow collector. This can be useful in high-traffic environments to reduce the load on the collector. +This defines the size of the packet header (in bytes) captured for each sFlow sample. + +The sampling rate is configured globally under the ``system sflow`` section and automatically applied to VPP sFlow. +This ensures consistent sampling behavior between the system and VPP, and prevents configuration conflicts. Finally, you need to enable integration between VPP and the kernel sFlow agent using the following command: