PCI网卡的drv=igb_uio即完成绑定
步骤三测试,选择[27]和[28]
Option: 27Enter hex bitmask of cores to execute test app onExample: to execute app on cores 0 to 7, enter 0xffbitmask: 0x3Launching appsudo: x86_64-default-linuxapp-gcc/app/test: command not foundPress enter to continue ...
Option: 28Enter hex bitmask of cores to execute testpmd app onExample: to execute app on cores 0 to 7, enter 0xffbitmask: 0x3Launching appsudo: x86_64-default-linuxapp-gcc/app/testpmd: command not found
这两个测试都有可能会出现"command not found"的报错提醒,
其中[27]出现该错误不用理会,[28]若出现的话,可以退出脚本(选[35]),到/[你的DPDK目录]/x86_64-native-linuxapp-gcc/app
下找到testpmd,再运行它进行测试即可,若无以外会得到以下输出
root@ubuntu:/root/trex/v3.00/dpdk-stable-18.11.9/x86_64-native-linuxapp-gcc/app# ./testpmdEAL: Detected 4 lcore(s)EAL: Detected 1 NUMA nodesEAL: Multi-process socket /var/run/dpdk/rte/mp_socketEAL: No free hugepages reported in hugepages-1048576kBEAL: Probing VFIO support...EAL: VFIO support initializedEAL: PCI device 0000:02:01.0 on NUMA socket -1EAL:Invalid NUMA socket, default to 0EAL:probe driver: 8086:100f net_e1000_emEAL: PCI device 0000:02:06.0 on NUMA socket -1EAL:Invalid NUMA socket, default to 0EAL:probe driver: 8086:100f net_e1000_emEAL: PCI device 0000:02:07.0 on NUMA socket -1EAL:Invalid NUMA socket, default to 0EAL:probe driver: 8086:100f net_e1000_emtestpmd: create a new mbuf pool <mbuf_pool_socket_0>: n=171456, size=2176, socket=0testpmd: preferred mempool ops selected: ring_mp_mcConfiguring Port 0 (socket 0)Port 0: 00:0C:29:AE:BF:4DConfiguring Port 1 (socket 0)Port 1: 00:0C:29:AE:BF:43Checking link statuses...DoneNo commandline core given, start packet forwardingio packet forwarding - ports=2 - cores=1 - streams=2 - NUMA support enabled, MP allocation mode: nativeLogical Core 1 (socket 0) forwards packets on 2 streams:RX P=0/Q=0 (socket 0) -> TX P=1/Q=0 (socket 0) peer=02:00:00:00:00:01RX P=1/Q=0 (socket 0) -> TX P=0/Q=0 (socket 0) peer=02:00:00:00:00:00io packet forwarding packets/burst=32nb forwarding cores=1 - nb forwarding ports=2port 0: RX queue number: 1 Tx queue number: 1Rx offloads=0x0 Tx offloads=0x0RX queue: 0RX desc=256 - RX free threshold=0RX threshold registers: pthresh=0 hthresh=0wthresh=0RX Offloads=0x0TX queue: 0TX desc=256 - TX free threshold=0TX threshold registers: pthresh=0 hthresh=0wthresh=0TX offloads=0x0 - TX RS bit threshold=0port 1: RX queue number: 1 Tx queue number: 1Rx offloads=0x0 Tx offloads=0x0RX queue: 0RX desc=256 - RX free threshold=0RX threshold registers: pthresh=0 hthresh=0wthresh=0RX Offloads=0x0TX queue: 0TX desc=256 - TX free threshold=0TX threshold registers: pthresh=0 hthresh=0wthresh=0TX offloads=0x0 - TX RS bit threshold=0Press enter to exitTelling cores to stop...Waiting for lcores to finish...---------------------- Forward statistics for port 0----------------------RX-packets: 44RX-dropped: 0RX-total: 44TX-packets: 34TX-dropped: 0TX-total: 34-------------------------------------------------------------------------------------------------- Forward statistics for port 1----------------------RX-packets: 59RX-dropped: 0RX-total: 59TX-packets: 24TX-dropped: 0TX-total: 24----------------------------------------------------------------------------+++++++++++++++ Accumulated forward statistics for all ports+++++++++++++++RX-packets: 103RX-dropped: 0RX-total: 103TX-packets: 58TX-dropped: 0TX-total: 58++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++Done.Stopping port 0...Stopping ports...DoneStopping port 1...Stopping ports...DoneShutting down port 0...Closing ports...DoneShutting down port 1...Closing ports...DoneBye...
运行testpmd可能出现的问题1、HugePage容量问题
当运行测试时或者testpmd
, 可能会遇到如下问题
root@ubuntu:/root/trex/v3.00/dpdk-stable-18.11.9/x86_64-native-linuxapp-gcc/app# ./testpmdEAL: Detected 8 lcore(s)EAL: Detected 1 NUMA nodesEAL: Multi-process socket /var/run/dpdk/rte/mp_socketEAL: No free hugepages reported in hugepages-2048kBEAL: No free hugepages reported in hugepages-2048kBEAL: FATAL: Cannot get hugepage information.EAL: Cannot get hugepage information.PANIC in main():Cannot init EAL5: [./testpmd(_start+0x29) [0x498829]]4: [/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf0) [0x7f8a0fee0830]]3: [./testpmd(main+0xc48) [0x48f528]]2: [./testpmd(__rte_panic+0xbb) [0x47eb09]]1: [./testpmd(rte_dump_stack+0x2b) [0x5c8a1b]]Aborted (core dumped)
这说明Hugepage不够用,可以先查看系统内存状况
root@ubuntu:/root/trex/v3.00/dpdk-stable-18.11.9/x86_64-native-linuxapp-gcc/app# cat /proc/meminfo | grep HugeAnonHugePages:0 kBShmemHugePages:0 kBFileHugePages:0 kBHugePages_Total:1024HugePages_Free:775HugePages_Rsvd:0HugePages_Surp:0Hugepagesize:2048 kBHugetlb:2097152 kB
如果不够用可以按需修改
推荐阅读
- 星之彼端丹铜事件该如何选择
- iphone怎么刷机(iphone刷机教程)
- 《正义联盟》中超人是怎么死的
- 王者荣耀娜可露露前尘镜中文语音包怎么设置
- 《三国演义》中曹操的大将许褚是怎么死的(三国许褚做了哪些大事)
- 怎么玩比较合适(休假去哪玩比较合适)
- 红米Note11真机曝光_红米Note11外观详情
- 阿玛尼口红哪款好用 阿玛尼口红排行榜top5推荐
- 【深入浅出 Yarn 架构与实现】2-2 Yarn 基础库 - 底层通信库 RPC
- 韩国免税店购物攻略【二】