DPDK usage discussions
 help / color / mirror / Atom feed
From: Peter Keereweer <peterkeereweer@hotmail.com>
To: "users@dpdk.org" <users@dpdk.org>
Subject: [dpdk-users] pktgen: sending / capturing more packets than configured?
Date: Thu, 2 Feb 2017 06:22:16 +0000	[thread overview]
Message-ID: <DB6PR1001MB14165EBB6FF989CC0698539BC04C0@DB6PR1001MB1416.EURPRD10.PROD.OUTLOOK.COM> (raw)

Hi!

I'am still running some tests with the Load Balancer Sample Application by sending packets with pktgen. I have a setup of 2 servers (Machine A and B in the example below) with each server containing a Intel 10Gbe 82599 NIC (connected to each other). The Load Balancer application has been configured to use 1 core for RX, 1 worker core and 1 TX core. The TX core sends all packets back to the pktgen application. The packets, send back to pktgen by the Load Balancer application, will be captured (by pktgen) and written to a pcap-file.

So I'm using 2 servers in my test:

Machine A: pktgen
Machine B: load_balancer

This is how I started the pktgen application on Machine A and all commands that I executed:

A:

> sudo ./pktgen -c 0x1f -n 3 -- -P -T -m "[2:4].0"

Pktgen> user.pattern 0 "TIC"
Pktgen> proto udp 0
Pktgen> set 0 count 1024
Pktgen> capture 0 on
Pktgen> start 0
Pktgen> user.pattern 0 "TOC"
Pktgen> start 0
Pktgen> capture 0 off

In pktgen I get all packets (2 x 1024 = 2048 packets) that I have send to the Load Balancer application. These packets are captured and written to disk. I expect to see 1024 'TIC' packets and 1024 'TOC' packets in the pcapfile. But during exploring the pcap file with wireshark, I encountered some weird behavior. This are all packets that I can see in the pcap file (captured by pktgen):

- [1-1024]    TIC upd packets (1024)
- [1025-1088] TOC udp packets (64)
- [1089-1504] TIC udp packets (416) !! (why?)
- [1505-1568] TOC udp packets (64)
- [1569-1984] TIC udp packets (416) !! (why?)
- [1985-2048] TOC udp packets (64)
-------------------------------------------
Total: (2048)

How is it possible that I send 1024 'TIC' packets with pktgen, but if I count all 'TIC' packets in the pcap-file I can see more than 1024 'TIC' packets (and a way less then 1024 'TOC' packets)?

To give you as much details as possible, this is how I started the Load Balancer application on Machine B:

B:

> sudo build/app/load_balancer -c 0xfff -n 4 -- --rx "(0,0,0)" --tx "(0,2)" --w "4" --bsz "(32,32),(64,64),(32,32)"

Another thing that strikes me is that the data, send in the UDP packets above (containing the message 'TIC' or 'TOC'), is padded with zeros (6 bytes) at the beginning of the message. Are all packets, with user defined messages, padded with zeros?

I hope someone can help me with this questions!  

Peter

             reply	other threads:[~2017-02-02  6:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-02  6:22 Peter Keereweer [this message]
2017-02-02 16:59 ` Wiles, Keith

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=DB6PR1001MB14165EBB6FF989CC0698539BC04C0@DB6PR1001MB1416.EURPRD10.PROD.OUTLOOK.COM \
    --to=peterkeereweer@hotmail.com \
    --cc=users@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).