Hello, all.
I'm trying to fulfill Pktgen to test the performance of openNetVM, however, something unexpected occurred. How could I resolve this problem?
$ cd openNetVM/dpdk/tools/
$ ./dpdk-setup-iface.sh eth1 10.0.0.1 255.255.255.0 up
$ ./dpdk-setup-iface.sh eth2 10.0.0.2 255.255.255.0 up
$ cd openNetVM/tools/Pktgen/pktgen-dpdk/
$ make
$ sudo bash run-pktgen.sh
pass an argument for port count
example usage: sudo bash run-pktgen.sh 1
$ sudo bash run-pktgen.sh 1
root@sdn:/home/sdn/openNetVM/tools/Pktgen/pktgen-dpdk/openNetVM-Scripts# sudo bash run-pktgen.sh 1
Start pktgen
Copyright (c) <2010-2016>, Intel Corporation. All rights reserved. Powered by Intelยฎ DPDK
EAL: Detected 8 lcore(s)
EAL: lcore 8 unavailable
EAL: invalid coremask
Usage: ./app/app/x86_64-native-linuxapp-gcc/app/pktgen [options]
EAL common options:
-c COREMASK Hexadecimal bitmask of cores to run on
-l CORELIST List of cores to run on
The argument format is <c1>[-c2][,c3[-c4],...]
where c1, c2, etc are core indexes between 0 and 128
--lcores COREMAP Map lcore set to physical cpu set
The argument format is
'<lcores[@cpus]>[<,lcores[@cpus]>...]'
lcores and cpus list are grouped by '(' and ')'
Within the group, '-' is used for range separator,
',' is used for single number separator.
'( )' can be omitted for single element group,
'@' can be omitted if cpus and lcores have the same value
--master-lcore ID Core ID that is used as master
-n CHANNELS Number of memory channels
-m MB Memory to allocate (see also --socket-mem)
-r RANKS Force number of memory ranks (don't detect)
-b, --pci-blacklist Add a PCI device in black list.
Prevent EAL from using this PCI device. The argument
format is <domain:bus:devid.func>.
-w, --pci-whitelist Add a PCI device in white list.
Only use the specified PCI devices. The argument format
is <[domain:]bus:devid.func>. This option can be present
several times (once per device).
[NOTE: PCI whitelist cannot be used with -b option]
--vdev Add a virtual device.
The argument format is <driver><id>[,key=val,...]
(ex: --vdev=net_pcap0,iface=eth2).
-d LIB.so|DIR Add a driver or driver directory
(can be used multiple times)
--vmware-tsc-map Use VMware TSC map instead of native RDTSC
--proc-type Type of this process (primary|secondary|auto)
--syslog Set syslog facility
--log-level Set default log level
-v Display version information on startup
-h, --help This help
EAL options for DEBUG use only:
--huge-unlink Unlink hugepage files after init
--no-huge Use malloc instead of hugetlbfs
--no-pci Disable PCI
--no-hpet Disable HPET
--no-shconf No shared config (mmap'd files)
EAL Linux options:
--socket-mem Memory to allocate on sockets (comma separated values)
--huge-dir Directory where hugetlbfs is mounted
--file-prefix Prefix for hugepage filenames
--base-virtaddr Base virtual address
--create-uio-dev Create /dev/uioX (usually done by hotplug)
--vfio-intr Interrupt mode for VFIO (legacy|msi|msix)
--xen-dom0 Support running on Xen dom0 without hugetlbfs
===== Application Usage =====
Usage: ./app/app/x86_64-native-linuxapp-gcc/app/pktgen [EAL options] -- [-h] [-P] [-G] [-T] [-f cmd_file] [-l log_file] [-s P:PCAP_file] [-m <string>]
-s P:file PCAP packet stream file, 'P' is the port number
-f filename Command file (.pkt) to execute or a Lua script (.lua) file
-l filename Write log to filename
-P Enable PROMISCUOUS mode on all ports
-g address Optional IP address and port number default is (localhost:0x5606)
If -g is used that enable socket support as a server application
-G Enable socket support using default server values localhost:0x5606
-N Enable NUMA support
-T Enable the color output
--crc-strip Strip CRC on all ports
-m <string> matrix for mapping ports to logical cores
BNF: (or kind of BNF)
<matrix-string> := """ <lcore-port> { "," <lcore-port>} """
<lcore-port> := <lcore-list> "." <port-list>
<lcore-list> := "[" <rx-list> ":" <tx-list> "]"
<port-list> := "[" <rx-list> ":" <tx-list>"]"
<rx-list> := <num> { "/" (<num> | <list>) }
<tx-list> := <num> { "/" (<num> | <list>) }
<list> := <num> { "/" (<range> | <list>) }
<range> := <num> "-" <num> { "/" <range> }
<num> := <digit>+
<digit> := 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
1.0, 2.1, 3.2 - core 1 handles port 0 rx/tx,
core 2 handles port 1 rx/tx
core 3 handles port 2 rx/tx
1.[0-2], 2.3, ... - core 1 handle ports 0,1,2 rx/tx,
core 2 handle port 3 rx/tx
[0-1].0, [2/4-5].1, ... - cores 0-1 handle port 0 rx/tx,
cores 2,4,5 handle port 1 rx/tx
[1:2].0, [4:6].1, ... - core 1 handles port 0 rx,
core 2 handles port 0 tx,
[1:2].[0-1], [4:6].[2/3], ... - core 1 handles port 0 & 1 rx,
core 2 handles port 0 & 1 tx
[1:2-3].0, [4:5-6].1, ... - core 1 handles port 0 rx, cores 2,3 handle port 0 tx
core 4 handles port 1 rx & core 5,6 handles port 1 tx
[1-2:3].0, [4-5:6].1, ... - core 1,2 handles port 0 rx, core 3 handles port 0 tx
core 4,5 handles port 1 rx & core 6 handles port 1 tx
[1-2:3-5].0, [4-5:6/8].1, ... - core 1,2 handles port 0 rx, core 3,4,5 handles port 0 tx
core 4,5 handles port 1 rx & core 6,8 handles port 1 tx
[1:2].[0:0-7], [3:4].[1:0-7], - core 1 handles port 0 rx, core 2 handles ports 0-7 tx
core 3 handles port 1 rx & core 4 handles port 0-7 tx
BTW: you can use "{}" instead of "[]" as it does not matter to the syntax.
-h Display the help information
Pktgen done
System: Ubuntu 14.04, 64bit.
AnonHugePages: 391168 kB
HugePages_Total: 1024
HugePages_Free: 1024
HugePages_Rsvd: 0
HugePages_Surp: 0
Hugepagesize: 2048 kB
I'm a new hand on this domain. Is there somthing wrong with my steps? Thank you for your help!