519d5405190ef6df7dfb571627ca3a87ee8fdde1
[vswitchperf.git] / docs / to-be-reorganized / vswitchperf_ltd.rst
1 CHARACTERIZE VSWITCH PERFORMANCE FOR TELCO NFV USE CASES LEVEL TEST DESIGN
2 ==========================================================================
3
4 .. contents:: Table of Contents
5
6 1. Introduction
7 ===============
8
9 The objective of the OPNFV project titled
10 **“Characterize vSwitch Performance for Telco NFV Use Cases”**, is to
11 evaluate a virtual switch to identify its suitability for a Telco
12 Network Function Virtualization (NFV) environment. The intention of this
13 Level Test Design (LTD) document is to specify the set of tests to carry
14 out in order to objectively measure the current characteristics of a
15 virtual switch in the Network Function Virtualization Infrastructure
16 (NFVI) as well as the test pass criteria. The detailed test cases will
17 be defined in `Section 2 <#DetailsOfTheLevelTestDesign>`__, preceded by
18 the `Document identifier <#DocId>`__ and the `Scope <#Scope>`__.
19
20 This document is currently in draft form.
21
22 1.1. Document identifier
23 ------------------------
24
25 The document id will be used to uniquely
26 identify versions of the LTD. The format for the document id will be:
27 OPNFV\_vswitchperf\_LTD\_ver\_NUM\_MONTH\_YEAR\_STATUS, where by the
28 status is one of: draft, reviewed, corrected or final. The document id
29 for this version of the LTD is:
30 OPNFV\_vswitchperf\_LTD\_ver\_1.6\_Jan\_15\_DRAFT.
31
32 1.2. Scope
33 ----------
34
35 The main purpose of this project is to specify a suite of
36 performance tests in order to objectively measure the current packet
37 transfer characteristics of a virtual switch in the NFVI. The intent of
38 the project is to facilitate testing of any virtual switch. Thus, a
39 generic suite of tests shall be developed, with no hard dependencies to
40 a single implementation. In addition, the test case suite shall be
41 architecture independent.
42
43 The test cases developed in this project shall not form part of a
44 separate test framework, all of these tests may be inserted into the
45 Continuous Integration Test Framework and/or the Platform Functionality
46 Test Framework - if a vSwitch becomes a standard component of an OPNFV
47 release.
48
49 1.3. References
50 ---------------
51
52 *  `RFC 1242 Benchmarking Terminology for Network Interconnection
53    Devices <http://www.ietf.org/rfc/rfc1242.txt>`__
54 *  `RFC 2544 Benchmarking Methodology for Network Interconnect
55    Devices <http://www.ietf.org/rfc/rfc2544.txt>`__
56 *  `RFC 2285 Benchmarking Terminology for LAN Switching
57    Devices <http://www.ietf.org/rfc/rfc2285.txt>`__
58 *  `RFC 2889 Benchmarking Methodology for LAN Switching
59    Devices <http://www.ietf.org/rfc/rfc2889.txt>`__
60 *  `RFC 3918 Methodology for IP Multicast
61    Benchmarking <http://www.ietf.org/rfc/rfc3918.txt>`__
62 *  `RFC 4737 Packet Reordering
63    Metrics <http://www.ietf.org/rfc/rfc4737.txt>`__
64 *  `RFC 5481 Packet Delay Variation Applicability
65    Statement <http://www.ietf.org/rfc/rfc5481.txt>`__
66 *  `RFC 6201 Device Reset
67    Characterization <http://tools.ietf.org/html/rfc6201>`__
68
69 2. Details of the Level Test Design
70 ===================================
71
72 This section describes the features to be tested (`cf. 2.1
73 <#FeaturesToBeTested>`__), the test approach (`cf. 2.2 <#Approach>`__);
74 it also identifies the sets of test cases or scenarios (`cf. 2.3
75 <#TestIdentification>`__) along with the pass/fail criteria (`cf. 2.4
76 <#PassFail>`__) and the test deliverables (`cf. 2.5 <#TestDeliverables>`__).
77
78 2.1. Features to be tested
79 --------------------------
80
81 Characterizing virtual switches (i.e. Device Under Test (DUT) in this document)
82 includes measuring the following performance metrics:
83
84 - **Throughput** as defined by `RFC1242
85   <https://www.rfc-editor.org/rfc/rfc1242.txt>`__: The maximum rate at which
86   **none** of the offered frames are dropped by the DUT. The maximum frame
87   rate and bit rate that can be transmitted by the DUT without any error
88   should be recorded. Note there is an equivalent bit rate and a specific
89   layer at which the payloads contribute to the bits. Errors and
90   improperly formed frames or packets are dropped.
91 - **Packet delay** introduced by the DUT and its cumulative effect on
92   E2E networks. Frame delay can be measured equivalently.
93 - **Packet delay variation**: measured from the perspective of the
94   VNF/application. Packet delay variation is sometimes called "jitter".
95   However, we will avoid the term "jitter" as the term holds different
96   meaning to different groups of people. In this document we will
97   simply use the term packet delay variation. The preferred form for this
98   metric is the PDV form of delay variation defined in `RFC5481
99   <https://www.rfc-editor.org/rfc/rfc5481.txt>`__. The most relevant 
100   measurement of PDV considers the delay variation of a single user flow,
101   as this will be relevant to the size of end-system buffers to compensate
102   for delay variation. The measurement system's ability to store the 
103   delays of individual packets in the flow of interest is a key factor 
104   that determines the specific measurement method. At the outset, it is 
105   ideal to view the complete PDV distribution. Systems that can capture
106   and store packets and their delays have the freedom to calculate the 
107   reference minimum delay and to determine various quantiles of the PDV
108   distribution accurately (in post-measurement processing routines). 
109   Systems without storage must apply algorithms to calculate delay and
110   statistical measurements on the fly. For example, a system may store 
111   temporary estimates of the mimimum delay and the set of (100) packets 
112   with the longest delays during measurement (to calculate a high quantile,
113   and update these sets with new values periodically. 
114   In some cases, a limited number of delay histogram bins will be 
115   available, and the bin limits will need to be set using results from
116   repeated experiments. See section 8 of `RFC5481
117   <https://www.rfc-editor.org/rfc/rfc5481.txt>`__.
118 - **Packet loss** (within a configured waiting time at the receiver): All
119   packets sent to the DUT should be accounted for.
120 - **Burst behaviour**: measures the ability of the DUT to buffer packets.
121 - **Packet re-ordering**: measures the ability of the device under test to
122   maintain sending order throughout transfer to the destination.
123 - **Packet correctness**: packets or Frames must be well-formed, in that
124   they include all required fields, conform to length requirements, pass
125   integrity checks, etc.
126 - **Availability and capacity** of the DUT i.e. when the DUT is fully “up”
127   and connected:
128
129   - Includes power consumption of the CPU (in various power states) and
130     system.
131   - Includes CPU utilization.
132   - Includes the number of NIC interfaces supported.
133   - Includes headroom of VM workload processing cores (i.e. available
134     for applications).
135
136
137 2.2. Approach
138 ==============
139
140 In order to determine the packet transfer characteristics of a virtual
141 switch, the tests will be broken down into the following categories:
142
143 2.2.1 Test Categories
144 ----------------------
145 - **Throughput Tests** to measure the maximum forwarding rate (in
146   frames per second or fps) and bit rate (in Mbps) for a constant load
147   (as defined by `RFC1242 <https://www.rfc-editor.org/rfc/rfc1242.txt>`__)
148   without traffic loss.
149 - **Packet and Frame Delay Tests** to measure average, min and max
150   packet and frame delay for constant loads.
151 - **Stream Performance Tests** (TCP, UDP) to measure bulk data transfer
152   performance, i.e. how fast systems can send and receive data through
153   the switch.
154 - **Request/Response Performance** Tests (TCP, UDP) the measure the
155   transaction rate through the switch.
156 - **Packet Delay Tests** to understand latency distribution for
157   different packet sizes and over an extended test run to uncover
158   outliers.
159 - **Scalability Tests** to understand how the virtual switch performs
160   as the number of flows, active ports, complexity of the forwarding
161   logic's configuration... it has to deal with increases.
162 - **Control Path and Datapath Coupling** Tests, to understand how
163   closely coupled the datapath and the control path are as well as the
164   effect of this coupling on the performance of the DUT.
165 - **CPU and Memory Consumption Tests** to understand the virtual
166   switch’s footprint on the system, this includes:
167
168   * CPU utilization
169   * Cache utilization
170   * Memory footprint
171   * Time To Establish Flows Tests.
172
173 - **Noisy Neighbour Tests**, to understand the effects of resource
174   sharing on the performance of a virtual switch.
175
176 **Note:** some of the tests above can be conducted simultaneously where
177 the combined results would be insightful, for example Packet/Frame Delay
178 and Scalability.
179
180 2.2.2 Deployment Scenarios
181 --------------------------
182 The following represents possible deployments which can help to
183 determine the performance of both the virtual switch and the datapath
184 into the VNF:
185
186 Physical port → vSwitch → physical port
187 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
188   .. code-block:: console
189
190                                                             _
191        +--------------------------------------------------+  |
192        |              +--------------------+              |  |
193        |              |                    |              |  |
194        |              |                    v              |  |  Host
195        |   +--------------+            +--------------+   |  |
196        |   |   phy port   |  vSwitch   |   phy port   |   |  |
197        +---+--------------+------------+--------------+---+ _|
198                   ^                           :
199                   |                           |
200                   :                           v
201        +--------------------------------------------------+
202        |                                                  |
203        |                traffic generator                 |
204        |                                                  |
205        +--------------------------------------------------+
206
207
208 Physical port → vSwitch → VNF → vSwitch → physical port
209 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
210   .. code-block:: console
211
212                                                              _
213        +---------------------------------------------------+  |
214        |                                                   |  |
215        |   +-------------------------------------------+   |  |
216        |   |                 Application               |   |  |
217        |   +-------------------------------------------+   |  |
218        |       ^                                  :        |  |
219        |       |                                  |        |  |  Guest
220        |       :                                  v        |  |
221        |   +---------------+           +---------------+   |  |
222        |   | logical port 0|           | logical port 1|   |  |
223        +---+---------------+-----------+---------------+---+ _|
224                ^                                  :
225                |                                  |
226                :                                  v         _
227        +---+---------------+----------+---------------+---+  |
228        |   | logical port 0|          | logical port 1|   |  |
229        |   +---------------+          +---------------+   |  |
230        |       ^                                  :       |  |
231        |       |                                  |       |  |  Host
232        |       :                                  v       |  |
233        |   +--------------+            +--------------+   |  |
234        |   |   phy port   |  vSwitch   |   phy port   |   |  |
235        +---+--------------+------------+--------------+---+ _|
236                   ^                           :
237                   |                           |
238                   :                           v
239        +--------------------------------------------------+
240        |                                                  |
241        |                traffic generator                 |
242        |                                                  |
243        +--------------------------------------------------+
244
245
246 Physical port → vSwitch → VNF → vSwitch → VNF → vSwitch → physical port
247 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
248
249   .. code-block:: console
250
251                                                        _
252     +----------------------+  +----------------------+  |
253     |   Guest 1            |  |   Guest 2            |  |
254     |   +---------------+  |  |   +---------------+  |  |
255     |   |  Application  |  |  |   |  Application  |  |  |
256     |   +---------------+  |  |   +---------------+  |  |
257     |       ^       |      |  |       ^       |      |  |
258     |       |       v      |  |       |       v      |  |  Guests
259     |   +---------------+  |  |   +---------------+  |  |
260     |   | logical ports |  |  |   | logical ports |  |  |
261     |   |   0       1   |  |  |   |   0       1   |  |  |
262     +---+---------------+--+  +---+---------------+--+ _|
263             ^       :                 ^       :
264             |       |                 |       |
265             :       v                 :       v        _
266     +---+---------------+---------+---------------+--+  |
267     |   |   0       1   |         |   3       4   |  |  |
268     |   | logical ports |         | logical ports |  |  |
269     |   +---------------+         +---------------+  |  |
270     |       ^       |                 ^       |      |  |  Host
271     |       |       L-----------------+       v      |  |
272     |   +--------------+          +--------------+   |  |
273     |   |   phy ports  | vSwitch  |   phy ports  |   |  |
274     +---+--------------+----------+--------------+---+ _|
275             ^       ^                 :       :
276             |       |                 |       |
277             :       :                 v       v
278     +--------------------------------------------------+
279     |                                                  |
280     |                traffic generator                 |
281     |                                                  |
282     +--------------------------------------------------+
283
284
285 Physical port → vSwitch → VNF
286 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
287
288   .. code-block:: console
289
290                                                           _
291     +---------------------------------------------------+  |
292     |                                                   |  |
293     |   +-------------------------------------------+   |  |
294     |   |                 Application               |   |  |
295     |   +-------------------------------------------+   |  |
296     |       ^                                           |  |
297     |       |                                           |  |  Guest
298     |       :                                           |  |
299     |   +---------------+                               |  |
300     |   | logical port 0|                               |  |
301     +---+---------------+-------------------------------+ _|
302             ^
303             |
304             :                                            _
305     +---+---------------+------------------------------+  |
306     |   | logical port 0|                              |  |
307     |   +---------------+                              |  |
308     |       ^                                          |  |
309     |       |                                          |  |  Host
310     |       :                                          |  |
311     |   +--------------+                               |  |
312     |   |   phy port   |  vSwitch                      |  |
313     +---+--------------+------------ -------------- ---+ _|
314                ^
315                |
316                :
317     +--------------------------------------------------+
318     |                                                  |
319     |                traffic generator                 |
320     |                                                  |
321     +--------------------------------------------------+
322
323 VNF → vSwitch → physical port
324 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
325
326   .. code-block:: console
327
328                                                           _
329     +---------------------------------------------------+  |
330     |                                                   |  |
331     |   +-------------------------------------------+   |  |
332     |   |                 Application               |   |  |
333     |   +-------------------------------------------+   |  |
334     |                                          :        |  |
335     |                                          |        |  |  Guest
336     |                                          v        |  |
337     |                               +---------------+   |  |
338     |                               | logical port  |   |  |
339     +-------------------------------+---------------+---+ _|
340                                                :
341                                                |
342                                                v         _
343     +------------------------------+---------------+---+  |
344     |                              | logical port  |   |  |
345     |                              +---------------+   |  |
346     |                                          :       |  |
347     |                                          |       |  |  Host
348     |                                          v       |  |
349     |                               +--------------+   |  |
350     |                     vSwitch   |   phy port   |   |  |
351     +-------------------------------+--------------+---+ _|
352                                            :
353                                            |
354                                            v
355     +--------------------------------------------------+
356     |                                                  |
357     |                traffic generator                 |
358     |                                                  |
359     +--------------------------------------------------+
360
361 VNF → vSwitch → VNF → vSwitch
362 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
363
364   .. code-block:: console
365
366                                                              _
367     +-------------------------+  +-------------------------+  |
368     |   Guest 1               |  |   Guest 2               |  |
369     |   +-----------------+   |  |   +-----------------+   |  |
370     |   |   Application   |   |  |   |   Application   |   |  |
371     |   +-----------------+   |  |   +-----------------+   |  |
372     |                :        |  |       ^                 |  |
373     |                |        |  |       |                 |  |  Guest
374     |                v        |  |       :                 |  |
375     |     +---------------+   |  |   +---------------+     |  |
376     |     | logical port 0|   |  |   | logical port 0|     |  |
377     +-----+---------------+---+  +---+---------------+-----+ _|
378                     :                    ^
379                     |                    |
380                     v                    :                    _
381     +----+---------------+------------+---------------+-----+  |
382     |    |     port 0    |            |     port 1    |     |  |
383     |    +---------------+            +---------------+     |  |
384     |              :                    ^                   |  |
385     |              |                    |                   |  |  Host
386     |              +--------------------+                   |  |
387     |                                                       |  |
388     |                     vswitch                           |  |
389     +-------------------------------------------------------+ _|
390
391 HOST 1(Physical port → virtual switch → VNF → virtual switch →
392 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
393 Physical port) → HOST 2(Physical port → virtual switch → VNF →
394 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
395 virtual switch → Physical port)
396 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
397
398   .. code-block:: console
399
400                                                        _
401     +----------------------+  +----------------------+  |
402     |   Guest 1            |  |   Guest 2            |  |
403     |   +---------------+  |  |   +---------------+  |  |
404     |   |  Application  |  |  |   |  Application  |  |  |
405     |   +---------------+  |  |   +---------------+  |  |
406     |       ^       |      |  |       ^       |      |  |
407     |       |       v      |  |       |       v      |  |  Guests
408     |   +---------------+  |  |   +---------------+  |  |
409     |   | logical ports |  |  |   | logical ports |  |  |
410     |   |   0       1   |  |  |   |   0       1   |  |  |
411     +---+---------------+--+  +---+---------------+--+ _|
412             ^       :                 ^       :
413             |       |                 |       |
414             :       v                 :       v        _
415     +---+---------------+--+  +---+---------------+--+  |
416     |   |   0       1   |  |  |   |   3       4   |  |  |
417     |   | logical ports |  |  |   | logical ports |  |  |
418     |   +---------------+  |  |   +---------------+  |  |
419     |       ^       |      |  |       ^       |      |  |  Hosts
420     |       |       v      |  |       |       v      |  |
421     |   +--------------+   |  |   +--------------+   |  |
422     |   |   phy ports  |   |  |   |   phy ports  |   |  |
423     +---+--------------+---+  +---+--------------+---+ _|
424             ^       :                 :       :
425             |       +-----------------+       |
426             :                                 v
427     +--------------------------------------------------+
428     |                                                  |
429     |                traffic generator                 |
430     |                                                  |
431     +--------------------------------------------------+
432
433
434
435 **Note:** For tests where the traffic generator and/or measurement
436 receiver are implemented on VM and connected to the virtual switch
437 through vNIC, the issues of shared resources and interactions between
438 the measurement devices and the device under test must be considered.
439
440 **Note:** Some RFC 2889 tests require a full-mesh sending and receiving
441 pattern involving more than two ports. This possibility is illustrated in the
442 Physical port → vSwitch → VNF → vSwitch → VNF → vSwitch → physical port
443 diagram above (with 2 sending and 2 receiving ports, though all ports
444 could be used bi-directionally).
445
446 2.2.3 General Methodology:
447 --------------------------
448 To establish the baseline performance of the virtual switch, tests would
449 initially be run with a simple workload in the VNF (the recommended
450 simple workload VNF would be `DPDK <http://www.dpdk.org/>`__'s testpmd
451 application forwarding packets in a VM or vloop\_vnf a simple kernel
452 module that forwards traffic between two network interfaces inside the
453 virtualized environment while bypassing the networking stack).
454 Subsequently, the tests would also be executed with a real Telco
455 workload running in the VNF, which would exercise the virtual switch in
456 the context of higher level Telco NFV use cases, and prove that its
457 underlying characteristics and behaviour can be measured and validated.
458 Suitable real Telco workload VNFs are yet to be identified.
459
460 2.2.3.1 Default Test Parameters
461 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
462
463 The following list identifies the default parameters for suite of
464 tests:
465
466 -  Reference application: Simple forwarding or Open Source VNF.
467 -  Frame size (bytes): 64, 128, 256, 512, 1024, 1280, 1518, 2K, 4k OR
468    Packet size based on use-case (e.g. RTP 64B, 256B).
469 -  Reordering check: Tests should confirm that packets within a flow are
470    not reordered.
471 -  Duplex: Unidirectional / Bidirectional. Default: Full duplex with
472    traffic transmitting in both directions, as network traffic generally
473    does not flow in a single direction. By default the data rate of
474    transmitted traffic should be the same in both directions, please
475    note that asymmetric traffic (e.g. downlink-heavy) tests will be
476    mentioned explicitly for the relevant test cases.
477 -  Number of Flows: Default for non scalability tests is a single flow.
478    For scalability tests the goal is to test with maximum supported
479    flows but where possible will test up to 10 Million flows. Start with
480    a single flow and scale up. By default flows should be added
481    sequentially, tests that add flows simultaneously will explicitly
482    call out their flow addition behaviour. Packets are generated across
483    the flows uniformly with no burstiness.
484 -  Traffic Types: UDP, SCTP, RTP, GTP and UDP traffic.
485 -  Deployment scenarios are:
486 -  Physical → virtual switch → physical.
487 -  Physical → virtual switch → VNF → virtual switch → physical.
488 -  Physical → virtual switch → VNF → virtual switch → VNF → virtual
489    switch → physical.
490 -  Physical → virtual switch → VNF.
491 -  VNF → virtual switch → Physical.
492 -  VNF → virtual switch → VNF.
493
494 Tests MUST have these parameters unless otherwise stated. **Test cases
495 with non default parameters will be stated explicitly**.
496
497 **Note**: For throughput tests unless stated otherwise, test
498 configurations should ensure that traffic traverses the installed flows
499 through the switch, i.e. flows are installed and have an appropriate
500 time out that doesn't expire before packet transmission starts.
501
502 2.2.3.2 Flow Classification
503 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
504
505 Virtual switches classify packets into flows by processing and matching
506 particular header fields in the packet/frame and/or the input port where
507 the packets/frames arrived. The vSwitch then carries out an action on
508 the group of packets that match the classification parameters. Thus a
509 flow is considered to be a sequence of packets that have a shared set of
510 header field values or have arrived on the same port and have the same
511 action applied to them. Performance results can vary based on the
512 parameters the vSwitch uses to match for a flow. The recommended flow
513 classification parameters for L3 vSwitch performance tests are: the
514 input port, the source IP address, the destination IP address and the
515 Ethernet protocol type field. It is essential to increase the flow
516 time-out time on a vSwitch before conducting any performance tests that
517 do not measure the flow set-up time. Normally the first packet of a
518 particular flow will install the flow in the vSwitch which adds an
519 additional latency, subsequent packets of the same flow are not subject
520 to this latency if the flow is already installed on the vSwitch.
521
522 2.2.3.3 Test Priority
523 ~~~~~~~~~~~~~~~~~~~~~
524
525 Tests will be assigned a priority in order to determine which tests
526 should be implemented immediately and which tests implementations
527 can be deferred.
528
529 Priority can be of following types: - Urgent: Must be implemented
530 immediately. - High: Must be implemented in the next release. - Medium:
531 May be implemented after the release. - Low: May or may not be
532 implemented at all.
533
534 2.2.3.4 SUT Setup
535 ~~~~~~~~~~~~~~~~~
536
537 The SUT should be configured to its "default" state. The
538 SUT's configuration or set-up must not change between tests in any way
539 other than what is required to do the test. All supported protocols must
540 be configured and enabled for each test set up.
541
542 2.2.3.4.1 Port Configuration
543 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
544
545 The DUT should be configured with n ports where
546 n is a multiple of 2. Half of the ports on the DUT should be used as
547 ingress ports and the other half of the ports on the DUT should be used
548 as egress ports. Where a DUT has more than 2 ports, the ingress data
549 streams should be set-up so that they transmit packets to the egress
550 ports in sequence so that there is an even distribution of traffic
551 across ports. For example, if a DUT has 4 ports 0(ingress), 1(ingress),
552 2(egress) and 3(egress), the traffic stream directed at port 0 should
553 output a packet to port 2 followed by a packet to port 3. The traffic
554 stream directed at port 1 should also output a packet to port 2 followed
555 by a packet to port 3.
556
557 2.2.3.4.2 Frame Formats
558 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
559
560 Frame formats Layer 2 (data link layer) protocols
561 ++++++++++++++++++++++++++++++++++++++++++++++++++
562 -  Ethernet II
563
564   .. code-block:: console
565
566      +---------------------+--------------------+-----------+
567      |   Ethernet Header   |       Payload      | Check Sum |
568      +---------------------+--------------------+-----------+
569      |_____________________|____________________|___________|
570            14 Bytes            46 - 1500 Bytes      4 Bytes
571
572 Layer 3 (network layer) protocols
573 ++++++++++++++++++++++++++++++++++
574
575 -  IPv4
576
577   .. code-block:: console
578
579      +---------------------+--------------------+--------------------+-----------+
580      |   Ethernet Header   |      IP Header     |       Payload      | Check Sum |
581      +---------------------+--------------------+--------------------+-----------+
582      |_____________________|____________________|____________________|___________|
583            14 Bytes            20 bytes             26 - 1480 Bytes      4 Bytes
584
585 -  IPv6
586
587   .. code-block:: console
588
589      +---------------------+--------------------+--------------------+-----------+
590      |   Ethernet Header   |      IP Header     |       Payload      | Check Sum |
591      +---------------------+--------------------+--------------------+-----------+
592      |_____________________|____________________|____________________|___________|
593            14 Bytes            40 bytes             26 - 1460 Bytes      4 Bytes
594
595 Layer 4 (transport layer) protocols
596 ++++++++++++++++++++++++++++++++++++
597   - TCP
598   - UDP
599   - SCTP
600
601   .. code-block:: console
602
603      +---------------------+--------------------+-----------------+--------------------+-----------+
604      |   Ethernet Header   |      IP Header     | Layer 4 Header  |       Payload      | Check Sum |
605      +---------------------+--------------------+-----------------+--------------------+-----------+
606      |_____________________|____________________|_________________|____________________|___________|
607            14 Bytes            40 bytes               20 Bytes       6 - 1460 Bytes      4 Bytes
608
609 Layer 5 (application layer) protocols
610 +++++++++++++++++++++++++++++++++++++
611   - RTP
612   - GTP
613
614   .. code-block:: console
615
616      +---------------------+--------------------+-----------------+--------------------+-----------+
617      |   Ethernet Header   |      IP Header     | Layer 4 Header  |       Payload      | Check Sum |
618      +---------------------+--------------------+-----------------+--------------------+-----------+
619      |_____________________|____________________|_________________|____________________|___________|
620            14 Bytes            20 bytes               20 Bytes         Min 6 Bytes       4 Bytes
621
622
623 2.2.3.4.3 Packet Throughput
624 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
625 There is a difference between an Ethernet frame,
626 an IP packet, and a UDP datagram. In the seven-layer OSI model of
627 computer networking, packet refers to a data unit at layer 3 (network
628 layer). The correct term for a data unit at layer 2 (data link layer) is
629 a frame, and at layer 4 (transport layer) is a segment or datagram.
630
631 Important concepts related to 10GbE performance are frame rate and
632 throughput. The MAC bit rate of 10GbE, defined in the IEEE standard 802
633 .3ae, is 10 billion bits per second. Frame rate is based on the bit rate
634 and frame format definitions. Throughput, defined in IETF RFC 1242, is
635 the highest rate at which the system under test can forward the offered
636 load, without loss.
637
638 The frame rate for 10GbE is determined by a formula that divides the 10
639 billion bits per second by the preamble + frame length + inter-frame
640 gap.
641
642 The maximum frame rate is calculated using the minimum values of the
643 following parameters, as described in the IEEE 802 .3ae standard:
644
645 -  Preamble: 8 bytes \* 8 = 64 bits
646 -  Frame Length: 64 bytes (minimum) \* 8 = 512 bits
647 -  Inter-frame Gap: 12 bytes (minimum) \* 8 = 96 bits
648
649 Therefore, Maximum Frame Rate (64B Frames)
650 = MAC Transmit Bit Rate / (Preamble + Frame Length + Inter-frame Gap)
651 = 10,000,000,000 / (64 + 512 + 96)
652 = 10,000,000,000 / 672
653 = 14,880,952.38 frame per second (fps)
654
655 2.2.3.4.4 System isolation and validation
656 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
657
658 A key consideration when conducting any sort of benchmark is trying to
659 ensure the consistency and repeatability of test results between runs.
660 When benchmarking the performance of a virtual switch there are many
661 factors that can affect the consistency of results. This section
662 describes these factors and the measures that can be taken to limit
663 their effects. In addition, this section will outline some system tests
664 to validate the platform and the VNF before conducting any vSwitch
665 benchmarking tests.
666
667 System Isolation
668 ++++++++++++++++
669 When conducting a benchmarking test on any SUT, it is essential to limit
670 (and if reasonable, eliminate) any noise that may interfere with the
671 accuracy of the metrics collected by the test. This noise may be
672 introduced by other hardware or software (OS, other applications), and
673 can result in significantly varying performance metrics being collected
674 between consecutive runs of the same test. In the case of characterizing
675 the performance of a virtual switch, there are a number of configuration
676 parameters that can help increase the repeatability and stability of
677 test results, including:
678
679 -  OS/GRUB configuration:
680
681    -  maxcpus = n where n >= 0; limits the kernel to using 'n'
682       processors. Only use exactly what you need.
683    -  isolcpus: Isolate CPUs from the general scheduler. Isolate all
684       CPUs bar one which will be used by the OS.
685    -  use taskset to affinitize the forwarding application and the VNFs
686       onto isolated cores. VNFs and the vSwitch should be allocated
687       their own cores, i.e. must not share the same cores. vCPUs for the
688       VNF should be affinitized to individual cores also.
689    -  Limit the amount of background applications that are running and
690       set OS to boot to runlevel 3. Make sure to kill any unnecessary
691       system processes/daemons.
692    -  Only enable hardware that you need to use for your test – to
693       ensure there are no other interrupts on the system.
694    -  Configure NIC interrupts to only use the cores that are not
695       allocated to any other process (VNF/vSwitch).
696
697 -  NUMA configuration: Any unused sockets in a multi-socket system
698    should be disabled.
699 -  CPU pinning: The vSwitch and the VNF should each be affinitized to
700    separate logical cores using a combination of maxcpus, isolcpus and
701    taskset.
702 -  BIOS configuration: BIOS should be configured for performance where
703    an explicit option exists, sleep states should be disabled, any
704    virtualization optimization technologies should be enabled, and
705    hyperthreading should also be enabled.
706
707 System Validation
708 +++++++++++++++++
709 System validation is broken down into two sub-categories: Platform
710 validation and VNF validation. The validation test itself involves
711 verifying the forwarding capability and stability for the sub-system
712 under test. The rationale behind system validation is two fold. Firstly
713 to give a tester confidence in the stability of the platform or VNF that
714 is being tested; and secondly to provide base performance comparison
715 points to understand the overhead introduced by the virtual switch.
716
717 * Benchmark platform forwarding capability: This is an OPTIONAL test
718   used to verify the platform and measure the base performance (maximum
719   forwarding rate in fps and latency) that can be achieved by the
720   platform without a vSwitch or a VNF. The following diagram outlines
721   the set-up for benchmarking Platform forwarding capability:
722
723   .. code-block:: console
724
725                                                             __
726        +--------------------------------------------------+   |
727        |   +------------------------------------------+   |   |
728        |   |                                          |   |   |
729        |   |          l2fw or DPDK L2FWD app          |   |  Host
730        |   |                                          |   |   |
731        |   +------------------------------------------+   |   |
732        |   |                 NIC                      |   |   |
733        +---+------------------------------------------+---+ __|
734                   ^                           :
735                   |                           |
736                   :                           v
737        +--------------------------------------------------+
738        |                                                  |
739        |                traffic generator                 |
740        |                                                  |
741        +--------------------------------------------------+
742
743 * Benchmark VNF forwarding capability: This test is used to verify
744   the VNF and measure the base performance (maximum forwarding rate in
745   fps and latency) that can be achieved by the VNF without a vSwitch.
746   The performance metrics collected by this test will serve as a key
747   comparison point for NIC passthrough technologies and vSwitches. VNF
748   in this context refers to the hypervisor and the VM. The following
749   diagram outlines the set-up for benchmarking VNF forwarding
750   capability:
751
752   .. code-block:: console
753
754                                                             __
755        +--------------------------------------------------+   |
756        |   +------------------------------------------+   |   |
757        |   |                                          |   |   |
758        |   |                 VNF                      |   |   |
759        |   |                                          |   |   |
760        |   +------------------------------------------+   |   |
761        |   |          Passthrough/SR-IOV              |   |  Host
762        |   +------------------------------------------+   |   |
763        |   |                 NIC                      |   |   |
764        +---+------------------------------------------+---+ __|
765                   ^                           :
766                   |                           |
767                   :                           v
768        +--------------------------------------------------+
769        |                                                  |
770        |                traffic generator                 |
771        |                                                  |
772        +--------------------------------------------------+
773
774
775 Methodology to benchmark Platform/VNF forwarding capability
776 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
777
778 The recommended methodology for the platform/VNF validation and
779 benchmark is: - Run `RFC2889 <https://www.rfc-editor.org/rfc/rfc2289.txt>`__
780 Maximum Forwarding Rate test, this test will produce maximum
781 forwarding rate and latency results that will serve as the
782 expected values. These expected values can be used in
783 subsequent steps or compared with in subsequent validation tests. -
784 Transmit bidirectional traffic at line rate/max forwarding rate
785 (whichever is higher) for at least 72 hours, measure throughput (fps)
786 and latency. - Note: Traffic should be bidirectional. - Establish a
787 baseline forwarding rate for what the platform can achieve. - Additional
788 validation: After the test has completed for 72 hours run bidirectional
789 traffic at the maximum forwarding rate once more to see if the system is
790 still functional and measure throughput (fps) and latency. Compare the
791 measure the new obtained values with the expected values.
792
793 **NOTE 1**: How the Platform is configured for its forwarding capability
794 test (BIOS settings, GRUB configuration, runlevel...) is how the
795 platform should be configured for every test after this
796
797 **NOTE 2**: How the VNF is configured for its forwarding capability test
798 (# of vCPUs, vNICs, Memory, affinitization…) is how it should be
799 configured for every test that uses a VNF after this.
800
801 2.2.4 RFCs for testing switch performance
802 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
803
804 The starting point for defining the suite of tests for benchmarking the
805 performance of a virtual switch is to take existing RFCs and standards
806 that were designed to test their physical counterparts and adapting them
807 for testing virtual switches. The rationale behind this is to establish
808 a fair comparison between the performance of virtual and physical
809 switches. This section outlines the RFCs that are used by this
810 specification.
811
812 RFC 1242 Benchmarking Terminology for Network Interconnection
813 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
814 Devices RFC 1242 defines the terminology that is used in describing
815 performance benchmarking tests and their results. Definitions and
816 discussions covered include: Back-to-back, bridge, bridge/router,
817 constant load, data link frame size, frame loss rate, inter frame gap,
818 latency, and many more.
819
820 RFC 2544 Benchmarking Methodology for Network Interconnect Devices
821 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
822 RFC 2544 outlines a benchmarking methodology for network Interconnect
823 Devices. The methodology results in performance metrics such as latency,
824 frame loss percentage, and maximum data throughput.
825
826 In this document network “throughput” (measured in millions of frames
827 per second) is based on RFC 2544, unless otherwise noted. Frame size
828 refers to Ethernet frames ranging from smallest frames of 64 bytes to
829 largest frames of 4K bytes.
830
831 Types of tests are:
832
833 1. Throughput test defines the maximum number of frames per second
834    that can be transmitted without any error.
835
836 2. Latency test measures the time required for a frame to travel from
837    the originating device through the network to the destination device.
838    Please note that RFC2544 Latency measurement will be superseded with
839    a measurement of average latency over all successfully transferred
840    packets or frames.
841
842 3. Frame loss test measures the network’s
843    response in overload conditions - a critical indicator of the
844    network’s ability to support real-time applications in which a
845    large amount of frame loss will rapidly degrade service quality.
846
847 4. Burst test assesses the buffering capability of a switch. It
848    measures the maximum number of frames received at full line rate
849    before a frame is lost. In carrier Ethernet networks, this
850    measurement validates the excess information rate (EIR) as defined in
851    many SLAs.
852
853 5. System recovery to characterize speed of recovery from an overload
854    condition.
855
856 6. Reset to characterize speed of recovery from device or software
857    reset. This type of test has been updated by `RFC6201 <https://www.rfc-editor.org/rfc/rfc6201.txt>`__ as such,
858    the methodology defined by this specification will be that of RFC 6201.
859
860 Although not included in the defined RFC 2544 standard, another crucial
861 measurement in Ethernet networking is packet delay variation. The
862 definition set out by this specification comes from
863 `RFC5481 <https://www.rfc-editor.org/rfc/rfc5481.txt>`__.
864
865 RFC 2285 Benchmarking Terminology for LAN Switching Devices
866 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
867 RFC 2285 defines the terminology that is used to describe the
868 terminology for benchmarking a LAN switching device. It extends RFC
869 1242 and defines: DUTs, SUTs, Traffic orientation and distribution,
870 bursts, loads, forwarding rates, etc.
871
872 RFC 2889 Benchmarking Methodology for LAN Switching
873 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
874 RFC 2889 outlines a benchmarking methodology for LAN switching, it
875 extends RFC 2544. The outlined methodology gathers performance
876 metrics for forwarding, congestion control, latency, address handling
877 and finally filtering.
878
879 RFC 3918 Methodology for IP Multicast Benchmarking
880 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
881 RFC 3918 outlines a methodology for IP Multicast benchmarking.
882
883 RFC 4737 Packet Reordering Metrics
884 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
885 RFC 4737 describes metrics for identifying and counting re-ordered
886 packets within a stream, and metrics to measure the extent each
887 packet has been re-ordered.
888
889 RFC 5481 Packet Delay Variation Applicability Statement
890 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
891 RFC 5481 defined two common, but different forms of delay variation
892 metrics, and compares the metrics over a range of networking
893 circumstances and tasks. The most suitable form for vSwitch
894 benchmarking is the "PDV" form.
895
896 RFC 6201 Device Reset Characterization
897 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
898 RFC 6201 extends the methodology for characterizing the speed of
899 recovery of the DUT from device or software reset described in RFC
900 2544.
901
902 2.2.5 Details of the Test Report
903 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
904
905 There are a number of parameters related to the system, DUT and tests
906 that can affect the repeatability of a test results and should be
907 recorded. In order to minimise the variation in the results of a test,
908 it is recommended that the test report includes the following information:
909
910 -  Hardware details including:
911
912    -  Platform details.
913    -  Processor details.
914    -  Memory information (see below)
915    -  Number of enabled cores.
916    -  Number of cores used for the test.
917    -  Number of physical NICs, as well as their details (manufacturer,
918       versions, type and the PCI slot they are plugged into).
919    -  NIC interrupt configuration.
920    -  BIOS version, release date and any configurations that were
921       modified.
922
923 -  Software details including:
924
925    -  OS version (for host and VNF)
926    -  Kernel version (for host and VNF)
927    -  GRUB boot parameters (for host and VNF).
928    -  Hypervisor details (Type and version).
929    -  Selected vSwitch, version number or commit id used.
930    -  vSwitch launch command line if it has been parameterised.
931    -  Memory allocation to the vSwitch – which NUMA node it is using,
932       and how many memory channels.
933    -  Where the vswitch is built from source: compiler details including
934       versions and the flags that were used to compile the vSwitch.
935    -  DPDK or any other SW dependency version number or commit id used.
936    -  Memory allocation to a VM - if it's from Hugpages/elsewhere.
937    -  VM storage type: snapshot/independent persistent/independent
938       non-persistent.
939    -  Number of VMs.
940    -  Number of Virtual NICs (vNICs), versions, type and driver.
941    -  Number of virtual CPUs and their core affinity on the host.
942    -  Number vNIC interrupt configuration.
943    -  Thread affinitization for the applications (including the vSwitch
944       itself) on the host.
945    -  Details of Resource isolation, such as CPUs designated for
946       Host/Kernel (isolcpu) and CPUs designated for specific processes
947       (taskset).
948
949 -  Memory Details
950
951    -  Total memory
952    -  Type of memory
953    -  Used memory
954    -  Active memory
955    -  Inactive memory
956    -  Free memory
957    -  Buffer memory
958    -  Swap cache
959    -  Total swap
960    -  Used swap
961    -  Free swap
962
963 -  Test duration.
964 -  Number of flows.
965 -  Traffic Information:
966
967    -  Traffic type - UDP, TCP, IMIX / Other.
968    -  Packet Sizes.
969
970 -  Deployment Scenario.
971
972 **Note**: Tests that require additional parameters to be recorded will
973 explicitly specify this.
974
975 2.3. Test identification
976 ------------------------
977 2.3.1 Throughput tests
978 ~~~~~~~~~~~~~~~~~~~~~~
979 The following tests aim to determine the maximum forwarding rate that
980 can be achieved with a virtual switch. The list is not exhaustive but
981 should indicate the type of tests that should be required. It is
982 expected that more will be added.
983
984 Test ID: LTD.Throughput.RFC2544.PacketLossRatio
985 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
986     **Title**: RFC 2544 X% packet loss ratio Throughput and Latency Test
987
988     **Prerequisite Test**: N/A
989
990     **Priority**:
991
992     **Description**:
993
994     This test determines the DUT's maximum forwarding rate with X% traffic
995     loss for a constant load (fixed length frames at a fixed interval time).
996     The default loss percentages to be tested are: - X = 0% - X = 10^-7%
997
998     Note: Other values can be tested if required by the user.
999
1000     The selected frame sizes are those previously defined under `Default
1001     Test Parameters <#DefaultParams>`__. The test can also be used to
1002     determine the average latency of the traffic.
1003
1004     Under the `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__
1005     test methodology, the test duration will
1006     include a number of trials; each trial should run for a minimum period
1007     of 60 seconds. A binary search methodology must be applied for each
1008     trial to obtain the final result.
1009
1010     **Expected Result**: At the end of each trial, the presence or absence
1011     of loss determines the modification of offered load for the next trial,
1012     converging on a maximum rate, or
1013     `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__ Throughput with X% loss.
1014     The Throughput load is re-used in related
1015     `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__ tests and other
1016     tests.
1017
1018     **Metrics Collected**:
1019
1020     The following are the metrics collected for this test:
1021
1022     -  The maximum forwarding rate in Frames Per Second (FPS) and Mbps of
1023        the DUT for each frame size with X% packet loss.
1024     -  The average latency of the traffic flow when passing through the DUT
1025        (if testing for latency, note that this average is different from the
1026        test specified in Section 26.3 of
1027        `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__).
1028     -  CPU and memory utilization may also be collected as part of this
1029        test, to determine the vSwitch's performance footprint on the system.
1030
1031 Test ID: LTD.Throughput.RFC2544.PacketLossRatioFrameModification
1032 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1033     **Title**: RFC 2544 X% packet loss Throughput and Latency Test with
1034     packet modification
1035
1036     **Prerequisite Test**: N/A
1037
1038     **Priority**:
1039
1040     **Description**:
1041
1042     This test determines the DUT's maximum forwarding rate with X% traffic
1043     loss for a constant load (fixed length frames at a fixed interval time).
1044     The default loss percentages to be tested are: - X = 0% - X = 10^-7%
1045
1046     Note: Other values can be tested if required by the user.
1047
1048     The selected frame sizes are those previously defined under `Default
1049     Test Parameters <#DefaultParams>`__. The test can also be used to
1050     determine the average latency of the traffic.
1051
1052     Under the `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__
1053     test methodology, the test duration will
1054     include a number of trials; each trial should run for a minimum period
1055     of 60 seconds. A binary search methodology must be applied for each
1056     trial to obtain the final result.
1057
1058     During this test, the DUT must perform the following operations on the
1059     traffic flow:
1060
1061     -  Perform packet parsing on the DUT's ingress port.
1062     -  Perform any relevant address look-ups on the DUT's ingress ports.
1063     -  Modify the packet header before forwarding the packet to the DUT's
1064        egress port. Packet modifications include:
1065
1066        -  Modifying the Ethernet source or destination MAC address.
1067        -  Modifying/adding a VLAN tag. (**Recommended**).
1068        -  Modifying/adding a MPLS tag.
1069        -  Modifying the source or destination ip address.
1070        -  Modifying the TOS/DSCP field.
1071        -  Modifying the source or destination ports for UDP/TCP/SCTP.
1072        -  Modifying the TTL.
1073
1074     **Expected Result**: The Packet parsing/modifications require some
1075     additional degree of processing resource, therefore the
1076     `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__
1077     Throughput is expected to be somewhat lower than the Throughput level
1078     measured without additional steps. The reduction is expected to be
1079     greatest on tests with the smallest packet sizes (greatest header
1080     processing rates).
1081
1082     **Metrics Collected**:
1083
1084     The following are the metrics collected for this test:
1085
1086     -  The maximum forwarding rate in Frames Per Second (FPS) and Mbps of
1087        the DUT for each frame size with X% packet loss and packet
1088        modification operations being performed by the DUT.
1089     -  The average latency of the traffic flow when passing through the DUT
1090        (if testing for latency, note that this average is different from the
1091        test specified in Section 26.3 of
1092        `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__).
1093     -  The `RFC5481 <https://www.rfc-editor.org/rfc/rfc5481.txt>`__
1094        PDV form of delay variation on the traffic flow,
1095        using the 99th percentile.
1096     -  CPU and memory utilization may also be collected as part of this
1097        test, to determine the vSwitch's performance footprint on the system.
1098
1099 Test ID: LTD.Throughput.RFC2544.Profile
1100 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1101     **Title**: RFC 2544 Throughput and Latency Profile
1102
1103     **Prerequisite Test**: N/A
1104
1105     **Priority**:
1106
1107     **Description**:
1108
1109     This test reveals how throughput and latency degrades as the offered
1110     rate varies in the region of the DUT's maximum forwarding rate as
1111     determined by LTD.Throughput.RFC2544.PacketLossRatio (0% Packet Loss).
1112     For example it can be used to determine if the degradation of throughput
1113     and latency as the offered rate increases is slow and graceful or sudden
1114     and severe.
1115
1116     The selected frame sizes are those previously defined under `Default
1117     Test Parameters <#DefaultParams>`__.
1118
1119     The offered traffic rate is described as a percentage delta with respect
1120     to the DUT's maximum forwarding rate as determined by
1121     LTD.Throughput.RFC2544.PacketLoss Ratio (0% Packet Loss case). A delta
1122     of 0% is equivalent to an offered traffic rate equal to the maximum
1123     forwarding rate; A delta of +50% indicates an offered rate half-way
1124     between the maximum forwarding rate and line-rate, whereas a delta of
1125     -50% indicates an offered rate of half the maximum rate. Therefore the
1126     range of the delta figure is natuarlly bounded at -100% (zero offered
1127     traffic) and +100% (traffic offered at line rate).
1128
1129     The following deltas to the maximum forwarding rate should be applied:
1130
1131     -  -50%, -10%, 0%, +10% & +50%
1132
1133     **Expected Result**: For each packet size a profile should be produced
1134     of how throughput and latency vary with offered rate.
1135
1136     **Metrics Collected**:
1137
1138     The following are the metrics collected for this test:
1139
1140     -  The forwarding rate in Frames Per Second (FPS) and Mbps of the DUT
1141        for each delta to the maximum forwarding rate and for each frame
1142        size.
1143     -  The average latency for each delta to the maximum forwarding rate and
1144        for each frame size.
1145     -  CPU and memory utilization may also be collected as part of this
1146        test, to determine the vSwitch's performance footprint on the system.
1147     -  Any failures experienced (for example if the vSwitch crashes, stops
1148        processing packets, restarts or becomes unresponsive to commands)
1149        when the offered load is above Maximum Throughput MUST be recorded
1150        and reported with the results.
1151
1152 Test ID: LTD.Throughput.RFC2544.SystemRecoveryTime
1153 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1154     **Title**: RFC 2544 System Recovery Time Test
1155
1156     **Prerequisite Test** LTD.Throughput.RFC2544.PacketLossRatio
1157
1158     **Priority**:
1159
1160     **Description**:
1161
1162     The aim of this test is to determine the length of time it takes the DUT
1163     to recover from an overload condition for a constant load (fixed length
1164     frames at a fixed interval time). The selected frame sizes are those
1165     previously defined under `Default Test Parameters <#DefaultParams>`__,
1166     traffic should be sent to the DUT under normal conditions. During the
1167     duration of the test and while the traffic flows are passing though the
1168     DUT, at least one situation leading to an overload condition for the DUT
1169     should occur. The time from the end of the overload condition to when
1170     the DUT returns to normal operations should be measured to determine
1171     recovery time. Prior to overloading the DUT, one should record the
1172     average latency for 10,000 packets forwarded through the DUT.
1173
1174     The overload condition SHOULD be to transmit traffic at a very high
1175     frame rate to the DUT (150% of the maximum 0% packet loss rate as
1176     determined by LTD.Throughput.RFC2544.PacketLossRatio or line-rate
1177     whichever is lower), for at least 60 seconds, then reduce the frame rate
1178     to 75% of the maximum 0% packet loss rate. A number of time-stamps
1179     should be recorded: - Record the time-stamp at which the frame rate was
1180     reduced and record a second time-stamp at the time of the last frame
1181     lost. The recovery time is the difference between the two timestamps. -
1182     Record the average latency for 10,000 frames after the last frame loss
1183     and continue to record average latency measurements for every 10,000
1184     frames, when latency returns to within 10% of pre-overload levels record
1185     the time-stamp.
1186
1187     **Expected Result**:
1188
1189     **Metrics collected**
1190
1191     The following are the metrics collected for this test:
1192
1193     -  The length of time it takes the DUT to recover from an overload
1194        condition.
1195     -  The length of time it takes the DUT to recover the average latency to
1196        pre-overload conditions.
1197
1198     **Deployment scenario**:
1199
1200     -  Physical → virtual switch → physical.
1201
1202 Test ID: LTD.Throughput.RFC2544.BackToBackFrames
1203 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1204     **Title**: RFC2544 Back To Back Frames Test
1205
1206     **Prerequisite Test**: N
1207
1208     **Priority**:
1209
1210     **Description**:
1211
1212     The aim of this test is to characterize the ability of the DUT to
1213     process back-to-back frames. For each frame size previously defined
1214     under `Default Test Parameters <#DefaultParams>`__, a burst of traffic
1215     is sent to the DUT with the minimum inter-frame gap between each frame.
1216     If the number of received frames equals the number of frames that were
1217     transmitted, the burst size should be increased and traffic is sent to
1218     the DUT again. The value measured is the back-to-back value, that is the
1219     maximum burst size the DUT can handle without any frame loss.
1220
1221     **Expected Result**:
1222
1223     Tests of back-to-back frames with physical devices have produced
1224     unstable results in some cases. All tests should be repeated in multiple
1225     test sessions and results stability should be examined.
1226
1227     **Metrics collected**
1228
1229     The following are the metrics collected for this test:
1230
1231     -  The back-to-back value, which is the the number of frames in the
1232        longest burst that the DUT will handle without the loss of any
1233        frames.
1234     -  CPU and memory utilization may also be collected as part of this
1235        test, to determine the vSwitch's performance footprint on the system.
1236
1237     **Deployment scenario**:
1238
1239     -  Physical → virtual switch → physical.
1240
1241 Test ID: LTD.Throughput.RFC2889.Soak
1242 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1243     **Title**: RFC 2889 X% packet loss Throughput Soak Test
1244
1245     **Prerequisite Test** LTD.Throughput.RFC2544.PacketLossRatio
1246
1247     **Priority**:
1248
1249     **Description**:
1250
1251     The aim of this test is to understand the Throughput stability over an
1252     extended test duration in order to uncover any outliers. To allow for an
1253     extended test duration, the test should ideally run for 24 hours or, if
1254     this is not possible, for at least 6 hours. For this test, each frame
1255     size must be sent at the highest Throughput with X% packet loss, as
1256     determined in the prerequisite test. The default loss percentages to be
1257     tested are: - X = 0% - X = 10^-7%
1258
1259     Note: Other values can be tested if required by the user.
1260
1261     **Expected Result**:
1262
1263     **Metrics Collected**:
1264
1265     The following are the metrics collected for this test:
1266
1267     -  Throughput stability of the DUT.
1268
1269        -  This means reporting the number of packets lost per time interval
1270           and reporting any time intervals with packet loss. The
1271           `RFC2889 <https://www.rfc-editor.org/rfc/rfc2289.txt>`__
1272           Forwarding Rate shall be measured in each interval.
1273           An interval of 60s is suggested.
1274
1275     -  CPU and memory utilization may also be collected as part of this
1276        test, to determine the vSwitch's performance footprint on the system.
1277     -  The `RFC5481 <https://www.rfc-editor.org/rfc/rfc5481.txt>`__
1278        PDV form of delay variation on the traffic flow,
1279        using the 99th percentile.
1280
1281 Test ID: LTD.Throughput.RFC2889.SoakFrameModification
1282 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1283     **Title**: RFC 2889 Throughput Soak Test with Frame Modification
1284
1285     **Prerequisite Test**: LTD.Throughput.RFC2544.PacketLossRatioFrameModification (0% Packet Loss)
1286
1287     **Priority**:
1288
1289     **Description**:
1290
1291     The aim of this test is to understand the throughput stability over an
1292     extended test duration in order to uncover any outliers. To allow for an
1293     extended test duration, the test should ideally run for 24 hours or, if
1294     this is not possible, for at least 6 hour. For this test, each frame
1295     size must be sent at the highest Throughput with 0% packet loss, as
1296     determined in the prerequisite test.
1297
1298     During this test, the DUT must perform the following operations on the
1299     traffic flow:
1300
1301     -  Perform packet parsing on the DUT's ingress port.
1302     -  Perform any relevant address look-ups on the DUT's ingress ports.
1303     -  Modify the packet header before forwarding the packet to the DUT's
1304        egress port. Packet modifications include:
1305
1306        -  Modifying the Ethernet source or destination MAC address.
1307        -  Modifying/adding a VLAN tag (**Recommended**).
1308        -  Modifying/adding a MPLS tag.
1309        -  Modifying the source or destination ip address.
1310        -  Modifying the TOS/DSCP field.
1311        -  Modifying the source or destination ports for UDP/TCP/SCTP.
1312        -  Modifying the TTL.
1313
1314     **Expected Result**:
1315
1316     **Metrics Collected**:
1317
1318     The following are the metrics collected for this test:
1319
1320     -  Throughput stability of the DUT.
1321
1322        -  This means reporting the number of packets lost per time interval
1323           and reporting any time intervals with packet loss. The
1324           `RFC2889 <https://www.rfc-editor.org/rfc/rfc2289.txt>`__
1325           Forwarding Rate shall be measured in each interval.
1326           An interval of 60s is suggested.
1327
1328     -  CPU and memory utilization may also be collected as part of this
1329        test, to determine the vSwitch's performance footprint on the system.
1330     -  The `RFC5481 <https://www.rfc-editor.org/rfc/rfc5481.txt>`__ PDV form of delay variation on the traffic flow,
1331        using the 99th percentile.
1332
1333 Test ID: LTD.Throughput.RFC6201.ResetTime
1334 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1335     **Title**: RFC 6201 Reset Time Test
1336
1337     **Prerequisite Test**: N/A
1338
1339     **Priority**:
1340
1341     **Description**:
1342
1343     The aim of this test is to determine the length of time it takes the DUT
1344     to recover from a reset.
1345
1346     Two reset methods are defined - planned and unplanned. A planned reset
1347     requires stopping and restarting the virtual switch by the usual
1348     'graceful' method defined by it's documentation. An unplanned reset
1349     requires simulating a fatal internal fault in the virtual switch - for
1350     example by using kill -SIGKILL on a Linux environment.
1351
1352     Both reset methods SHOULD be exercised.
1353
1354     For each frame size previously defined under `Default Test
1355     Parameters <#DefaultParams>`__, traffic should be sent to the DUT under
1356     normal conditions. During the duration of the test and while the traffic
1357     flows are passing through the DUT, the DUT should be reset and the Reset
1358     time measured. The Reset time is the total time that a device is
1359     determined to be out of operation and includes the time to perform the
1360     reset and the time to recover from it (cf. `RFC6201 <https://www.rfc-editor.org/rfc/rfc6201.txt>`__).
1361
1362     `RFC6201 <https://www.rfc-editor.org/rfc/rfc6201.txt>`__ defines two methods to measure the Reset time:
1363       - Frame-Loss Method: which requires the monitoring of the number of
1364         lost frames and calculates the Reset time based on the number of
1365         frames lost and the offered rate according to the following
1366         formula:
1367
1368         .. code-block:: console
1369
1370                                     Frames_lost (packets)
1371                  Reset_time = -------------------------------------
1372                                 Offered_rate (packets per second)
1373
1374       - Timestamp Method: which measures the time from which the last frame
1375         is forwarded from the DUT to the time the first frame is forwarded
1376         after the reset. This involves time-stamping all transmitted frames
1377         and recording the timestamp of the last frame that was received prior
1378         to the reset and also measuring the timestamp of the first frame that
1379         is received after the reset. The Reset time is the difference between
1380         these two timestamps.
1381
1382     According to `RFC6201 <https://www.rfc-editor.org/rfc/rfc6201.txt>`__ the choice of method depends on the test
1383     tool's capability; the Frame-Loss method SHOULD be used if the test tool
1384     supports: - Counting the number of lost frames per stream. -
1385     Transmitting test frame despite the physical link status.
1386
1387     whereas the Timestamp method SHOULD be used if the test tool supports: -
1388     Timestamping each frame. - Monitoring received frame's timestamp. -
1389     Transmitting frames only if the physical link status is up.
1390
1391     **Expected Result**:
1392
1393     **Metrics collected**
1394
1395     The following are the metrics collected for this test: - Average Reset
1396     Time over the number of trials performed.
1397
1398     Results of this test should include the following information: - The
1399     reset method used. - Throughput in Fps and Mbps. - Average Frame Loss
1400     over the number of trials performed. - Average Reset Time in
1401     milliseconds over the number of trials performed. - Number of trials
1402     performed. - Protocol: IPv4, IPv6, MPLS, etc. - Frame Size in Octets -
1403     Port Media: Ethernet, Gigabit Ethernet (GbE), etc. - Port Speed: 10
1404     Gbps, 40 Gbps etc. - Interface Encapsulation: Ethernet, Ethernet VLAN,
1405     etc.
1406
1407     **Deployment scenario**:
1408
1409     -  Physical → virtual switch → physical.
1410
1411 Test ID: LTD.Throughput.RFC2889.MaxForwardingRate
1412 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1413     **Title**: RFC2889 Forwarding Rate Test
1414
1415     **Prerequisite Test**: LTD.Throughput.RFC2544.PacketLossRatio
1416
1417     **Priority**:
1418
1419     **Description**:
1420
1421     This test measures the DUT's Max Forwarding Rate when the Offered Load
1422     is varied between the throughput and the Maximum Offered Load for fixed
1423     length frames at a fixed time interval. The selected frame sizes are
1424     those previously defined under `Default Test
1425     Parameters <#DefaultParams>`__. The throughput is the maximum offered
1426     load with 0% frame loss (measured by the prerequisite test), and the
1427     Maximum Offered Load (as defined by
1428     `RFC2285 <https://www.rfc-editor.org/rfc/rfc2285.txt>`__) is *"the highest
1429     number of frames per second that an external source can transmit to a
1430     DUT/SUT for forwarding to a specified output interface or interfaces"*.
1431
1432     Traffic should be sent to the DUT at a particular rate (TX rate)
1433     starting with TX rate equal to the throughput rate. The rate of
1434     successfully received frames at the destination counted (in FPS). If the
1435     RX rate is equal to the TX rate, the TX rate should be increased by a
1436     fixed step size and the RX rate measured again until the Max Forwarding
1437     Rate is found.
1438
1439     The trial duration for each iteration should last for the period of time
1440     needed for the system to reach steady state for the frame size being
1441     tested. Under `RFC2889 <https://www.rfc-editor.org/rfc/rfc2289.txt>`__
1442     (Sec. 5.6.3.1) test methodology, the test
1443     duration should run for a minimum period of 30 seconds, regardless
1444     whether the system reaches steady state before the minimum duration
1445     ends.
1446
1447     **Expected Result**: According to
1448     `RFC2889 <https://www.rfc-editor.org/rfc/rfc2289.txt>`__ The Max Forwarding Rate
1449     is the highest forwarding rate of a DUT taken from an iterative set of
1450     forwarding rate measurements. The iterative set of forwarding rate
1451     measurements are made by setting the intended load transmitted from an
1452     external source and measuring the offered load (i.e what the DUT is
1453     capable of forwarding). If the Throughput == the Maximum Offered Load,
1454     it follows that Max Forwarding Rate is equal to the Maximum Offered
1455     Load.
1456
1457     **Metrics Collected**:
1458
1459     The following are the metrics collected for this test:
1460
1461     -  The Max Forwarding Rate for the DUT for each packet size.
1462     -  CPU and memory utilization may also be collected as part of this
1463        test, to determine the vSwitch's performance footprint on the system.
1464
1465 Test ID: LTD.Throughput.RFC2889.ForwardPressure
1466 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1467     **Title**: RFC2889 Forward Pressure Test
1468
1469     **Prerequisite Test**: LTD.Throughput.RFC2889.MaxForwardingRate
1470
1471     **Priority**:
1472
1473     **Description**:
1474
1475     The aim of this test is to determine if the DUT transmits frames with an
1476     inter-frame gap that is less than 12 bytes. This test overloads the DUT
1477     and measures the output for forward pressure. Traffic should be
1478     transmitted to the DUT with an inter-frame gap of 11 bytes, this will
1479     overload the DUT by 1 byte per frame. The forwarding rate of the DUT
1480     should be measured.
1481
1482     **Expected Result**: The forwarding rate should not exceed the maximum
1483     forwarding rate of the DUT collected by
1484     LTD.Throughput.RFC2889.MaxForwardingRate.
1485
1486     **Metrics collected**
1487
1488     The following are the metrics collected for this test:
1489
1490     -  Forwarding rate of the DUT in FPS or Mbps.
1491     -  CPU and memory utilization may also be collected as part of this
1492        test, to determine the vSwitch's performance footprint on the system.
1493
1494     **Deployment scenario**:
1495
1496     -  Physical → virtual switch → physical.
1497
1498 Test ID: LTD.Throughput.RFC2889.AddressCachingCapacity
1499 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1500     **Title**: RFC2889 Address Caching Capacity Test
1501
1502     **Prerequisite Test**: N/A
1503
1504     **Priority**:
1505
1506     **Description**:
1507
1508     Please note this test is only applicable to switches that are capable of
1509     MAC learning. The aim of this test is to determine the address caching
1510     capacity of the DUT for a constant load (fixed length frames at a fixed
1511     interval time). The selected frame sizes are those previously defined
1512     under `Default Test Parameters <#DefaultParams>`__.
1513
1514     In order to run this test the aging time, that is the maximum time the
1515     DUT will keep a learned address in its flow table, and a set of initial
1516     addresses, whose value should be >= 1 and <= the max number supported by
1517     the implementation must be known. Please note that if the aging time is
1518     configurable it must be longer than the time necessary to produce frames
1519     from the external source at the specified rate. If the aging time is
1520     fixed the frame rate must be brought down to a value that the external
1521     source can produce in a time that is less than the aging time.
1522
1523     Learning Frames should be sent from an external source to the DUT to
1524     install a number of flows. The Learning Frames must have a fixed
1525     destination address and must vary the source address of the frames. The
1526     DUT should install flows in its flow table based on the varying source
1527     addresses. Frames should then be transmitted from an external source at
1528     a suitable frame rate to see if the DUT has properly learned all of the
1529     addresses. If there is no frame loss and no flooding, the number of
1530     addresses sent to the DUT should be increased and the test is repeated
1531     until the max number of cached addresses supported by the DUT
1532     determined.
1533
1534     **Expected Result**:
1535
1536     **Metrics collected**:
1537
1538     The following are the metrics collected for this test:
1539
1540     -  Number of cached addresses supported by the DUT.
1541     -  CPU and memory utilization may also be collected as part of this
1542        test, to determine the vSwitch's performance footprint on the system.
1543
1544     **Deployment scenario**:
1545
1546     -  Physical → virtual switch → physical.
1547
1548 Test ID: LTD.Throughput.RFC2889.AddressLearningRate
1549 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1550     **Title**: RFC2889 Address Learning Rate Test
1551
1552     **Prerequisite Test**: LTD.Memory.RFC2889.AddressCachingCapacity
1553
1554     **Priority**:
1555
1556     **Description**:
1557
1558     Please note this test is only applicable to switches that are capable of
1559     MAC learning. The aim of this test is to determine the rate of address
1560     learning of the DUT for a constant load (fixed length frames at a fixed
1561     interval time). The selected frame sizes are those previously defined
1562     under `Default Test Parameters <#DefaultParams>`__, traffic should be
1563     sent with each IPv4/IPv6 address incremented by one. The rate at which
1564     the DUT learns a new address should be measured. The maximum caching
1565     capacity from LTD.Memory.RFC2889.AddressCachingCapacity should be taken
1566     into consideration as the maximum number of addresses for which the
1567     learning rate can be obtained.
1568
1569     **Expected Result**: It may be worthwhile to report the behaviour when
1570     operating beyond address capacity - some DUTS may be more friendly to
1571     new addresses than others.
1572
1573     **Metrics collected**:
1574
1575     The following are the metrics collected for this test:
1576
1577     -  The address learning rate of the DUT.
1578
1579     **Deployment scenario**:
1580
1581     -  Physical → virtual switch → physical.
1582
1583 Test ID: LTD.Throughput.RFC2889.ErrorFramesFiltering
1584 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1585     **Title**: RFC2889 Error Frames Filtering Test
1586
1587     **Prerequisite Test**: N/A
1588
1589     **Priority**:
1590
1591     **Description**:
1592
1593     The aim of this test is to determine whether the DUT will propagate any
1594     erroneous frames it receives or whether it is capable of filtering out
1595     the erroneous frames. Traffic should be sent with erroneous frames
1596     included within the flow at random intervals. Illegal frames that must
1597     be tested include: - Oversize Frames. - Undersize Frames. - CRC Errored
1598     Frames. - Dribble Bit Errored Frames - Alignment Errored Frames
1599
1600     The traffic flow exiting the DUT should be recorded and checked to
1601     determine if the erroneous frames where passed through the DUT.
1602
1603     **Expected Result**: Broken frames are not passed!
1604
1605     **Metrics collected**
1606
1607     No Metrics are collected in this test, instead it determines:
1608
1609     -  Whether the DUT will propagate erroneous frames.
1610     -  Or whether the DUT will correctly filter out any erroneous frames
1611        from traffic flow with out removing correct frames.
1612
1613     **Deployment scenario**:
1614
1615     -  Physical → virtual switch → physical.
1616
1617 Test ID: LTD.Throughput.RFC2889.BroadcastFrameForwarding
1618 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1619     **Title**: RFC2889 Broadcast Frame Forwarding Test
1620
1621     **Prerequisite Test**: N
1622
1623     **Priority**:
1624
1625     **Description**:
1626
1627     The aim of this test is to determine the maximum forwarding rate of the
1628     DUT when forwarding broadcast traffic. For each frame previously defined
1629     under `Default Test Parameters <#DefaultParams>`__, the traffic should
1630     be set up as broadcast traffic. The traffic throughput of the DUT should
1631     be measured.
1632
1633     The test should be conducted with at least 4 physical ports on the DUT.
1634     The number of ports used MUST be recorded.
1635
1636     As broadcast involves forwarding a single incoming packet to several
1637     destinations, the latency of a single packet is defined as the average
1638     of the latencies for each of the broadcast destinations.
1639
1640     The incoming packet is transmitted on each of the other physical ports,
1641     it is not transmitted on the port on which it was received. The test MAY
1642     be conducted using different broadcasting ports to uncover any
1643     performance differences.
1644
1645     **Expected Result**:
1646
1647     **Metrics collected**:
1648
1649     The following are the metrics collected for this test:
1650
1651     -  The forwarding rate of the DUT when forwarding broadcast traffic.
1652     -  The minimum, average & maximum packets latencies observed.
1653
1654     **Deployment scenario**:
1655
1656     -  Physical → virtual switch 3x physical.
1657
1658 2.3.2 Packet Latency tests
1659 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
1660 These tests will measure the store and forward latency as well as the packet
1661 delay variation for various packet types through the virtual switch. The
1662 following list is not exhaustive but should indicate the type of tests
1663 that should be required. It is expected that more will be added.
1664
1665 Test ID: LTD.PacketLatency.InitialPacketProcessingLatency
1666 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1667     **Title**: Initial Packet Processing Latency
1668
1669     **Prerequisite Test**: N/A
1670
1671     **Priority**:
1672
1673     **Description**:
1674
1675     In some virtual switch architectures, the first packets of a flow will
1676     take the system longer to process than subsequent packets in the flow.
1677     This test determines the latency for these packets. The test will
1678     measure the latency of the packets as they are processed by the
1679     flow-setup-path of the DUT. There are two methods for this test, a
1680     recommended method and a nalternative method that can be used if it is
1681     possible to disable the fastpath of the virtual switch.
1682
1683     Recommended method: This test will send 64,000 packets to the DUT, each
1684     belonging to a different flow. Average packet latency will be determined
1685     over the 64,000 packets.
1686
1687     Alternative method: This test will send a single packet to the DUT after
1688     a fixed interval of time. The time interval will be equivalent to the
1689     amount of time it takes for a flow to time out in the virtual switch
1690     plus 10%. Average packet latency will be determined over 1,000,000
1691     packets.
1692
1693     This test is intended only for non-learning switches; For learning
1694     switches use RFC2889.
1695
1696     For this test, only unidirectional traffic is required.
1697
1698     **Expected Result**: The average latency for the initial packet of all
1699     flows should be greater than the latency of subsequent traffic.
1700
1701     **Metrics Collected**:
1702
1703     The following are the metrics collected for this test:
1704
1705     -  Average latency of the initial packets of all flows that are
1706        processed by the DUT.
1707
1708     **Deployment scenario**:
1709
1710     -  Physical → Virtual Switch → Physical.
1711
1712 Test ID: LTD.PacketDelayVariation.RFC3393.Soak
1713 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1714     **Title**: Packet Delay Variation Soak Test
1715
1716     **Prerequisite Tests**: LTD.Throughput.RFC2544.PacketLossRatio (0% Packet Loss)
1717
1718     **Priority**:
1719
1720     **Description**:
1721
1722     The aim of this test is to understand the distribution of packet delay
1723     variation for different frame sizes over an extended test duration and
1724     to determine if there are any outliers. To allow for an extended test
1725     duration, the test should ideally run for 24 hours or, if this is not
1726     possible, for at least 6 hour. For this test, each frame size must be
1727     sent at the highest possible throughput with 0% packet loss, as
1728     determined in the prerequisite test.
1729
1730     **Expected Result**:
1731
1732     **Metrics Collected**:
1733
1734     The following are the metrics collected for this test:
1735
1736     -  The packet delay variation value for traffic passing through the DUT.
1737     -  The `RFC5481 <https://www.rfc-editor.org/rfc/rfc5481.txt>`__
1738        PDV form of delay variation on the traffic flow,
1739        using the 99th percentile, for each 60s interval during the test.
1740     -  CPU and memory utilization may also be collected as part of this
1741        test, to determine the vSwitch's performance footprint on the system.
1742
1743 2.3.3 Scalability tests
1744 ~~~~~~~~~~~~~~~~~~~~~~~~
1745 The general aim of these tests is to understand the impact of large flow
1746 table size and flow lookups on throughput. The following list is not
1747 exhaustive but should indicate the type of tests that should be required.
1748 It is expected that more will be added.
1749
1750 Test ID: LTD.Scalability.RFC2544.0PacketLoss
1751 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1752     **Title**: RFC 2544 0% loss Scalability throughput test
1753
1754     **Prerequisite Test**:
1755
1756     **Priority**:
1757
1758     **Description**:
1759
1760     The aim of this test is to measure how throughput changes as the number
1761     of flows in the DUT increases. The test will measure the throughput
1762     through the fastpath, as such the flows need to be installed on the DUT
1763     before passing traffic.
1764
1765     For each frame size previously defined under `Default Test
1766     Parameters <#DefaultParams>`__ and for each of the following number of
1767     flows:
1768
1769     -  1,000
1770     -  2,000
1771     -  4,000
1772     -  8,000
1773     -  16,000
1774     -  32,000
1775     -  64,000
1776     -  Max supported number of flows.
1777
1778     The maximum 0% packet loss throughput should be determined in a manner
1779     identical to LTD.Throughput.RFC2544.PacketLossRatio.
1780
1781     **Expected Result**:
1782
1783     **Metrics Collected**:
1784
1785     The following are the metrics collected for this test:
1786
1787     -  The maximum number of frames per second that can be forwarded at the
1788        specified number of flows and the specified frame size, with zero
1789        packet loss.
1790
1791 Test ID: LTD.MemoryBandwidth.RFC2544.0PacketLoss.Scalability
1792 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1793     **Title**: RFC 2544 0% loss Memory Bandwidth Scalability test
1794
1795     **Prerequisite Tests**:
1796
1797     **Priority**:
1798
1799     **Description**:
1800
1801     The aim of this test is to understand how the DUT's performance is
1802     affected by cache sharing and memory bandwidth between processes.
1803
1804     During the test all cores not used by the vSwitch should be running a
1805     memory intensive application. This application should read and write
1806     random data to random addresses in unused physical memory. The random
1807     nature of the data and addresses is intended to consume cache, exercise
1808     main memory access (as opposed to cache) and exercise all memory buses
1809     equally. Furthermore: - the ratio of reads to writes should be recorded.
1810     A ratio of 1:1 SHOULD be used. - the reads and writes MUST be of
1811     cache-line size and be cache-line aligned. - in NUMA architectures
1812     memory access SHOULD be local to the core's node. Whether only local
1813     memory or a mix of local and remote memory is used MUST be recorded. -
1814     the memory bandwidth (reads plus writes) used per-core MUST be recorded;
1815     the test MUST be run with a per-core memory bandwidth equal to half the
1816     maximum system memory bandwidth divided by the number of cores. The test
1817     MAY be run with other values for the per-core memory bandwidth. - the
1818     test MAY also be run with the memory intensive application running on
1819     all cores.
1820
1821     Under these conditions the DUT's 0% packet loss throughput is determined
1822     as per LTD.Throughput.RFC2544.PacketLossRatio.
1823
1824     **Expected Result**:
1825
1826     **Metrics Collected**:
1827
1828     The following are the metrics collected for this test:
1829
1830     -  The DUT's 0% packet loss throughput in the presence of cache sharing and memory bandwidth between processes.
1831
1832 2.3.5 Coupling between control path and datapath Tests
1833 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1834 The following tests aim to determine how tightly coupled the datapath
1835 and the control path are within a virtual switch. The following list
1836 is not exhaustive but should indicate the type of tests that should be
1837 required. It is expected that more will be added.
1838
1839 Test ID: LTD.CPDPCouplingFlowAddition
1840 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1841     **Title**: Control Path and Datapath Coupling
1842
1843     **Prerequisite Test**:
1844
1845     **Priority**:
1846
1847     **Description**:
1848
1849     The aim of this test is to understand how exercising the DUT's control
1850     path affects datapath performance.
1851
1852     Initially a certain number of flow table entries are installed in the
1853     vSwitch. Then over the duration of an RFC2544 throughput test
1854     flow-entries are added and removed at the rates specified below. No
1855     traffic is 'hitting' these flow-entries, they are simply added and
1856     removed.
1857
1858     The test MUST be repeated with the following initial number of
1859     flow-entries installed: - < 10 - 1000 - 100,000 - 10,000,000 (or the
1860     maximum supported number of flow-entries)
1861
1862     The test MUST be repeated with the following rates of flow-entry
1863     addition and deletion per second: - 0 - 1 (i.e. 1 addition plus 1
1864     deletion) - 100 - 10,000
1865
1866     **Expected Result**:
1867
1868     **Metrics Collected**:
1869
1870     The following are the metrics collected for this test:
1871
1872     -  The maximum forwarding rate in Frames Per Second (FPS) and Mbps of
1873        the DUT.
1874     -  The average latency of the traffic flow when passing through the DUT
1875        (if testing for latency, note that this average is different from the
1876        test specified in Section 26.3 of
1877        `RFC2544 <https://www.rfc-editor.org/rfc/rfc2544.txt>`__).
1878     -  CPU and memory utilization may also be collected as part of this
1879        test, to determine the vSwitch's performance footprint on the system.
1880
1881     **Deployment scenario**:
1882
1883     -  Physical → virtual switch → physical.
1884
1885 2.3.4 CPU and memory consumption
1886 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1887 The following tests will profile a virtual switch's CPU and memory
1888 utilization under various loads and circumstances. The following
1889 list is not exhaustive but should indicate the type of tests that
1890 should be required. It is expected that more will be added.
1891
1892 Test ID: LTD.CPU.RFC2544.0PacketLoss
1893 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1894     **Title**: RFC 2544 0% Loss Compute Test
1895
1896     **Prerequisite Test**:
1897
1898     **Priority**:
1899
1900     **Description**:
1901
1902     The aim of this test is to understand the overall performance of the
1903     system when a CPU intensive application is run on the same DUT as the
1904     Virtual Switch. For each frame size, an
1905     LTD.Throughput.RFC2544.PacketLossRatio (0% Packet Loss) test should be
1906     performed. Throughout the entire test a CPU intensive application should
1907     be run on all cores on the system not in use by the Virtual Switch. For
1908     NUMA system only cores on the same NUMA node are loaded.
1909
1910     It is recommended that stress-ng be used for loading the non-Virtual
1911     Switch cores but any stress tool MAY be used.
1912
1913     **Expected Result**:
1914
1915     **Metrics Collected**:
1916
1917     The following are the metrics collected for this test:
1918
1919     -  CPU utilization of the cores running the Virtual Switch.
1920     -  The number of identity of the cores allocated to the Virtual Switch.
1921     -  The configuration of the stress tool (for example the command line
1922        parameters used to start it.)
1923
1924 2.3.9 Summary List of Tests
1925 ~~~~~~~~~~~~~~~~~~~~~~~~~~~
1926 1. Throughput tests
1927
1928   - Test ID: LTD.Throughput.RFC2544.PacketLossRatio
1929   - Test ID: LTD.Throughput.RFC2544.PacketLossRatioFrameModification
1930   - Test ID: LTD.Throughput.RFC2544.Profile
1931   - Test ID: LTD.Throughput.RFC2544.SystemRecoveryTime
1932   - Test ID: LTD.Throughput.RFC2544.BackToBackFrames
1933   - Test ID: LTD.Throughput.RFC2889.Soak
1934   - Test ID: LTD.Throughput.RFC2889.SoakFrameModification
1935   - Test ID: LTD.Throughput.RFC6201.ResetTime
1936   - Test ID: LTD.Throughput.RFC2889.MaxForwardingRate
1937   - Test ID: LTD.Throughput.RFC2889.ForwardPressure
1938   - Test ID: LTD.Throughput.RFC2889.AddressCachingCapacity
1939   - Test ID: LTD.Throughput.RFC2889.AddressLearningRate
1940   - Test ID: LTD.Throughput.RFC2889.ErrorFramesFiltering
1941   - Test ID: LTD.Throughput.RFC2889.BroadcastFrameForwarding
1942
1943 2. Packet Latency tests
1944
1945   - Test ID: LTD.PacketLatency.InitialPacketProcessingLatency
1946   - Test ID: LTD.PacketDelayVariation.RFC3393.Soak
1947
1948 3. Scalability tests
1949
1950   - Test ID: LTD.Scalability.RFC2544.0PacketLoss
1951   - Test ID: LTD.MemoryBandwidth.RFC2544.0PacketLoss.Scalability
1952
1953 4. Coupling between control path and datapath Tests
1954
1955   - Test ID: LTD.CPDPCouplingFlowAddition
1956
1957 5. CPU and memory consumption
1958
1959   - Test ID: LTD.CPU.RFC2544.0PacketLoss