-
Notifications
You must be signed in to change notification settings - Fork 119
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
Does pktgen-dpdk have feature to control PPS rate? #286
Comments
You can set the rate, but you can't set a duration. If you wrote a Lua script you can control the duration by starting/stopping the traffic via the commands. If you do not want to write a script it means type the commands by hand. |
Hello, @KeithWiles Thank you for response. |
The rate is in percent of the port max wire rate along with the packet size and you have to play with the rate value to get the MPPS you want. If NIC max rate 100Gbits with 64 byte frames, you will need to set the rate to some value to get the correct MPPS. 100GB with 64 byte frames max mpps is about 148.8MPPS so the rate would be less then 10% if I did the math right. If you look in the scripts directory you can find some lua script using RFC2544 which uses Lua. |
Hello, @KeithWiles Thank you for your prompt response. It is really helpful. I have another observation. When I use two tx queues like When I replace the rx node with dpdk-testpmd, it got much higher packet on dpdk-testpmd while there are some drops (~ 7M Pakcets are dropped). I am not sure why they are not the same. Are there any missing flags or options? How to scale-up RX side? I just generate two flows
Do you have any ideas? |
Please tell me the DPDK and Pktgen versions you are using. I only test latest DPDK and Pktgen versions. From DPDK.org and from github.com/pktgen/Pktgen-DPDK. Also what is the NIC being used? When sending on two threads the packets are being pulled from the same pool of packets and 2 times is normal for two TX queues, if three then three times. I would not mess with txd/rxd queues the NIC driver normally has good values already. The To get the RX side to work with more than one queue it will use RSS to distribute the packets across all queues. This means the receiving packets 5-tuples need to be different to make the NIC hardware distribute the packets across all of the RX queues. |
@KeithWiles Environment:
Right. I can change -l 0-4. In RX node, the packets are well evenly distributed. I can check it with
In RX node
If I use dpdk-testpmd instead of pktgen-dpdk on RX side, it shows
I guess I missed some configs or setup on RX node. |
Can you please update to the latest Pktgen 24.07.1 and latest DPDK. I had made some performance updates in the latest version. I would have used `-l 0-3' instead. |
Sure. I will try it now. The recent is v24.07. |
I updated Pktgen to 24.07.1 and DPDK to 24.07.0. It worked well and seemed like improving the perf. However, it still rx does catch up TX PPS.
RX
Do I need to use cfg file to initialize something? |
I worry about setting the tx/rx descriptor size, did you try this test without having then options? The above command line means the RX side it using one core and TX is using 2 cores. A single core has a limit to the number of packets it can process for RX and TX. The RX side does have to do a bit more work then TX side. You seem to be able to distribute the RX packet across two queues and I need to understand the full configuration of Pktgen. Change the command line to I use the ./tools/run.py with a cfg file to make it easier to use, but it is up to you. In what mode are you sending packets in, single, sequence, range or pcap modes? |
Hello, @KeithWiles I have another issues now with the recent version (Pktgen 24.07.1 Powered by DPDK 24.07.0) With Pktgen 23.10.0 (DPDK 23.11.0) Powered by DPDK , I can send packets (with pktgen) and receive it (testpmd). Please find the details below.
With Pktgen 24.07.1 Powered by DPDK 24.07.0, I cannot send packets (with pktgen) to RX node
However, RX on pktgen works. I can use testpmd as sender and pktgen as receiver.
|
Please try this branch fixes-for-release as I have been working on a number of fixes for the next release. Sorry, day job is sucking up a lot of my time. :-( |
Hello, @KeithWiles Thank you for support. I will try the branch and let you know. |
Hello, @KeithWiles I tried the branch
Got this error and update the code and enabled to compile
However, it still did not work on TX on pktgen while TX still works. I felt like somehow TX part filters the packet on pktgen. |
Ah, I forgot to test building with lua and I will fix it. Thanks |
I have fixed the build problem and pushed the changes, thanks again |
Thank you for fixing it promptly. Do you have any speculations why it did not work on TX while RX works? |
Hello,
I have two servers running pktgen-dpdk. One server send packet and the other server receive the packet.
Does pktgen-dpdk have feature to control PPS rate?
For example, I want to send 10 MPPS for 10 seconds and then send 20 MPPS for next 10 seconds.
There is
rate
option, but I am not sure how to achieve this.Thanks,
The text was updated successfully, but these errors were encountered: