1 .. This work is licensed under a Creative Commons Attribution 4.0 International
3 .. http://creativecommons.org/licenses/by/4.0
4 .. (c) OPNFV, 2016-2017 Intel Corporation.
6 Yardstick - NSB Testing -Installation
7 =====================================
12 The Network Service Benchmarking (NSB) extends the yardstick framework to do
13 VNF characterization and benchmarking in three different execution
14 environments viz., bare metal i.e. native Linux environment, standalone virtual
15 environment and managed virtualized environment (e.g. Open stack etc.).
16 It also brings in the capability to interact with external traffic generators
17 both hardware & software based for triggering and validating the traffic
18 according to user defined profiles.
20 The steps needed to run Yardstick with NSB testing are:
22 * Install Yardstick (NSB Testing).
23 * Setup pod.yaml describing Test topology
24 * Create the test configuration yaml file.
31 Refer chapter Yardstick Instalaltion for more information on yardstick
34 Several prerequisites are needed for Yardstick(VNF testing):
36 - Python Modules: pyzmq, pika.
56 Install Yardstick (NSB Testing)
57 -------------------------------
59 Refer chapter :doc:`04-installation` for more information on installing *Yardstick*
61 After *Yardstick* is installed, executing the "nsb_setup.sh" script to setup
68 It will also automatically download all the packages needed for NSB Testing setup.
73 .. code-block:: console
75 +----------+ +----------+
77 | | (0)----->(0) | Ping/ |
81 +----------+ +----------+
85 OpenStack parameters and credentials
86 ------------------------------------
91 Before running Yardstick (NSB Testing) it is necessary to export traffic
96 source ~/.bash_profile
99 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
103 cp ./etc/yardstick/yardstick.conf.sample /etc/yardstick/yardstick.conf
104 vi /etc/yardstick/yardstick.conf
106 Add trex_path and bin_path in 'nsb' section.
112 dispatcher = influxdb
114 [dispatcher_influxdb]
116 target = http://{YOUR_IP_HERE}:8086
122 trex_path=/opt/nsb_bin/trex/scripts
123 bin_path=/opt/nsb_bin
126 Config pod.yaml describing Topology
127 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
129 Before executing Yardstick test cases, make sure that pod.yaml reflects the
130 topology and update all the required fields.
134 cp /etc/yardstick/nodes/pod.yaml.nsb.sample /etc/yardstick/nodes/pod.yaml
146 xe0: # logical name from topology.yaml and vnfd.yaml
148 driver: i40e # default kernel driver
150 local_ip: "152.16.100.20"
151 netmask: "255.255.255.0"
152 local_mac: "00:00:00:00:00:01"
153 xe1: # logical name from topology.yaml and vnfd.yaml
155 driver: i40e # default kernel driver
157 local_ip: "152.16.40.20"
158 netmask: "255.255.255.0"
159 local_mac: "00:00.00:00:00:02"
167 host: 1.1.1.2 #BM - host == ip, virtualized env - Host - compute node
169 xe0: # logical name from topology.yaml and vnfd.yaml
171 driver: i40e # default kernel driver
173 local_ip: "152.16.100.19"
174 netmask: "255.255.255.0"
175 local_mac: "00:00:00:00:00:03"
177 xe1: # logical name from topology.yaml and vnfd.yaml
179 driver: i40e # default kernel driver
181 local_ip: "152.16.40.19"
182 netmask: "255.255.255.0"
183 local_mac: "00:00:00:00:00:04"
185 - network: "152.16.100.20"
186 netmask: "255.255.255.0"
187 gateway: "152.16.100.20"
189 - network: "152.16.40.20"
190 netmask: "255.255.255.0"
191 gateway: "152.16.40.20"
194 - network: "0064:ff9b:0:0:0:0:9810:6414"
196 gateway: "0064:ff9b:0:0:0:0:9810:6414"
198 - network: "0064:ff9b:0:0:0:0:9810:2814"
200 gateway: "0064:ff9b:0:0:0:0:9810:2814"
203 Enable yardstick virtual environment
204 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
206 Before executing yardstick test cases, make sure to activate yardstick
207 python virtual environment
211 source /opt/nsb_bin/yardstick_venv/bin/activate
214 Run Yardstick - Network Service Testcases
215 -----------------------------------------
217 NS testing - using NSBperf CLI
218 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
221 source /opt/nsb_setup/yardstick_venv/bin/activate
222 PYTHONPATH: ". ~/.bash_profile"
223 cd <yardstick_repo>/yardstick/cmd
225 Execute command: ./NSPerf.py -h
226 ./NSBperf.py --vnf <selected vnf> --test <rfc test>
227 eg: ./NSBperf.py --vnf vpe --test tc_baremetal_rfc2544_ipv4_1flow_64B.yaml
229 NS testing - using yardstick CLI
230 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
233 source /opt/nsb_setup/yardstick_venv/bin/activate
234 PYTHONPATH: ". ~/.bash_profile"
236 Go to test case forlder type we want to execute.
237 e.g. <yardstick repo>/samples/vnf_samples/nsut/<vnf>/
238 run: yardstick --debug task start <test_case.yaml>