cisco-system-traffic-generator/trex-core

Single NIC how to have what method can you achieve RFC2544 play stream?

Snailfl opened this issue · 4 comments

I want to use trex streaming on two different devices. How can I test it?
/etc/trex_cfg.yaml:
version: 2
interfaces: ['0a:00.0', 'dummy']
port_info:

  • src_mac: 68:ed:a4:31:ba:fa
    dest_mac: 68:ed:a4:5c:90:83

platform:
master_thread_id: 0
latency_thread_id: 1
dual_if:

  • socket: 0
    threads: [2,3]

I tried to test RFC2544 on two different devices. The two devices were directly connected through a single network port, as shown in /etc/trex_cfg.yaml.
At first, I used the way to play back the packet. In /etc/trex_cfg.yaml, I used the NIC name configuration, and set the route loopback on another device.
(echo 1 > /proc/sys/net/ipv4/ip_forward
route add -net 16.0.0.0 netmask 255.0.0.0 gw 6.6.6.2
route add -net 48.0.0.0 netmask 255.0.0.0 gw 6.6.6.2)
This way is feasible, because the network card is not taken over by dpdk, but the 64 byte rate is very small, suspect not to take dpdk, followed by pci 0a:00.0 to configure /etc/trex_cfg.yaml, this way does not work, because the network card is taken over by dpdk, in the stream side of the packet can not come back, drop_rate All packets are lost.

I thought this page might be helpful

Thanks,
Are you using two different devices or one device?

Thanks, Are you using two different devices or one device?

I think If the configuration is correct, it doesn't matter if there are multiple NICs or multiple interfaces on one NIC.
Unofficial explanation, the answer is for reference only