ARP Request sent by trex has a wrong pdst ip than the one given in stream

43 views
Skip to first unread message

chris...@gmail.com

unread,
Jul 5, 2024, 9:01:28 AMJul 5
to TRex Traffic Generator
trex version v2.90
I am using stateless.

Packet: 
class STLS1(object):
    def get_streams(self, port_id = 0,direction = 0, **kwargs):
        streams = []
        packet = (Ether(src="00:00:00:01:02:03",dst="ff:ff:ff:ff:ff:ff") /
                  Dot1Q(vlan=1552) /
                  ARP(op=1,plen=4,hwlen=6,hwtype=1, psrc="25.20.20.100",pdst="25.20.20.10",hwsrc="0e:be:2a:3f:46:94") /
                  Raw(0*50))


        vm = STLVM()
        stream = STLStream(packet = STLPktBuilder(pkt = packet, vm = vm),stream_id = 1,name = 'TC16_UC2_SCTP',mode =STLTXSingleBurst(total_pkts = 2,pps = 50),flow_stats = STLFlowLatencyStats(pg_id = 1))
        streams.append(stream)
        return streams

def register():
    return STLS1()

But when i capture the packet sent out by trex , it manipulates the pdst to a different value . Can someone please help understand as to why is this happening?

Capture:
trex(service)>

    Ether(dst='ff:ff:ff:ff:ff:ff',src='00:00:00:01:02:03',type=33024)/Dot1Q(prio=0,id=0,vlan=1552,type=2054)/ARP(hwtype=1,ptype=2048,hwlen=6,plen=4,op=1,hwsrc='0e:be:2a:3f:46:94',psrc='25.20.20.100',hwdst='00:00:00:00:00:00',pdst='25.20.171.49')/Padding(load=b'\x00\x00\xff\xff\xff\xffG\xdfN\x8f\x1d@\x0e\x00')

trex(service)>

chris...@gmail.com

unread,
Jul 5, 2024, 9:17:30 AMJul 5
to TRex Traffic Generator
Swicthed to trex v3.00 . Same issue seen there as well 

chris...@gmail.com

unread,
Jul 5, 2024, 9:24:44 AMJul 5
to TRex Traffic Generator
trex_cfg used is 
### Config file generated by dpdk_setup_ports.py ###

- port_limit: 2
  version   : 2
  #c         : 2
  interfaces: ['test1', 'dummy']
  stack     : linux_based
  low_end   : true
  low_end_core: 3

chris...@gmail.com

unread,
Jul 12, 2024, 9:52:48 AMJul 12
to TRex Traffic Generator
Can someone please help here ? This change in pdst happens on adding Vlan header.

Hanoch Haim

unread,
Jul 14, 2024, 6:20:48 AMJul 14
to TRex Traffic Generator
Hi Chris, 
can you remove flow_stats = STLFlowLatencyStats(pg_id = 1) from the stream, this is not supported for ARP packet 

chris...@gmail.com

unread,
Jul 22, 2024, 12:30:48 AM (7 days ago) Jul 22
to TRex Traffic Generator
Thanks a lot Hanoh , It works now .But how to get stream statistics for arp streams ?
Reply all
Reply to author
Forward
0 new messages