Trex in promiscuous mode

1,020 views
Skip to first unread message

santhosh kumar

unread,
Apr 29, 2016, 7:26:31 PM4/29/16
to TRex Traffic Generator
I see an option to configuring a port to promiscuous mode from console "portattr -a --prom". I wanted to know if there is any command line option while running TRex.

Thanks
santhosh

Itay Marom

unread,
Apr 30, 2016, 2:06:35 PM4/30/16
to santhosh kumar, TRex Traffic Generator
Hi Santhosh,

There isn't a specific switch for promiscuous mode.

However,
Some time ago we added an option for a batch file running commands at startup.
I'll send you an example tomorrow.

This is a generic solution and you can basically do anything you can from the console
at startup.

Thanks,
Itay



santhosh

--
You received this message because you are subscribed to the Google Groups "TRex Traffic Generator" group.
To unsubscribe from this group and stop receiving emails from it, send an email to trex-tgn+u...@googlegroups.com.
To post to this group, send email to trex...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/trex-tgn/ea58f57c-6a32-4484-b35b-42af32b63fdd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Itay Marom

Itay Marom

unread,
Apr 30, 2016, 4:48:12 PM4/30/16
to santhosh kumar, TRex Traffic Generator
Hi Santhosh,

Just to emphasize another point:
All of the switches for the client are client oriented switches:
such as how to connect, which ports to acquire and etc.

However,
the 'portattr' is a server command.
this means that entering the console, doing portattr --prom and exiting will not reset the setting.
when you reconnect to the console, you will see that the ports are still on promiscuous mode.

And as I said, we support batch commands, which can include server commands such as portattr.

Thanks,
Itay
--
Itay Marom

hanoh haim

unread,
May 2, 2016, 6:29:35 AM5/2/16
to Itay Marom, santhosh kumar, TRex Traffic Generator
Hi Itay, 
I think it would be better to change the default server port state to be promiscuous.  
This will reduce the number of questions 

thanks,
Hanoh


For more options, visit https://groups.google.com/d/optout.



--
Hanoh
Sent from my iPhone

santhosh kumar

unread,
May 2, 2016, 2:29:35 PM5/2/16
to Itay Marom, TRex Traffic Generator
Hi Itay,

Thanks for the clarification.

I set the promiscuous mode from the console and then exited the console. The setting are not reset when I login again.

trex>stats--ps
Port Status

     port       |          0           |          1          
-------------------------------------------------------------
driver          |    rte_ixgbe_pmd     |    rte_ixgbe_pmd    
maximum         |       10 Gb/s        |       10 Gb/s        
status          |         IDLE         |         IDLE        
promiscuous     |          on          |          on          
--              |                      |                      
HW src mac      |  00:00:00:00:00:00   |  00:00:00:00:00:00  
SW src mac      |  02:00:00:00:00:00   |  02:00:00:00:00:01  
SW dst mac      |  90:e2:ba:08:42:d4   |  90:e2:ba:08:42:d5  
---             |                      |                      
PCI Address     |     0000:05:00.0     |     0000:05:00.1    
NUMA Node       |          0           |          0    
     

However if I run with command line option "./t-rex-64-o  -c 10 -f cap2/dns.yaml  -l 10000 -m 28mpps -d 60 ", I see packets are not received (rx_ok is still zero)

  Total-Tx        :      21.23 Mbps  
 Total-Rx        :       0.00  bps  
 Total-PPS       :      38.91 Kpps  
 Total-CPS       :      31.88  cps  

 Expected-PPS    :      56.00 Kpps  
 Expected-CPS    :      28.00 Kcps  
 Expected-BPS    :      29.57 Mbps  

 Active-flows    :      255  Clients :      250   Socket-util : 0.0016 %    
 Open-flows      :      255  Servers :      250   Socket :      255 Socket/Clients :  1.0
 drop-rate       :      21.23 Mbps  
 current time    : 4.0 sec  
 test duration   : 56.0 sec  

-Latency stats enabled
 Cpu Utilization : 0.5 %  
 if|   tx_ok , rx_ok  , rx check ,error,       latency (usec) ,    Jitter          max window
   |         ,        ,          ,     ,   average   ,   max  ,    (usec)                    
 ----------------------------------------------------------------------------------------------------------------
 0 |    30038,       0,         0,    0,          0  ,       0,       0      |  0  0  0  0  0  0  0  0  0  0  0  0  0
 1 |    30038,       0,         0,    0,          0  ,       0,       0      |  0  0  0  0  0  0  0  0  0  0  0  0  0
 All cores stopped !!


I have a setup with 2 10G ports connected from dut1 back to back to dut2. I send udp packets from both client and server ports and the packet gets L3fwd at dut2 and are send back to dut2. 

When I set the Src MAC  in .yaml file I receive the packets.

I guess when running t-rex in command line  the promiscuous settings are not getting enabled.

Can you please let me know what's wrong here ?

Thanks
santhosh 

hanoh haim

unread,
May 2, 2016, 3:30:58 PM5/2/16
to santhosh kumar, Itay Marom, TRex Traffic Generator
Hi,
This is correct. in TRex Stateful mode it is support only non-promiscuous mode as we are dealing with L7 testing. 
 

thanks
Hanoh


For more options, visit https://groups.google.com/d/optout.



--
Reply all
Reply to author
Forward
0 new messages