504b4458d274e49d62a5547a6bb725375b7c661a
[vswitchperf.git] / conf / integration / 01_testcases.conf
1 # Copyright 2015-2016 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 # The 1st value of SUPPORTED_TUNNELING_PROTO is used as the default
16 # tunneling protocol for OP2P tests.
17 SUPPORTED_TUNNELING_PROTO = ['vxlan', 'gre', 'geneve']
18
19 #
20 # Generic test configuration options are described at conf/01_testcases.conf
21 #
22
23 #
24 # Options specific to integration testcases are described below:
25 #
26 # Required for OP2P tests
27 # "Tunnel Type": ["vxlan"|"gre"|"geneve"]   # Tunnel Type defines tunneling protocol to use.
28 #                                   # It can be overridden by cli option TUNNEL_TYPE.
29 #                                   # Values:
30 #                                   #    "vxlan" - iteration of destination MAC address
31 #                                   #    "gre" - iteration of destination IP address
32 #                                   #    "geneve" - iteration of destination UDP port
33 #                                   # Default value is "vxlan".
34 #
35 # bidirectional testing for OP2P is not yet supported.
36 # TRAFFIC['bidir'] must be set to 'False'.
37 #
38 # "TestSteps": []                   # Definition of integration test steps.
39 #                                   # In case that this list is defined, then
40 #                                   # vsperf will execute defined test steps
41 #                                   # one by one. It can be used to configure
42 #                                   # vswitch, insert flows and transmit traffic.
43 #                                   # It is possible to refer to result of any
44 #                                   # previous step through #STEP[i][j] macro.
45 #                                   # Where i is a number of step (starts from 0)
46 #                                   # and j is index of result returned by step i.
47
48 #
49 # Common TestSteps parts ("macros")
50 #
51
52 # P2P macros
53 STEP_VSWITCH_P2P_FLOWS_INIT = [
54     ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
55     ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
56     ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
57     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
58     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
59 ]
60
61 STEP_VSWITCH_P2P_FLOWS_FINIT = [
62     ['vswitch', 'dump_flows', 'int_br0'],
63     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
64     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
65     ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
66     ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
67     ['vswitch', 'del_switch', 'int_br0'],
68 ]
69
70 # PVP and PVVP macros
71 STEP_VSWITCH_PVP_INIT = [
72     ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
73     ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
74     ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
75     ['vswitch', 'add_vport', 'int_br0'],            # STEP 3    vm1 ports
76     ['vswitch', 'add_vport', 'int_br0'],            # STEP 4
77 ]
78
79 STEP_VSWITCH_PVP_FINIT = [
80     ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
81     ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
82     ['vswitch', 'del_port', 'int_br0', '#STEP[3][0]'],
83     ['vswitch', 'del_port', 'int_br0', '#STEP[4][0]'],
84     ['vswitch', 'del_switch', 'int_br0'],
85 ]
86
87 STEP_VSWITCH_PVP_FLOWS_INIT = STEP_VSWITCH_PVP_INIT + [
88     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
89     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
90     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
91     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[3][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
92 ]
93
94 STEP_VSWITCH_PVP_FLOWS_FINIT = [
95     ['vswitch', 'dump_flows', 'int_br0'],
96     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
97     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[4][1]'}],
98     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
99     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[3][1]'}],
100 ] + STEP_VSWITCH_PVP_FINIT
101
102 STEP_VSWITCH_PVVP_INIT = STEP_VSWITCH_PVP_INIT + [
103     ['vswitch', 'add_vport', 'int_br0'],            # STEP 5    vm2 ports
104     ['vswitch', 'add_vport', 'int_br0'],            # STEP 6
105 ]
106
107 STEP_VSWITCH_PVVP_FINIT = [
108     ['vswitch', 'del_port', 'int_br0', '#STEP[5][0]'],  # vm2 ports
109     ['vswitch', 'del_port', 'int_br0', '#STEP[6][0]'],
110 ] + STEP_VSWITCH_PVP_FINIT
111
112 STEP_VSWITCH_PVVP_FLOWS_INIT = STEP_VSWITCH_PVVP_INIT + [
113     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
114     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
115     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
116     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', 'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
117     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[5][1]', 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
118     ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[3][1]', 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
119 ]
120
121 STEP_VSWITCH_PVVP_FLOWS_FINIT = [
122     ['vswitch', 'dump_flows', 'int_br0'],
123     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
124     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[4][1]'}],
125     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[6][1]'}],
126     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[2][1]'}],
127     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[5][1]'}],
128     ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[3][1]'}],
129 ] + STEP_VSWITCH_PVVP_FINIT
130
131 STEP_VSWITCH_P4VP_INIT = STEP_VSWITCH_PVVP_INIT + [
132     ['vswitch', 'add_vport', 'int_br0'],            # STEP 7    vm3 ports
133     ['vswitch', 'add_vport', 'int_br0'],            # STEP 8
134     ['vswitch', 'add_vport', 'int_br0'],            # STEP 9    vm4 ports
135     ['vswitch', 'add_vport', 'int_br0'],            # STEP 10
136 ]
137
138 STEP_VSWITCH_P4VP_FINIT = [
139     ['vswitch', 'del_port', 'int_br0', '#STEP[7][0]'],  # vm3 ports
140     ['vswitch', 'del_port', 'int_br0', '#STEP[8][0]'],
141     ['vswitch', 'del_port', 'int_br0', '#STEP[9][0]'],  # vm4 ports
142     ['vswitch', 'del_port', 'int_br0', '#STEP[10][0]'],
143 ] + STEP_VSWITCH_PVVP_FINIT
144
145 STEP_VSWITCH_P4VP_FLOWS_INIT = STEP_VSWITCH_P4VP_INIT + [
146             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
147                 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
148             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', \
149                 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
150             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', \
151                 'actions': ['output:#STEP[7][1]'], 'idle_timeout': '0'}],
152             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[8][1]', \
153                 'actions': ['output:#STEP[9][1]'], 'idle_timeout': '0'}],
154             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[10][1]', \
155                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
156             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[2][1]', \
157                 'actions': ['output:#STEP[10][1]'], 'idle_timeout': '0'}],
158             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[9][1]', \
159                 'actions': ['output:#STEP[8][1]'], 'idle_timeout': '0'}],
160             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[7][1]', \
161                 'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
162             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[5][1]', \
163                 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
164             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[3][1]', \
165                 'actions': ['output:#STEP[1][1]'], 'idle_timeout': '0'}],
166 ]
167
168 STEP_VSWITCH_P4VP_FLOWS_FINIT = [
169     ['vswitch', 'dump_flows', 'int_br0'],
170     ['vswitch', 'del_flow', 'int_br0'],
171 ] + STEP_VSWITCH_P4VP_FINIT
172
173 STEP_VSWITCH_2PHY_2VM_INIT = STEP_VSWITCH_PVVP_INIT
174
175 STEP_VSWITCH_2PHY_2VM_FINIT = STEP_VSWITCH_PVVP_FINIT
176
177 STEP_VSWITCH_2_PARALLEL_VM_FLOWS_INIT  = [
178             # Setup Flows to reply ICMPv6 and similar packets, so to
179             # avoid flooding the internal port with their re-transmissions
180             ['vswitch', 'add_flow', 'int_br0', \
181                 {'priority': '1', 'dl_src': '00:00:00:00:00:01', \
182                 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
183             ['vswitch', 'add_flow', 'int_br0', \
184                 {'priority': '1', 'dl_src': '00:00:00:00:00:02', \
185                 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
186             ['vswitch', 'add_flow', 'int_br0', \
187                 {'priority': '1', 'dl_src': '00:00:00:00:00:03', \
188                 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
189             ['vswitch', 'add_flow', 'int_br0', \
190                 {'priority': '1', 'dl_src': '00:00:00:00:00:04', \
191                 'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
192             # Forward UDP packets depending on dest port
193             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
194                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '0', \
195                 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
196             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
197                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '1', \
198                 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
199             # Send VM outputs to phy port #2
200             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', \
201                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
202             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', \
203                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
204 ]
205
206 STEP_VSWITCH_2PHY_4VM_INIT = STEP_VSWITCH_2PHY_2VM_INIT + [
207     ['vswitch', 'add_vport', 'int_br0'],            # STEP 7    vm3 ports
208     ['vswitch', 'add_vport', 'int_br0'],            # STEP 8
209     ['vswitch', 'add_vport', 'int_br0'],            # STEP 9    vm4 ports
210     ['vswitch', 'add_vport', 'int_br0'],            # STEP 10
211 ]
212
213 STEP_VSWITCH_2PHY_4VM_FINIT = [
214     ['vswitch', 'del_port', 'int_br0', '#STEP[7][0]'],  # vm3 ports
215     ['vswitch', 'del_port', 'int_br0', '#STEP[8][0]'],
216     ['vswitch', 'del_port', 'int_br0', '#STEP[9][0]'],  # vm4 ports
217     ['vswitch', 'del_port', 'int_br0', '#STEP[10][0]'],
218 ] + STEP_VSWITCH_2PHY_2VM_FINIT
219
220 STEP_VSWITCH_FLOWS_FINIT = [
221     ['vswitch', 'dump_flows', 'int_br0'],
222     ['vswitch', 'del_flow', 'int_br0'],
223 ]
224
225 STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT = [
226             # Setup Flows to reply ICMPv6 and similar packets, so to
227             # avoid flooding the internal port with their re-transmissions
228             ['vswitch', 'add_flow', 'int_br0', \
229                 {'priority': '1', 'dl_src': '00:00:00:00:00:01', \
230                 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
231             ['vswitch', 'add_flow', 'int_br0', \
232                 {'priority': '1', 'dl_src': '00:00:00:00:00:02', \
233                 'actions': ['output:#STEP[4][1]'], 'idle_timeout': '0'}],
234             ['vswitch', 'add_flow', 'int_br0', \
235                 {'priority': '1', 'dl_src': '00:00:00:00:00:03', \
236                 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
237             ['vswitch', 'add_flow', 'int_br0', \
238                 {'priority': '1', 'dl_src': '00:00:00:00:00:04', \
239                 'actions': ['output:#STEP[6][1]'], 'idle_timeout': '0'}],
240             ['vswitch', 'add_flow', 'int_br0', \
241                 {'priority': '1', 'dl_src': '00:00:00:00:00:05', \
242                 'actions': ['output:#STEP[7][1]'], 'idle_timeout': '0'}],
243             ['vswitch', 'add_flow', 'int_br0', \
244                 {'priority': '1', 'dl_src': '00:00:00:00:00:06', \
245                 'actions': ['output:#STEP[8][1]'], 'idle_timeout': '0'}],
246             ['vswitch', 'add_flow', 'int_br0', \
247                 {'priority': '1', 'dl_src': '00:00:00:00:00:07', \
248                 'actions': ['output:#STEP[9][1]'], 'idle_timeout': '0'}],
249             ['vswitch', 'add_flow', 'int_br0', \
250                 {'priority': '1', 'dl_src': '00:00:00:00:00:08', \
251                 'actions': ['output:#STEP[10][1]'], 'idle_timeout': '0'}],
252             # Forward UDP packets depending on dest port
253             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
254                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '0', \
255                 'actions': ['output:#STEP[3][1]'], 'idle_timeout': '0'}],
256             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
257                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '1', \
258                 'actions': ['output:#STEP[5][1]'], 'idle_timeout': '0'}],
259             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
260                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '2', \
261                 'actions': ['output:#STEP[7][1]'], 'idle_timeout': '0'}],
262             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
263                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '3', \
264                 'actions': ['output:#STEP[9][1]'], 'idle_timeout': '0'}],
265             # Send VM outputs to phy port #2
266             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[4][1]', \
267                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
268             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[6][1]', \
269                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
270             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[8][1]', \
271                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
272             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[10][1]', \
273                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
274 ]
275
276 STEP_VSWITCH_2PHY_6VM_INIT = STEP_VSWITCH_2PHY_4VM_INIT + [
277             ['vswitch', 'add_vport', 'int_br0'],        # STEP 11   vm5    vhu8
278             ['vswitch', 'add_vport', 'int_br0'],        # STEP 12          vhu9
279             ['vswitch', 'add_vport', 'int_br0'],        # STEP 13   vm6    vhu10
280             ['vswitch', 'add_vport', 'int_br0'],        # STEP 14          vhu11
281 ]
282
283 STEP_VSWITCH_6_PARALLEL_VM_FLOWS_INIT = STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT + [
284             ['vswitch', 'add_flow', 'int_br0', \
285                 {'priority': '1', 'dl_src': '00:00:00:00:00:09', \
286                 'actions': ['output:#STEP[11][1]'], 'idle_timeout': '0'}],
287             ['vswitch', 'add_flow', 'int_br0', \
288                 {'priority': '1', 'dl_src': '00:00:00:00:00:0a', \
289                 'actions': ['output:#STEP[12][1]'], 'idle_timeout': '0'}],
290             ['vswitch', 'add_flow', 'int_br0', \
291                 {'priority': '1', 'dl_src': '00:00:00:00:00:0b', \
292                 'actions': ['output:#STEP[13][1]'], 'idle_timeout': '0'}],
293             ['vswitch', 'add_flow', 'int_br0', \
294                 {'priority': '1', 'dl_src': '00:00:00:00:00:0c', \
295                 'actions': ['output:#STEP[14][1]'], 'idle_timeout': '0'}],
296             # Forward UDP packets depending on dest port
297             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
298                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '4', \
299                 'actions': ['output:#STEP[11][1]'], 'idle_timeout': '0'}],
300             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', \
301                 'dl_type': '0x0800', 'nw_proto': '17', 'udp_dst': '5', \
302                 'actions': ['output:#STEP[13][1]'], 'idle_timeout': '0'}],
303             # Send VM outputs to phy port #2
304             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[12][1]', \
305                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
306             ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[14][1]', \
307                 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
308 ]
309
310 STEP_VSWITCH_2PHY_6VM_FINIT = [
311             ['vswitch', 'del_port', 'int_br0', '#STEP[11][0]'],  # vm5 ports
312             ['vswitch', 'del_port', 'int_br0', '#STEP[12][0]'],
313             ['vswitch', 'del_port', 'int_br0', '#STEP[13][0]'],  # vm6 ports
314             ['vswitch', 'del_port', 'int_br0', '#STEP[14][0]'],
315 ] + STEP_VSWITCH_2PHY_4VM_FINIT
316
317 #
318 # Definition of integration tests
319 #
320 INTEGRATION_TESTS = [
321     {
322         "Name": "overlay_p2p_mod_tput",
323         "Deployment": "ptunp",
324         "Tunnel Type": "vxlan",
325         "Description": ("Tunneling Throughput RFC2544 Test."
326                        "The encap and decap are performed inside the "
327                        "virtual switch itself in each direction to avoid "
328                        "the need of ingress overlay traffic."),
329         "Parameters": {
330             "TRAFFICGEN_IXNET_TCL_SCRIPT" : "ixnetrfc2544v2.tcl",
331             "TRAFFIC" : {
332                 "traffic_type" : "rfc2544_throughput",
333                 "bidir" : "False",
334             },
335         },
336     },
337     {
338         "Name": "overlay_p2p_tput",
339         "Deployment": "op2p",
340         "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
341         "Tunnel Operation": "encapsulation",
342         "Description": "Overlay Encapsulation Throughput RFC2544 Test",
343         "Parameters": {
344             "TRAFFICGEN_IXNET_TCL_SCRIPT" : "ixnetrfc2544v2.tcl",
345             "TRAFFIC" : {
346                 "traffic_type" : "rfc2544_throughput",
347                 "bidir" : "False",
348             },
349         },
350     },
351     {
352         "Name": "overlay_p2p_cont",
353         "Deployment": "op2p",
354         "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
355         "Tunnel Operation": "encapsulation",
356         "Description": "Overlay Encapsulation RFC2544 Continuous Stream",
357         "Parameters": {
358             "TRAFFICGEN_IXNET_TCL_SCRIPT" : "ixnetrfc2544v2.tcl",
359             "TRAFFIC" : {
360                 "traffic_type" : "rfc2544_continuous",
361                 "bidir" : "False",
362             },
363         },
364     },
365     {
366         "Name": "overlay_p2p_decap_tput",
367         "Deployment": "op2p",
368         "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
369         "Tunnel Operation": "decapsulation",
370         "Description": "Overlay Decapsulation Throughput RFC2544 Test",
371         "Parameters": {
372             "TRAFFICGEN_IXNET_TCL_SCRIPT" : "ixnetrfc2544v2.tcl",
373             "TRAFFIC" : {
374                 "traffic_type" : "rfc2544_throughput",
375                 "bidir" : "False",
376             },
377         },
378     },
379     {
380         "Name": "overlay_p2p_decap_cont",
381         "Deployment": "op2p",
382         "Tunnel Type": SUPPORTED_TUNNELING_PROTO[0],
383         "Tunnel Operation": "decapsulation",
384         "Description": "Overlay Decapsulation RFC2544 Continuous Stream",
385         "Parameters": {
386             "TRAFFICGEN_IXNET_TCL_SCRIPT" : "ixnetrfc2544v2.tcl",
387             "TRAFFIC" : {
388                 "traffic_type" : "rfc2544_continuous",
389                 "bidir" : "False",
390             },
391         },
392     },
393     {
394         "Name": "vswitch_add_del_bridge",
395         "Deployment": "clean",
396         "Description": "vSwitch - add and delete bridge",
397         "TestSteps": [
398                         ['vswitch', 'add_switch', 'int_br0'],
399                         ['vswitch', 'del_switch', 'int_br0'],
400                      ]
401     },
402     {
403         "Name": "vswitch_add_del_bridges",
404         "Deployment": "clean",
405         "Description": "vSwitch - add and delete bridges",
406         "TestSteps": [
407                         ['vswitch', 'add_switch', 'int_br0'],
408                         ['vswitch', 'add_switch', 'int_br1'],
409                         ['vswitch', 'del_switch', 'int_br0'],
410                         ['vswitch', 'del_switch', 'int_br1'],
411                      ]
412     },
413     {
414         "Name": "vswitch_add_del_phy_port",
415         "Deployment": "clean",
416         "Description": "vSwitch - add and delete physical port",
417         "TestSteps": [
418                         ['vswitch', 'add_switch', 'int_br0'],
419                         ['vswitch', 'add_phy_port', 'int_br0'],
420                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
421                         ['vswitch', 'del_switch', 'int_br0'],
422                      ]
423     },
424     {
425         "Name": "vswitch_add_del_phy_ports",
426         "Deployment": "clean",
427         "Description": "vSwitch - add and delete physical ports",
428         "TestSteps": [
429                         ['vswitch', 'add_switch', 'int_br0'],
430                         ['vswitch', 'add_phy_port', 'int_br0'],
431                         ['vswitch', 'add_phy_port', 'int_br0'],
432                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
433                         ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
434                         ['vswitch', 'del_switch', 'int_br0'],
435                      ]
436     },
437     {
438         "Name": "vswitch_add_del_vport",
439         "Deployment": "clean",
440         "Description": "vSwitch - add and delete virtual port",
441         "TestSteps": [
442                         ['vswitch', 'add_switch', 'int_br0'],
443                         ['vswitch', 'add_vport', 'int_br0'],
444                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
445                         ['vswitch', 'del_switch', 'int_br0'],
446                      ]
447     },
448     {
449         "Name": "vswitch_add_del_vports",
450         "Deployment": "clean",
451         "Description": "vSwitch - add and delete virtual ports",
452         "TestSteps": [
453                         ['vswitch', 'add_switch', 'int_br0'],
454                         ['vswitch', 'add_vport', 'int_br0'],
455                         ['vswitch', 'add_vport', 'int_br0'],
456                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
457                         ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
458                         ['vswitch', 'del_switch', 'int_br0'],
459                      ]
460     },
461     {
462         "Name": "vswitch_add_del_flow",
463         "Deployment": "clean",
464         "Description": "vSwitch - add and delete flow",
465         "TestSteps": [
466                         ['vswitch', 'add_switch', 'int_br0'],
467                         ['vswitch', 'add_phy_port', 'int_br0'],
468                         ['vswitch', 'add_phy_port', 'int_br0'],
469                         ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
470                         ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
471                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
472                         ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
473                         ['vswitch', 'del_switch', 'int_br0'],
474                      ]
475     },
476     {
477         "Name": "vswitch_vports_add_del_flow",
478         "Deployment": "clean",
479         "Description": "vSwitch - configure switch with vports, add and delete flow",
480         "TestSteps": [
481                         ['vswitch', 'add_switch', 'int_br0'],
482                         ['vswitch', 'add_vport', 'int_br0'],
483                         ['vswitch', 'add_vport', 'int_br0'],
484                         ['vswitch', 'add_flow', 'int_br0', {'in_port': '#STEP[1][1]', 'actions': ['output:#STEP[2][1]'], 'idle_timeout': '0'}],
485                         ['vswitch', 'del_flow', 'int_br0', {'in_port': '#STEP[1][1]'}],
486                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
487                         ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
488                         ['vswitch', 'del_switch', 'int_br0'],
489                      ]
490     },
491     {
492         "Name": "vswitch_add_del_flows",
493         "Deployment": "clean",
494         "Description": "vSwitch - add and delete flows",
495         "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
496                      STEP_VSWITCH_P2P_FLOWS_FINIT
497     },
498     {
499         "Name": "vswitch_p2p_tput",
500         "Deployment": "clean",
501         "Description": "vSwitch - configure switch and execute RFC2544 throughput test",
502         "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
503                      [
504                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', 'bidir' : 'True'}],
505                      ] +
506                      STEP_VSWITCH_P2P_FLOWS_FINIT
507     },
508     {
509         "Name": "vswitch_p2p_back2back",
510         "Deployment": "clean",
511         "Description": "vSwitch - configure switch and execute RFC2544 back2back test",
512         "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
513                      [
514                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', 'bidir' : 'True'}],
515                      ] +
516                      STEP_VSWITCH_P2P_FLOWS_FINIT
517     },
518     {
519         "Name": "vswitch_p2p_cont",
520         "Deployment": "clean",
521         "Description": "vSwitch - configure switch and execute RFC2544 continuous stream test",
522         "TestSteps": STEP_VSWITCH_P2P_FLOWS_INIT +
523                      [
524                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
525                      ] +
526                      STEP_VSWITCH_P2P_FLOWS_FINIT
527     },
528     {
529         "Name": "vswitch_pvp",
530         "Deployment": "clean",
531         "Description": "vSwitch - configure switch and one vnf",
532         "TestSteps": STEP_VSWITCH_PVP_INIT +
533                      [
534                         ['vnf', 'start'],
535                         ['vnf', 'stop'],
536                      ] +
537                      STEP_VSWITCH_PVP_FINIT
538     },
539     {
540         "Name": "vswitch_vports_pvp",
541         "Deployment": "clean",
542         "Description": "vSwitch - configure switch with vports and one vnf",
543         "TestSteps": [
544                         ['vswitch', 'add_switch', 'int_br0'],
545                         ['vswitch', 'add_vport', 'int_br0'],
546                         ['vswitch', 'add_vport', 'int_br0'],
547                         ['vnf', 'start'],
548                         ['vnf', 'stop'],
549                         ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
550                         ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
551                         ['vswitch', 'del_switch', 'int_br0'],
552                      ]
553     },
554     {
555         "Name": "vswitch_pvp_tput",
556         "Deployment": "clean",
557         "Description": "vSwitch - configure switch, vnf and execute RFC2544 throughput test",
558         "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
559                      [
560                         ['vnf', 'start'],
561                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', 'bidir' : 'True'}],
562                         ['vnf', 'stop'],
563                      ] +
564                      STEP_VSWITCH_PVP_FLOWS_FINIT
565     },
566     {
567         "Name": "vswitch_pvp_back2back",
568         "Deployment": "clean",
569         "Description": "vSwitch - configure switch, vnf and execute RFC2544 back2back test",
570         "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
571                      [
572                         ['vnf', 'start'],
573                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', 'bidir' : 'True'}],
574                         ['vnf', 'stop'],
575                      ] +
576                      STEP_VSWITCH_PVP_FLOWS_FINIT
577     },
578     {
579         "Name": "vswitch_pvp_cont",
580         "Deployment": "clean",
581         "Description": "vSwitch - configure switch, vnf and execute RFC2544 continuous stream test",
582         "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
583                      [
584                         ['vnf', 'start'],
585                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
586                         ['vnf', 'stop'],
587                      ] +
588                      STEP_VSWITCH_PVP_FLOWS_FINIT
589     },
590     {
591         "Name": "vswitch_pvp_all",
592         "Deployment": "clean",
593         "Description": "vSwitch - configure switch, vnf and execute all test types",
594         "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
595                      [
596                         ['vnf', 'start'],
597                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', 'bidir' : 'True'}],
598                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', 'bidir' : 'True'}],
599                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
600                         ['vnf', 'stop'],
601                      ] +
602                      STEP_VSWITCH_PVP_FLOWS_FINIT
603     },
604     {
605         "Name": "vswitch_pvvp",
606         "Deployment": "clean",
607         "Description": "vSwitch - configure switch and two vnfs",
608         "TestSteps": STEP_VSWITCH_PVVP_INIT +
609                      [
610                         ['vnf1', 'start'],
611                         ['vnf2', 'start'],
612                         ['vnf1', 'stop'],
613                         ['vnf2', 'stop'],
614                      ] +
615                      STEP_VSWITCH_PVVP_FINIT
616     },
617     {
618         "Name": "vswitch_pvvp_tput",
619         "Deployment": "clean",
620         "Description": "vSwitch - configure switch, two chained vnfs and execute RFC2544 throughput test",
621         "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
622                      [
623                         ['vnf1', 'start'],
624                         ['vnf2', 'start'],
625                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', 'bidir' : 'True'}],
626                         ['vnf1', 'stop'],
627                         ['vnf2', 'stop'],
628                      ] +
629                      STEP_VSWITCH_PVVP_FLOWS_FINIT
630     },
631     {
632         "Name": "vswitch_pvvp_back2back",
633         "Deployment": "clean",
634         "Description": "vSwitch - configure switch, two chained vnfs and execute RFC2544 back2back test",
635         "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
636                      [
637                         ['vnf1', 'start'],
638                         ['vnf2', 'start'],
639                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', 'bidir' : 'True'}],
640                         ['vnf1', 'stop'],
641                         ['vnf2', 'stop'],
642                      ] +
643                      STEP_VSWITCH_PVVP_FLOWS_FINIT
644     },
645     {
646         "Name": "vswitch_pvvp_cont",
647         "Deployment": "clean",
648         "Description": "vSwitch - configure switch, two chained vnfs and execute RFC2544 continuous stream test",
649         "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
650                      [
651                         ['vnf1', 'start'],
652                         ['vnf2', 'start'],
653                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
654                         ['vnf1', 'stop'],
655                         ['vnf2', 'stop'],
656                      ] +
657                      STEP_VSWITCH_PVVP_FLOWS_FINIT
658     },
659     {
660         "Name": "vswitch_pvvp_all",
661         "Deployment": "clean",
662         "Description": "vSwitch - configure switch, two chained vnfs and execute all test types",
663         "TestSteps": STEP_VSWITCH_PVVP_FLOWS_INIT +
664                      [
665                         ['vnf1', 'start'],
666                         ['vnf2', 'start'],
667                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', 'bidir' : 'True'}],
668                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', 'bidir' : 'True'}],
669                         ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
670                         ['vnf1', 'stop'],
671                         ['vnf2', 'stop'],
672                      ] +
673                      STEP_VSWITCH_PVVP_FLOWS_FINIT
674     },
675     {
676         "Name": "vswitch_p4vp",
677         "Description": "Just configure 4 chained vnfs",
678         "Deployment": "clean",
679         "TestSteps": STEP_VSWITCH_P4VP_FLOWS_INIT +
680         [
681             ['vnf1', 'start'],
682             ['vnf2', 'start'],
683             ['vnf3', 'start'],
684             ['vnf4', 'start'],
685             ['vnf1', 'stop'],
686             ['vnf2', 'stop'],
687             ['vnf3', 'stop'],
688             ['vnf4', 'stop'],
689         ] +
690         STEP_VSWITCH_P4VP_FLOWS_FINIT
691     },
692     {
693         "Name": "vswitch_p4vp_tput",
694         "Description": "4 chained vnfs, execute RFC2544 throughput test",
695         "Deployment": "clean",
696         "TestSteps": STEP_VSWITCH_P4VP_FLOWS_INIT +
697         [
698             ['vnf1', 'start'],
699             ['vnf2', 'start'],
700             ['vnf3', 'start'],
701             ['vnf4', 'start'],
702             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', \
703                 'bidir' : 'True'}],
704             ['vnf1', 'stop'],
705             ['vnf2', 'stop'],
706             ['vnf3', 'stop'],
707             ['vnf4', 'stop'],
708         ] +
709         STEP_VSWITCH_P4VP_FLOWS_FINIT
710     },
711     {
712         "Name": "vswitch_p4vp_back2back",
713         "Description": "4 chained vnfs, execute RFC2544 back2back test",
714         "Deployment": "clean",
715         "TestSteps": STEP_VSWITCH_P4VP_FLOWS_INIT +
716         [
717             ['vnf1', 'start'],
718             ['vnf2', 'start'],
719             ['vnf3', 'start'],
720             ['vnf4', 'start'],
721             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', \
722                 'bidir' : 'True'}],
723             ['vnf1', 'stop'],
724             ['vnf2', 'stop'],
725             ['vnf3', 'stop'],
726             ['vnf4', 'stop'],
727         ] +
728         STEP_VSWITCH_P4VP_FLOWS_FINIT
729     },
730     {
731         "Name": "vswitch_p4vp_cont",
732         "Description": "4 chained vnfs, execute RFC2544 continuous stream test",
733         "Deployment": "clean",
734         "TestSteps": STEP_VSWITCH_P4VP_FLOWS_INIT +
735         [
736             ['vnf1', 'start'],
737             ['vnf2', 'start'],
738             ['vnf3', 'start'],
739             ['vnf4', 'start'],
740             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', \
741                 'bidir' : 'True'}],
742             ['vnf1', 'stop'],
743             ['vnf2', 'stop'],
744             ['vnf3', 'stop'],
745             ['vnf4', 'stop'],
746         ] +
747         STEP_VSWITCH_P4VP_FLOWS_FINIT
748     },
749     {
750         "Name": "vswitch_p4vp_all",
751         "Description": "4 chained vnfs, execute RFC2544 throughput test",
752         "Deployment": "clean",
753         "TestSteps": STEP_VSWITCH_P4VP_FLOWS_INIT +
754         [
755             ['vnf1', 'start'],
756             ['vnf2', 'start'],
757             ['vnf3', 'start'],
758             ['vnf4', 'start'],
759             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_throughput', \
760                 'bidir' : 'True'}],
761             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_back2back', \
762                 'bidir' : 'True'}],
763             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', \
764                 'bidir' : 'True'}],
765             ['vnf1', 'stop'],
766             ['vnf2', 'stop'],
767             ['vnf3', 'stop'],
768             ['vnf4', 'stop'],
769         ] +
770         STEP_VSWITCH_P4VP_FLOWS_FINIT
771     },
772     {
773       # Topology: 2 Parallel PVP connections
774       # To run a Linux bridge as a loopback in the Guest use:
775       #     --test-params "GUEST_LOOPBACK=['linux_bridge']" --integration 2pvp_udp_dest_flows
776       # or add "Parameters" option to the test definition:
777       #     "Parameters" : {'GUEST_LOOPBACK' : ['linux_bridge'],},
778         "Name": "2pvp_udp_dest_flows",
779         "Description": "RFC2544 Continuous TC with 2 Parallel VMs, flows on UDP Dest Port",
780         "Deployment": "clean",
781         "Parameters" : {
782             "TRAFFIC" : {
783                 "multistream" : 2,
784                 "stream_type" : "L4",
785             },
786         },
787         "TestSteps": STEP_VSWITCH_2PHY_2VM_INIT +
788             STEP_VSWITCH_2_PARALLEL_VM_FLOWS_INIT + [
789             # Start 2 VMs
790             ['vnf1', 'start'],
791             ['vnf2', 'start'],
792             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'False'}],
793             ['vnf1', 'stop'],
794             ['vnf2', 'stop'],
795             # Clean up
796         ] + STEP_VSWITCH_FLOWS_FINIT +
797             STEP_VSWITCH_2PHY_2VM_FINIT
798     },
799     {
800       # Topology: 4 Parallel PVP connections
801       # To run a Linux bridge as a loopback in the Guest use:
802       #     --test-params "GUEST_LOOPBACK=['linux_bridge']" --integration 4pvp_udp_dest_flows
803       # or add "Parameters" option to the test definition:
804       #     "Parameters" : {'GUEST_LOOPBACK' : ['linux_bridge'],},
805         "Name": "4pvp_udp_dest_flows",
806         "Description": "RFC2544 Continuous TC with 4 Parallel VMs, flows on UDP Dest Port",
807         "Deployment": "clean",
808         "Parameters" : {
809             "TRAFFIC" : {
810                 "multistream" : 4,
811                 "stream_type" : "L4",
812             },
813         },
814         "TestSteps": STEP_VSWITCH_2PHY_4VM_INIT +
815             STEP_VSWITCH_4_PARALLEL_VM_FLOWS_INIT + [
816             # Start 4 VMs
817             ['vnf1', 'start'],
818             ['vnf2', 'start'],
819             ['vnf3', 'start'],
820             ['vnf4', 'start'],
821             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'False'}],
822             ['vnf1', 'stop'],
823             ['vnf2', 'stop'],
824             ['vnf3', 'stop'],
825             ['vnf4', 'stop'],
826             # Clean up
827         ] + STEP_VSWITCH_FLOWS_FINIT +
828             STEP_VSWITCH_2PHY_4VM_FINIT
829     },
830     {
831       # Topology: 6 Parallel PVP connections
832       # To run a Linux bridge as a loopback in the Guest use:
833       #     --test-params "GUEST_LOOPBACK=['linux_bridge']" --integration 6pvp_udp_dest_flows
834       # or add "Parameters" option to the test definition:
835       #     "Parameters" : {'GUEST_LOOPBACK' : ['linux_bridge'],},
836         "Name": "6pvp_udp_dest_flows",
837         "Description": "RFC2544 Continuous TC with 6 Parallel VMs, flows on UDP Dest Port",
838         "Deployment": "clean",
839         "Parameters" : {
840             "TRAFFIC" : {
841                 "multistream" : 6,
842                 "stream_type" : "L4",
843             },
844         },
845         "TestSteps": STEP_VSWITCH_2PHY_6VM_INIT +
846             STEP_VSWITCH_6_PARALLEL_VM_FLOWS_INIT + [
847             # Start VMs
848             ['vnf1', 'start'],
849             ['vnf2', 'start'],
850             ['vnf3', 'start'],
851             ['vnf4', 'start'],
852             ['vnf5', 'start'],
853             ['vnf6', 'start'],
854             ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'False'}],
855             ['vnf1', 'stop'],
856             ['vnf2', 'stop'],
857             ['vnf3', 'stop'],
858             ['vnf4', 'stop'],
859             ['vnf5', 'stop'],
860             ['vnf6', 'stop'],
861         ] + STEP_VSWITCH_FLOWS_FINIT +
862         STEP_VSWITCH_2PHY_6VM_FINIT
863     },
864     {
865         # Testcase for verification of vHost User NUMA awareness feature
866         # introduced in DPDK v2.2. Test case will execute two VNFs, each
867         # pinned to different NUMA slot. After that it will verify that
868         # QEMU and PMD threads serving its interfaces are co-located
869         # at the same NUMA slot.
870         #
871         # Prerequisites:
872         #     * architecture with at least 2 NUMA slots
873         #     * OVS with DPDK support and DPDK v2.2 and newer
874         #     * OVS configuration utilizing both NUMA slots
875         #
876         #     Example of OVS configuration valid for DPDK v16.04 and cores
877         #     split between NUMA slots as follows:
878         #           node 0 cpus: 0 1 2 3 4 5 6 7 8 9
879         #           node 1 cpus: 10 11 12 13 14 15 16 17 18 19
880         #
881         #     VSWITCH_PMD_CPU_MASK = '1010'
882         #     VSWITCHD_DPDK_CONFIG = {
883         #         'dpdk-init' : 'true',
884         #         'dpdk-lcore-mask' : '0x4004',
885         #         'pmd-cpu-mask' : 'FF0FF',
886         #         'dpdk-socket-mem' : '1024,1024',
887         #     }
888         #
889         "Name": "vhost_numa_awareness",
890         "Deployment": "clean",
891         "Description": "vSwitch DPDK - verify that PMD threads are served "
892                        "by the same NUMA slot as QEMU instances",
893         "vSwitch" : "OvsDpdkVhost",
894         "TestSteps": STEP_VSWITCH_PVVP_INIT +                                       # STEP 0-6
895             [
896                 # check that at least 2 numa slots are available
897                 ['tools', 'exec', 'numactl -H', 'available: ([0-9]+)'],             # STEP 7
898                 ['tools', 'assert', '#STEP[-1][0]>1'],                              # STEP 8
899                 # store last 2 cores from numa slot 0
900                 ['tools', 'exec', 'numactl -H', 'node 0 cpus:.*\s+(\\d+) (\\d+)$'], # STEP 9
901                 # store last 2 cores from numa slot 1
902                 ['tools', 'exec', 'numactl -H', 'node 1 cpus:.*\s+(\\d+) (\\d+)$'], # STEP 10
903                 # pin VNF1 to 1st NUMA slot and VNF2 to 2nd NUMA slot
904                 ['settings', 'setValue', 'GUEST_CORE_BINDING',                      # STEP 11
905                     [("#STEP[-2][0][0]", "#STEP[-2][0][1]"),
906                      ("#STEP[-1][0][0]", "#STEP[-1][0][1]")]
907                 ],
908                 # start 2 VNFs
909                 ['vnf1', 'start'],                                                  # STEP 12
910                 ['vnf2', 'start'],                                                  # STEP 13
911                 # read paths to ovs utilities
912                 ['settings', 'getValue', 'TOOLS'],                                  # STEP 14
913                 # check that PMD thread serving VNF1 runs at NUMA slot 0
914                 ## i.e. get numa slot ID serving dpdhvhostuser0...
915                 ['tools', 'exec', "sudo #STEP[-1]['ovs-appctl'] "                   # STEP 15
916                     "dpif-netdev/pmd-rxq-show | "
917                     "sed -e '/dpdkvhostuser0/,$d' | tac",
918                     'pmd thread numa_id ([0-9])+'
919                 ],
920                 ## ...and check that it is NUMA slot 0
921                 ['tools', 'assert', '#STEP[-1][0]==0'],                             # STEP 16
922                 # check that PMD thread serving VNF2 runs at NUMA slot 1
923                 ## i.e. get numa slot ID serving dpdhvhostuser2...
924                 ['tools', 'exec', "sudo #STEP[-3]['ovs-appctl'] "                   # STEP 17
925                     "dpif-netdev/pmd-rxq-show | "
926                     "sed -e '/dpdkvhostuser2/,$d' | tac",
927                     'pmd thread numa_id ([0-9])+'
928                 ],
929                 ## ...and check that it is NUMA slot 1
930                 ['tools', 'assert', '#STEP[-1][0]==1'],                             # STEP 18
931                 # clean up
932                 ['vnf2', 'stop'],                                                   # STEP 19
933                 ['vnf1', 'stop'],                                                   # STEP 20
934             ] +
935             STEP_VSWITCH_PVVP_FINIT                                                 # STEP 21...
936     },
937 ]
938
939 # Example of TC definition with exact vSwitch, VNF and TRAFFICGEN values.
940 #    {
941 #        "Name": "ovs_vanilla_linux_bridge_pvp_cont",
942 #        "Deployment": "clean",
943 #        "Description": "vSwitch - configure OVS Vanilla, QemuVirtioNet with linux bridge and execute continuous stream test",
944 #        "vSwitch" : "OvsVanilla",
945 #        "VNF" : "QemuVirtioNet",
946 #        "Trafficgen": "IxNet",
947 #        "Parameters": {"GUEST_LOOPBACK" : ["linux_bridge"],},
948 #        "TestSteps": STEP_VSWITCH_PVP_FLOWS_INIT +
949 #                     [
950 #                        ['vnf', 'start'],
951 #                        ['trafficgen', 'send_traffic', {'traffic_type' : 'rfc2544_continuous', 'bidir' : 'True'}],
952 #                        ['vnf', 'stop'],
953 #                     ] +
954 #                     STEP_VSWITCH_PVP_FLOWS_FINIT
955 #    },