ICode9

精准搜索请尝试: 精确搜索
首页 > 其他分享> 文章详细

【Trex试用】emu icmp功能测试

2022-02-09 17:30:39  阅读:222  来源: 互联网

标签:10.1 emu 00 off 1.1 Trex 功能测试 trex


trex配置文件
trex_cfg.yaml

  • port_limit : 2
    version : 2
    #List of interfaces. Change to suit your setup. Use ./dpdk_setup_ports.py -s to see available options
    interfaces : [“00:09.0”,“00:0a.0”]
    port_info : # Port IPs. Change to suit your needs. In case of loopback, you can leave as is.
    - ip : 10.1.1.2
    default_gw : 10.1.1.1
    - ip : 10.1.1.1
    default_gw : 10.1.1.2
    启动trex 服务
    ./t-rex-64 -i --software --emu
    启动trex-console
    ./trex-console
    trex>plugins load emu

加载profile
trex>emu_load_profile -f emu/simple_icmp.py -t --ns 1 --clients 3

Converting file to profile [SUCCESS]

Converting profile took: 3.53 [ms]

Removing old emu profile [SUCCESS]

Sending emu profile
[SUCCESS]

Sending profile took: 20.41 [ms]
26.36 [ms]

simple_icmp.py文件如下:在trex emu目录下

ping模拟的设备
trex>portattr -a
Port Status

 port       |          0           |          1           

----------------±---------------------±--------------------
driver | net_e1000_em | net_e1000_em
description | 82545EM Gigabit Et | 82545EM Gigabit Et
link status | UP | UP
link speed | 1 Gb/s | 1 Gb/s
port status | IDLE | IDLE
promiscuous | off | off
multicast | off | off
flow ctrl | none | none
vxlan fs | - | -
– | |
layer mode | IPv4 | IPv4
src IPv4 | 10.1.1.2 | 10.1.1.1
IPv6 | off | off
src MAC | 00:0c:29:49:2d:16 | 00:0c:29:49:2d:0c
— | |
Destination | 10.1.1.1 | 10.1.1.2
ARP Resolution | 00:0c:29:49:2d:0c | 00:0c:29:49:2d:16
---- | |
VLAN | - | -
----- | |
PCI Address | 0000:02:08.0 | 0000:02:07.0
NUMA Node | 0 | 0
RX Filter Mode | hardware match | hardware match
RX Queueing | off | off
Grat ARP | off | off
------ | |
trex>emu_show_all
Namespace #1 Information

Port | Vlan tags | Tpids | Plugins | #Clients
-----±----------±------±----------±--------
0 | - | - | arp, icmp | 3

Clients Information

   MAC        |  IPv4   | DG-IPv4 | MTU  |  Plugins  

------------------±--------±--------±-----±---------
00:00:00:70:00:03 | 1.1.1.3 | 1.1.1.1 | 1500 | arp, icmp
00:00:00:70:00:04 | 1.1.1.4 | 1.1.1.1 | 1500 | arp, icmp
00:00:00:70:00:05 | 1.1.1.5 | 1.1.1.1 | 1500 | arp, icmp

48.55 [ms]

trex>emu_icmp_ping -p 0 --mac 00:00:00:70:00:03

Starting to ping : [SUCCESS]

Progress: 100.00%, Sent: 5/5, Rcv: 0/5, Err: 0/5, RTT min/avg/max = 0.00/0.00/0.00 ms

Completed

参考https://www.cnblogs.com/liudf0716/p/15796785.html

收到的报文是0,RTT都是0,说明没有收到ping的回复报文,需要排查是什么原因

标签:10.1,emu,00,off,1.1,Trex,功能测试,trex
来源: https://blog.csdn.net/qingyu3044/article/details/122845363

本站声明: 1. iCode9 技术分享网(下文简称本站)提供的所有内容,仅供技术学习、探讨和分享;
2. 关于本站的所有留言、评论、转载及引用,纯属内容发起人的个人观点,与本站观点和立场无关;
3. 关于本站的所有言论和文字,纯属内容发起人的个人观点,与本站观点和立场无关;
4. 本站文章均是网友提供,不完全保证技术分享内容的完整性、准确性、时效性、风险性和版权归属;如您发现该文章侵犯了您的权益,可联系我们第一时间进行删除;
5. 本站为非盈利性的个人网站,所有内容不会用来进行牟利,也不会利用任何形式的广告来间接获益,纯粹是为了广大技术爱好者提供技术内容和技术思想的分享性交流网站。

专注分享技术,共同学习,共同进步。侵权联系[81616952@qq.com]

Copyright (C)ICode9.com, All Rights Reserved.

ICode9版权所有