Merge "xena_cont_accuracy_fix: Xena continuous traffic accuracy fixes"
[vswitchperf.git] / conf / 03_traffic.conf
1 # Copyright 2015 Intel Corporation.
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #   http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 # ############################
16 # Traffic gen configuration
17 # ############################
18
19 # log file for all traffic generator related commands
20 LOG_FILE_TRAFFIC_GEN = 'traffic-gen.log'
21
22 # TRAFFIC dictionary defines traffic parameters used by all traffic generators.
23 # Detailed description of TRAFFIC dictionary items follows:
24 #
25 #    'traffic_type'  - One of the supported traffic types.
26 #                      E.g. rfc2544_throughput, rfc2544_back2back
27 #                      or rfc2544_continuous
28 #                      Data type: str
29 #                      Default value: "rfc2544_throughput".
30 #    'bidir'         - Specifies if generated traffic will be full-duplex (True)
31 #                      or half-duplex (False)
32 #                      Data type: str
33 #                      Supported values: "True", "False"
34 #                      Default value: "False".
35 #    'frame_rate'    - Defines desired percentage of frame rate used during
36 #                      continuous stream tests.
37 #                      Data type: int
38 #                      Default value: 100.
39 #    'multistream'   - Defines number of flows simulated by traffic generator.
40 #                      Value 0 disables multistream feature
41 #                      Data type: int
42 #                      Supported values: 0-65535
43 #                      Default value: 0.
44 #    'stream_type'   - Stream type is an extension of the "multistream" feature.
45 #                      If multistream is disabled, then stream type will be
46 #                      ignored. Stream type defines ISO OSI network layer used
47 #                      for simulation of multiple streams.
48 #                      Data type: str
49 #                      Supported values:
50 #                         "L2" - iteration of destination MAC address
51 #                         "L3" - iteration of destination IP address
52 #                         "L4" - iteration of destination port
53 #                                of selected transport protocol
54 #                      Default value: "L4".
55 #    'pre_installed_flows'
56 #                   -  Pre-installed flows is an extension of the multistream"
57 #                      feature. If multistream is disabled, then pre-installed
58 #                      flows will be ignored. It defines if stream specific flows
59 #                      will be inserted into OVS or not.
60 #                      Data type: str
61 #                      Supported values:
62 #                         "Yes" - flows will be inserted into OVS
63 #                         "No"  - flows won't be inserted into OVS
64 #                      Default value: "No".
65 #    'flow_type'     - Defines flows complexity.
66 #                      Data type: str
67 #                      Supported values:
68 #                         "port" - flow is defined by ingress ports
69 #                         "IP"   - flow is defined by ingress ports
70 #                                  and src and dst IP addresses
71 #                      Default value: "port"
72 #    'l2'            - A dictionary with l2 network layer details. Supported
73 #                      values are:
74 #        'srcmac'    - Specifies source MAC address filled by traffic generator.
75 #                      NOTE: It can be modified by vsperf in some scenarios.
76 #                      Data type: str
77 #                      Default value: "00:00:00:00:00:00".
78 #        'dstmac'    - Specifies destination MAC address filled by traffic generator.
79 #                      NOTE: It can be modified by vsperf in some scenarios.
80 #                      Data type: str
81 #                      Default value: "00:00:00:00:00:00".
82 #        'framesize' - Specifies default frame size. This value should not be
83 #                      changed directly. It will be overridden during testcase
84 #                      execution by values specified by list TRAFFICGEN_PKT_SIZES.
85 #                      Data type: int
86 #                      Default value: 64
87 #    'l3'            - A dictionary with l3 network layer details. Supported
88 #                      values are:
89 #        'srcip'     - Specifies source MAC address filled by traffic generator.
90 #                      NOTE: It can be modified by vsperf in some scenarios.
91 #                      Data type: str
92 #                      Default value: "1.1.1.1".
93 #        'dstip'     - Specifies destination MAC address filled by traffic generator.
94 #                      NOTE: It can be modified by vsperf in some scenarios.
95 #                      Data type: str
96 #                      Default value: "90.90.90.90".
97 #        'proto'     - Specifies deflaut protocol type.
98 #                      Please check particular traffic generator implementation
99 #                      for supported protocol types.
100 #                      Data type: str
101 #                      Default value: "udp".
102 #    'l4'            - A dictionary with l4 network layer details. Supported
103 #                      values are:
104 #        'srcport'   - Specifies source port of selected transport protocol.
105 #                      NOTE: It can be modified by vsperf in some scenarios.
106 #                      Data type: int
107 #                      Default value: 3000
108 #        'dstport'   - Specifies destination port of selected transport protocol.
109 #                      NOTE: It can be modified by vsperf in some scenarios.
110 #                      Data type: int
111 #                      Default value: 3001
112 #    'vlan'          - A dictionary with vlan encapsulation details. Supported
113 #                      values are:
114 #        'enabled'   - Specifies if vlan encapsulation should be enabled or
115 #                      disabled.
116 #                      Data type: bool
117 #                      Default value: False
118 #        'id'        - Specifies vlan id.
119 #                      Data type: int (NOTE: must fit to 12 bits)
120 #                      Default value: 0
121 #        'priority'  - Specifies a vlan priority (PCP header field).
122 #                      Data type: int (NOTE: must fit to 3 bits)
123 #                      Default value: 0
124 #        'cfi'       - Specifies if frames can or cannot be dropped during
125 #                      congestion (DEI header field).
126 #                      Data type: int (NOTE: must fit to 1 bit)
127 #                      Default value: 0
128 TRAFFIC = {
129     'traffic_type' : 'rfc2544_throughput',
130     'frame_rate' : 100,
131     'bidir' : 'True',  # will be passed as string in title format to tgen
132     'multistream' : 0,
133     'stream_type' : 'L4',
134     'pre_installed_flows' : 'No',           # used by vswitch implementation
135     'flow_type' : 'port',                   # used by vswitch implementation
136
137     'l2': {
138         'framesize': 64,
139         'srcmac': '00:00:00:00:00:00',
140         'dstmac': '00:00:00:00:00:00',
141     },
142     'l3': {
143         'proto': 'udp',
144         'srcip': '1.1.1.1',
145         'dstip': '90.90.90.90',
146     },
147     'l4': {
148         'srcport': 3000,
149         'dstport': 3001,
150     },
151     'vlan': {
152         'enabled': False,
153         'id': 0,
154         'priority': 0,
155         'cfi': 0,
156     },
157 }
158
159 #path to traffic generators directory.
160 TRAFFICGEN_DIR = os.path.join(ROOT_DIR, 'tools/pkt_gen')
161
162 # traffic generator to use in tests
163 #TRAFFICGEN = 'TestCenter'
164 TRAFFICGEN = 'Dummy'
165 #TRAFFICGEN = 'IxNet'
166 #TRAFFICGEN = 'Ixia'
167 #TRAFFICGEN = 'Xena'
168 #TRAFFICGEN = 'Moongen'
169
170 # List of packet sizes to send.
171 # Expand like this: (64, 128, 256, 512, 1024)
172 TRAFFICGEN_PKT_SIZES = (64,)
173
174 TRAFFICGEN_DURATION = 30
175
176 TRAFFICGEN_RFC2544_TESTS = 1
177 TRAFFICGEN_RFC2889_TRIALS = 1
178 TRAFFICGEN_LOSSRATE = 0.0
179
180 ##############################
181 # DUMMY Configuration -- BEGIN
182
183 # By default, dummy traffic generator asks for "measured" values.
184 # Following dictionary allows to preconfigure these values and
185 # to avoid user interaction. It can be useful for automated
186 # integration tests.
187 # Example of values for continuous traffic type:
188 #   TRAFFICGEN_DUMMY_RESULTS{'frames rx': 500000,
189 #                            'frames tx': 500000,
190 #                            'rx rate %': 100,
191 #                            'tx rate %': 100,
192 #                            'frameloss %': 0,
193 #                            'min latency': 1,
194 #                            'max latency': 15,
195 #                            'avg latency': 2.5,
196 #                           }
197 #
198 TRAFFICGEN_DUMMY_RESULTS = {}
199
200 # DUMMY Configuration -- END
201 ############################
202
203 #############################
204 # IXIA Configuration -- BEGIN
205
206 # path to 'ixos' install path
207 TRAFFICGEN_IXIA_ROOT_DIR = '/opt/ixos'
208
209 # network address of IXIA chassis
210 TRAFFICGEN_IXIA_HOST = ''
211
212 TRAFFICGEN_IXIA_CARD = ''
213
214 TRAFFICGEN_IXIA_PORT1 = ''
215
216 TRAFFICGEN_IXIA_PORT2 = ''
217
218 TRAFFICGEN_IXNET_LIB_PATH = '/opt/ixnetwork/lib/IxTclNetwork'
219
220 # IxNetwork host IP address
221 TRAFFICGEN_IXNET_MACHINE = ''
222 TRAFFICGEN_IXNET_PORT = ''
223 TRAFFICGEN_IXNET_USER = ''
224 TRAFFICGEN_IXNET_CHASSIS = ''
225
226 # The result directory on $TRAFFICGEN_IXNET_MACHINE
227 TRAFFICGEN_IXNET_TESTER_RESULT_DIR = ''
228
229 # The result directory on DUT. This needs to map to the same directory
230 # as the previous one
231 TRAFFICGEN_IXNET_DUT_RESULT_DIR = ''
232
233 # directory with 3rd party scripts generated by IXIA tools
234 TRAFFICGEN_IXIA_3RD_PARTY = os.path.join(ROOT_DIR, '3rd_party/ixia')
235
236 # default TCL script, which will be used for IXNETWORK configuration
237 TRAFFICGEN_IXNET_TCL_SCRIPT = 'ixnetrfc2544.tcl'
238
239 # IXIA Configuration -- END
240 ###########################
241
242
243 ###########################################
244 # Spirent TestCenter Configuration -- BEGIN
245
246 # Path to Python 2 executable
247 TRAFFICGEN_STC_PYTHON2_PATH = "/bin/python2.7"
248
249 # Path to the location of the TestCenter files
250 TRAFFICGEN_STC_TESTCENTER_PATH = os.path.join(ROOT_DIR, 'tools/pkt_gen/testcenter')
251
252 # Name of the TestCenter RFC2544 Tput helper python script
253 TRAFFICGEN_STC_RFC2544_TPUT_TEST_FILE_NAME = "testcenter-rfc2544-throughput.py"
254
255 # Name of the Testcenter RFC2899 Tput Helper Python Scripts
256 TRAFFICGEN_STC_RFC2889_TEST_FILE_NAME = "testcenter-rfc2889-rest.py"
257
258 # 2889 Port Locations
259 TRAFFICGEN_STC_RFC2889_LOCATION = ""
260
261 # The address of the Spirent Lab Server to use
262 TRAFFICGEN_STC_LAB_SERVER_ADDR = ""
263
264 # The address of the Spirent License Server in your environment
265 TRAFFICGEN_STC_LICENSE_SERVER_ADDR = ""
266
267 # The address of the TestCenter chassis that holds the east port
268 TRAFFICGEN_STC_EAST_CHASSIS_ADDR = ""
269
270 # The slot number of the card that holds the east port
271 TRAFFICGEN_STC_EAST_SLOT_NUM = ""
272
273 # The port number on the card that holds the east port
274 TRAFFICGEN_STC_EAST_PORT_NUM = ""
275
276 # The address of the TestCenter chassis that holds the west port
277 TRAFFICGEN_STC_WEST_CHASSIS_ADDR = ""
278
279 # The slot number of the card that holds the west port
280 TRAFFICGEN_STC_WEST_SLOT_NUM = ""
281
282 # The port number on the card that holds the west port
283 TRAFFICGEN_STC_WEST_PORT_NUM = ""
284
285 # The friendly name to identify the Spirent Lab Server test session
286 TRAFFICGEN_STC_TEST_SESSION_NAME = "RFC2544 Tput"
287 # The directory to copy results to
288
289 TRAFFICGEN_STC_RESULTS_DIR = os.path.join(ROOT_DIR, "Results")
290 #  The prefix for the CSV results file
291
292 TRAFFICGEN_STC_CSV_RESULTS_FILE_PREFIX = "RFC2544_tput"
293 # The number of trials to execute during the test
294
295 TRAFFICGEN_STC_NUMBER_OF_TRIALS = "1"
296
297 # The duration of each trial executed during the test, in seconds
298 TRAFFICGEN_STC_TRIAL_DURATION_SEC = "60"
299
300 # The traffic pattern between endpoints, BACKBONE, MESH or PAIR
301 TRAFFICGEN_STC_TRAFFIC_PATTERN = "PAIR"
302
303 # The search mode used to find the throughput rate, COMBO, STEP or BINARY
304 TRAFFICGEN_STC_SEARCH_MODE = "BINARY"
305
306 # The learning mode used during the test, AUTO, L2_LEARNING, L3_LERNING, or NONE
307 TRAFFICGEN_STC_LEARNING_MODE = "AUTO"
308
309 # The minimum percent line rate that will be used during the test
310 TRAFFICGEN_STC_RATE_LOWER_LIMIT_PCT = "1.0"
311
312 # The maximum percent line rate that will be used during the test
313 TRAFFICGEN_STC_RATE_UPPER_LIMIT_PCT = "99.0"
314
315 # If SearchMode is BINARY, the percent line rate that will be used at the start of the test
316 TRAFFICGEN_STC_RATE_INITIAL_PCT = "99.0"
317
318 # When SearchMode is STEP, the percent increase in load per step
319 TRAFFICGEN_STC_RATE_STEP_PCT = "10.0"
320
321 # The minimum percentage of load adjustment between iterations
322 TRAFFICGEN_STC_RESOLUTION_PCT = "1.0"
323
324 # The frame size, in bytes
325 TRAFFICGEN_STC_FRAME_SIZE = "256"
326
327 # The maximum acceptable frame loss percent in any iteration
328 TRAFFICGEN_STC_ACCEPTABLE_FRAME_LOSS_PCT = "0.0"
329
330 # The address to assign to the first emulated device interface on the first east port
331 TRAFFICGEN_STC_EAST_INTF_ADDR = ""
332
333 # The gateway address to assign to the first emulated device interface on the first east port
334 TRAFFICGEN_STC_EAST_INTF_GATEWAY_ADDR = ""
335
336 # The address to assign to the first emulated device interface on the first west port
337 TRAFFICGEN_STC_WEST_INTF_ADDR = ""
338
339 # The gateway address to assign to the first emulated device interface on the first west port
340 TRAFFICGEN_STC_WEST_INTF_GATEWAY_ADDR = ""
341
342 # Print additional information to the terminal during the test
343 TRAFFICGEN_STC_VERBOSE = "True"
344
345 # Spirent TestCenter Configuration -- END
346 #########################################
347
348 #############################
349 # Xena Configuration -- BEGIN
350
351 # Xena traffic generator connection info
352 TRAFFICGEN_XENA_IP = ''
353 TRAFFICGEN_XENA_PORT1 = ''
354 TRAFFICGEN_XENA_PORT2 = ''
355 TRAFFICGEN_XENA_USER = ''
356 TRAFFICGEN_XENA_PASSWORD = ''
357 TRAFFICGEN_XENA_MODULE1 = ''
358 TRAFFICGEN_XENA_MODULE2 = ''
359
360 # Xena Port IP info
361 TRAFFICGEN_XENA_PORT0_IP = '192.168.199.10'
362 TRAFFICGEN_XENA_PORT0_CIDR = 24
363 TRAFFICGEN_XENA_PORT0_GATEWAY = '192.168.199.1'
364 TRAFFICGEN_XENA_PORT1_IP = '192.168.199.11'
365 TRAFFICGEN_XENA_PORT1_CIDR = 24
366 TRAFFICGEN_XENA_PORT1_GATEWAY = '192.168.199.1'
367
368 # Xena RFC 2544 options
369 # Please reference xena documentation before making changes to these settings
370 TRAFFICGEN_XENA_2544_TPUT_INIT_VALUE = '10.0'
371 TRAFFICGEN_XENA_2544_TPUT_MIN_VALUE = '0.1'
372 TRAFFICGEN_XENA_2544_TPUT_MAX_VALUE = '100.0'
373 TRAFFICGEN_XENA_2544_TPUT_VALUE_RESOLUTION = '0.5'
374 TRAFFICGEN_XENA_2544_TPUT_USEPASS_THRESHHOLD = 'false'
375 TRAFFICGEN_XENA_2544_TPUT_PASS_THRESHHOLD = '0.0'
376
377 # Xena Continuous traffic options
378 # Please reference xena documentation before making changes to these settings
379 TRAFFICGEN_XENA_CONT_PORT_LEARNING_ENABLED = True
380 TRAFFICGEN_XENA_CONT_PORT_LEARNING_DURATION = 3
381
382 # Xena Configuration -- END
383 ###########################
384
385 ###################################################
386 # MoonGen Configuration and Connection Info-- BEGIN
387
388 # Ex: TRAFFICGEN_MOONGEN_HOST_IP_ADDR = "192.10.1.1"
389 TRAFFICGEN_MOONGEN_HOST_IP_ADDR = ''
390 TRAFFICGEN_MOONGEN_USER = ''
391 TRAFFICGEN_MOONGEN_BASE_DIR = ''
392 TRAFFICGEN_MOONGEN_PORTS = ''
393 # Ex. 10 Gbps: TRAFFICGEN_MOONGEN_LINE_SPEED_GBPS = '10'
394 # Today only 10 Gbps is supported
395 TRAFFICGEN_MOONGEN_LINE_SPEED_GBPS = ''
396
397 # MoonGen Configuration and Connection Info-- END
398 ###################################################