Merge "vpp: Initial support of VPP vSwitch"
[vswitchperf.git] / conf / 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 # This file describes a list of testcases.  Each testcase is described as a
16 # dictionary in a list of dictionaries.
17 #
18 # The dictionary keys, their meanings and available values are:
19 #
20 # "Name": "phy2phy_burst",         # A human-readable string identifying the
21 #                                  # test.
22 # "Deployment": "p2p",             # One of the supported deployment scenarios.
23 # "Description": "Lorem ipsum..."  # Optional. A human-readable string
24 #                                  # describing the test.
25 # "Frame Modification": "vlan"     # One of the supported frame modifications:
26 #                                  # vlan, mpls, mac, dscp, ttl, ip_addr,
27 #                                  # ip_port.
28 # "Load": dictionary               # Optional. Configures background load
29 #                                  # during testcase execution.
30 #   Description of "Load" dictionary keys, their meanings and available values:
31 #
32 #   "tool": "stress"               # One of the supported load generators.
33 #   "load": 0-100                  # percentage of cores which should be
34 #                                  # utilized by load generator
35 #                                  # e.g. load = 70%, detected cpu cores = 14 =>
36 #                                  # round(14*0.7)=10, i.e. 10 instances of load
37 #                                  # generator will be executed
38 #   "reserved": 0- (Default 0)     # Optional. Defines number of cores reserved
39 #                                  # for vsperf
40 #                                  # e.g. load = 80%, detected cpu cores = 14,
41 #                                  # reserved = 4 => round((14-4)*0.8)=8,
42 #                                  # i.e. 8 load gen. instances will be executed
43 #   "pattern" : "c"                # stress/stress-ng specific; Number of 'c',
44 #                                  # 'm' and 'i' defines ratio between cpu, mem
45 #                                  # and io workers respectively
46 #                                  # e.g. "ccccmmi" => ratio among workers types
47 #                                  # will be 3:2:1, so in case that 12 stress
48 #                                  # instances should be executed, then 6 cpu,
49 #                                  # 4 memory and 2 io workers will be executed
50 #   "load_memory": 0-100           # Optional. Defines percentage of the system
51 #                                  # memory, which should be utilized by memory
52 #                                  # workers (if they are part of "pattern").
53 #                                  # if not specified then default stress(-ng)
54 #                                  # value will be used
55 #   "options": ""                  # Optional. Additional command line options
56 #                                  # to be passed to the load generator.
57 # "vSwitch" : "OvsVanilla"         # Defines vSwitch to be used for test execution.
58 #                                  # It will override any VSWITCH option stated
59 #                                  # in configuration files or value specified
60 #                                  # on command line through --vswitch parameter.
61 # "VNF" : "QemuVirtioNet"          # Defines VNF to be used for test execution.
62 #                                  # It will override any VNF option stated
63 #                                  # in configuration files or value specified
64 #                                  # on command line through --vnf parameter.
65 # "Trafficgen" : "Dummy"           # Defines traffic generator to be used for test
66 #                                  # execution. It will override any VNF option
67 #                                  # stated in configuration files or value
68 #                                  # specified on command line through --trafficgen
69 #                                  # parameter.
70 # "Parameters" : {'TRAFFICGEN_PKT_SIZES' : (512,)},
71 #                                  # Dictionary with testcase specific configuration
72 #                                  # environment. Specified parameters will be modified
73 #                                  # before the test execution and their original values will
74 #                                  # be restored after TC finishes. This dictionary will
75 #                                  # override any values defined by TEST_PARAMS option
76 #                                  # stated in configuration files or values specified
77 #                                  # on command line through --test-params parameter.
78 # "Test Modifier": [FrameMod|Other],
79 # "Dependency": [Test_Case_Name |None],
80
81 #
82 # VPP specific macros used in TC defintions
83 #
84 VPP_P2P =   [
85                 ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
86                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
87                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
88                 ['vswitch', 'add_connection', 'int_br0', '#STEP[1][0]', '#STEP[2][0]', True],
89                 ['vswitch', 'add_connection', 'int_br0', '#STEP[2][0]', '#STEP[1][0]', True],
90                 ['trafficgen', 'send_traffic', {}],
91                 ['vswitch', 'dump_connections', 'int_br0'],
92                 ['vswitch', 'del_connection', 'int_br0', '#STEP[1][0]', '#STEP[2][0]', True],
93                 ['vswitch', 'del_connection', 'int_br0', '#STEP[2][0]', '#STEP[1][0]', True],
94                 ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
95                 ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
96                 ['vswitch', 'del_switch', 'int_br0'],
97             ]
98 VPP_PVP =   [
99                 ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
100                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
101                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
102                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 3
103                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 4
104                 ['vswitch', 'add_connection', 'int_br0', '#STEP[1][0]', '#STEP[3][0]', True],
105                 ['vswitch', 'add_connection', 'int_br0', '#STEP[4][0]', '#STEP[2][0]', True],
106                 ['vswitch', 'add_connection', 'int_br0', '#STEP[2][0]', '#STEP[4][0]', True],
107                 ['vswitch', 'add_connection', 'int_br0', '#STEP[3][0]', '#STEP[1][0]', True],
108                 ['vnf', 'start'],
109                 ['trafficgen', 'send_traffic', {}],
110                 ['vnf', 'stop'],
111                 ['vswitch', 'dump_connections', 'int_br0'],
112                 ['vswitch', 'del_connection', 'int_br0', '#STEP[1][0]', '#STEP[3][0]', True],
113                 ['vswitch', 'del_connection', 'int_br0', '#STEP[4][0]', '#STEP[2][0]', True],
114                 ['vswitch', 'del_connection', 'int_br0', '#STEP[2][0]', '#STEP[4][0]', True],
115                 ['vswitch', 'del_connection', 'int_br0', '#STEP[3][0]', '#STEP[1][0]', True],
116                 ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
117                 ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
118                 ['vswitch', 'del_port', 'int_br0', '#STEP[3][0]'],
119                 ['vswitch', 'del_port', 'int_br0', '#STEP[4][0]'],
120                 ['vswitch', 'del_switch', 'int_br0'],
121             ]
122 VPP_PVVP =   [
123                 ['vswitch', 'add_switch', 'int_br0'],           # STEP 0
124                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 1
125                 ['vswitch', 'add_phy_port', 'int_br0'],         # STEP 2
126                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 3
127                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 4
128                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 5
129                 ['vswitch', 'add_vport', 'int_br0'],            # STEP 6
130                 ['vswitch', 'add_connection', 'int_br0', '#STEP[1][0]', '#STEP[3][0]', True],
131                 ['vswitch', 'add_connection', 'int_br0', '#STEP[4][0]', '#STEP[5][0]', True],
132                 ['vswitch', 'add_connection', 'int_br0', '#STEP[6][0]', '#STEP[2][0]', True],
133                 ['vswitch', 'add_connection', 'int_br0', '#STEP[2][0]', '#STEP[6][0]', True],
134                 ['vswitch', 'add_connection', 'int_br0', '#STEP[5][0]', '#STEP[4][0]', True],
135                 ['vswitch', 'add_connection', 'int_br0', '#STEP[3][0]', '#STEP[1][0]', True],
136                 ['vnf1', 'start'],
137                 ['vnf2', 'start'],
138                 ['trafficgen', 'send_traffic', {}],
139                 ['vnf2', 'stop'],
140                 ['vnf1', 'stop'],
141                 ['vswitch', 'dump_connections', 'int_br0'],
142                 ['vswitch', 'del_connection', 'int_br0', '#STEP[1][0]', '#STEP[3][0]', True],
143                 ['vswitch', 'del_connection', 'int_br0', '#STEP[4][0]', '#STEP[5][0]', True],
144                 ['vswitch', 'del_connection', 'int_br0', '#STEP[6][0]', '#STEP[2][0]', True],
145                 ['vswitch', 'del_connection', 'int_br0', '#STEP[2][0]', '#STEP[6][0]', True],
146                 ['vswitch', 'del_connection', 'int_br0', '#STEP[5][0]', '#STEP[4][0]', True],
147                 ['vswitch', 'del_connection', 'int_br0', '#STEP[3][0]', '#STEP[1][0]', True],
148                 ['vswitch', 'del_port', 'int_br0', '#STEP[1][0]'],
149                 ['vswitch', 'del_port', 'int_br0', '#STEP[2][0]'],
150                 ['vswitch', 'del_port', 'int_br0', '#STEP[3][0]'],
151                 ['vswitch', 'del_port', 'int_br0', '#STEP[4][0]'],
152                 ['vswitch', 'del_port', 'int_br0', '#STEP[5][0]'],
153                 ['vswitch', 'del_port', 'int_br0', '#STEP[6][0]'],
154                 ['vswitch', 'del_switch', 'int_br0'],
155             ]
156
157 #
158 # Generic performance TC definitions
159 #
160 PERFORMANCE_TESTS = [
161     {
162         "Name": "phy2phy_tput",
163         "Deployment": "p2p",
164         "Description": "LTD.Throughput.RFC2544.PacketLossRatio",
165         "Parameters" : {
166             "TRAFFIC" : {
167                 "traffic_type" : "rfc2544_throughput",
168             },
169         },
170     },
171     {
172         "Name": "phy2phy_forwarding",
173         "Deployment": "p2p",
174         "Description": "LTD.Forwarding.RFC2889.MaxForwardingRate",
175         "Parameters" : {
176             "TRAFFIC" : {
177                 "traffic_type" : "rfc2889_forwarding",
178             },
179         },
180     },
181     {
182         "Name": "phy2phy_learning",
183         "Deployment": "p2p",
184         "Description": "LTD.AddrLearning.RFC2889.AddrLearningRate",
185         "Parameters" : {
186             "TRAFFIC" : {
187                 "traffic_type" : "rfc2889_learning",
188             },
189         },
190     },
191     {
192         "Name": "phy2phy_caching",
193         "Deployment": "p2p",
194         "Description": "LTD.AddrCaching.RFC2889.AddrCachingCapacity",
195         "Parameters" : {
196             "TRAFFIC" : {
197                 "traffic_type" : "rfc2889_caching",
198             },
199         },
200     },
201     {
202         "Name": "back2back",
203         "Deployment": "p2p",
204         "Description": "LTD.Throughput.RFC2544.BackToBackFrames",
205         "Parameters" : {
206             "TRAFFIC" : {
207                 "traffic_type" : "rfc2544_back2back",
208             },
209         },
210     },
211     {
212         "Name": "phy2phy_tput_mod_vlan",
213         "Deployment": "p2p",
214         "Frame Modification": "vlan",
215         "Description": "LTD.Throughput.RFC2544.PacketLossRatioFrameModification",
216         "Parameters" : {
217             "TRAFFIC" : {
218                 "traffic_type" : "rfc2544_throughput",
219             },
220         },
221     },
222     {
223         "Name": "phy2phy_cont",
224         "Deployment": "p2p",
225         "Description": "Phy2Phy Continuous Stream",
226         "Parameters" : {
227             "TRAFFIC" : {
228                 "traffic_type" : "rfc2544_continuous",
229                 "frame_rate" : 100,
230             },
231         },
232     },
233     {
234         "Name": "pvp_cont",
235         "Deployment": "pvp",
236         "Description": "PVP Continuous Stream",
237         "Parameters" : {
238             "TRAFFIC" : {
239                 "traffic_type" : "rfc2544_continuous",
240                 "frame_rate" : 100,
241             },
242         },
243     },
244     {
245         "Name": "pvvp_cont",
246         "Deployment": "pvvp",
247         "Description": "PVVP Continuous Stream",
248         "Parameters" : {
249             "TRAFFIC" : {
250                 "traffic_type" : "rfc2544_continuous",
251                 "frame_rate" : 100,
252             },
253         },
254     },
255     {
256         "Name": "pvpv_cont",
257         "Deployment": "pvpv",
258         "Description": "Two VMs in parallel with Continuous Stream",
259         "Parameters" : {
260             "TRAFFIC" : {
261                 "traffic_type" : "rfc2544_continuous",
262                 "frame_rate" : 100,
263             },
264         },
265     },
266     {
267         "Name": "phy2phy_scalability",
268         "Deployment": "p2p",
269         "Description": "LTD.Scalability.Flows.RFC2544.0PacketLoss",
270         "Parameters" : {
271             "TRAFFIC" : {
272                 "traffic_type" : "rfc2544_throughput",
273                 "multistream" : "8000",
274             },
275         },
276     },
277     {
278         "Name": "pvp_tput",
279         "Deployment": "pvp",
280         "Description": "LTD.Throughput.RFC2544.PacketLossRatio",
281         "Parameters" : {
282             "TRAFFIC" : {
283                 "traffic_type" : "rfc2544_throughput",
284             },
285         },
286     },
287     {
288         "Name": "pvp_back2back",
289         "Deployment": "pvp",
290         "Description": "LTD.Throughput.RFC2544.BackToBackFrames",
291         "Parameters" : {
292             "TRAFFIC" : {
293                 "traffic_type" : "rfc2544_back2back",
294             },
295         },
296     },
297     {
298         "Name": "pvvp_tput",
299         "Collector": "cpu",
300         "Deployment": "pvvp",
301         "Description": "LTD.Throughput.RFC2544.PacketLossRatio",
302         "Parameters" : {
303             "TRAFFIC" : {
304                 "traffic_type" : "rfc2544_throughput",
305             },
306         },
307     },
308     {
309         "Name": "pvvp_back2back",
310         "Collector": "cpu",
311         "Deployment": "pvvp",
312         "Description": "LTD.Throughput.RFC2544.BackToBackFrames",
313         "Parameters" : {
314             "TRAFFIC" : {
315                 "traffic_type" : "rfc2544_back2back",
316             },
317         },
318     },
319     {
320         "Name": "phy2phy_cpu_load",
321         "Deployment": "p2p",
322         "Description": "LTD.CPU.RFC2544.0PacketLoss",
323         "Load" : {
324             "tool" : "stress-ng",
325             "load" : 100,
326             "reserved" : 4,
327             "pattern" : "c",
328         },
329         "Parameters" : {
330             "TRAFFIC" : {
331                 "traffic_type" : "rfc2544_throughput",
332             },
333         },
334     },
335     {
336         "Name": "phy2phy_mem_load",
337         "Deployment": "p2p",
338         "Description": "LTD.Memory.RFC2544.0PacketLoss",
339         "Load" : {
340             "tool" : "stress-ng",
341             "load" : 50,
342             "pattern" : "m",
343             "load_memory" : 80,
344         },
345         "Parameters" : {
346             "TRAFFIC" : {
347                 "traffic_type" : "rfc2544_throughput",
348             },
349         },
350     },
351     {
352         "Name": "phy2phy_tput_vpp",
353         "Deployment": "clean",
354         "Description": "VPP: LTD.Throughput.RFC2544.PacketLossRatio",
355         "vSwitch" : "VppDpdkVhost",
356         "Parameters" : {
357             "TRAFFIC" : {
358                 "traffic_type" : "rfc2544_throughput",
359             },
360         },
361         "TestSteps": VPP_P2P,
362     },
363     {
364         "Name": "phy2phy_cont_vpp",
365         "Deployment": "clean",
366         "Description": "VPP: Phy2Phy Continuous Stream",
367         "vSwitch" : "VppDpdkVhost",
368         "Parameters" : {
369             "TRAFFIC" : {
370                 "traffic_type" : "rfc2544_continuous",
371                 "frame_rate" : 100,
372             },
373         },
374         "TestSteps": VPP_P2P,
375     },
376     {
377         "Name": "phy2phy_back2back_vpp",
378         "Deployment": "clean",
379         "Description": "VPP: LTD.Throughput.RFC2544.BackToBackFrames",
380         "vSwitch" : "VppDpdkVhost",
381         "Parameters" : {
382             "TRAFFIC" : {
383                 "traffic_type" : "rfc2544_back2back",
384             },
385         },
386         "TestSteps": VPP_P2P,
387     },
388     {
389         "Name": "pvp_tput_vpp",
390         "Deployment": "clean",
391         "Description": "VPP: LTD.Throughput.RFC2544.PacketLossRatio",
392         "vSwitch" : "VppDpdkVhost",
393         "Parameters" : {
394             "TRAFFIC" : {
395                 "traffic_type" : "rfc2544_throughput",
396             },
397         },
398         "TestSteps": VPP_PVP,
399     },
400     {
401         "Name": "pvp_cont_vpp",
402         "Deployment": "clean",
403         "Description": "VPP: PVP Continuous Stream",
404         "vSwitch" : "VppDpdkVhost",
405         "Parameters" : {
406             "TRAFFIC" : {
407                 "traffic_type" : "rfc2544_continuous",
408             },
409         },
410         "TestSteps": VPP_PVP,
411     },
412     {
413         "Name": "pvp_back2back_vpp",
414         "Deployment": "clean",
415         "Description": "VPP: LTD.Throughput.RFC2544.BackToBackFrames",
416         "vSwitch" : "VppDpdkVhost",
417         "Parameters" : {
418             "TRAFFIC" : {
419                 "traffic_type" : "rfc2544_back2back",
420             },
421         },
422         "TestSteps": VPP_PVP,
423     },
424     {
425         "Name": "pvvp_tput_vpp",
426         "Deployment": "clean",
427         "Description": "VPP: LTD.Throughput.RFC2544.PacketLossRatio",
428         "vSwitch" : "VppDpdkVhost",
429         "Parameters" : {
430             "TRAFFIC" : {
431                 "traffic_type" : "rfc2544_throughput",
432             },
433         },
434         "TestSteps": VPP_PVVP,
435     },
436     {
437         "Name": "pvvp_cont_vpp",
438         "Deployment": "clean",
439         "Description": "VPP: PVP Continuous Stream",
440         "vSwitch" : "VppDpdkVhost",
441         "Parameters" : {
442             "TRAFFIC" : {
443                 "traffic_type" : "rfc2544_continuous",
444             },
445         },
446         "TestSteps": VPP_PVVP,
447     },
448     {
449         "Name": "pvvp_back2back_vpp",
450         "Deployment": "clean",
451         "Description": "VPP: LTD.Throughput.RFC2544.BackToBackFrames",
452         "vSwitch" : "VppDpdkVhost",
453         "Parameters" : {
454             "TRAFFIC" : {
455                 "traffic_type" : "rfc2544_back2back",
456             },
457         },
458         "TestSteps": VPP_PVVP,
459     },
460 ]