1 # Copyright 2015 Intel Corporation.
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
7 # http://www.apache.org/licenses/LICENSE-2.0
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.
15 # ############################
16 # Traffic gen configuration
17 # ############################
19 # log file for all traffic generator related commands
20 LOG_FILE_TRAFFIC_GEN = 'traffic-gen.log'
22 #path to traffic generators directory.
23 TRAFFICGEN_DIR = os.path.join(ROOT_DIR, 'tools/pkt_gen')
25 # traffic generator to use in tests
26 #TRAFFICGEN = 'TestCenter'
31 #TRAFFICGEN = 'Moongen'
33 # List of packet sizes to send.
34 # Expand like this: (64, 128, 256, 512, 1024)
35 TRAFFICGEN_PKT_SIZES = (64,)
37 TRAFFICGEN_DURATION = 30
39 TRAFFICGEN_RFC2544_TESTS = 1
40 TRAFFICGEN_RFC2889_TRIALS = 1
41 TRAFFICGEN_LOSSRATE = 0.0
43 ##############################
44 # DUMMY Configuration -- BEGIN
46 # By default, dummy traffic generator asks for "measured" values.
47 # Following dictionary allows to preconfigure these values and
48 # to avoid user interaction. It can be useful for automated
50 # Example of values for continuous traffic type:
51 # TRAFFICGEN_DUMMY_RESULTS{'frames rx': 500000,
52 # 'frames tx': 500000,
61 TRAFFICGEN_DUMMY_RESULTS = {}
63 # DUMMY Configuration -- END
64 ############################
66 #############################
67 # IXIA Configuration -- BEGIN
69 # path to 'ixos' install path
70 TRAFFICGEN_IXIA_ROOT_DIR = '/opt/ixos'
72 # network address of IXIA chassis
73 TRAFFICGEN_IXIA_HOST = ''
75 TRAFFICGEN_IXIA_CARD = ''
77 TRAFFICGEN_IXIA_PORT1 = ''
79 TRAFFICGEN_IXIA_PORT2 = ''
81 TRAFFICGEN_IXNET_LIB_PATH = '/opt/ixnetwork/lib/IxTclNetwork'
83 # IxNetwork host IP address
84 TRAFFICGEN_IXNET_MACHINE = ''
85 TRAFFICGEN_IXNET_PORT = ''
86 TRAFFICGEN_IXNET_USER = ''
87 TRAFFICGEN_IXNET_CHASSIS = ''
89 # The result directory on $TRAFFICGEN_IXNET_MACHINE
90 TRAFFICGEN_IXNET_TESTER_RESULT_DIR = ''
92 # The result directory on DUT. This needs to map to the same directory
94 TRAFFICGEN_IXNET_DUT_RESULT_DIR = ''
96 # directory with 3rd party scripts generated by IXIA tools
97 TRAFFICGEN_IXIA_3RD_PARTY = os.path.join(ROOT_DIR, '3rd_party/ixia')
99 # default TCL script, which will be used for IXNETWORK configuration
100 TRAFFICGEN_IXNET_TCL_SCRIPT = 'ixnetrfc2544.tcl'
102 # IXIA Configuration -- END
103 ###########################
106 ###########################################
107 # Spirent TestCenter Configuration -- BEGIN
109 # Path to Python 2 executable
110 TRAFFICGEN_STC_PYTHON2_PATH = "/bin/python2.7"
112 # Path to the location of the TestCenter files
113 TRAFFICGEN_STC_TESTCENTER_PATH = os.path.join(ROOT_DIR, 'tools/pkt_gen/testcenter')
115 # Name of the TestCenter RFC2544 Tput helper python script
116 TRAFFICGEN_STC_RFC2544_TPUT_TEST_FILE_NAME = "testcenter-rfc2544-throughput.py"
118 # Name of the Testcenter RFC2899 Tput Helper Python Scripts
119 TRAFFICGEN_STC_RFC2889_TEST_FILE_NAME = "testcenter-rfc2889-rest.py"
121 # 2889 Port Locations
122 TRAFFICGEN_STC_RFC2889_LOCATION = ""
124 # The address of the Spirent Lab Server to use
125 TRAFFICGEN_STC_LAB_SERVER_ADDR = ""
127 # The address of the Spirent License Server in your environment
128 TRAFFICGEN_STC_LICENSE_SERVER_ADDR = ""
130 # The address of the TestCenter chassis that holds the east port
131 TRAFFICGEN_STC_EAST_CHASSIS_ADDR = ""
133 # The slot number of the card that holds the east port
134 TRAFFICGEN_STC_EAST_SLOT_NUM = ""
136 # The port number on the card that holds the east port
137 TRAFFICGEN_STC_EAST_PORT_NUM = ""
139 # The address of the TestCenter chassis that holds the west port
140 TRAFFICGEN_STC_WEST_CHASSIS_ADDR = ""
142 # The slot number of the card that holds the west port
143 TRAFFICGEN_STC_WEST_SLOT_NUM = ""
145 # The port number on the card that holds the west port
146 TRAFFICGEN_STC_WEST_PORT_NUM = ""
148 # The friendly name to identify the Spirent Lab Server test session
149 TRAFFICGEN_STC_TEST_SESSION_NAME = "RFC2544 Tput"
150 # The directory to copy results to
152 TRAFFICGEN_STC_RESULTS_DIR = os.path.join(ROOT_DIR, "Results")
153 # The prefix for the CSV results file
155 TRAFFICGEN_STC_CSV_RESULTS_FILE_PREFIX = "RFC2544_tput"
156 # The number of trials to execute during the test
158 TRAFFICGEN_STC_NUMBER_OF_TRIALS = "1"
160 # The duration of each trial executed during the test, in seconds
161 TRAFFICGEN_STC_TRIAL_DURATION_SEC = "60"
163 # The traffic pattern between endpoints, BACKBONE, MESH or PAIR
164 TRAFFICGEN_STC_TRAFFIC_PATTERN = "PAIR"
166 # The search mode used to find the throughput rate, COMBO, STEP or BINARY
167 TRAFFICGEN_STC_SEARCH_MODE = "BINARY"
169 # The learning mode used during the test, AUTO, L2_LEARNING, L3_LERNING, or NONE
170 TRAFFICGEN_STC_LEARNING_MODE = "AUTO"
172 # The minimum percent line rate that will be used during the test
173 TRAFFICGEN_STC_RATE_LOWER_LIMIT_PCT = "1.0"
175 # The maximum percent line rate that will be used during the test
176 TRAFFICGEN_STC_RATE_UPPER_LIMIT_PCT = "99.0"
178 # If SearchMode is BINARY, the percent line rate that will be used at the start of the test
179 TRAFFICGEN_STC_RATE_INITIAL_PCT = "99.0"
181 # When SearchMode is STEP, the percent increase in load per step
182 TRAFFICGEN_STC_RATE_STEP_PCT = "10.0"
184 # The minimum percentage of load adjustment between iterations
185 TRAFFICGEN_STC_RESOLUTION_PCT = "1.0"
187 # The frame size, in bytes
188 TRAFFICGEN_STC_FRAME_SIZE = "256"
190 # The maximum acceptable frame loss percent in any iteration
191 TRAFFICGEN_STC_ACCEPTABLE_FRAME_LOSS_PCT = "0.0"
193 # The address to assign to the first emulated device interface on the first east port
194 TRAFFICGEN_STC_EAST_INTF_ADDR = ""
196 # The gateway address to assign to the first emulated device interface on the first east port
197 TRAFFICGEN_STC_EAST_INTF_GATEWAY_ADDR = ""
199 # The address to assign to the first emulated device interface on the first west port
200 TRAFFICGEN_STC_WEST_INTF_ADDR = ""
202 # The gateway address to assign to the first emulated device interface on the first west port
203 TRAFFICGEN_STC_WEST_INTF_GATEWAY_ADDR = ""
205 # Print additional information to the terminal during the test
206 TRAFFICGEN_STC_VERBOSE = "True"
208 # Spirent TestCenter Configuration -- END
209 #########################################
211 #############################
212 # Xena Configuration -- BEGIN
214 # Xena traffic generator connection info
215 TRAFFICGEN_XENA_IP = ''
216 TRAFFICGEN_XENA_PORT1 = ''
217 TRAFFICGEN_XENA_PORT2 = ''
218 TRAFFICGEN_XENA_USER = ''
219 TRAFFICGEN_XENA_PASSWORD = ''
220 TRAFFICGEN_XENA_MODULE1 = ''
221 TRAFFICGEN_XENA_MODULE2 = ''
224 TRAFFICGEN_XENA_PORT0_IP = '192.168.199.10'
225 TRAFFICGEN_XENA_PORT0_CIDR = 24
226 TRAFFICGEN_XENA_PORT0_GATEWAY = '192.168.199.1'
227 TRAFFICGEN_XENA_PORT1_IP = '192.168.199.11'
228 TRAFFICGEN_XENA_PORT1_CIDR = 24
229 TRAFFICGEN_XENA_PORT1_GATEWAY = '192.168.199.1'
231 # Xena RFC 2544 options
232 # Please reference xena documentation before making changes to these settings
233 TRAFFICGEN_XENA_2544_TPUT_INIT_VALUE = '10.0'
234 TRAFFICGEN_XENA_2544_TPUT_MIN_VALUE = '0.1'
235 TRAFFICGEN_XENA_2544_TPUT_MAX_VALUE = '100.0'
236 TRAFFICGEN_XENA_2544_TPUT_VALUE_RESOLUTION = '0.5'
237 TRAFFICGEN_XENA_2544_TPUT_USEPASS_THRESHHOLD = 'false'
238 TRAFFICGEN_XENA_2544_TPUT_PASS_THRESHHOLD = '0.0'
240 # Xena Configuration -- END
241 ###########################
243 ###################################################
244 # MoonGen Configuration and Connection Info-- BEGIN
246 # Ex: TRAFFICGEN_MOONGEN_HOST_IP_ADDR = "192.10.1.1"
247 TRAFFICGEN_MOONGEN_HOST_IP_ADDR = ''
248 TRAFFICGEN_MOONGEN_USER = ''
249 TRAFFICGEN_MOONGEN_BASE_DIR = ''
250 TRAFFICGEN_MOONGEN_PORTS = ''
251 # Ex. 10 Gbps: TRAFFICGEN_MOONGEN_LINE_SPEED_GBPS = '10'
252 # Today only 10 Gbps is supported
253 TRAFFICGEN_MOONGEN_LINE_SPEED_GBPS = ''
255 # MoonGen Configuration and Connection Info-- END
256 ###################################################