dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x00,0x00,0x00,0x01,0x00,0x00] <3>
- cap_ipg : true <4>
- cap_ipg_min : 30 <5>
- cap_override_ipg : 200 <6>
- vlan : { enable : 1 , vlan0 : 100 , vlan1 : 200 } <7>
- mac_override_by_ip : true <8>
+ cap_ipg : true <3>
+ cap_ipg_min : 30 <4>
+ cap_override_ipg : 200 <5>
+ vlan : { enable : 1 , vlan0 : 100 , vlan1 : 200 } <6>
+ mac_override_by_ip : true <7>
----
<1> Test duration (seconds). Can be overridden using the `-d` option.
-<2> See the link:trex_manual.html#_clients_servers_ip_allocation_scheme[generator] section.
-// what does note 2 mean? see somewhere else? isn't this simply the generator section?
-<3> Default source/destination MAC address. The configuration YAML can override this.
-<4> true (default) indicates that the IPG is taken from the cap file (also taking into account cap_ipg_min and cap_override_ipg if they exist). false indicates that IPG is taken from per template section.
-<5> The following two options can set the min ipg in microseconds: (if (pkt_ipg<cap_ipg_min) { pkt_ipg=cap_override_ipg} )
-<6> Value to override (microseconds), as described in note above.
-<7> Enable load balance feature. See xref:trex_load_bal[trex load balance section] for info.
-<8> Enable MAC address replacement by client IP.
-
+<2> See full explanation on generator section link:trex_manual.html#_clients_servers_ip_allocation_scheme[here].
+<3> true (default) indicates that the IPG is taken from the cap file (also taking into account cap_ipg_min and cap_override_ipg if they exist). false indicates that IPG is taken from per template section.
+<4> The following two options can set the min ipg in microseconds: (if (pkt_ipg<cap_ipg_min) { pkt_ipg=cap_override_ipg} )
+<5> Value to override (microseconds), as described in note above.
+<6> Enable load balance feature. See xref:trex_load_bal[trex load balance section] for info.
+<7> Enable MAC address replacement by client IP.
==== Timer Wheel section configuration
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_ipg : false
cap_ipg_min : 100
cap_override_ipg : 1000
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#cap_ipg : true
cap_info :
- name: cap2/udp_10_pkts.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#cap_ipg : true
cap_info :
- name: cap2/udp_10_pkts.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
- #cap_ipg : true
tw : # set timer wheel configuration options
buckets : 16384
levels : 2
dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg_min : 100
#cap_override_ipg : 200
wlength : 7
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 0.5
buckets : 32768
levels : 2
bucket_time_usec : 20.0
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
- #vlan : { enable : 1 , vlan0 : 100 , vlan1 : 200 }
- #mac_override_by_ip : true
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg_min : 30
#cap_override_ipg : 200
wlength : 10
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
#cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_ipg : true
cap_info :
- name: avl/delay_10_rtp_160k_full.pcap
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/delay_10_http_browsing_0.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#cap_ipg : true
cap_info :
- name: cap2/190_packet.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_ipg : true
cap_info :
- name: avl/delay_10_http_browsing_0.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#cap_ipg : true
cap_info :
- name: avl/delay_10_http_browsing_0.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/udp_64B.pcap
cps : 28.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automatically
-# but for now it like this , you should have at least 8
-#
+# The templates are duplicated on purpose in order to utilize all DRAM bandwidth and get better performance
+# Should do this automaticlly in the future somehow. You should have at least 8 templates
+#
cap_info :
- name: cap2/udp_1518B.pcap
cps : 1000.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automaticly
-# but for now it like this , you should have at least 8
-#
+# The templates are duplicated on purpose in order to utilize all DRAM bandwidth and get better performance
+# Should do this automaticlly in the future somehow. You should have at least 8 templates
+#
cap_info :
- name: cap2/udp_64B.pcap
cps : 1000.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automaticly
-# but for now it like this , you should have at least 8
-#
+# The templates are duplicated on purpose in order to utilize all DRAM bandwidth and get better performance
+# Should do this automaticlly in the future somehow. You should have at least 8 templates
+#
cap_info :
- name: cap2/udp_64B.pcap
cps : 1000.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
-#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automaticly
-# but for now it like this , you should have at least 8
-#
cap_info :
- name: cap2/udp_64B.pcap
cps : 1000000.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automaticly
-# but for now it like this , you should have at least 8
-#
+# The templates are duplicated on purpose in order to utilize all DRAM bandwidth and get better performance
+# Should do this automaticlly in the future somehow. You should have at least 8 templates
+#
cap_info :
- name: stl/yaml/ipv4_udp_9k.pcap
cps : 1000.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
-#
-# the templates are duplicated in purpose , to utilized all DRAM BW and get better performance, we should do it automaticly
-# but for now it like this , you should have at least 8
-#
cap_info :
- name: stl/yaml/ipv4_udp_9k_burst_10.pcap
cps : 0.1
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/udp_64B.pcap
cps : 90615
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/udp_64B.pcap
cps : 90615
dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
vlan : { enable : 1 , vlan0 : 100 , vlan1 : 200 }
cap_info :
- name: cap2/udp_64B.pcap
udp_aging : 1
src_ipv6 : [0x2001,0x0232,0x1002,0x0051,0x0000,0x0000]
dst_ipv6 : [0x3001,0x0DB8,0x0003,0x0004,0x0000,0x0000]
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/ipv6.pcap
cps : 10.0
udp_aging : 1
src_ipv6 : [0x2001,0x0232,0x1002,0x0051,0x0000,0x0000]
dst_ipv6 : [0x3001,0x0DB8,0x0003,0x0004,0x0000,0x0000]
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
vlan : { enable : 1 , vlan0 : 100 , vlan1 : 200 }
cap_info :
- name: cap2/ipv6.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/jumbo.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_ipg : true
cap_info :
- name: avl/delay_10_https_0.pcap
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/dns.pcap
cps : 15.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/udp_64B.pcap
cps : 6.0
ip_start : "38.0.0.1"
ip_end : "38.0.3.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
client_pool: "c1"
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
ip_start : "38.0.0.1"
ip_end : "38.0.1.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
cps : 1.0
ip_start : "38.0.0.1"
ip_end : "38.0.1.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
client_pool: "c1"
ip_start : "38.0.0.1"
ip_end : "38.0.1.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
client_pool: "c2"
ip_start : "38.0.0.1"
ip_end : "38.0.1.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
client_pool: "c2"
ip_start : "38.0.0.1"
ip_end : "38.0.3.255"
track_ports : false
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
client_pool: "c2"
#cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/rtsp_short.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/delay_10_rtp_250k_full.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/delay_10_rtp_160k_full.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/delay_10_rtp_250k_short.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/delay_10_rtp_250k_short.pcap
cps : 0.01
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/delay_10_rtp_250k_short.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/delay_10_rtp_250k_short.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/Oracle.pcap
cps : 150.0
dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/Oracle.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/Oracle.pcap
cps : 0.5
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/http_get.pcap
cps : 1.0
max_src_ip : 0x90000001
min_dst_ip : 0xa0000001
max_dst_ip : 0xb0000001
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/Oracle.pcap
cps : 60
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: cap2/Oracle.pcap
cps : 21.6
dual_port_mask : "1.0.0.0"
tcp_aging : 0
udp_aging : 0
- mac : [0x0,0x0,0x0,0x1,0x0,0x00]
cap_info :
- name: avl/delay_10_smtp_0.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/delay_10_sip_video_call_short.pcap
cps : 1.0
cap_ipg : true
#cap_ipg_min : 100
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/delay_10_sip_video_call_short.pcap
cps : 1.0
+++ /dev/null
-- min_ip : "1.1.1.1"
- items :
- - ip : "1.1.1.1"
- mac : [0x2,0x0,0x0,0x1,0x0,0x0]
-
- - ip : "1.1.1.2"
- mac : [0x3,0x0,0x0,0x1,0x0,0x0]
- - ip : "1.1.1.103"
- mac : [0x3,0x0,0x0,0x1,0x0,0x0]
cap_ipg : true
#cap_ipg_min : 30
#cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/citrix_0.pcap
cps : 1.0
cap_ipg : true
cap_ipg_min : 30
cap_override_ipg : 200
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: avl/citrix_0.pcap
cps : 1.0
dual_port_mask : "1.0.0.0"
tcp_aging : 1
udp_aging : 1
- mac : [0x00,0x00,0x00,0x01,0x00,0x00]
cap_info :
- name: cap2/wrong_ip.pcap
cps : 1.0
flows_info.m_mac_replace_by_ip =false;
}
- const YAML::Node& mac_info = node["mac"];
- for(unsigned i=0;i<mac_info.size();i++) {
- uint32_t fi;
- const YAML::Node & node =mac_info;
- node[i] >> fi;
- flows_info.m_mac_base.push_back(fi);
- }
-
const YAML::Node& cap_info = node["cap_info"];
for(unsigned i=0;i<cap_info.size();i++) {
CFlowYamlInfo fi;
m_vlan_info.Dump(fd);
- fprintf(fd," mac base : ");
- int i;
- for (i=0; i<(int)m_mac_base.size(); i++) {
- if (i< (int)(m_mac_base.size()-1) ) {
- fprintf(fd,"0x%02x,",m_mac_base[i]);
- }else{
- fprintf(fd,"0x%02x",m_mac_base[i]);
- }
- }
- fprintf(fd,"\n");
-
fprintf(fd," cap file info \n");
fprintf(fd," ------------- \n");
- for (i=0; i<(int)m_vec.size(); i++) {
+ for (int i=0; i<(int)m_vec.size(); i++) {
m_vec[i].Dump(fd);
}
m_tw.Dump(fd);
}
CGlobalInfo::m_options.preview.set_mac_ip_overide_enable(m_yaml_info.m_mac_replace_by_ip);
- if ( m_yaml_info.m_mac_base.size() != 6 ){
- printf(" mac addr is not valid \n");
- exit(0);
- }
-
if (m_yaml_info.m_ipv6_set == true) {
// Copy the most significant 96-bits from yaml data
for (idx=0; idx<6; idx++){
struct CFlowsYamlInfo {
public:
double m_duration_sec; //duration in sec for the cap file
-
-// IPv4 addressing
-
// IPv6 addressing
std::vector <uint16_t> m_src_ipv6;
std::vector <uint16_t> m_dst_ipv6;
CVlanYamlInfo m_vlan_info;
CTupleGenYamlInfo m_tuple_gen;
bool m_tuple_gen_was_set;
-
-
- std::vector <uint8_t> m_mac_base;
-
std::vector <CFlowYamlInfo> m_vec;
-
bool m_is_plugin_configured; /* any plugin is configured */
CTimerWheelYamlInfo m_tw;