Home

Awesome

dperf Apache V2 License <a href="https://hellogithub.com/repository/67958cc5d1f44a6a84f3544e3c007e5f" target="_blank"><img src="https://abroad.hellogithub.com/v1/widgets/recommend.svg?rid=67958cc5d1f44a6a84f3544e3c007e5f&claim_uid=Thc9mJByaKSbdng&theme=small" alt="Featured|HelloGitHub" /></a>

English | 中文

dperf is a DPDK based 100Gbps network performance and load testing software.

Advantage

Performance

HTTP Connections per Second

Client CoresServer CoresHTTP CPS
112,101,044
224,000,423
447,010,743
6610,027,172

HTTP Throughput per Second

Client CoresServer CoresRX(Gbps)TX(Gbps)Client CPU Usage(%)Server CPU Usage(%)
1118186059
2235356059
4446464343

HTTP Current Connections

Client CoresServer CoresCurrent ConnectionsClient CPU Usage(%)Server CPU Usage(%)
11100,000,0003439
22200,000,0003639
44400,000,0004041

UDP TX PPS

Client CoresTX MPPSClient CPU Usage(%)
115.9695
229.9595
434.9267
635.9254
837.1222

Note: this test is under one 25Gbps Mellanox CX4

Client & Server Configuration

Above performance is obtained with below configurations:

Statistics

dperf outputs various statistics every second:

seconds 22                 cpuUsage 52
pktRx   3,001,058          pktTx    3,001,025          bitsRx   2,272,799,040      bitsTx  1,920,657,600      dropTx  0
arpRx   0                  arpTx    0                  icmpRx   0                  icmpTx  0                  otherRx 0          badRx 0
synRx   1,000,345          synTx    1,000,330          finRx    1,000,350          finTx   1,000,350          rstRx   0          rstTx 0
synRt   0                  finRt    0                  ackRt    0                  pushRt  0                  tcpDrop 0
skOpen  1,000,330          skClose  1,000,363          skCon    230                skErr   0
httpGet 1,000,345          http2XX  1,000,350          httpErr  0
ierrors 0                  oerrors  0                  imissed  0

Getting Started

Set hugepages

#edit '/boot/grub2/grub.cfg' like this, and reboot the OS
linux16 /vmlinuz-... nopku transparent_hugepage=never default_hugepagesz=1G hugepagesz=1G hugepages=8

Build DPDK

#edit 'config/common_base' to enable PMDs
#Mellanox CX4/CX5 requires 'CONFIG_RTE_LIBRTE_MLX5_PMD=y'
#HNS3 requires 'CONFIG_RTE_LIBRTE_HNS3_PMD=y'
#VMXNET3 requires 'CONFIG_RTE_LIBRTE_VMXNET3_PMD=y'

TARGET=x86_64-native-linuxapp-gcc #or arm64-armv8a-linuxapp-gcc

cd /root/dpdk/dpdk-stable-19.11.10
make install T=$TARGET -j16

Build dperf

cd dperf
make -j8 RTE_SDK=/root/dpdk/dpdk-stable-19.11.10 RTE_TARGET=$TARGET

Bind interface

#Mellanox NIC skip this step!
#Suppose your PCI number is 0000:1b:00.0

modprobe uio
modprobe uio_pci_generic
/root/dpdk/dpdk-stable-19.11.10/usertools/dpdk-devbind.py -b uio_pci_generic 0000:1b:00.0

Start dperf server

#dperf server bind at 6.6.241.27:80,  gateway is 6.6.241.1
./build/dperf -c test/http/server-cps.conf

Send request from a client

#the client IP must be in the range of 'client' in the configuration file
ping 6.6.241.27
curl http://6.6.241.27/

Running the tests

Below example will start a HTTP CPS stress test.

#run dperf server
./build/dperf -c test/http/server-cps.conf

#from another host, run dperf client
./build/dperf -c test/http/client-cps.conf

Documentation

See the website at https://dperf.org/.

Limitation

Contributing

dperf welcomes your contribution. See the CONTRIBUTING file for details.

Patent

Author

License

dperf is distributed under the Apache License, Version 2.0.