c5e395ee6a3af561a739b3d9c5035adac3438424
[yardstick.git] / docs / testing / user / userguide / 12-nsb-overview.rst
1 .. This work is licensed under a Creative Commons Attribution 4.0 International
2 .. License.
3 .. http://creativecommons.org/licenses/by/4.0
4 .. (c) OPNFV, 2016-2017 Intel Corporation.
5
6 ===================================
7 Network Services Benchmarking (NSB)
8 ===================================
9
10 .. _Yardstick: https://wiki.opnfv.org/display/yardstick
11 .. _`ETSI GS NFV-TST001`: http://www.etsi.org/deliver/etsi_gs/NFV-TST/001_099/001/01.01.01_60/gs_nfv-tst001v010101p.pdf
12
13 Abstract
14 --------
15
16 This chapter provides an overview of the NSB, a contribution to OPNFV
17 Yardstick_ from Intel.
18
19 Overview
20 --------
21
22 The goal of NSB is to Extend Yardstick to perform real world VNFs and NFVi
23 Characterization and benchmarking with repeatable and deterministic methods.
24
25 The Network Service Benchmarking (NSB) extends the yardstick framework to do
26 VNF characterization and benchmarking in three different execution
27 environments - bare metal i.e. native Linux environment, standalone virtual
28 environment and managed virtualized environment (e.g. Open stack etc.).
29 It also brings in the capability to interact with external traffic generators
30 both hardware & software based for triggering and validating the traffic
31 according to user defined profiles.
32
33 NSB extension includes:
34
35 * Generic data models of Network Services, based on ETSI spec
36   `ETSI GS NFV-TST 001`_
37 * Standalone :term:`context` for VNF testing like SRIOV, OVS, OVS-DPDK, etc
38 * Generic VNF configuration models and metrics implemented with Python
39   classes
40 * Traffic generator features and traffic profiles
41
42     * L1-L3 stateless traffic profiles
43     * L4-L7 state-full traffic profiles
44     * Tunneling protocol/network overlay support
45
46 * Test case samples
47
48     * Ping
49     * Trex
50     * vPE, vCGNAT, vFirewall etc - ipv4 throughput, latency etc
51
52 * Traffic generators i.e. Trex, ab/nginx, ixia, iperf, etc
53 * KPIs for a given use case:
54
55     * System agent support for collecting NFVi KPI. This includes:
56
57         * CPU statistic
58         * Memory BW
59         * OVS-DPDK Stats
60
61     * Network KPIs e.g. inpackets, outpackets, thoughput, latency
62     * VNF KPIs e.g. packet_in, packet_drop, packet_fwd
63
64 Architecture
65 ============
66
67 The Network Service (NS) defines a set of Virtual Network Functions (VNF)
68 connected together using NFV infrastructure.
69
70 The Yardstick NSB extension can support multiple VNFs created by different
71 vendors including traffic generators. Every VNF being tested has its
72 own data model. The Network service defines a VNF modelling on base of
73 performed network functionality. The part of the data model is a set of the
74 configuration parameters, number of connection points used and flavor including
75 core and memory amount.
76
77 ETSI defines a Network Service as a set of configurable VNFs working in some
78 NFV Infrastructure connecting each other using Virtual Links available through
79 Connection Points. The ETSI MANO specification defines a set of management
80 entities called Network Service Descriptors (NSD) and VNF Descriptors (VNFD)
81 that define real Network Service. The picture below makes an example how the
82 real Network Operator use-case can map into ETSI Network service definition.
83
84 Network Service framework performs the necessary test steps. It may involve:
85
86 * Interacting with traffic generator and providing the inputs on traffic
87   type / packet structure to generate the required traffic as per the
88   test case. Traffic profiles will be used for this.
89 * Executing the commands required for the test procedure and analyses the
90   command output for confirming whether the command got executed correctly
91   or not e.g. as per the test case, run the traffic for the given
92   time period and wait for the necessary time delay.
93 * Verify the test result.
94 * Validate the traffic flow from SUT.
95 * Fetch the data from SUT and verify the value as per the test case.
96 * Upload the logs from SUT onto the Test Harness server
97 * Retrieve the KPI's provided by particular VNF
98
99 Components of Network Service
100 -----------------------------
101
102 * *Models for Network Service benchmarking*: The Network Service benchmarking
103   requires the proper modelling approach. The NSB provides models using Python
104   files and defining of NSDs and VNFDs.
105
106 The benchmark control application being a part of OPNFV yardstick can call
107 that python models to instantiate and configure the VNFs. Depending on
108 infrastructure type (bare-metal or fully virtualized) that calls could be
109 made directly or using MANO system.
110
111 * *Traffic generators in NSB*: Any benchmark application requires a set of
112   traffic generator and traffic profiles defining the method in which traffic
113   is generated.
114
115 The Network Service benchmarking model extends the Network Service
116 definition with a set of Traffic Generators (TG) that are treated
117 same way as other VNFs being a part of benchmarked network service.
118 Same as other VNFs the traffic generator are instantiated and terminated.
119
120 Every traffic generator has own configuration defined as a traffic profile
121 and a set of KPIs supported. The python models for TG is extended by
122 specific calls to listen and generate traffic.
123
124 * *The stateless TREX traffic generator*: The main traffic generator used as
125   Network Service stimulus is open source TREX tool.
126
127 The TREX tool can generate any kind of stateless traffic.
128
129 .. code-block:: console
130
131         +--------+      +-------+      +--------+
132         |        |      |       |      |        |
133         |  Trex  | ---> |  VNF  | ---> |  Trex  |
134         |        |      |       |      |        |
135         +--------+      +-------+      +--------+
136
137 Supported testcases scenarios:
138
139 * Correlated UDP traffic using TREX traffic generator and replay VNF.
140
141     * using different IMIX configuration like pure voice, pure video traffic etc
142     * using different number IP flows e.g. 1, 1K, 16K, 64K, 256K, 1M flows
143     * Using different number of rules configured e.g. 1, 1K, 10K rules
144
145 For UDP correlated traffic following Key Performance Indicators are collected
146 for every combination of test case parameters:
147
148 * RFC2544 throughput for various loss rate defined (1% is a default)
149
150 Graphical Overview
151 ==================
152
153 NSB Testing with Yardstick framework facilitate performance testing of various
154 VNFs provided.
155
156 .. code-block:: console
157
158   +-----------+
159   |           |                                             +-------------+
160   |   vPE     |                                          -->| TGen Port 0 |
161   | TestCase  |                                          |  +-------------+
162   |           |                                          |
163   +-----------+     +---------------+      +-------+     |
164                     |               | ---> |  VNF  | <--->
165   +-----------+     |   Yardstick   |      +-------+     |
166   | Test Case | --> |  NSB Testing  |                    |
167   +-----------+     |               |                    |
168         |           |               |                    |
169         |           +---------------+                    |
170   +-----------+                                          |  +-------------+
171   |   Traffic |                                          -->| TGen Port 1 |
172   |  patterns |                                             +-------------+
173   +-----------+
174
175               Figure 1: Network Service - 2 server configuration
176
177 VNFs supported for chracterization:
178 -----------------------------------
179
180 1. CGNAPT - Carrier Grade Network Address and port Translation
181 2. vFW - Virtual Firewall
182 3. vACL - Access Control List
183 4. Prox - Packet pROcessing eXecution engine:
184      * VNF can act as Drop, Basic Forwarding (no touch),
185        L2 Forwarding (change MAC), GRE encap/decap, Load balance based on
186        packet fields, Symmetric load balancing
187      * QinQ encap/decap IPv4/IPv6, ARP, QoS, Routing, Unmpls, Policing, ACL
188 5. UDP_Replay