CSIT-179 IPv6 Scale - performance
[csit.git] / resources / libraries / robot / performance.robot
1 # Copyright (c) 2016 Cisco and/or its affiliates.
2 # Licensed under the Apache License, Version 2.0 (the "License");
3 # you may not use this file except in compliance with the License.
4 # You may obtain a copy of the License at:
5 #
6 #     http://www.apache.org/licenses/LICENSE-2.0
7 #
8 # Unless required by applicable law or agreed to in writing, software
9 # distributed under the License is distributed on an "AS IS" BASIS,
10 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11 # See the License for the specific language governing permissions and
12 # limitations under the License.
13
14 *** Settings ***
15 | Library | resources.libraries.python.topology.Topology
16 | Library | resources.libraries.python.NodePath
17 | Library | resources.libraries.python.InterfaceUtil
18 | Library | resources.libraries.python.TrafficGenerator
19 | Library | resources.libraries.python.TrafficGenerator.TGDropRateSearchImpl
20 | Resource | resources/libraries/robot/default.robot
21 | Resource | resources/libraries/robot/interfaces.robot
22 | Resource | resources/libraries/robot/counters.robot
23 | Resource | resources/libraries/robot/bridge_domain.robot
24 | Resource | resources/libraries/robot/l2_xconnect.robot
25 | Resource | resources/libraries/robot/ipv4.robot
26 | Resource | resources/libraries/robot/ipv6.robot
27 | Documentation | Performance suite keywords
28
29 *** Keywords ***
30 | Setup performance rate Variables
31 | | [Documentation]
32 | | ... | Setup performance linerates as Suite Variables. Variables are used
33 | | ... | as search boundaries in RFC2544 throughput search.
34 | | ...
35 | | ... | _NOTE:_ This KW sets following suite variables:
36 | | ... | - 10Ge_linerate_pps_64B - Maximum number of packet per second
37 | | ... |                           for 10GE with 64B L2 Frame.
38 | | ... | - 10Ge_linerate_pps_68B - Maximum number of packet per second
39 | | ... |                           for 10GE with 68B L2 Frame.
40 | | ... | - 10Ge_linerate_pps_72B - Maximum number of packet per second
41 | | ... |                           for 10GE with 72B L2 Frame.
42 | | ... | - 10Ge_linerate_pps_78B - Maximum number of packet per second
43 | | ... |                           for 10GE with 78B L2 Frame.
44 | | ... | - 10Ge_linerate_pps_1518B - Maximum number of packet per second
45 | | ... |                             for 10GE with 1518B L2 Frame.
46 | | ... | - 10Ge_linerate_pps_1522B - Maximum number of packet per second
47 | | ... |                             for 10GE with 1522B L2 Frame.
48 | | ... | - 10Ge_linerate_pps_1526B - Maximum number of packet per second
49 | | ... |                             for 10GE with 1526B L2 Frame.
50 | | ... | - 10Ge_linerate_pps_9000B - Maximum number of packet per second
51 | | ... |                             for 10GE with 9000B L2 Frame.
52 | | ... | - 10Ge_linerate_pps_9004B - Maximum number of packet per second
53 | | ... |                             for 10GE with 9004B L2 Frame.
54 | | ... | - 10Ge_linerate_pps_9008B - Maximum number of packet per second
55 | | ... |                             for 10GE with 9008B L2 Frame.
56 | | ... | - 10Ge_linerate_pps_IMIX_v4_1 - Maximum number of packet per second
57 | | ... |                                 for 10GE with IMIX_v4_1 profile.
58 | | ... | - 40Ge_linerate_pps_64B - Maximum number of packet per second
59 | | ... |                           for 40GE with 64B L2 Frame.
60 | | ... | - 40Ge_linerate_pps_68B - Maximum number of packet per second
61 | | ... |                           for 40GE with 68B L2 Frame.
62 | | ... | - 40Ge_linerate_pps_72B - Maximum number of packet per second
63 | | ... |                           for 40GE with 72B L2 Frame.
64 | | ... | - 40Ge_linerate_pps_78B - Maximum number of packet per second
65 | | ... |                           for 40GE with 78B L2 Frame.
66 | | ... | - 40Ge_linerate_pps_1518B - Maximum number of packet per second
67 | | ... |                             for 40GE with 1518B L2 Frame.
68 | | ... | - 40Ge_linerate_pps_1522B - Maximum number of packet per second
69 | | ... |                             for 40GE with 1522B L2 Frame.
70 | | ... | - 40Ge_linerate_pps_1526B - Maximum number of packet per second
71 | | ... |                             for 40GE with 1526B L2 Frame.
72 | | ... | - 40Ge_linerate_pps_9000B - Maximum number of packet per second
73 | | ... |                             for 40GE with 9000B L2 Frame.
74 | | ... | - 40Ge_linerate_pps_9004B - Maximum number of packet per second
75 | | ... |                             for 40GE with 9004B L2 Frame.
76 | | ... | - 40Ge_linerate_pps_9008B - Maximum number of packet per second
77 | | ... |                             for 40GE with 9008B L2 Frame.
78 | | ...
79 | | Set Suite Variable | ${10Ge_linerate_pps_64B} | 14880952
80 | | Set Suite Variable | ${10Ge_linerate_pps_68B} | 14204545
81 | | Set Suite Variable | ${10Ge_linerate_pps_72B} | 13586956
82 | | Set Suite Variable | ${10Ge_linerate_pps_78B} | 12755102
83 | | Set Suite Variable | ${10Ge_linerate_pps_1518B} | 812743
84 | | Set Suite Variable | ${10Ge_linerate_pps_1522B} | 810635
85 | | Set Suite Variable | ${10Ge_linerate_pps_9000B} | 138580
86 | | Set Suite Variable | ${10Ge_linerate_pps_9004B} | 138519
87 | | Set Suite Variable | ${10Ge_linerate_pps_9008B} | 138458
88 | | Set Suite Variable | ${10Ge_linerate_pps_IMIX_v4_1} | 3343736
89 | | Set Suite Variable | ${40Ge_linerate_pps_64B} | 59523809
90 | | Set Suite Variable | ${40Ge_linerate_pps_68B} | 56818181
91 | | Set Suite Variable | ${40Ge_linerate_pps_72B} | 54347826
92 | | Set Suite Variable | ${40Ge_linerate_pps_78B} | 51020408
93 | | Set Suite Variable | ${40Ge_linerate_pps_1518B} | 3250975
94 | | Set Suite Variable | ${40Ge_linerate_pps_1522B} | 3242542
95 | | Set Suite Variable | ${40Ge_linerate_pps_9000B} | 554323
96 | | Set Suite Variable | ${40Ge_linerate_pps_9004B} | 554078
97 | | Set Suite Variable | ${40Ge_linerate_pps_9008B} | 553832
98
99 | Get Frame Size
100 | | [Documentation]
101 | | ... | Framesize can be either integer in case of a single packet
102 | | ... | in stream, or set of packets in case of IMIX type or simmilar.
103 | | ... | This keyword returns average framesize.
104 | | ...
105 | | ... | *Arguments:*
106 | | ... | - framesize - Framesize. Type: integer or string
107 | | ...
108 | | ... | *Example:*
109 | | ...
110 | | ... | \| Get Frame Size \| IMIX_v4_1
111 | | [Arguments] | ${framesize}
112 | | Run Keyword If | '${framesize}' == 'IMIX_v4_1'
113 | | ...            | Return From Keyword | 353.83333
114 | | Return From Keyword | ${framesize}
115
116 | Setup performance global Variables
117 | | [Documentation]
118 | | ... | Setup suite Variables. Variables are used across performance testing.
119 | | ...
120 | | ... | _NOTE:_ This KW sets following suite variables:
121 | | ... | - glob_loss_acceptance - Loss acceptance treshold
122 | | ... | - glob_loss_acceptance_type - Loss acceptance treshold type
123 | | ...
124 | | Set Suite Variable | ${glob_loss_acceptance} | 0.5
125 | | Set Suite Variable | ${glob_loss_acceptance_type} | percentage
126
127 | 2-node circular Topology Variables Setup
128 | | [Documentation]
129 | | ... | Compute path for testing on two given nodes in circular
130 | | ... | topology and set corresponding suite variables.
131 | | ...
132 | | ... | _NOTE:_ This KW sets following suite variables:
133 | | ... | - tg - TG node
134 | | ... | - tg_if1 - 1st TG interface towards DUT.
135 | | ... | - tg_if2 - 2nd TG interface towards DUT.
136 | | ... | - dut1 - DUT1 node
137 | | ... | - dut1_if1 - 1st DUT interface towards TG.
138 | | ... | - dut1_if2 - 2nd DUT interface towards TG.
139 | | ...
140 | | Append Nodes | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['TG']}
141 | | Compute Path
142 | | ${tg_if1} | ${tg}= | Next Interface
143 | | ${dut1_if1} | ${dut1}= | Next Interface
144 | | ${dut1_if2} | ${dut1}= | Next Interface
145 | | ${tg_if2} | ${tg}= | Next Interface
146 | | Set Suite Variable | ${tg}
147 | | Set Suite Variable | ${tg_if1}
148 | | Set Suite Variable | ${tg_if2}
149 | | Set Suite Variable | ${dut1}
150 | | Set Suite Variable | ${dut1_if1}
151 | | Set Suite Variable | ${dut1_if2}
152
153 | 3-node circular Topology Variables Setup
154 | | [Documentation]
155 | | ... | Compute path for testing on three given nodes in circular
156 | | ... | topology and set corresponding suite variables.
157 | | ...
158 | | ... | _NOTE:_ This KW sets following suite variables:
159 | | ... | - tg - TG node
160 | | ... | - tg_if1 - TG interface towards DUT1.
161 | | ... | - tg_if2 - TG interface towards DUT2.
162 | | ... | - dut1 - DUT1 node
163 | | ... | - dut1_if1 - DUT1 interface towards TG.
164 | | ... | - dut1_if2 - DUT1 interface towards DUT2.
165 | | ... | - dut2 - DUT2 node
166 | | ... | - dut2_if1 - DUT2 interface towards TG.
167 | | ... | - dut2_if2 - DUT2 interface towards DUT1.
168 | | ...
169 | | Append Nodes | ${nodes['TG']} | ${nodes['DUT1']} | ${nodes['DUT2']}
170 | | ...          | ${nodes['TG']}
171 | | Compute Path
172 | | ${tg_if1} | ${tg}= | Next Interface
173 | | ${dut1_if1} | ${dut1}= | Next Interface
174 | | ${dut1_if2} | ${dut1}= | Next Interface
175 | | ${dut2_if1} | ${dut2}= | Next Interface
176 | | ${dut2_if2} | ${dut2}= | Next Interface
177 | | ${tg_if2} | ${tg}= | Next Interface
178 | | Set Suite Variable | ${tg}
179 | | Set Suite Variable | ${tg_if1}
180 | | Set Suite Variable | ${tg_if2}
181 | | Set Suite Variable | ${dut1}
182 | | Set Suite Variable | ${dut1_if1}
183 | | Set Suite Variable | ${dut1_if2}
184 | | Set Suite Variable | ${dut2}
185 | | Set Suite Variable | ${dut2_if1}
186 | | Set Suite Variable | ${dut2_if2}
187
188 | 2-node circular Topology Variables Setup with DUT interface model
189 | | [Documentation]
190 | | ... | Compute path for testing on two given nodes in circular topology
191 | | ... | based on interface model provided as an argument and set
192 | | ... | corresponding suite variables.
193 | | ...
194 | | ... | *Arguments:*
195 | | ... | - iface_model - Interface model. Type: string
196 | | ...
197 | | ... | _NOTE:_ This KW sets following suite variables:
198 | | ... | - tg - TG node
199 | | ... | - tg_if1 - 1st TG interface towards DUT.
200 | | ... | - tg_if2 - 2nd TG interface towards DUT.
201 | | ... | - dut1 - DUT1 node
202 | | ... | - dut1_if1 - 1st DUT interface towards TG.
203 | | ... | - dut1_if2 - 2nd DUT interface towards TG.
204 | | ...
205 | | ... | *Example:*
206 | | ...
207 | | ... | \| 2-node circular Topology Variables Setup with DUT interface model \
208 | | ... | \| Intel-X520-DA2 \|
209 | | [Arguments] | ${iface_model}
210 | | ${iface_model_list}= | Create list | ${iface_model}
211 | | Append Node | ${nodes['TG']}
212 | | Append Node | ${nodes['DUT1']} | filter_list=${iface_model_list}
213 | | Append Node | ${nodes['TG']}
214 | | Compute Path
215 | | ${tg_if1} | ${tg}= | Next Interface
216 | | ${dut1_if1} | ${dut1}= | Next Interface
217 | | ${dut1_if2} | ${dut1}= | Next Interface
218 | | ${tg_if2} | ${tg}= | Next Interface
219 | | Set Suite Variable | ${tg}
220 | | Set Suite Variable | ${tg_if1}
221 | | Set Suite Variable | ${tg_if2}
222 | | Set Suite Variable | ${dut1}
223 | | Set Suite Variable | ${dut1_if1}
224 | | Set Suite Variable | ${dut1_if2}
225
226 | 3-node circular Topology Variables Setup with DUT interface model
227 | | [Documentation]
228 | | ... | Compute path for testing on three given nodes in circular topology
229 | | ... | based on interface model provided as an argument and set
230 | | ... | corresponding suite variables.
231 | | ...
232 | | ... | *Arguments:*
233 | | ... | - iface_model - Interface model. Type: string
234 | | ...
235 | | ... | _NOTE:_ This KW sets following suite variables:
236 | | ... | - tg - TG node
237 | | ... | - tg_if1 - TG interface towards DUT1.
238 | | ... | - tg_if2 - TG interface towards DUT2.
239 | | ... | - dut1 - DUT1 node
240 | | ... | - dut1_if1 - DUT1 interface towards TG.
241 | | ... | - dut1_if2 - DUT1 interface towards DUT2.
242 | | ... | - dut2 - DUT2 node
243 | | ... | - dut2_if1 - DUT2 interface towards TG.
244 | | ... | - dut2_if2 - DUT2 interface towards DUT1.
245 | | ...
246 | | ... | *Example:*
247 | | ...
248 | | ... | \| 3-node circular Topology Variables Setup with DUT interface model \
249 | | ... | \| Intel-X520-DA2 \|
250 | | [Arguments] | ${iface_model}
251 | | ${iface_model_list}= | Create list | ${iface_model}
252 | | Append Node | ${nodes['TG']}
253 | | Append Node | ${nodes['DUT1']} | filter_list=${iface_model_list}
254 | | Append Node | ${nodes['DUT2']} | filter_list=${iface_model_list}
255 | | Append Node | ${nodes['TG']}
256 | | Compute Path
257 | | ${tg_if1} | ${tg}= | Next Interface
258 | | ${dut1_if1} | ${dut1}= | Next Interface
259 | | ${dut1_if2} | ${dut1}= | Next Interface
260 | | ${dut2_if1} | ${dut2}= | Next Interface
261 | | ${dut2_if2} | ${dut2}= | Next Interface
262 | | ${tg_if2} | ${tg}= | Next Interface
263 | | Set Suite Variable | ${tg}
264 | | Set Suite Variable | ${tg_if1}
265 | | Set Suite Variable | ${tg_if2}
266 | | Set Suite Variable | ${dut1}
267 | | Set Suite Variable | ${dut1_if1}
268 | | Set Suite Variable | ${dut1_if2}
269 | | Set Suite Variable | ${dut2}
270 | | Set Suite Variable | ${dut2_if1}
271 | | Set Suite Variable | ${dut2_if2}
272
273 | VPP interfaces in path are up in a 2-node circular topology
274 | | [Documentation]
275 | | ... | *Set UP state on VPP interfaces in path on nodes in 2-node circular
276 | | ... | topology.*
277 | | ...
278 | | Set Interface State | ${dut1} | ${dut1_if1} | up
279 | | Set Interface State | ${dut1} | ${dut1_if2} | up
280 | | Vpp Node Interfaces Ready Wait | ${dut1}
281
282 | VPP interfaces in path are up in a 3-node circular topology
283 | | [Documentation]
284 | | ... | *Set UP state on VPP interfaces in path on nodes in 3-node circular
285 | | ... | topology.*
286 | | ...
287 | | Set Interface State | ${dut1} | ${dut1_if1} | up
288 | | Set Interface State | ${dut1} | ${dut1_if2} | up
289 | | Set Interface State | ${dut2} | ${dut2_if1} | up
290 | | Set Interface State | ${dut2} | ${dut2_if2} | up
291 | | Vpp Node Interfaces Ready Wait | ${dut1}
292 | | Vpp Node Interfaces Ready Wait | ${dut2}
293
294 | IPv4 forwarding initialized in a 3-node circular topology
295 | | [Documentation]
296 | | ... | Set UP state on VPP interfaces in path on nodes in 3-node circular
297 | | ... | topology. Get the interface MAC addresses and setup ARP on all VPP
298 | | ... | interfaces. Setup IPv4 addresses with /24 prefix on DUT-TG links and
299 | | ... | /30 prefix on DUT1-DUT2 link. Set routing on both DUT nodes with
300 | | ... | prefix /24 and next hop of neighbour DUT interface IPv4 address.
301 | | ...
302 | | Set Interface State | ${dut1} | ${dut1_if1} | up
303 | | Set Interface State | ${dut1} | ${dut1_if2} | up
304 | | Set Interface State | ${dut2} | ${dut2_if1} | up
305 | | Set Interface State | ${dut2} | ${dut2_if2} | up
306 | | ${tg1_if1_mac}= | Get Interface MAC | ${tg} | ${tg_if1}
307 | | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
308 | | ${dut1_if2_mac}= | Get Interface MAC | ${dut1} | ${dut1_if2}
309 | | ${dut2_if1_mac}= | Get Interface MAC | ${dut2} | ${dut2_if1}
310 | | dut1_v4.set_arp | ${dut1_if1} | 10.10.10.2 | ${tg1_if1_mac}
311 | | dut1_v4.set_arp | ${dut1_if2} | 1.1.1.2 | ${dut2_if1_mac}
312 | | dut2_v4.set_arp | ${dut2_if1} | 1.1.1.1 | ${dut1_if2_mac}
313 | | dut2_v4.set_arp | ${dut2_if2} | 20.20.20.2 | ${tg1_if2_mac}
314 | | dut1_v4.set_ip | ${dut1_if1} | 10.10.10.1 | 24
315 | | dut1_v4.set_ip | ${dut1_if2} | 1.1.1.1 | 30
316 | | dut2_v4.set_ip | ${dut2_if1} | 1.1.1.2 | 30
317 | | dut2_v4.set_ip | ${dut2_if2} | 20.20.20.1 | 24
318 | | dut1_v4.set_route | 20.20.20.0 | 24 | 1.1.1.2 | ${dut1_if2}
319 | | dut2_v4.set_route | 10.10.10.0 | 24 | 1.1.1.1 | ${dut2_if1}
320 | | All Vpp Interfaces Ready Wait | ${nodes}
321
322 | Scale IPv4 forwarding initialized in a 3-node circular topology
323 | | [Documentation]
324 | | ... | Custom setup of IPv4 topology with scalability of ip routes on all
325 | | ... | DUT nodes in 3-node circular topology
326 | | ...
327 | | ... | *Arguments:*
328 | | ... | - ${count} - IP route count. Type: integer
329 | | ...
330 | | ... | *Return:*
331 | | ... | - No value returned
332 | | ...
333 | | ... | *Example:*
334 | | ...
335 | | ... | \| Scale IPv4 forwarding initialized in a 3-node circular topology \
336 | | ... | \| 100000 \|
337 | | [Arguments] | ${count}
338 | | Set Interface State | ${dut1} | ${dut1_if1} | up
339 | | Set Interface State | ${dut1} | ${dut1_if2} | up
340 | | Set Interface State | ${dut2} | ${dut2_if1} | up
341 | | Set Interface State | ${dut2} | ${dut2_if2} | up
342 | | ${tg1_if1_mac}= | Get Interface MAC | ${tg} | ${tg_if1}
343 | | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
344 | | ${dut1_if2_mac}= | Get Interface MAC | ${dut1} | ${dut1_if2}
345 | | ${dut2_if1_mac}= | Get Interface MAC | ${dut2} | ${dut2_if1}
346 | | Add arp on dut | ${dut1} | ${dut1_if1} | 1.1.1.1 | ${tg1_if1_mac}
347 | | Add arp on dut | ${dut1} | ${dut1_if2} | 2.2.2.2 | ${dut2_if1_mac}
348 | | Add arp on dut | ${dut2} | ${dut2_if1} | 2.2.2.1 | ${dut1_if2_mac}
349 | | Add arp on dut | ${dut2} | ${dut2_if2} | 3.3.3.1 | ${tg1_if2_mac}
350 | | IP addresses are set on interfaces | ${dut1} | ${dut1_if1} | 1.1.1.2 | 30
351 | | IP addresses are set on interfaces | ${dut1} | ${dut1_if2} | 2.2.2.1 | 30
352 | | IP addresses are set on interfaces | ${dut2} | ${dut2_if1} | 2.2.2.2 | 30
353 | | IP addresses are set on interfaces | ${dut2} | ${dut2_if2} | 3.3.3.2 | 30
354 | | Vpp Route Add | ${dut1} | 10.0.0.0 | 32 | 1.1.1.1 | ${dut1_if1}
355 | | ...           | count=${count}
356 | | Vpp Route Add | ${dut1} | 20.0.0.0 | 32 | 2.2.2.2 | ${dut1_if2}
357 | | ...           | count=${count}
358 | | Vpp Route Add | ${dut2} | 10.0.0.0 | 32 | 2.2.2.1 | ${dut2_if1}
359 | | ...           | count=${count}
360 | | Vpp Route Add | ${dut2} | 20.0.0.0 | 32 | 3.3.3.1 | ${dut2_if2}
361 | | ...           | count=${count}
362 | | All Vpp Interfaces Ready Wait | ${nodes}
363
364 | IPv6 forwarding initialized in a 3-node circular topology
365 | | [Documentation]
366 | | ... | Set UP state on VPP interfaces in path on nodes in 3-node circular
367 | | ... | topology. Get the interface MAC addresses and setup neighbour on all
368 | | ... | VPP interfaces. Setup IPv6 addresses with /128 prefixes on all
369 | | ... | interfaces. Set routing on both DUT nodes with prefix /64 and
370 | | ... | next hop of neighbour DUT interface IPv6 address.
371 | | ...
372 | | ${prefix}= | Set Variable | 64
373 | | ${tg1_if1_mac}= | Get Interface MAC | ${tg} | ${tg_if1}
374 | | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
375 | | ${dut1_if2_mac}= | Get Interface MAC | ${dut1} | ${dut1_if2}
376 | | ${dut2_if1_mac}= | Get Interface MAC | ${dut2} | ${dut2_if1}
377 | | VPP Set If IPv6 Addr | ${dut1} | ${dut1_if1} | 2001:1::1 | ${prefix}
378 | | VPP Set If IPv6 Addr | ${dut1} | ${dut1_if2} | 2001:3::1 | ${prefix}
379 | | VPP Set If IPv6 Addr | ${dut2} | ${dut2_if1} | 2001:3::2 | ${prefix}
380 | | VPP Set If IPv6 Addr | ${dut2} | ${dut2_if2} | 2001:2::1 | ${prefix}
381 | | Vpp nodes ra suppress link layer | ${nodes}
382 | | Add Ip Neighbor | ${dut1} | ${dut1_if1} | 2001:1::2 | ${tg1_if1_mac}
383 | | Add Ip Neighbor | ${dut2} | ${dut2_if2} | 2001:2::2 | ${tg1_if2_mac}
384 | | Add Ip Neighbor | ${dut1} | ${dut1_if2} | 2001:3::2 | ${dut2_if1_mac}
385 | | Add Ip Neighbor | ${dut2} | ${dut2_if1} | 2001:3::1 | ${dut1_if2_mac}
386 | | Vpp Route Add | ${dut1} | 2001:2::0 | ${prefix} | 2001:3::2 | ${dut1_if2}
387 | | Vpp Route Add | ${dut2} | 2001:1::0 | ${prefix} | 2001:3::1 | ${dut2_if1}
388
389 | Scale IPv6 forwarding initialized in a 3-node circular topology
390 | | [Documentation]
391 | | ... | Custom setup of IPv6 topology with scalability of ip routes on all
392 | | ... | DUT nodes in 3-node circular topology
393 | | ...
394 | | ... | *Arguments:*
395 | | ... | - ${count} - IP route count. Type: integer
396 | | ...
397 | | ... | *Return:*
398 | | ... | - No value returned
399 | | ...
400 | | ... | *Example:*
401 | | ...
402 | | ... | \| Scale IPv6 forwarding initialized in a 3-node circular topology \
403 | | ... | \| 100000 \|
404 | | [Arguments] | ${count}
405 | | ${subn_prefix}= | Set Variable | 64
406 | | ${host_prefix}= | Set Variable | 128
407 | | VPP Set If IPv6 Addr | ${dut1} | ${dut1_if1} | 2001:3::1 | ${subn_prefix}
408 | | VPP Set If IPv6 Addr | ${dut1} | ${dut1_if2} | 2001:4::1 | ${subn_prefix}
409 | | VPP Set If IPv6 Addr | ${dut2} | ${dut2_if1} | 2001:4::2 | ${subn_prefix}
410 | | VPP Set If IPv6 Addr | ${dut2} | ${dut2_if2} | 2001:5::1 | ${subn_prefix}
411 | | ${tg1_if1_mac}= | Get Interface MAC | ${tg} | ${tg_if1}
412 | | ${tg1_if2_mac}= | Get Interface MAC | ${tg} | ${tg_if2}
413 | | ${dut1_if2_mac}= | Get Interface MAC | ${dut1} | ${dut1_if2}
414 | | ${dut2_if1_mac}= | Get Interface MAC | ${dut2} | ${dut2_if1}
415 | | Vpp nodes ra suppress link layer | ${nodes}
416 | | Add Ip Neighbor | ${dut1} | ${dut1_if1} | 2001:3::2 | ${tg1_if1_mac}
417 | | Add Ip Neighbor | ${dut1} | ${dut1_if2} | 2001:4::2 | ${dut2_if1_mac}
418 | | Add Ip Neighbor | ${dut2} | ${dut2_if1} | 2001:4::1 | ${dut1_if2_mac}
419 | | Add Ip Neighbor | ${dut2} | ${dut2_if2} | 2001:5::2 | ${tg1_if2_mac}
420 | | Vpp Route Add | ${dut1} | 2001:2::0 | ${host_prefix} | 2001:4::2
421 | | ...           | interface=${dut1_if2} | count=${count}
422 | | Vpp Route Add | ${dut1} | 2001:1::0 | ${host_prefix} | 2001:3::2
423 | | ...           | interface=${dut1_if1} | count=${count}
424 | | Vpp Route Add | ${dut2} | 2001:1::0 | ${host_prefix} | 2001:4::1
425 | | ...           | interface=${dut2_if2} | count=${count}
426 | | Vpp Route Add | ${dut2} | 2001:2::0 | ${host_prefix} | 2001:5::2
427 | | ...           | interface=${dut2_if1} | count=${count}
428
429 | L2 xconnect initialized in a 3-node circular topology
430 | | [Documentation]
431 | | ... | Setup L2 xconnect topology by cross connecting two interfaces on
432 | | ... | each DUT. Interfaces are brought up.
433 | | ... |
434 | | L2 setup xconnect on DUT | ${dut1} | ${dut1_if1} | ${dut1_if2}
435 | | L2 setup xconnect on DUT | ${dut2} | ${dut2_if1} | ${dut2_if2}
436 | | All Vpp Interfaces Ready Wait | ${nodes}
437
438 | L2 bridge domain initialized in a 3-node circular topology
439 | | [Documentation]
440 | | ... | Setup L2 DB topology by adding two interfaces on each DUT into BD
441 | | ... | that is created automatically with index 1. Learning is enabled.
442 | | ... | Interfaces are brought up.
443 | | ... |
444 | | Vpp l2bd forwarding setup | ${dut1} | ${dut1_if1} | ${dut1_if2}
445 | | Vpp l2bd forwarding setup | ${dut2} | ${dut2_if1} | ${dut2_if2}
446 | | All Vpp Interfaces Ready Wait | ${nodes}
447
448 | 2-node Performance Suite Setup
449 | | [Documentation]
450 | | ... | Suite preparation phase that setup default startup configuration of
451 | | ... | VPP on all DUTs. Updates interfaces on all nodes and setup global
452 | | ... | variables used in test cases. Initializes traffic generator.
453 | | ...
454 | | ... | *Arguments:*
455 | | ... | - topology_type - Topology type. Type: string
456 | | ...
457 | | ... | *Example:*
458 | | ...
459 | | ... | \| 2-node Performance Suite Setup \| L2 \|
460 | | [Arguments] | ${topology_type}
461 | | Setup default startup configuration of VPP on all DUTs
462 | | Show vpp version on all DUTs
463 | | Setup performance rate Variables
464 | | Setup performance global Variables
465 | | 2-node circular Topology Variables Setup
466 | | Initialize traffic generator | ${tg} | ${tg_if1} | ${tg_if2}
467 | | ...                          | ${dut1} | ${dut1_if1}
468 | | ...                          | ${dut1} | ${dut1_if2}
469 | | ...                          | ${topology_type}
470
471 | 3-node Performance Suite Setup
472 | | [Documentation]
473 | | ... | Suite preparation phase that setup default startup configuration of
474 | | ... | VPP on all DUTs. Updates interfaces on all nodes and setup global
475 | | ... | variables used in test cases. Initializes traffic generator.
476 | | ...
477 | | ... | *Arguments:*
478 | | ... | - topology_type - Topology type. Type: string
479 | | ...
480 | | ... | *Example:*
481 | | ...
482 | | ... | \| 3-node Performance Suite Setup \| L2 \|
483 | | [Arguments] | ${topology_type}
484 | | Setup default startup configuration of VPP on all DUTs
485 | | Show vpp version on all DUTs
486 | | Setup performance rate Variables
487 | | Setup performance global Variables
488 | | 3-node circular Topology Variables Setup
489 | | Initialize traffic generator | ${tg} | ${tg_if1} | ${tg_if2}
490 | | ...                          | ${dut1} | ${dut1_if1}
491 | | ...                          | ${dut2} | ${dut2_if2}
492 | | ...                          | ${topology_type}
493
494 2-node Performance Suite Setup with DUT's NIC model
495 | | [Documentation]
496 | | ... | Suite preparation phase that setup default startup configuration of
497 | | ... | VPP on all DUTs. Updates interfaces on all nodes and setup global
498 | | ... | variables used in test cases based on interface model provided as an
499 | | ... | argument. Initializes traffic generator.
500 | | ...
501 | | ... | *Arguments:*
502 | | ... | - topology_type - Topology type. Type: string
503 | | ... | - nic_model - Interface model. Type: string
504 | | ...
505 | | ... | *Example:*
506 | | ...
507 | | ... | \| 2-node Performance Suite Setup \| L2 \| Intel-X520-DA2 \|
508 | | [Arguments] | ${topology_type} | ${nic_model}
509 | | Setup default startup configuration of VPP on all DUTs
510 | | Show vpp version on all DUTs
511 | | Setup performance rate Variables
512 | | Setup performance global Variables
513 | | 2-node circular Topology Variables Setup with DUT interface model
514 | | ... | ${nic_model}
515 | | Initialize traffic generator | ${tg} | ${tg_if1} | ${tg_if2}
516 | | ...                          | ${dut1} | ${dut1_if1}
517 | | ...                          | ${dut1} | ${dut1_if2}
518 | | ...                          | ${topology_type}
519
520 3-node Performance Suite Setup with DUT's NIC model
521 | | [Documentation]
522 | | ... | Suite preparation phase that setup default startup configuration of
523 | | ... | VPP on all DUTs. Updates interfaces on all nodes and setup global
524 | | ... | variables used in test cases based on interface model provided as an
525 | | ... | argument. Initializes traffic generator.
526 | | ...
527 | | ... | *Arguments:*
528 | | ... | - topology_type - Topology type. Type: string
529 | | ... | - nic_model - Interface model. Type: string
530 | | ...
531 | | ... | *Example:*
532 | | ...
533 | | ... | \| 3-node Performance Suite Setup \| L2 \| Intel-X520-DA2 \|
534 | | [Arguments] | ${topology_type} | ${nic_model}
535 | | Setup default startup configuration of VPP on all DUTs
536 | | Show vpp version on all DUTs
537 | | Setup performance rate Variables
538 | | Setup performance global Variables
539 | | 3-node circular Topology Variables Setup with DUT interface model
540 | | ... | ${nic_model}
541 | | Initialize traffic generator | ${tg} | ${tg_if1} | ${tg_if2}
542 | | ...                          | ${dut1} | ${dut1_if1}
543 | | ...                          | ${dut2} | ${dut2_if2}
544 | | ...                          | ${topology_type}
545
546 | 3-node Performance Suite Teardown
547 | | [Documentation]
548 | | ... | Suite teardown phase with traffic generator teardown.
549 | | ...
550 | | Teardown traffic generator | ${tg}
551
552 | Find NDR using linear search and pps
553 | | [Documentation]
554 | | ... | Find throughput by using RFC2544 linear search with non drop rate.
555 | | ...
556 | | ... | *Arguments:*
557 | | ... | - framesize - L2 Frame Size [B]. Type: integer
558 | | ... | - start_rate - Initial start rate [pps]. Type: float
559 | | ... | - step_rate - Step of linear search [pps]. Type: float
560 | | ... | - topology_type - Topology type. Type: string
561 | | ... | - min_rate - Lower limit of search [pps]. Type: float
562 | | ... | - max_rate - Upper limit of search [pps]. Type: float
563 | | ...
564 | | ... | *Return:*
565 | | ... | - No value returned
566 | | ...
567 | | ... | *Example:*
568 | | ...
569 | | ... | \| Find NDR using linear search and pps \| 64 \| 5000000 \| \
570 | | ... | \| 100000 \| 3-node-IPv4 \| 100000 \| 14880952
571 | | [Arguments] | ${framesize} | ${start_rate} | ${step_rate}
572 | | ...         | ${topology_type} | ${min_rate} | ${max_rate}
573 | | ${duration}= | Set Variable | 10
574 | | Set Duration | ${duration}
575 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
576 | | Set Search Linear Step | ${step_rate}
577 | | Set Search Frame Size | ${framesize}
578 | | Set Search Rate Type pps
579 | | Linear Search | ${start_rate} | ${topology_type}
580 | | ${rate_per_stream} | ${latency}= | Verify Search Result
581 | | Display result of NDR search | ${rate_per_stream} | ${framesize} | 2
582 | | ...                          | ${latency}
583 | | Traffic should pass with no loss | ${duration} | ${rate_per_stream}pps
584 | | ...                              | ${framesize} | ${topology_type}
585 | | ...                              | fail_on_loss=${False}
586
587 | Find PDR using linear search and pps
588 | | [Documentation]
589 | | ... | Find throughput by using RFC2544 linear search with partial drop rate
590 | | ... | with PDR threshold and type specified by parameter.
591 | | ...
592 | | ... | *Arguments:*
593 | | ... | - framesize - L2 Frame Size [B]. Type: integer
594 | | ... | - start_rate - Initial start rate [pps]. Type: float
595 | | ... | - step_rate - Step of linear search [pps]. Type: float
596 | | ... | - topology_type - Topology type. Type: string
597 | | ... | - min_rate - Lower limit of search [pps]. Type: float
598 | | ... | - max_rate - Upper limit of search [pps]. Type: float
599 | | ... | - loss_acceptance - Accepted loss during search. Type: float
600 | | ... | - loss_acceptance_type - Percentage or frames. Type: string
601 | | ...
602 | | ... | *Example:*
603 | | ...
604 | | ... | \| Find PDR using linear search and pps \| 64 \| 5000000 \
605 | | ... | \| 100000 \| 3-node-IPv4 \| 100000 \| 14880952 \| 0.5 \| percentage
606 | | [Arguments] | ${framesize} | ${start_rate} | ${step_rate}
607 | | ...         | ${topology_type} | ${min_rate} | ${max_rate}
608 | | ...         | ${loss_acceptance}=0 | ${loss_acceptance_type}='frames'
609 | | ${duration}= | Set Variable | 10
610 | | Set Duration | ${duration}
611 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
612 | | Set Search Linear Step | ${step_rate}
613 | | Set Search Frame Size | ${framesize}
614 | | Set Search Rate Type pps
615 | | Set Loss Acceptance | ${loss_acceptance}
616 | | Run Keyword If | '${loss_acceptance_type}' == 'percentage'
617 | | ...            | Set Loss Acceptance Type Percentage
618 | | Linear Search | ${start_rate} | ${topology_type}
619 | | ${rate_per_stream} | ${latency}= | Verify Search Result
620 | | Display result of PDR search | ${rate_per_stream} | ${framesize} | 2
621 | | ...                          | ${loss_acceptance} | ${loss_acceptance_type}
622 | | ...                          | ${latency}
623 | | Traffic should pass with partial loss | ${duration} | ${rate_per_stream}pps
624 | | ...                                   | ${framesize} | ${topology_type}
625 | | ...                                   | ${loss_acceptance}
626 | | ...                                   | ${loss_acceptance_type}
627 | | ...                                   | fail_on_loss=${False}
628
629 | Find NDR using binary search and pps
630 | | [Documentation]
631 | | ... | Find throughput by using RFC2544 binary search with non drop rate.
632 | | ...
633 | | ... | *Arguments:*
634 | | ... | - framesize - L2 Frame Size [B]. Type: integer
635 | | ... | - binary_min - Lower boundary of search [pps]. Type: float
636 | | ... | - binary_max - Upper boundary of search [pps]. Type: float
637 | | ... | - topology_type - Topology type. Type: string
638 | | ... | - min_rate - Lower limit of search [pps]. Type: float
639 | | ... | - max_rate - Upper limit of search [pps]. Type: float
640 | | ... | - threshold - Threshold to stop search [pps]. Type: integer
641 | | ...
642 | | ... | *Example:*
643 | | ...
644 | | ... | \| Find NDR using binary search and pps \| 64 \| 6000000 \
645 | | ... | \| 12000000 \| 3-node-IPv4 \| 100000 \| 14880952 \| 50000
646 | | [Arguments] | ${framesize} | ${binary_min} | ${binary_max}
647 | | ...         | ${topology_type} | ${min_rate} | ${max_rate} | ${threshold}
648 | | ${duration}= | Set Variable | 10
649 | | Set Duration | ${duration}
650 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
651 | | Set Search Frame Size | ${framesize}
652 | | Set Search Rate Type pps
653 | | Set Binary Convergence Threshold | ${threshold}
654 | | Binary Search | ${binary_min} | ${binary_max} | ${topology_type}
655 | | ${rate_per_stream} | ${latency}= | Verify Search Result
656 | | Display result of NDR search | ${rate_per_stream} | ${framesize} | 2
657 | | ...                          | ${latency}
658 | | Traffic should pass with no loss | ${duration} | ${rate_per_stream}pps
659 | | ...                              | ${framesize} | ${topology_type}
660 | | ...                              | fail_on_loss=${False}
661
662 | Find PDR using binary search and pps
663 | | [Documentation]
664 | | ... | Find throughput by using RFC2544 binary search with partial drop rate
665 | | ... | with PDR threshold and type specified by parameter.
666 | | ...
667 | | ... | *Arguments:*
668 | | ... | - framesize - L2 Frame Size [B]. Type: integer
669 | | ... | - binary_min - Lower boundary of search [pps]. Type: float
670 | | ... | - binary_max - Upper boundary of search [pps]. Type: float
671 | | ... | - topology_type - Topology type. Type: string
672 | | ... | - min_rate - Lower limit of search [pps]. Type: float
673 | | ... | - max_rate - Upper limit of search [pps]. Type: float
674 | | ... | - threshold - Threshold to stop search [pps]. Type: integer
675 | | ... | - loss_acceptance - Accepted loss during search. Type: float
676 | | ... | - loss_acceptance_type - Percentage or frames. Type: string
677 | | ...
678 | | ... | *Example:*
679 | | ...
680 | | ... | \| Find PDR using binary search and pps \| 64 \| 6000000 \
681 | | ... | \| 12000000 \| 3-node-IPv4 \| 100000 \| 14880952 \| 50000 \| 0.5 \
682 | | ... | \| percentage
683 | | [Arguments] | ${framesize} | ${binary_min} | ${binary_max}
684 | | ...         | ${topology_type} | ${min_rate} | ${max_rate} | ${threshold}
685 | | ...         | ${loss_acceptance}=0 | ${loss_acceptance_type}='frames'
686 | | ${duration}= | Set Variable | 10
687 | | Set Duration | ${duration}
688 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
689 | | Set Search Frame Size | ${framesize}
690 | | Set Search Rate Type pps
691 | | Set Loss Acceptance | ${loss_acceptance}
692 | | Run Keyword If | '${loss_acceptance_type}' == 'percentage'
693 | | ...            | Set Loss Acceptance Type Percentage
694 | | Set Binary Convergence Threshold | ${threshold}
695 | | Binary Search | ${binary_min} | ${binary_max} | ${topology_type}
696 | | ${rate_per_stream} | ${latency}= | Verify Search Result
697 | | Display result of PDR search | ${rate_per_stream} | ${framesize} | 2
698 | | ...                          | ${loss_acceptance} | ${loss_acceptance_type}
699 | | ...                          | ${latency}
700 | | Traffic should pass with partial loss | ${duration} | ${rate_per_stream}pps
701 | | ...                                   | ${framesize} | ${topology_type}
702 | | ...                                   | ${loss_acceptance}
703 | | ...                                   | ${loss_acceptance_type}
704 | | ...                                   | fail_on_loss=${False}
705
706 | Find NDR using combined search and pps
707 | | [Documentation]
708 | | ... | Find throughput by using RFC2544 combined search (linear+binary) with
709 | | ... | non drop rate.
710 | | ...
711 | | ... | *Arguments:*
712 | | ... | - framesize - L2 Frame Size [B]. Type: integer
713 | | ... | - start_rate - Initial start rate [pps]. Type: float
714 | | ... | - step_rate - Step of linear search [pps]. Type: float
715 | | ... | - topology_type - Topology type. Type: string
716 | | ... | - min_rate - Lower limit of search [pps]. Type: float
717 | | ... | - max_rate - Upper limit of search [pps]. Type: float
718 | | ... | - threshold - Threshold to stop search [pps]. Type: integer
719 | | ...
720 | | ... | *Example:*
721 | | ...
722 | | ... | \| Find NDR using combined search and pps \| 64 \| 5000000 \
723 | | ... | \| 100000 \| 3-node-IPv4 \| 100000 \| 14880952 \| 5000
724 | | [Arguments] | ${framesize} | ${start_rate} | ${step_rate}
725 | | ...         | ${topology_type} | ${min_rate} | ${max_rate} | ${threshold}
726 | | ${duration}= | Set Variable | 10
727 | | Set Duration | ${duration}
728 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
729 | | Set Search Linear Step | ${step_rate}
730 | | Set Search Frame Size | ${framesize}
731 | | Set Search Rate Type pps
732 | | Set Binary Convergence Threshold | ${threshold}
733 | | Combined Search | ${start_rate} | ${topology_type}
734 | | ${rate_per_stream} | ${latency}= | Verify Search Result
735 | | Display result of NDR search | ${rate_per_stream} | ${framesize} | 2
736 | | ...                          | ${latency}
737 | | Traffic should pass with no loss | ${duration} | ${rate_per_stream}pps
738 | | ...                              | ${framesize} | ${topology_type}
739 | | ...                              | fail_on_loss=${False}
740
741 | Find PDR using combined search and pps
742 | | [Documentation]
743 | | ... | Find throughput by using RFC2544 combined search (linear+binary) with
744 | | ... | partial drop rate with PDR threshold and type specified by parameter.
745 | | ...
746 | | ... | *Arguments:*
747 | | ... | - framesize - L2 Frame Size [B]. Type: integer
748 | | ... | - start_rate - Initial start rate [pps]. Type: float
749 | | ... | - step_rate - Step of linear search [pps]. Type: float
750 | | ... | - topology_type - Topology type. Type: string
751 | | ... | - min_rate - Lower limit of search [pps]. Type: float
752 | | ... | - max_rate - Upper limit of search [pps]. Type: float
753 | | ... | - threshold - Threshold to stop search [pps]. Type: integer
754 | | ... | - loss_acceptance - Accepted loss during search. Type: float
755 | | ... | - loss_acceptance_type - Percentage or frames. Type: string
756 | | ...
757 | | ... | *Example:*
758 | | ...
759 | | ... | \| Find PDR using combined search and pps \| 64 \| 5000000 \
760 | | ... | \| 100000 \| 3-node-IPv4 \| 100000 \| 14880952 \| 5000 \| 0.5 \
761 | | ... | \| percentage
762 | | [Arguments] | ${framesize} | ${start_rate} | ${step_rate}
763 | | ...         | ${topology_type} | ${min_rate} | ${max_rate} | ${threshold}
764 | | ...         | ${loss_acceptance}=0 | ${loss_acceptance_type}='frames'
765 | | ${duration}= | Set Variable | 10
766 | | Set Duration | ${duration}
767 | | Set Search Rate Boundaries | ${max_rate} | ${min_rate}
768 | | Set Search Linear Step | ${step_rate}
769 | | Set Search Frame Size | ${framesize}
770 | | Set Search Rate Type pps
771 | | Set Loss Acceptance | ${loss_acceptance}
772 | | Run Keyword If | '${loss_acceptance_type}' == 'percentage'
773 | | ...            | Set Loss Acceptance Type Percentage
774 | | Set Binary Convergence Threshold | ${threshold}
775 | | Combined Search | ${start_rate} | ${topology_type}
776 | | ${rate_per_stream} | ${latency}= | Verify Search Result
777 | | Display result of PDR search | ${rate_per_stream} | ${framesize} | 2
778 | | ...                          | ${loss_acceptance} | ${loss_acceptance_type}
779 | | ...                          | ${latency}
780 | | Traffic should pass with partial loss | ${duration} | ${rate_per_stream}pps
781 | | ...                                   | ${framesize} | ${topology_type}
782 | | ...                                   | ${loss_acceptance}
783 | | ...                                   | ${loss_acceptance_type}
784 | | ...                                   | fail_on_loss=${False}
785
786 | Display result of NDR search
787 | | [Documentation]
788 | | ... | Display result of NDR search in packet per seconds (total and per
789 | | ... | stream) and Gbps total bandwidth with untagged packet.
790 | | ... | Througput is calculated as:
791 | | ... | Measured rate per stream * Total number of streams
792 | | ... | Bandwidth is calculated as:
793 | | ... | (Througput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
794 | | ...
795 | | ... | *Arguments:*
796 | | ... | - rate_per_stream - Measured rate per stream [pps]. Type: string
797 | | ... | - framesize - L2 Frame Size [B]. Type: integer
798 | | ... | - nr_streams - Total number of streams. Type: integer
799 | | ... | - latency - Latency stats. Type: dictionary
800 | | ...
801 | | ... | *Example:*
802 | | ...
803 | | ... | \| Display result of NDR search \| 4400000 \| 64 \| 2 \
804 | | ... | \| (0, 10/10/10) \|
805 | | [Arguments] | ${rate_per_stream} | ${framesize} | ${nr_streams}
806 | | ...         | ${latency}
807 | | ${framesize}= | Get Frame Size | ${framesize}
808 | | ${rate_total}= | Evaluate | ${rate_per_stream}*${nr_streams}
809 | | ${bandwidth_total}= | Evaluate | ${rate_total}*(${framesize}+20)*8/(10**9)
810 | | Set Test Message | FINAL_RATE: ${rate_total} pps
811 | | Set Test Message | (${nr_streams}x ${rate_per_stream} pps)
812 | | ...              | append=yes
813 | | Set Test Message | ${\n}FINAL_BANDWIDTH: ${bandwidth_total} Gbps (untagged)
814 | | ...              | append=yes
815 | | :FOR | ${idx} | ${lat} | IN ENUMERATE | @{latency}
816 | | | Set Test Message | ${\n}LATENCY_STREAM_${idx}: ${lat} usec (min/avg/max)
817 | | ...                | append=yes
818
819 | Display result of PDR search
820 | | [Documentation]
821 | | ... | Display result of PDR search in packet per seconds (total and per
822 | | ... | stream) and Gbps total bandwidth with untagged packet.
823 | | ... | Througput is calculated as:
824 | | ... | Measured rate per stream * Total number of streams
825 | | ... | Bandwidth is calculated as:
826 | | ... | (Througput * (L2 Frame Size + IPG) * 8) / Max bitrate of NIC
827 | | ...
828 | | ... | *Arguments:*
829 | | ... | - rate_per_stream - Measured rate per stream [pps]. Type: string
830 | | ... | - framesize - L2 Frame Size [B]. Type: integer
831 | | ... | - nr_streams - Total number of streams. Type: integer
832 | | ... | - loss_acceptance - Accepted loss during search. Type: float
833 | | ... | - loss_acceptance_type - Percentage or frames. Type: string
834 | | ... | - latency - Latency stats. Type: dictionary
835 | | ...
836 | | ... | *Example:*
837 | | ...
838 | | ... | \| Display result of PDR search \| 4400000 \| 64 \| 2 \| 0.5 \
839 | | ... | \| percentage \| (0, 10/10/10) \|
840 | | [Arguments] | ${rate_per_stream} | ${framesize} | ${nr_streams}
841 | | ...         | ${loss_acceptance} | ${loss_acceptance_type} | ${latency}
842 | | ${framesize}= | Get Frame Size | ${framesize}
843 | | ${rate_total}= | Evaluate | ${rate_per_stream}*${nr_streams}
844 | | ${bandwidth_total}= | Evaluate | ${rate_total}*(${framesize}+20)*8/(10**9)
845 | | Set Test Message | FINAL_RATE: ${rate_total} pps
846 | | Set Test Message | (${nr_streams}x ${rate_per_stream} pps)
847 | | ...              | append=yes
848 | | Set Test Message | ${\n}FINAL_BANDWIDTH: ${bandwidth_total} Gbps (untagged)
849 | | ...              | append=yes
850 | | :FOR | ${idx} | ${lat} | IN ENUMERATE | @{latency}
851 | | | Set Test Message | ${\n}LATENCY_STREAM_${idx}: ${lat} usec (min/avg/max)
852 | | ...                | append=yes
853 | | Set Test Message | ${\n}LOSS_ACCEPTANCE: ${loss_acceptance} ${loss_acceptance_type}
854 | | ...              | append=yes
855
856 | Traffic should pass with no loss
857 | | [Documentation]
858 | | ... | Send traffic at specified rate. No packet loss is accepted at loss
859 | | ... | evaluation.
860 | | ...
861 | | ... | *Arguments:*
862 | | ... | - duration - Duration of traffic run [s]. Type: integer
863 | | ... | - rate - Rate for sending packets. Type: string
864 | | ... | - framesize - L2 Frame Size [B]. Type: integer
865 | | ... | - topology_type - Topology type. Type: string
866 | | ...
867 | | ... | *Example:*
868 | | ...
869 | | ... | \| Traffic should pass with no loss \| 10 \| 4.0mpps \| 64 \
870 | | ... | \| 3-node-IPv4
871 | | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
872 | | ...         | ${fail_on_loss}=${True}
873 | | Clear and show runtime counters with running traffic | ${duration}
874 | | ...  | ${rate} | ${framesize} | ${topology_type}
875 | | Clear all counters on all DUTs
876 | | Send traffic on tg | ${duration} | ${rate} | ${framesize}
877 | | ...                | ${topology_type} | warmup_time=0
878 | | Show statistics on all DUTs
879 | | Run Keyword If | ${fail_on_loss} | No traffic loss occurred
880
881 | Traffic should pass with partial loss
882 | | [Documentation]
883 | | ... | Send traffic at specified rate. Partial packet loss is accepted
884 | | ... | within loss acceptance value specified as argument.
885 | | ...
886 | | ... | *Arguments:*
887 | | ... | - duration - Duration of traffic run [s]. Type: integer
888 | | ... | - rate - Rate for sending packets. Type: string
889 | | ... | - framesize - L2 Frame Size [B]. Type: integer
890 | | ... | - topology_type - Topology type. Type: string
891 | | ... | - loss_acceptance - Accepted loss during search. Type: float
892 | | ... | - loss_acceptance_type - Percentage or frames. Type: string
893 | | ...
894 | | ... | *Example:*
895 | | ...
896 | | ... | \| Traffic should pass with partial loss \| 10 \| 4.0mpps \| 64 \
897 | | ... | \| 3-node-IPv4 \| 0.5 \| percentage
898 | | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
899 | | ...         | ${loss_acceptance} | ${loss_acceptance_type}
900 | | ...         | ${fail_on_loss}=${True}
901 | | Clear and show runtime counters with running traffic | ${duration}
902 | | ...  | ${rate} | ${framesize} | ${topology_type}
903 | | Clear all counters on all DUTs
904 | | Send traffic on tg | ${duration} | ${rate} | ${framesize}
905 | | ...                | ${topology_type} | warmup_time=0
906 | | Show statistics on all DUTs
907 | | Run Keyword If | ${fail_on_loss} | Partial traffic loss accepted
908 | | ...            | ${loss_acceptance} | ${loss_acceptance_type}
909
910 | Clear and show runtime counters with running traffic
911 | | [Documentation]
912 | | ... | Start traffic at specified rate then clear runtime counters on all
913 | | ... | DUTs. Wait for specified amount of time and capture runtime counters
914 | | ... | on all DUTs. Finally stop traffic
915 | | ...
916 | | ... | *Arguments:*
917 | | ... | - duration - Duration of traffic run [s]. Type: integer
918 | | ... | - rate - Rate for sending packets. Type: string
919 | | ... | - framesize - L2 Frame Size [B]. Type: integer
920 | | ... | - topology_type - Topology type. Type: string
921 | | ...
922 | | ... | *Example:*
923 | | ...
924 | | ... | \| Traffic should pass with partial loss \| 10 \| 4.0mpps \| 64 \
925 | | ... | \| 3-node-IPv4 \| 0.5 \| percentage
926 | | [Arguments] | ${duration} | ${rate} | ${framesize} | ${topology_type}
927 | | Send traffic on tg | -1 | ${rate} | ${framesize}
928 | | ...                | ${topology_type} | warmup_time=0 | async_call=${True}
929 | | ...                | latency=${False}
930 | | Clear runtime counters on all DUTs
931 | | Sleep | ${duration}
932 | | Show runtime counters on all DUTs
933 | | Stop traffic on tg
934
935 | Add PCI devices to DUTs from 3-node single link topology
936 | | ${dut1_if1_pci}= | Get Interface PCI Addr | ${dut1} | ${dut1_if1}
937 | | ${dut1_if2_pci}= | Get Interface PCI Addr | ${dut1} | ${dut1_if2}
938 | | ${dut2_if1_pci}= | Get Interface PCI Addr | ${dut2} | ${dut2_if1}
939 | | ${dut2_if2_pci}= | Get Interface PCI Addr | ${dut2} | ${dut2_if2}
940 | | Add PCI device | ${dut1} | ${dut1_if1_pci} | ${dut1_if2_pci}
941 | | Add PCI device | ${dut2} | ${dut2_if1_pci} | ${dut2_if2_pci}