summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ansible/install.yaml37
-rw-r--r--ansible/roles/build_yardstick_image/tasks/cloudimg_modify_nsb.yml8
-rwxr-xr-xansible/roles/install_dependencies_jumphost/tasks/Debian.yml10
-rw-r--r--ansible/roles/install_image_dependencies/defaults/main.yml1
-rw-r--r--docker/Dockerfile_ubuntu182
-rw-r--r--docs/release/release-notes/release-notes.rst42
-rwxr-xr-xdocs/testing/user/userguide/01-introduction.rst20
-rw-r--r--docs/testing/user/userguide/02-methodology.rst22
-rwxr-xr-xdocs/testing/user/userguide/03-architecture.rst46
-rw-r--r--docs/testing/user/userguide/04-installation.rst32
-rw-r--r--docs/testing/user/userguide/06-yardstick-plugin.rst26
-rw-r--r--docs/testing/user/userguide/07-result-store-InfluxDB.rst19
-rw-r--r--docs/testing/user/userguide/08-grafana.rst24
-rw-r--r--docs/testing/user/userguide/09-api.rst63
-rw-r--r--docs/testing/user/userguide/10-yardstick-user-interface.rst18
-rw-r--r--docs/testing/user/userguide/12-nsb-overview.rst319
-rw-r--r--docs/testing/user/userguide/13-nsb-installation.rst364
-rw-r--r--docs/testing/user/userguide/14-nsb-operation.rst57
-rw-r--r--samples/vnf_samples/nsut/agnostic/tc_baremetal_rfc2544_latency_ipv4_64B_ixia_L3.yaml (renamed from samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml)32
-rw-r--r--samples/vnf_samples/nsut/firewall/firewall-tg-topology-4port.yaml70
-rw-r--r--samples/vnf_samples/nsut/firewall/firewall-tg-topology.yaml50
-rw-r--r--samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia.yaml50
-rw-r--r--samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia_4port.yaml72
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml47
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml47
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia_4port.yaml48
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia_4port.yaml48
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1024B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1280B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_128B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_256B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_512B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml81
-rw-r--r--samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_trex.yaml79
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_acl-scale-up.yaml111
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd-scale-up.yaml103
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd_multiflow-scale-up.yaml102
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l3fwd-scale-up.yaml36
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_mpls_tagging-scale-up.yaml101
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_sriov_acl-scale-up.yaml101
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd-scale-up.yaml92
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd_multiflow-scale-up.yaml92
-rw-r--r--samples/vnf_samples/nsut/prox/tc_prox_sriov_mpls_tagging-scale-up.yaml91
-rw-r--r--samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_L3.yaml64
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc088.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc089.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc090.yaml2
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc091.yaml2
-rw-r--r--yardstick/benchmark/contexts/heat.py4
-rw-r--r--yardstick/benchmark/core/report.py122
-rw-r--r--yardstick/benchmark/scenarios/availability/monitor/monitor_multi.py27
-rw-r--r--yardstick/benchmark/scenarios/availability/monitor/monitor_process.py12
-rw-r--r--yardstick/common/exceptions.py4
-rw-r--r--yardstick/common/nsb_report.css19
-rw-r--r--yardstick/common/nsb_report.html.j252
-rw-r--r--yardstick/common/nsb_report.js73
-rw-r--r--yardstick/common/utils.py11
-rw-r--r--yardstick/network_services/libs/ixia_libs/ixnet/ixnet_api.py3
-rw-r--r--yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py90
-rw-r--r--yardstick/ssh.py8
-rw-r--r--yardstick/tests/functional/benchmark/core/__init__.py0
-rw-r--r--yardstick/tests/functional/benchmark/core/test_report.py114
-rw-r--r--yardstick/tests/unit/benchmark/core/test_report.py139
-rw-r--r--yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_multi.py17
-rw-r--r--yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_process.py16
-rw-r--r--yardstick/tests/unit/common/test_utils.py9
-rw-r--r--yardstick/tests/unit/network_services/libs/ixia_libs/test_ixnet_api.py6
-rw-r--r--yardstick/tests/unit/network_services/vnf_generic/vnf/test_sample_vnf.py105
-rw-r--r--yardstick/tests/unit/network_services/vnf_generic/vnf/test_tg_rfc2544_ixia.py100
78 files changed, 2223 insertions, 1845 deletions
diff --git a/ansible/install.yaml b/ansible/install.yaml
index f4f57bdc0..d181c5ffd 100644
--- a/ansible/install.yaml
+++ b/ansible/install.yaml
@@ -100,9 +100,12 @@
- install_pmu_tools
- download_collectd
- install_collectd
+ - docker
+ - barometer_collectd
-- hosts: jumphost
+- name: Prepare to build VM
+ hosts: jumphost
become: yes
vars:
img_prop_item: "{{ IMG_PROPERTY }}"
@@ -116,7 +119,8 @@
when: installation_mode != inst_mode_container
-- hosts: chroot_image
+- name: Build VM in chroot
+ hosts: chroot_image
connection: chroot
become: yes
vars:
@@ -131,7 +135,8 @@
when: installation_mode != inst_mode_container
-- hosts: jumphost
+- name: Clear up after VM is built
+ hosts: jumphost
become: yes
tasks:
@@ -142,11 +147,33 @@
when: installation_mode != inst_mode_container
-- name: start yardstick container on jumphost
+- hosts: jumphost
+ vars_files:
+ - yardstick_config.yml
+
+ roles:
+ - { role: convert_openrc, when: openrc_file is defined }
+
+
+- name: Add OpenStack variables, image
+ hosts: jumphost
+ vars_files:
+ - yardstick_config.yml
+ environment:
+ "{{ openrc }}"
+
+ roles:
+ - { role: clean_images, when: openrc_file is defined }
+ - { role: clean_flavors, when: openrc_file is defined }
+ - { role: create_samplevnfs_image, when: openrc_file is defined }
+
+
+- name: Start yardstick container on jumphost
hosts: jumphost
tasks:
- - include_role:
+ - name: Install docker needed to pull Yardstick container
+ include_role:
name: docker
when: installation_mode == inst_mode_container_pull
diff --git a/ansible/roles/build_yardstick_image/tasks/cloudimg_modify_nsb.yml b/ansible/roles/build_yardstick_image/tasks/cloudimg_modify_nsb.yml
index c2f72cada..8e2c3a623 100644
--- a/ansible/roles/build_yardstick_image/tasks/cloudimg_modify_nsb.yml
+++ b/ansible/roles/build_yardstick_image/tasks/cloudimg_modify_nsb.yml
@@ -1,4 +1,4 @@
-# Copyright (c) 2018 Intel Corporation.
+# Copyright (c) 2018-2019 Intel Corporation.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -72,6 +72,9 @@
loop_var: role_item
environment: "{{ proxy_env }}"
+- include_vars: roles/install_dpdk/defaults/main.yml
+ when: INSTALL_BIN_PATH is undefined
+
- name: Install PROX
include_role:
name: install_samplevnf
@@ -89,9 +92,6 @@
loop_var: role_item
environment: "{{ proxy_env }}"
-- include_vars: roles/install_dpdk/defaults/main.yml
- when: INSTALL_BIN_PATH is undefined
-
- include_vars: roles/download_samplevnfs/defaults/main.yml
when: samplevnf_dest is undefined
- set_fact:
diff --git a/ansible/roles/install_dependencies_jumphost/tasks/Debian.yml b/ansible/roles/install_dependencies_jumphost/tasks/Debian.yml
index 6c3900d26..a229cc1a2 100755
--- a/ansible/roles/install_dependencies_jumphost/tasks/Debian.yml
+++ b/ansible/roles/install_dependencies_jumphost/tasks/Debian.yml
@@ -91,8 +91,16 @@
- ansible_distribution == 'Ubuntu'
- ansible_distribution_major_version|int >= 17
+- name: Uninstall docker as it conflicts with docker-py
+ pip:
+ name:
+ - docker
+ state: absent
+
- name: Install required docker-py module
pip:
- name: docker-py
+ name:
+ - docker-py
+ - shade
state: latest
environment: "{{ proxy_env }}"
diff --git a/ansible/roles/install_image_dependencies/defaults/main.yml b/ansible/roles/install_image_dependencies/defaults/main.yml
index 7a3f5fa7e..42951bf6d 100644
--- a/ansible/roles/install_image_dependencies/defaults/main.yml
+++ b/ansible/roles/install_image_dependencies/defaults/main.yml
@@ -29,6 +29,7 @@ install_dependencies:
- libxft-dev
- libxss-dev
- expect
+ - libnuma-dev
RedHat:
- bc
- fio
diff --git a/docker/Dockerfile_ubuntu18 b/docker/Dockerfile_ubuntu18
index a9dfaeb6a..e9fe42ecb 100644
--- a/docker/Dockerfile_ubuntu18
+++ b/docker/Dockerfile_ubuntu18
@@ -9,7 +9,7 @@
FROM ubuntu:18.04
-LABEL image=opnfv/yardstick
+LABEL image=opnfv/yardstick-ubuntu-18.04
ARG BRANCH=master
diff --git a/docs/release/release-notes/release-notes.rst b/docs/release/release-notes/release-notes.rst
index 914daa3a4..920e90fbc 100644
--- a/docs/release/release-notes/release-notes.rst
+++ b/docs/release/release-notes/release-notes.rst
@@ -36,6 +36,9 @@ Version History
| December 14, 2018 | 7.1.0 | Yardstick for Gambia release |
| | | |
+-------------------+-----------+---------------------------------+
+| January 25, 2019 | 7.2.0 | Yardstick for Gambia release |
+| | | |
++-------------------+-----------+---------------------------------+
Important Notes
@@ -114,19 +117,19 @@ Release Data
| **Project** | Yardstick |
| | |
+--------------------------------+-----------------------+
-| **Repo/tag** | yardstick/opnfv-7.1.0 |
+| **Repo/tag** | yardstick/opnfv-7.2.0 |
| | |
+--------------------------------+-----------------------+
-| **Yardstick Docker image tag** | opnfv-7.1.0 |
+| **Yardstick Docker image tag** | opnfv-7.2.0 |
| | |
+--------------------------------+-----------------------+
-| **Release designation** | Gambia 7.1 |
+| **Release designation** | Gambia 7.2 |
| | |
+--------------------------------+-----------------------+
-| **Release date** | December 14, 2018 |
+| **Release date** | January 25, 2019 |
| | |
+--------------------------------+-----------------------+
-| **Purpose of the delivery** | OPNFV Gambia 7.1.0 |
+| **Purpose of the delivery** | OPNFV Gambia 7.2.0 |
| | |
+--------------------------------+-----------------------+
@@ -272,7 +275,7 @@ List of Scenarios
New Test cases
--------------
-.. note:: Yardstick Gambia 7.1.0 adds no new test cases.
+.. note:: Yardstick Gambia 7.2.0 adds no new test cases.
* Generic NFVI test cases
@@ -329,7 +332,7 @@ Feature additions
Scenario Matrix
===============
-For Gambia 7.1.0, Yardstick was tested on the following scenarios:
+For Gambia 7.2.0, Yardstick was tested on the following scenarios:
+-------------------------+------+---------+----------+------+
| Scenario | Apex | Compass | Fuel-arm | Fuel |
@@ -373,33 +376,16 @@ Known Issues/Faults
Corrected Faults
----------------
-Gambia 7.1.0:
+Gambia 7.2.0:
+--------------------+--------------------------------------------------------------------------+
| **JIRA REFERENCE** | **DESCRIPTION** |
+====================+==========================================================================+
-| YARDSTICK-1241 | Update NSB PROX devguide. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1458 | NSB NFVi PROX Should report realtime port activity not historical data. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1471 | Add Testcase Prox Standalone SRIOV. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1475 | Adding Testcase for Prox Stanalone OvS-DPDK. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1500 | Adding Testcase for Prox L2FWD PktTouch Stanalone OvS-DPDK. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1517 | Missing opnfv "os-ovn-nofeature-ha" scenario test suite. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-l526 | Run testcase 074 result overridden by job status. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1547 | Adding scale up test case for l3fwd OvS-DPDK. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1560 | Fix pip environment. |
-+--------------------+--------------------------------------------------------------------------+
-| YARDSTICK-1561 | L3FWD Gradana Dashboards Out-of-date and incorrect. |
+| YARDSTICK-1512 | [dovetail] split the sla check results into process recovery and service |
+| | recovery for HA test cases. |
+--------------------+--------------------------------------------------------------------------+
-Gambia 7.1.0 known restrictions/issues
+Gambia 7.2.0 known restrictions/issues
======================================
diff --git a/docs/testing/user/userguide/01-introduction.rst b/docs/testing/user/userguide/01-introduction.rst
index 5fc2e8d0f..2a3ab4ea7 100755
--- a/docs/testing/user/userguide/01-introduction.rst
+++ b/docs/testing/user/userguide/01-introduction.rst
@@ -1,7 +1,17 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International
-.. License.
-.. http://creativecommons.org/licenses/by/4.0
-.. (c) OPNFV, Ericsson AB and others.
+ License.
+ http://creativecommons.org/licenses/by/4.0
+ (c) OPNFV, Ericsson AB and others.
+
+ Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
============
Introduction
@@ -32,7 +42,7 @@ independent.
About This Document
-===================
+-------------------
This document consists of the following chapters:
@@ -79,7 +89,7 @@ This document consists of the following chapters:
cases.
Contact Yardstick
-=================
+-----------------
Feedback? `Contact us`_
diff --git a/docs/testing/user/userguide/02-methodology.rst b/docs/testing/user/userguide/02-methodology.rst
index 34d271095..b1eee9781 100644
--- a/docs/testing/user/userguide/02-methodology.rst
+++ b/docs/testing/user/userguide/02-methodology.rst
@@ -1,20 +1,30 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International
-.. License.
-.. http://creativecommons.org/licenses/by/4.0
-.. (c) OPNFV, Ericsson AB and others.
+ License.
+ http://creativecommons.org/licenses/by/4.0
+ (c) OPNFV, Ericsson AB and others.
+
+ Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
===========
Methodology
===========
Abstract
-========
+--------
This chapter describes the methodology implemented by the Yardstick project for
verifying the :term:`NFVI` from the perspective of a :term:`VNF`.
ETSI-NFV
-========
+--------
.. _NFV-TST001: http://www.etsi.org/deliver/etsi_gs/NFV-TST/001_099/001/01.01.01_60/gs_NFV-TST001v010101p.pdf
.. _Yardsticktst: https://wiki.opnfv.org/download/attachments/2925202/opnfv_summit_-_bridging_opnfv_and_etsi.pdf?version=1&modificationDate=1458848320000&api=v2
@@ -53,7 +63,7 @@ The methodology includes five steps:
.. seealso:: Yardsticktst_ for material on alignment ETSI TST001 and Yardstick.
Metrics
-=======
+-------
The metrics, as defined by ETSI GS NFV-TST001, are shown in
:ref:`Table1 <table2_1>`, :ref:`Table2 <table2_2>` and
diff --git a/docs/testing/user/userguide/03-architecture.rst b/docs/testing/user/userguide/03-architecture.rst
index 62250d6a3..94081b0e1 100755
--- a/docs/testing/user/userguide/03-architecture.rst
+++ b/docs/testing/user/userguide/03-architecture.rst
@@ -1,23 +1,34 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International
-.. License.
-.. http://creativecommons.org/licenses/by/4.0
-.. (c) 2016 Huawei Technologies Co.,Ltd and others
+ License.
+ http://creativecommons.org/licenses/by/4.0
+ (c) 2016 Huawei Technologies Co.,Ltd and others
+
+ Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
============
Architecture
============
Abstract
-========
-This chapter describes the yardstick framework software architecture. We will
-introduce it from Use-Case View, Logical View, Process View and Deployment
+--------
+
+This chapter describes the Yardstick framework software architecture. We will
+introduce it from Use Case View, Logical View, Process View and Deployment
View. More technical details will be introduced in this chapter.
Overview
-========
+--------
Architecture overview
----------------------
+^^^^^^^^^^^^^^^^^^^^^
Yardstick is mainly written in Python, and test configurations are made
in YAML. Documentation is written in reStructuredText format, i.e. .rst
files. Yardstick is inspired by Rally. Yardstick is intended to run on a
@@ -34,7 +45,8 @@ the test result will be shown with grafana.
Concept
--------
+^^^^^^^
+
**Benchmark** - assess the relative performance of something
**Benchmark** configuration file - describes a single test case in yaml format
@@ -62,7 +74,7 @@ configuration file and evaluated by the runner.
Runner types
-------------
+^^^^^^^^^^^^
There exists several predefined runner types to choose between when designing
a test scenario:
@@ -129,7 +141,8 @@ Snippet of an Iteration runner configuration:
Use-Case View
-=============
+-------------
+
Yardstick Use-Case View shows two kinds of users. One is the Tester who will
do testing in cloud, the other is the User who is more concerned with test
result and result analyses.
@@ -158,7 +171,8 @@ on OPNFV testing dashboard which use MongoDB as backend.
:alt: Yardstick Use-Case View
Logical View
-============
+------------
+
Yardstick Logical View describes the most important classes, their
organization, and the most important use-case realizations.
@@ -195,7 +209,8 @@ finished.
:alt: Yardstick framework architecture in Danube
Process View (Test execution flow)
-==================================
+----------------------------------
+
Yardstick process view shows how yardstick runs a test case. Below is the
sequence graph about the test execution flow using heat context, and each
object represents one module in yardstick:
@@ -222,7 +237,8 @@ will call "Openstack" to undeploy the heat stack. Once the stack is
undepoyed, the whole test ends.
Deployment View
-===============
+---------------
+
Yardstick deployment view shows how the yardstick tool can be deployed into the
underlying platform. Generally, yardstick tool is installed on JumpServer(see
`07-installation` for detail installation steps), and JumpServer is
@@ -235,7 +251,7 @@ result for better showing.
:alt: Yardstick Deployment View
Yardstick Directory structure
-=============================
+-----------------------------
**yardstick/** - Yardstick main directory.
diff --git a/docs/testing/user/userguide/04-installation.rst b/docs/testing/user/userguide/04-installation.rst
index 3ba312ce7..2dff80ef9 100644
--- a/docs/testing/user/userguide/04-installation.rst
+++ b/docs/testing/user/userguide/04-installation.rst
@@ -1,7 +1,17 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International
-.. License.
-.. http://creativecommons.org/licenses/by/4.0
-.. (c) OPNFV, Ericsson AB, Huawei Technologies Co.,Ltd and others.
+ License.
+ http://creativecommons.org/licenses/by/4.0
+ (c) OPNFV, Ericsson AB, Huawei Technologies Co.,Ltd and others.
+
+
+ Convention for heading levels in Yardstick documentation:
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
..
Convention for heading levels in Yardstick documentation:
@@ -18,7 +28,6 @@
Yardstick Installation
======================
-
Yardstick supports installation by Docker or directly in Ubuntu. The
installation procedure for Docker and direct installation are detailed in
the sections below.
@@ -139,7 +148,7 @@ in the following sections. Before that, access the Yardstick container::
and then configure Yardstick environments in the Yardstick container.
Using the CLI command ``env prepare`` (first way) (**recommended**)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
In the Yardstick container, the Yardstick repository is located in the
``/home/opnfv/repos`` directory. Yardstick provides a CLI to prepare OpenStack
@@ -171,10 +180,10 @@ terminal window and execute the following command::
Manually exporting the env variables and initializing OpenStack (second way)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Export OpenStack environment variables
-######################################
+''''''''''''''''''''''''''''''''''''''
Before running Yardstick it is necessary to export OpenStack environment
variables::
@@ -200,7 +209,7 @@ A sample ``openrc`` file may look like this::
Manual creation of Yardstick flavor and guest images
-####################################################
+''''''''''''''''''''''''''''''''''''''''''''''''''''
Before executing Yardstick test cases, make sure that Yardstick flavor and
guest image are available in OpenStack. Detailed steps about creating the
@@ -257,14 +266,14 @@ image. Add Cirros and Ubuntu images to OpenStack::
Automatic initialization of OpenStack (third way)
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
++++++++++++++++++++++++++++++++++++++++++++++++++
Similar to the second way, the first step is also to
`Export OpenStack environment variables`_. Then the following steps should be
done.
Automatic creation of Yardstick flavor and guest images
-#######################################################
+'''''''''''''''''''''''''''''''''''''''''''''''''''''''
Yardstick has a script for automatically creating Yardstick flavor and building
Yardstick guest images. This script is mainly used for CI and can be also used
@@ -340,7 +349,6 @@ For installing Yardstick directly in Ubuntu, the ``yardstick env`` command is
not available. You need to prepare OpenStack environment variables and create
Yardstick flavor and guest images manually.
-
Uninstall Yardstick
^^^^^^^^^^^^^^^^^^^
@@ -655,11 +663,9 @@ Modify ``yardstick.conf`` to add the ``influxdb`` dispatcher::
Now Yardstick will store results in InfluxDB when you run a testcase.
-
Deploy InfluxDB and Grafana directly in Ubuntu (**Todo**)
---------------------------------------------------------
-
Proxy Support
-------------
diff --git a/docs/testing/user/userguide/06-yardstick-plugin.rst b/docs/testing/user/userguide/06-yardstick-plugin.rst
index bc35e239d..a5d890b14 100644
--- a/docs/testing/user/userguide/06-yardstick-plugin.rst
+++ b/docs/testing/user/userguide/06-yardstick-plugin.rst
@@ -3,13 +3,23 @@
.. http://creativecommons.org/licenses/by/4.0
.. (c) OPNFV, Ericsson AB, Huawei Technologies Co.,Ltd and others.
+.. Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
+
===================================
Installing a plug-in into Yardstick
===================================
Abstract
-========
+--------
Yardstick provides a ``plugin`` CLI command to support integration with other
OPNFV testing projects. Below is an example invocation of Yardstick plugin
@@ -17,7 +27,7 @@ command and Storperf plug-in sample.
Installing Storperf into Yardstick
-==================================
+----------------------------------
Storperf is delivered as a Docker container from
https://hub.docker.com/r/opnfv/storperf/tags/.
@@ -31,7 +41,7 @@ In this introduction we will install Storperf on Jump Host.
Step 0: Environment preparation
--------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Running Storperf on Jump Host
Requirements:
@@ -100,7 +110,7 @@ container. You may need to copy it to the root directory of the Storperf
deployed host.
Step 1: Plug-in configuration file preparation
-----------------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
To install a plug-in, first you need to prepare a plug-in configuration file in
YAML format and store it in the "plugin" directory. The plugin configration
@@ -125,7 +135,7 @@ Here the Storperf will be installed on IP 192.168.23.2 which is the Jump Host
in my local environment.
Step 2: Plug-in install/remove scripts preparation
---------------------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
In ``yardstick/resource/scripts`` directory, there are two folders: an
``install`` folder and a ``remove`` folder. You need to store the plug-in
@@ -139,15 +149,15 @@ For example, the install and remove scripts for Storperf are both named
``storperf.bash``.
Step 3: Install and remove Storperf
------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
To install Storperf, simply execute the following command::
# Install Storperf
yardstick plugin install plugin/storperf.yaml
-Removing Storperf from yardstick
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+Removing Storperf from Yardstick
+++++++++++++++++++++++++++++++++
To remove Storperf, simply execute the following command::
diff --git a/docs/testing/user/userguide/07-result-store-InfluxDB.rst b/docs/testing/user/userguide/07-result-store-InfluxDB.rst
index cde931376..8a9196b1b 100644
--- a/docs/testing/user/userguide/07-result-store-InfluxDB.rst
+++ b/docs/testing/user/userguide/07-result-store-InfluxDB.rst
@@ -1,14 +1,23 @@
.. This work is licensed under a Creative Commons Attribution 4.0 International
-.. License.
-.. http://creativecommons.org/licenses/by/4.0
-.. (c) OPNFV, 2016 Huawei Technologies Co.,Ltd and others.
+ License.
+ http://creativecommons.org/licenses/by/4.0
+ (c) OPNFV, 2016 Huawei Technologies Co.,Ltd and others.
+ Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
==============================================
Store Other Project's Test Results in InfluxDB
==============================================
Abstract
-========
+--------
.. _Framework: https://wiki.opnfv.org/download/attachments/6827660/wiki.png?version=1&modificationDate=1470298075000&api=v2
@@ -21,7 +30,7 @@ into community's InfluxDB. The framework is shown in Framework_.
:alt: Store Other Project's Test Results in InfluxDB
Store Storperf Test Results into Community's InfluxDB
-=====================================================
+-----------------------------------------------------
.. _Influxdb: https://git.opnfv.org/cgit/yardstick/tree/yardstick/dispatcher/influxdb.py
.. _Mingjiang: mailto:limingjiang@huawei.com
diff --git a/docs/testing/user/userguide/08-grafana.rst b/docs/testing/user/userguide/08-grafana.rst
index 020a08a65..ebe9f570d 100644
--- a/docs/testing/user/userguide/08-grafana.rst
+++ b/docs/testing/user/userguide/08-grafana.rst
@@ -3,13 +3,23 @@
.. http://creativecommons.org/licenses/by/4.0
.. (c) 2016 Huawei Technologies Co.,Ltd and others
+.. Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
+
=================
Grafana dashboard
=================
Abstract
-========
+--------
This chapter describes the Yardstick grafana dashboard. The Yardstick grafana
dashboard can be found here: http://testresults.opnfv.org/grafana/
@@ -21,14 +31,14 @@ dashboard can be found here: http://testresults.opnfv.org/grafana/
Public access
-=============
+-------------
Yardstick provids a public account for accessing to the dashboard. The username
and password are both set to ‘opnfv’.
Testcase dashboard
-==================
+------------------
For each test case, there is a dedicated dashboard. Shown here is the dashboard
of TC002.
@@ -56,7 +66,7 @@ zoom out the chart.
Administration access
-=====================
+---------------------
For a user with administration rights it is easy to update and save any
dashboard configuration. Saved updates immediately take effect and become live.
@@ -72,11 +82,11 @@ This may cause issues like:
Any change made by administrator should be careful.
-Add a dashboard into yardstick grafana
-======================================
+Add a dashboard into Yardstick Grafana
+--------------------------------------
Due to security concern, users that using the public opnfv account are not able
-to edit the yardstick grafana directly.It takes a few more steps for a
+to edit the yardstick grafana directly. It takes a few more steps for a
non-yardstick user to add a custom dashboard into yardstick grafana.
There are 6 steps to go.
diff --git a/docs/testing/user/userguide/09-api.rst b/docs/testing/user/userguide/09-api.rst
index 1a896699b..f227878ae 100644
--- a/docs/testing/user/userguide/09-api.rst
+++ b/docs/testing/user/userguide/09-api.rst
@@ -2,6 +2,15 @@
.. License.
.. http://creativecommons.org/licenses/by/4.0
.. (c) OPNFV, Huawei Technologies Co.,Ltd and others.
+.. Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
=====================
Yardstick Restful API
@@ -9,16 +18,16 @@ Yardstick Restful API
Abstract
-========
+--------
Yardstick support restful API since Danube.
Available API
-=============
+-------------
/yardstick/env/action
----------------------
+^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to prepare Yardstick test environment.
For Euphrates, it supports:
@@ -69,7 +78,7 @@ get the task result.
/yardstick/asynctask
---------------------
+^^^^^^^^^^^^^^^^^^^^
Description: This API is used to get the status of asynchronous tasks
@@ -91,7 +100,7 @@ NOTE::
/yardstick/testcases
---------------------
+^^^^^^^^^^^^^^^^^^^^
Description: This API is used to list all released Yardstick test cases.
@@ -106,7 +115,7 @@ Example::
/yardstick/testcases/release/action
------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to run a Yardstick released test case.
@@ -130,7 +139,7 @@ result.
/yardstick/testcases/samples/action
------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to run a Yardstick sample test case.
@@ -154,7 +163,7 @@ the result.
/yardstick/testcases/<testcase_name>/docs
------------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to the documentation of a certain released test
case.
@@ -170,7 +179,7 @@ Example::
/yardstick/testsuites/action
-----------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to run a Yardstick test suite.
@@ -194,7 +203,7 @@ result.
/yardstick/tasks/<task_id>/log
-------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to get the real time log of test case execution.
@@ -209,7 +218,7 @@ Example::
/yardstick/results
-------------------
+^^^^^^^^^^^^^^^^^^
Description: This API is used to get the test results of tasks. If you call
/yardstick/testcases/samples/action API, it will return a task id. You can use
@@ -228,7 +237,7 @@ This API will return a list of test case result
/api/v2/yardstick/openrcs
--------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API provides functionality of handling OpenStack credential
file (openrc). For Euphrates, it supports:
@@ -282,7 +291,7 @@ Example::
/api/v2/yardstick/openrcs/<openrc_id>
--------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API provides functionality of handling OpenStack credential file (openrc). For Euphrates, it supports:
@@ -308,7 +317,7 @@ Example::
/api/v2/yardstick/pods
-----------------------
+^^^^^^^^^^^^^^^^^^^^^^
Description: This API provides functionality of handling Yardstick pod file
(pod.yaml). For Euphrates, it supports:
@@ -334,7 +343,7 @@ Example::
/api/v2/yardstick/pods/<pod_id>
--------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API provides functionality of handling Yardstick pod file (pod.yaml). For Euphrates, it supports:
@@ -358,7 +367,7 @@ Example::
/api/v2/yardstick/images
-------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Yardstick VM images.
For Euphrates, it supports:
@@ -383,7 +392,7 @@ Example::
/api/v2/yardstick/images/<image_id>
------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Yardstick VM images. For Euphrates, it supports:
@@ -407,7 +416,7 @@ Example::
/api/v2/yardstick/tasks
------------------------
+^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick tasks. For
Euphrates, it supports:
@@ -433,7 +442,7 @@ Example::
/api/v2/yardstick/tasks/<task_id>
----------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick tasks. For Euphrates, it supports:
@@ -518,7 +527,7 @@ Example::
/api/v2/yardstick/testcases
----------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Yardstick testcases.
For Euphrates, it supports:
@@ -553,7 +562,7 @@ Example::
/api/v2/yardstick/testcases/<case_name>
----------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick testcases. For Euphrates, it supports:
@@ -579,7 +588,7 @@ Example::
/api/v2/yardstick/testsuites
-----------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick test suites.
For Euphrates, it supports:
@@ -617,7 +626,7 @@ Example::
/api/v2/yardstick/testsuites
-----------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick test suites. For Euphrates, it supports:
@@ -643,7 +652,7 @@ Example::
/api/v2/yardstick/projects
---------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Yardstick test
projects. For Euphrates, it supports:
@@ -678,7 +687,7 @@ Example::
/api/v2/yardstick/projects
---------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to yardstick test projects. For Euphrates, it supports:
@@ -704,7 +713,7 @@ Example::
/api/v2/yardstick/containers
-----------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Docker containers.
For Euphrates, it supports:
@@ -744,7 +753,7 @@ Example::
/api/v2/yardstick/containers/<container_id>
--------------------------------------------
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Description: This API is used to do some work related to Docker containers. For Euphrates, it supports:
diff --git a/docs/testing/user/userguide/10-yardstick-user-interface.rst b/docs/testing/user/userguide/10-yardstick-user-interface.rst
index b3056ec99..246e1b1df 100644
--- a/docs/testing/user/userguide/10-yardstick-user-interface.rst
+++ b/docs/testing/user/userguide/10-yardstick-user-interface.rst
@@ -1,3 +1,17 @@
+.. This work is licensed under a Creative Commons Attribution 4.0 International
+.. License.
+.. http://creativecommons.org/licenses/by/4.0
+
+.. Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
+
========================
Yardstick User Interface
========================
@@ -18,7 +32,7 @@ The following layouts are available:
Commands
-========
+--------
To generate the compact HTML report, run::
@@ -30,7 +44,7 @@ To generate the dynamic HTML report, run::
Description
-===========
+-----------
1. When the command is triggered, the relevant values for the
provided task-id and testcase name are retrieved from the
diff --git a/docs/testing/user/userguide/12-nsb-overview.rst b/docs/testing/user/userguide/12-nsb-overview.rst
index 7b0d46804..70aba1e37 100644
--- a/docs/testing/user/userguide/12-nsb-overview.rst
+++ b/docs/testing/user/userguide/12-nsb-overview.rst
@@ -3,75 +3,88 @@
.. http://creativecommons.org/licenses/by/4.0
.. (c) OPNFV, 2016-2017 Intel Corporation.
+.. Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
+
===================================
Network Services Benchmarking (NSB)
===================================
-Abstract
-========
-
.. _Yardstick: https://wiki.opnfv.org/display/yardstick
+.. _`ETSI GS NFV-TST001`: http://www.etsi.org/deliver/etsi_gs/NFV-TST/001_099/001/01.01.01_60/gs_nfv-tst001v010101p.pdf
+
+Abstract
+--------
This chapter provides an overview of the NSB, a contribution to OPNFV
Yardstick_ from Intel.
Overview
-========
-
-The goal of NSB is to Extend Yardstick to perform real world VNFs and NFVi
-Characterization and benchmarking with repeatable and deterministic methods.
-
-The Network Service Benchmarking (NSB) extends the yardstick framework to do
-VNF characterization and benchmarking in three different execution
-environments - bare metal i.e. native Linux environment, standalone virtual
-environment and managed virtualized environment (e.g. Open stack etc.).
-It also brings in the capability to interact with external traffic generators
-both hardware & software based for triggering and validating the traffic
-according to user defined profiles.
+--------
+
+Network Services Benchmarking (:term:`NSB`) uses the :term:`Yardstick`
+framework for performing :term:`VNF` and :term:`NFVI` characterisation in an
+:term:`NFV` environment.
+
+For VNF characterisation, NSB will onboard a VNF, source and sink traffic to it
+via traffic generators, and collect a variety of key performance indicators
+(:term:`KPI`) during VNF execution. The stream of KPI data is stored in a
+database, and it is visualized in a performance-visualization dashboard.
+
+For NFVI characterisation, a fixed test VNF, called :term:`PROX` is used.
+PROX implements a suite of test cases and visualizes the output data of the
+test suite. The PROX test cases implement various execution kernels found in
+real-world VNFs, and the output of the test cases provides an indication of
+the fitness of the infrastructure for running NFV services, in addition to
+indicating potential performance optimizations for the NFVI.
+
+NSB extends the Yardstick framework to do VNF characterization in three
+different execution environments - bare metal i.e. native Linux environment,
+standalone virtual environment and managed virtualized environment (e.g.
+OpenStack). It also brings in the capability to interact with external traffic
+generators, both hardware and software based, for triggering and validating the
+traffic according to user defined profiles.
NSB extension includes:
- - Generic data models of Network Services, based on ETSI spec `ETSI GS NFV-TST 001 <http://www.etsi.org/deliver/etsi_gs/NFV-TST/001_099/001/01.01.01_60/gs_nfv-tst001v010101p.pdf>`_
-
- - New Standalone context for VNF testing like SRIOV, OVS, OVS-DPDK etc
-
- - Generic VNF configuration models and metrics implemented with Python
- classes
-
- - Traffic generator features and traffic profiles
-
- - L1-L3 state-less traffic profiles
-
- - L4-L7 state-full traffic profiles
-
- - Tunneling protocol / network overlay support
-
- - Test case samples
-
- - Ping
+* Generic data models of Network Services, based on ETSI spec
+ `ETSI GS NFV-TST 001`_
+* Standalone :term:`context` for VNF testing SRIOV, OVS, OVS-DPDK, etc
+* Generic VNF configuration models and metrics implemented with Python
+ classes
+* Traffic generator features and traffic profiles
- - Trex
+ * L1-L3 stateless traffic profiles
+ * L4-L7 state-full traffic profiles
+ * Tunneling protocol/network overlay support
- - vPE,vCGNAT, vFirewall etc - ipv4 throughput, latency etc
+* Test case samples
- - Traffic generators like Trex, ab/nginx, ixia, iperf etc
+ * Ping
+ * Trex
+ * vPE, vCGNAT, vFirewall etc - ipv4 throughput, latency etc
- - KPIs for a given use case:
+* Traffic generators i.e. Trex, ab/nginx, ixia, iperf, etc
+* KPIs for a given use case:
- - System agent support for collecting NFVi KPI. This includes:
+ * System agent support for collecting NFVi KPI. This includes:
- - CPU statistic
+ * CPU statistic
+ * Memory BW
+ * OVS-DPDK Stats
- - Memory BW
-
- - OVS-DPDK Stats
-
- - Network KPIs, e.g., inpackets, outpackets, thoughput, latency etc
-
- - VNF KPIs, e.g., packet_in, packet_drop, packet_fwd etc
+ * Network KPIs e.g. inpackets, outpackets, thoughput, latency
+ * VNF KPIs e.g. packet_in, packet_drop, packet_fwd
Architecture
-============
+------------
The Network Service (NS) defines a set of Virtual Network Functions (VNF)
connected together using NFV infrastructure.
@@ -83,124 +96,154 @@ performed network functionality. The part of the data model is a set of the
configuration parameters, number of connection points used and flavor including
core and memory amount.
-The ETSI defines a Network Service as a set of configurable VNFs working in
-some NFV Infrastructure connecting each other using Virtual Links available
-through Connection Points. The ETSI MANO specification defines a set of
-management entities called Network Service Descriptors (NSD) and
-VNF Descriptors (VNFD) that define real Network Service. The picture below
-makes an example how the real Network Operator use-case can map into ETSI
-Network service definition
-
-Network Service framework performs the necessary test steps. It may involve
-
- - Interacting with traffic generator and providing the inputs on traffic
- type / packet structure to generate the required traffic as per the
- test case. Traffic profiles will be used for this.
-
- - Executing the commands required for the test procedure and analyses the
- command output for confirming whether the command got executed correctly
- or not. E.g. As per the test case, run the traffic for the given
- time period / wait for the necessary time delay
-
- - Verify the test result.
-
- - Validate the traffic flow from SUT
-
- - Fetch the table / data from SUT and verify the value as per the test case
-
- - Upload the logs from SUT onto the Test Harness server
-
- - Read the KPI's provided by particular VNF
+ETSI defines a Network Service as a set of configurable VNFs working in some
+NFV Infrastructure connecting each other using Virtual Links available through
+Connection Points. The ETSI MANO specification defines a set of management
+entities called Network Service Descriptors (NSD) and VNF Descriptors (VNFD)
+that define real Network Service. The picture below makes an example how the
+real Network Operator use-case can map into ETSI Network service definition.
+
+Network Service framework performs the necessary test steps. It may involve:
+
+* Interacting with traffic generator and providing the inputs on traffic
+ type / packet structure to generate the required traffic as per the
+ test case. Traffic profiles will be used for this.
+* Executing the commands required for the test procedure and analyses the
+ command output for confirming whether the command got executed correctly
+ or not e.g. as per the test case, run the traffic for the given
+ time period and wait for the necessary time delay.
+* Verify the test result.
+* Validate the traffic flow from SUT.
+* Fetch the data from SUT and verify the value as per the test case.
+* Upload the logs from SUT onto the Test Harness server
+* Retrieve the KPI's provided by particular VNF
Components of Network Service
------------------------------
-
- * *Models for Network Service benchmarking*: The Network Service benchmarking
- requires the proper modelling approach. The NSB provides models using Python
- files and defining of NSDs and VNFDs.
-
- The benchmark control application being a part of OPNFV yardstick can call
- that python models to instantiate and configure the VNFs. Depending on
- infrastructure type (bare-metal or fully virtualized) that calls could be
- made directly or using MANO system.
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- * *Traffic generators in NSB*: Any benchmark application requires a set of
- traffic generator and traffic profiles defining the method in which traffic
- is generated.
+.. TODO: provide a list of components in this section and describe them in
+ later sub-sections
- The Network Service benchmarking model extends the Network Service
- definition with a set of Traffic Generators (TG) that are treated
- same way as other VNFs being a part of benchmarked network service.
- Same as other VNFs the traffic generator are instantiated and terminated.
+.. Components are the methodology, TGs, framework extensions, KPI collection,
+ Testcases, SampleVNFs
+.. Framework extentions include: VNF models, NSPerf Scenario, contexts
- Every traffic generator has own configuration defined as a traffic profile
- and a set of KPIs supported. The python models for TG is extended by
- specific calls to listen and generate traffic.
+* *Models for Network Service benchmarking*: The Network Service benchmarking
+ requires the proper modelling approach. The NSB provides models using Python
+ files and defining of NSDs and VNFDs.
- * *The stateless TREX traffic generator*: The main traffic generator used as
- Network Service stimulus is open source TREX tool.
+The benchmark control application being a part of OPNFV Yardstick can call
+that Python models to instantiate and configure the VNFs. Depending on
+infrastructure type (bare-metal or fully virtualized) that calls could be
+made directly or using MANO system.
- The TREX tool can generate any kind of stateless traffic.
+* *Traffic generators in NSB*: Any benchmark application requires a set of
+ traffic generator and traffic profiles defining the method in which traffic
+ is generated.
- .. code-block:: console
+The Network Service benchmarking model extends the Network Service
+definition with a set of Traffic Generators (TG) that are treated
+same way as other VNFs being a part of benchmarked network service.
+Same as other VNFs the traffic generator are instantiated and terminated.
- +--------+ +-------+ +--------+
- | | | | | |
- | Trex | ---> | VNF | ---> | Trex |
- | | | | | |
- +--------+ +-------+ +--------+
+Every traffic generator has own configuration defined as a traffic profile
+and a set of KPIs supported. The python models for TG is extended by
+specific calls to listen and generate traffic.
- Supported testcases scenarios:
+* *The stateless TREX traffic generator*: The main traffic generator used as
+ Network Service stimulus is open source TREX tool.
- - Correlated UDP traffic using TREX traffic generator and replay VNF.
+The TREX tool can generate any kind of stateless traffic.
- - using different IMIX configuration like pure voice, pure video traffic etc
-
- - using different number IP flows like 1 flow, 1K, 16K, 64K, 256K, 1M flows
-
- - Using different number of rules configured like 1 rule, 1K, 10K rules
-
- For UDP correlated traffic following Key Performance Indicators are collected
- for every combination of test case parameters:
+.. code-block:: console
- - RFC2544 throughput for various loss rate defined (1% is a default)
+ +--------+ +-------+ +--------+
+ | | | | | |
+ | Trex | ---> | VNF | ---> | Trex |
+ | | | | | |
+ +--------+ +-------+ +--------+
+
+Supported testcases scenarios:
+
+* Correlated UDP traffic using TREX traffic generator and replay VNF.
+
+ * using different IMIX configuration like pure voice, pure video traffic etc
+ * using different number IP flows e.g. 1, 1K, 16K, 64K, 256K, 1M flows
+ * Using different number of rules configured e.g. 1, 1K, 10K rules
+
+For UDP correlated traffic following Key Performance Indicators are collected
+for every combination of test case parameters:
+
+* RFC2544 throughput for various loss rate defined (1% is a default)
+
+KPI Collection
+^^^^^^^^^^^^^^
+
+KPI collection is the process of sampling KPIs at multiple intervals to allow
+for investigation into anomalies during runtime. Some KPI intervals are
+adjustable. KPIs are collected from traffic generators and NFVI for the SUT.
+There is already some reporting in NSB available, but NSB collects all KPIs for
+analytics to process.
+
+Below is an example list of basic KPIs:
+* Throughput
+* Latency
+* Packet delay variation
+* Maximum establishment rate
+* Maximum tear-down rate
+* Maximum simultaneous number of sessions
+
+Of course, there can be many other KPIs that will be relevant for a specific
+NFVI, but in most cases these KPIs are enough to give you a basic picture of
+the SUT. NSB also uses :term:`collectd` in order to collect the KPIs. Currently
+the following collectd plug-ins are enabled for NSB testcases:
+
+* Libvirt
+* Interface stats
+* OvS events
+* vSwitch stats
+* Huge Pages
+* RAM
+* CPU usage
+* Intel® PMU
+* Intel(r) RDT
Graphical Overview
-==================
+------------------
-NSB Testing with yardstick framework facilitate performance testing of various
+NSB Testing with Yardstick framework facilitate performance testing of various
VNFs provided.
.. code-block:: console
+-----------+
- | | +-----------+
- | vPE | ->|TGen Port 0|
- | TestCase | | +-----------+
- | | |
- +-----------+ +------------------+ +-------+ |
- | | -- API --> | VNF | <--->
- +-----------+ | Yardstick | +-------+ |
- | Test Case | --> | NSB Testing | |
- +-----------+ | | |
- | | | |
- | +------------------+ |
- +-----------+ | +-----------+
- | Traffic | ->|TGen Port 1|
- | patterns | +-----------+
+ | | +-------------+
+ | vPE | -->| TGen Port 0 |
+ | TestCase | | +-------------+
+ | | |
+ +-----------+ +---------------+ +-------+ |
+ | | ---> | VNF | <--->
+ +-----------+ | Yardstick | +-------+ |
+ | Test Case | --> | NSB Testing | |
+ +-----------+ | | |
+ | | | |
+ | +---------------+ |
+ +-----------+ | +-------------+
+ | Traffic | -->| TGen Port 1 |
+ | patterns | +-------------+
+-----------+
Figure 1: Network Service - 2 server configuration
-VNFs supported for chracterization:
------------------------------------
+VNFs supported for chracterization
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1. CGNAPT - Carrier Grade Network Address and port Translation
2. vFW - Virtual Firewall
3. vACL - Access Control List
-4. Prox - Packet pROcessing eXecution engine:
- - VNF can act as Drop, Basic Forwarding (no touch),
- L2 Forwarding (change MAC), GRE encap/decap, Load balance based on
- packet fields, Symmetric load balancing
- - QinQ encap/decap IPv4/IPv6, ARP, QoS, Routing, Unmpls, Policing, ACL
+4. PROX - Packet pROcessing eXecution engine:
+ * VNF can act as Drop, Basic Forwarding (no touch),
+ L2 Forwarding (change MAC), GRE encap/decap, Load balance based on
+ packet fields, Symmetric load balancing
+ * QinQ encap/decap IPv4/IPv6, ARP, QoS, Routing, Unmpls, Policing, ACL
5. UDP_Replay
diff --git a/docs/testing/user/userguide/13-nsb-installation.rst b/docs/testing/user/userguide/13-nsb-installation.rst
index 973d56628..71ced43ea 100644
--- a/docs/testing/user/userguide/13-nsb-installation.rst
+++ b/docs/testing/user/userguide/13-nsb-installation.rst
@@ -8,40 +8,35 @@
======= Heading 0 (reserved for the title in a document)
------- Heading 1
- ~~~~~~~ Heading 2
+ ^^^^^^^ Heading 2
+++++++ Heading 3
''''''' Heading 4
Avoid deeper levels because they do not render well.
-=====================================
-Yardstick - NSB Testing -Installation
-=====================================
+
+================
+NSB Installation
+================
+
+.. _OVS-DPDK: http://docs.openvswitch.org/en/latest/intro/install/dpdk/
+.. _devstack: https://docs.openstack.org/devstack/pike/>
Abstract
--------
-The Network Service Benchmarking (NSB) extends the yardstick framework to do
-VNF characterization and benchmarking in three different execution
-environments viz., bare metal i.e. native Linux environment, standalone virtual
-environment and managed virtualized environment (e.g. Open stack etc.).
-It also brings in the capability to interact with external traffic generators
-both hardware & software based for triggering and validating the traffic
-according to user defined profiles.
-
The steps needed to run Yardstick with NSB testing are:
* Install Yardstick (NSB Testing).
-* Setup/Reference pod.yaml describing Test topology
-* Create/Reference the test configuration yaml file.
+* Setup/reference ``pod.yaml`` describing Test topology
+* Create/reference the test configuration yaml file.
* Run the test case.
-
Prerequisites
-------------
-Refer chapter Yardstick Installation for more information on yardstick
-prerequisites
+Refer to :doc:`04-installation` for more information on Yardstick
+prerequisites.
Several prerequisites are needed for Yardstick (VNF testing):
@@ -57,11 +52,10 @@ Several prerequisites are needed for Yardstick (VNF testing):
* intel-cmt-cat
Hardware & Software Ingredients
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SUT requirements:
-
======= ===================
Item Description
======= ===================
@@ -74,7 +68,6 @@ SUT requirements:
Boot and BIOS settings:
-
============= =================================================
Boot settings default_hugepagesz=1G hugepagesz=1G hugepages=16
hugepagesz=2M hugepages=2048 isolcpus=1-11,22-33
@@ -93,29 +86,25 @@ Boot and BIOS settings:
Turbo Boost Disabled
============= =================================================
-
-
Install Yardstick (NSB Testing)
-------------------------------
-Download the source code and install Yardstick from it
+Download the source code and check out the latest stable branch::
.. code-block:: console
git clone https://gerrit.opnfv.org/gerrit/yardstick
-
cd yardstick
-
# Switch to latest stable branch
- # git checkout <tag or stable branch>
- git checkout stable/euphrates
+ git checkout stable/gambia
Configure the network proxy, either using the environment variables or setting
-the global environment file:
+the global environment file.
+
+* Set environment
-.. code-block:: ini
+.. code-block::
- cat /etc/environment
http_proxy='http://proxy.company.com:port'
https_proxy='http://proxy.company.com:port'
@@ -124,14 +113,11 @@ the global environment file:
export http_proxy='http://proxy.company.com:port'
export https_proxy='http://proxy.company.com:port'
-The last step is to modify the Yardstick installation inventory, used by
-Ansible:
-
-.. code-block:: ini
+Modify the Yardstick installation inventory, used by Ansible::
cat ./ansible/install-inventory.ini
[jumphost]
- localhost ansible_connection=local
+ localhost ansible_connection=local
[yardstick-standalone]
yardstick-standalone-node ansible_host=192.168.1.2
@@ -148,35 +134,29 @@ Ansible:
.. note::
- SSH access without password needs to be configured for all your nodes defined in
- ``install-inventory.ini`` file.
- If you want to use password authentication you need to install sshpass
-
- .. code-block:: console
+ SSH access without password needs to be configured for all your nodes
+ defined in ``yardstick-install-inventory.ini`` file.
+ If you want to use password authentication you need to install ``sshpass``::
sudo -EH apt-get install sshpass
-To execute an installation for a Bare-Metal or a Standalone context:
-
-.. code-block:: console
+To execute an installation for a BareMetal or a Standalone context::
./nsb_setup.sh
-To execute an installation for an OpenStack context:
-
-.. code-block:: console
+To execute an installation for an OpenStack context::
./nsb_setup.sh <path to admin-openrc.sh>
-Above command setup docker with latest yardstick code. To execute
-
-.. code-block:: console
+The above commands will set up Docker with the latest Yardstick code. To
+execute::
docker exec -it yardstick bash
It will also automatically download all the packages needed for NSB Testing
-setup. Refer chapter :doc:`04-installation` for more on docker
+setup. Refer chapter :doc:`04-installation` for more on Docker
+
**Install Yardstick using Docker (recommended)**
Another way to execute an installation for a Bare-Metal or a Standalone context
@@ -201,24 +181,22 @@ System Topology
Environment parameters and credentials
--------------------------------------
-Config yardstick conf
-~~~~~~~~~~~~~~~~~~~~~
+Configure yardstick.conf
+^^^^^^^^^^^^^^^^^^^^^^^^
-If user did not run 'yardstick env influxdb' inside the container, which will
-generate correct ``yardstick.conf``, then create the config file manually (run
-inside the container):
-::
+If you did not run ``yardstick env influxdb`` inside the container to generate
+ ``yardstick.conf``, then create the config file manually (run inside the
+container)::
cp ./etc/yardstick/yardstick.conf.sample /etc/yardstick/yardstick.conf
vi /etc/yardstick/yardstick.conf
-Add trex_path, trex_client_lib and bin_path in 'nsb' section.
-
-::
+Add ``trex_path``, ``trex_client_lib`` and ``bin_path`` to the ``nsb``
+section::
[DEFAULT]
debug = True
- dispatcher = file, influxdb
+ dispatcher = influxdb
[dispatcher_influxdb]
timeout = 5
@@ -235,25 +213,32 @@ Add trex_path, trex_client_lib and bin_path in 'nsb' section.
Run Yardstick - Network Service Testcases
-----------------------------------------
-
NS testing - using yardstick CLI
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
See :doc:`04-installation`
-.. code-block:: console
-
+Connect to the Yardstick container::
docker exec -it yardstick /bin/bash
- source /etc/yardstick/openstack.creds (only for heat TC if nsb_setup.sh was NOT used)
- export EXTERNAL_NETWORK="<openstack public network>" (only for heat TC)
+
+If you're running ``heat`` testcases and ``nsb_setup.sh`` was not used::
+ source /etc/yardstick/openstack.creds
+
+In addition to the above, you need to se the ``EXTERNAL_NETWORK`` for
+OpenStack::
+
+ export EXTERNAL_NETWORK="<openstack public network>"
+
+Finally, you should be able to run the testcase::
+
yardstick --debug task start yardstick/samples/vnf_samples/nsut/<vnf>/<test case>
Network Service Benchmarking - Bare-Metal
-----------------------------------------
Bare-Metal Config pod.yaml describing Topology
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Bare-Metal 2-Node setup
+++++++++++++++++++++++
@@ -284,8 +269,8 @@ Bare-Metal 3-Node setup - Correlated Traffic
Bare-Metal Config pod.yaml
-~~~~~~~~~~~~~~~~~~~~~~~~~~
-Before executing Yardstick test cases, make sure that pod.yaml reflects the
+^^^^^^^^^^^^^^^^^^^^^^^^^^
+Before executing Yardstick test cases, make sure that ``pod.yaml`` reflects the
topology and update all the required fields.::
cp /etc/yardstick/nodes/pod.yaml.nsb.sample /etc/yardstick/nodes/pod.yaml
@@ -358,22 +343,20 @@ topology and update all the required fields.::
if: "xe1"
-Network Service Benchmarking - Standalone Virtualization
---------------------------------------------------------
+Standalone Virtualization
+-------------------------
SR-IOV
-~~~~~~
+^^^^^^
SR-IOV Pre-requisites
+++++++++++++++++++++
On Host, where VM is created:
- a) Create and configure a bridge named ``br-int`` for VM to connect to external network.
- Currently this can be done using VXLAN tunnel.
+ a) Create and configure a bridge named ``br-int`` for VM to connect to
+ external network. Currently this can be done using VXLAN tunnel.
- Execute the following on host, where VM is created:
-
- .. code-block:: console
+ Execute the following on host, where VM is created::
ip link add type vxlan remote <Jumphost IP> local <DUT IP> id <ID: 10> dstport 4789
brctl addbr br-int
@@ -382,7 +365,7 @@ On Host, where VM is created:
ip addr add <IP#1, like: 172.20.2.1/24> dev br-int
ip link set dev br-int up
- .. note:: May be needed to add extra rules to iptable to forward traffic.
+ .. note:: You may need to add extra rules to iptable to forward traffic.
.. code-block:: console
@@ -416,23 +399,24 @@ On Host, where VM is created:
Yardstick has a tool for building this custom image with SampleVNF.
It is necessary to have ``sudo`` rights to use this tool.
- Also you may need to install several additional packages to use this tool, by
- following the commands below::
+ Also you may need to install several additional packages to use this tool, by
+ following the commands below::
- sudo apt-get update && sudo apt-get install -y qemu-utils kpartx
+ sudo apt-get update && sudo apt-get install -y qemu-utils kpartx
- This image can be built using the following command in the directory where Yardstick is installed
+ This image can be built using the following command in the directory where
+ Yardstick is installed::
- .. code-block:: console
+ export YARD_IMG_ARCH='amd64'
+ sudo echo "Defaults env_keep += \'YARD_IMG_ARCH\'" >> /etc/sudoers
- export YARD_IMG_ARCH='amd64'
- sudo echo "Defaults env_keep += \'YARD_IMG_ARCH\'" >> /etc/sudoers
+ For instructions on generating a cloud image using Ansible, refer to
+ :doc:`04-installation`.
- Please use ansible script to generate a cloud image refer to :doc:`04-installation`
+ for more details refer to chapter :doc:`04-installation`
- for more details refer to chapter :doc:`04-installation`
-
- .. note:: VM should be build with static IP and should be accessible from yardstick host.
+ .. note:: VM should be build with static IP and be accessible from the
+ Yardstick host.
SR-IOV Config pod.yaml describing Topology
@@ -457,10 +441,10 @@ SR-IOV 2-Node setup
+----------+ +-------------------------+
| | | ^ ^ |
| | | | | |
- | | (0)<----->(0) | ------ | |
- | TG1 | | SUT | |
- | | | | |
- | | (n)<----->(n) |------------------ |
+ | | (0)<----->(0) | ------ SUT | |
+ | TG1 | | | |
+ | | (n)<----->(n) | ----------------- |
+ | | | |
+----------+ +-------------------------+
trafficgen_1 host
@@ -470,29 +454,29 @@ SR-IOV 3-Node setup - Correlated Traffic
++++++++++++++++++++++++++++++++++++++++
.. code-block:: console
- +--------------------+
- | |
- | |
- | DUT |
- | (VNF) |
- | |
- +--------------------+
- | VF NIC | | VF NIC |
- +--------+ +--------+
- ^ ^
- | |
- | |
- +----------+ +-------------------------+ +--------------+
- | | | ^ ^ | | |
- | | | | | | | |
- | | (0)<----->(0) | ------ | | | TG2 |
- | TG1 | | SUT | | | (UDP Replay) |
- | | | | | | |
- | | (n)<----->(n) | ------ | (n)<-->(n) | |
- +----------+ +-------------------------+ +--------------+
- trafficgen_1 host trafficgen_2
-
-Before executing Yardstick test cases, make sure that pod.yaml reflects the
+ +--------------------+
+ | |
+ | |
+ | DUT |
+ | (VNF) |
+ | |
+ +--------------------+
+ | VF NIC | | VF NIC |
+ +--------+ +--------+
+ ^ ^
+ | |
+ | |
+ +----------+ +---------------------+ +--------------+
+ | | | ^ ^ | | |
+ | | | | | | | |
+ | | (0)<----->(0) |----- | | | TG2 |
+ | TG1 | | SUT | | | (UDP Replay) |
+ | | | | | | |
+ | | (n)<----->(n) | -----| (n)<-->(n) | |
+ +----------+ +---------------------+ +--------------+
+ trafficgen_1 host trafficgen_2
+
+Before executing Yardstick test cases, make sure that ``pod.yaml`` reflects the
topology and update all the required fields.
.. code-block:: console
@@ -547,8 +531,8 @@ SR-IOV Config host_sriov.yaml
SR-IOV testcase update:
``<yardstick>/samples/vnf_samples/nsut/vfw/tc_sriov_rfc2544_ipv4_1rule_1flow_64B_trex.yaml``
-Update "contexts" section
-'''''''''''''''''''''''''
+Update contexts section
+'''''''''''''''''''''''
.. code-block:: YAML
@@ -591,16 +575,15 @@ Update "contexts" section
gateway_ip: '152.16.100.20'
-
OVS-DPDK
-~~~~~~~~
+^^^^^^^^
OVS-DPDK Pre-requisites
-~~~~~~~~~~~~~~~~~~~~~~~
++++++++++++++++++++++++
On Host, where VM is created:
- a) Create and configure a bridge named ``br-int`` for VM to connect to external network.
- Currently this can be done using VXLAN tunnel.
+ a) Create and configure a bridge named ``br-int`` for VM to connect to
+ external network. Currently this can be done using VXLAN tunnel.
Execute the following on host, where VM is created:
@@ -647,26 +630,27 @@ On Host, where VM is created:
Yardstick has a tool for building this custom image with SampleVNF.
It is necessary to have ``sudo`` rights to use this tool.
- Also you may need to install several additional packages to use this tool, by
- following the commands below::
+ You may need to install several additional packages to use this tool, by
+ following the commands below::
- sudo apt-get update && sudo apt-get install -y qemu-utils kpartx
+ sudo apt-get update && sudo apt-get install -y qemu-utils kpartx
- This image can be built using the following command in the directory where Yardstick is installed::
+ This image can be built using the following command in the directory where
+ Yardstick is installed::
- export YARD_IMG_ARCH='amd64'
- sudo echo "Defaults env_keep += \'YARD_IMG_ARCH\'" >> /etc/sudoers
- sudo tools/yardstick-img-dpdk-modify tools/ubuntu-server-cloudimg-samplevnf-modify.sh
+ export YARD_IMG_ARCH='amd64'
+ sudo echo "Defaults env_keep += \'YARD_IMG_ARCH\'" >> /etc/sudoers
+ sudo tools/yardstick-img-dpdk-modify tools/ubuntu-server-cloudimg-samplevnf-modify.sh
- for more details refer to chapter :doc:`04-installation`
+ for more details refer to chapter :doc:`04-installation`
- .. note:: VM should be build with static IP and should be accessible from yardstick host.
+ .. note:: VM should be build with static IP and should be accessible from
+ yardstick host.
- c) OVS & DPDK version.
- - OVS 2.7 and DPDK 16.11.1 above version is supported
+3. OVS & DPDK version.
+ * OVS 2.7 and DPDK 16.11.1 above version is supported
- d) Setup OVS/DPDK on host.
- Please refer to below link on how to setup `OVS-DPDK <http://docs.openvswitch.org/en/latest/intro/install/dpdk/>`_
+4. Setup `OVS-DPDK`_ on host.
OVS-DPDK Config pod.yaml describing Topology
@@ -732,10 +716,8 @@ OVS-DPDK 3-Node setup - Correlated Traffic
trafficgen_1 host trafficgen_2
-Before executing Yardstick test cases, make sure that pod.yaml reflects the
-topology and update all the required fields.
-
-.. code-block:: console
+Before executing Yardstick test cases, make sure that the ``pod.yaml`` reflects
+the topology and update all the required fields::
cp <yardstick>/etc/yardstick/nodes/standalone/trex_bm.yaml.sample /etc/yardstick/nodes/standalone/pod_trex.yaml
cp <yardstick>/etc/yardstick/nodes/standalone/host_ovs.yaml /etc/yardstick/nodes/standalone/host_ovs.yaml
@@ -786,8 +768,8 @@ OVS-DPDK Config host_ovs.yaml
ovs_dpdk testcase update:
``<yardstick>/samples/vnf_samples/nsut/vfw/tc_ovs_rfc2544_ipv4_1rule_1flow_64B_trex.yaml``
-Update "contexts" section
-'''''''''''''''''''''''''
+Update contexts section
+'''''''''''''''''''''''
.. code-block:: YAML
@@ -841,16 +823,16 @@ Update "contexts" section
gateway_ip: '152.16.100.20'
-Network Service Benchmarking - OpenStack with SR-IOV support
-------------------------------------------------------------
+OpenStack with SR-IOV support
+-----------------------------
This section describes how to run a Sample VNF test case, using Heat context,
with SR-IOV. It also covers how to install OpenStack in Ubuntu 16.04, using
DevStack, with SR-IOV support.
-Single node OpenStack setup with external TG
-~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+Single node OpenStack with external TG
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. code-block:: console
@@ -883,26 +865,22 @@ Single node OpenStack setup with external TG
Host pre-configuration
++++++++++++++++++++++
-.. warning:: The following configuration requires sudo access to the system. Make
- sure that your user have the access.
+.. warning:: The following configuration requires sudo access to the system.
+ Make sure that your user have the access.
-Enable the Intel VT-d or AMD-Vi extension in the BIOS. Some system manufacturers
-disable this extension by default.
+Enable the Intel VT-d or AMD-Vi extension in the BIOS. Some system
+manufacturers disable this extension by default.
Activate the Intel VT-d or AMD-Vi extension in the kernel by modifying the GRUB
config file ``/etc/default/grub``.
-For the Intel platform:
-
-.. code:: bash
+For the Intel platform::
...
GRUB_CMDLINE_LINUX_DEFAULT="intel_iommu=on"
...
-For the AMD platform:
-
-.. code:: bash
+For the AMD platform::
...
GRUB_CMDLINE_LINUX_DEFAULT="amd_iommu=on"
@@ -917,9 +895,7 @@ Update the grub configuration file and restart the system:
sudo update-grub
sudo reboot
-Make sure the extension has been enabled:
-
-.. code:: bash
+Make sure the extension has been enabled::
sudo journalctl -b 0 | grep -e IOMMU -e DMAR
@@ -932,6 +908,8 @@ Make sure the extension has been enabled:
Feb 06 14:50:14 hostname kernel: DMAR: dmar1: reg_base_addr e0ffc000 ver 1:0 cap 8d2078c106f0466 ecap f020de
Feb 06 14:50:14 hostname kernel: DMAR: DRHD base: 0x000000ee7fc000 flags: 0x0
+.. TODO: Refer to the yardstick installation guide for proxy set up
+
Setup system proxy (if needed). Add the following configuration into the
``/etc/environment`` file:
@@ -954,13 +932,11 @@ Upgrade the system:
sudo -EH apt-get upgrade
sudo -EH apt-get dist-upgrade
-Install dependencies needed for the DevStack
+Install dependencies needed for DevStack
.. code:: bash
- sudo -EH apt-get install python
- sudo -EH apt-get install python-dev
- sudo -EH apt-get install python-pip
+ sudo -EH apt-get install python python-dev python-pip
Setup SR-IOV ports on the host:
@@ -983,10 +959,10 @@ Setup SR-IOV ports on the host:
DevStack installation
+++++++++++++++++++++
-Use official `Devstack <https://docs.openstack.org/devstack/pike/>`_
-documentation to install OpenStack on a host. Please note, that stable
-``pike`` branch of devstack repo should be used during the installation.
-The required `local.conf`` configuration file are described below.
+If you want to try out NSB, but don't have OpenStack set-up, you can use
+`Devstack`_ to install OpenStack on a host. Please note, that the
+``stable/pike`` branch of devstack repo should be used during the installation.
+The required ``local.conf`` configuration file are described below.
DevStack configuration file:
@@ -1001,15 +977,13 @@ DevStack configuration file:
Start the devstack installation on a host.
-
TG host configuration
+++++++++++++++++++++
-Yardstick automatically install and configure Trex traffic generator on TG
+Yardstick automatically installs and configures Trex traffic generator on TG
host based on provided POD file (see below). Anyway, it's recommended to check
-the compatibility of the installed NIC on the TG server with software Trex using
-the manual at https://trex-tgn.cisco.com/trex/doc/trex_manual.html.
-
+the compatibility of the installed NIC on the TG server with software Trex
+using the `manual <https://trex-tgn.cisco.com/trex/doc/trex_manual.html>`_.
Run the Sample VNF test case
++++++++++++++++++++++++++++
@@ -1018,7 +992,7 @@ There is an example of Sample VNF test case ready to be executed in an
OpenStack environment with SR-IOV support: ``samples/vnf_samples/nsut/vfw/
tc_heat_sriov_external_rfc2544_ipv4_1rule_1flow_64B_trex.yaml``.
-Install yardstick using `Install Yardstick (NSB Testing)`_ steps for OpenStack
+Install Yardstick using `Install Yardstick (NSB Testing)`_ steps for OpenStack
context.
Create pod file for TG in the yardstick repo folder located in the yardstick
@@ -1071,16 +1045,14 @@ Controller/Compute pre-configuration
++++++++++++++++++++++++++++++++++++
Pre-configuration of the controller and compute hosts are the same as
-described in `Host pre-configuration`_ section. Follow the steps in the section.
-
+described in `Host pre-configuration`_ section.
DevStack configuration
++++++++++++++++++++++
-Use official `Devstack <https://docs.openstack.org/devstack/pike/>`_
-documentation to install OpenStack on a host. Please note, that stable
-``pike`` branch of devstack repo should be used during the installation.
-The required `local.conf`` configuration file are described below.
+A reference ``local.conf`` for deploying OpenStack in a multi-host environment
+using `Devstack`_ is shown in this section. The ``stable/pike`` branch of
+devstack repo should be used during the installation.
.. note:: Update the devstack configuration files by replacing angluar brackets
with a short description inside.
@@ -1100,17 +1072,17 @@ DevStack configuration file for compute host:
Start the devstack installation on the controller and compute hosts.
-
Run the sample vFW TC
+++++++++++++++++++++
-Install yardstick using `Install Yardstick (NSB Testing)`_ steps for OpenStack
+Install Yardstick using `Install Yardstick (NSB Testing)`_ steps for OpenStack
context.
-Run sample vFW RFC2544 SR-IOV TC (``samples/vnf_samples/nsut/vfw/
-tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex.yaml``) in the heat
-context using steps described in `NS testing - using yardstick CLI`_ section
-and the following yardtick command line arguments:
+Run the sample vFW RFC2544 SR-IOV test case
+(``samples/vnf_samples/nsut/vfw/tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex.yaml``)
+in the heat context using steps described in
+`NS testing - using yardstick CLI`_ section and the following Yardstick command
+line arguments:
.. code:: bash
@@ -1118,8 +1090,8 @@ and the following yardtick command line arguments:
samples/vnf_samples/nsut/vfw/tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex.yaml
-Enabling other Traffic generator
---------------------------------
+Enabling other Traffic generators
+---------------------------------
IxLoad
~~~~~~
@@ -1138,14 +1110,16 @@ IxLoad
.. code-block:: console
- cp <repo>/etc/yardstick/nodes/pod.yaml.nsb.sample.ixia etc/yardstick/nodes/pod_ixia.yaml
+ cp <repo>/etc/yardstick/nodes/pod.yaml.nsb.sample.ixia \
+ etc/yardstick/nodes/pod_ixia.yaml
Config ``pod_ixia.yaml``
.. literalinclude:: code/pod_ixia.yaml
:language: console
- for sriov/ovs_dpdk pod files, please refer to above Standalone Virtualization for ovs-dpdk/sriov configuration
+ for sriov/ovs_dpdk pod files, please refer to `Standalone Virtualization`_
+ for ovs-dpdk/sriov configuration
3. Start IxOS TCL Server (Install 'Ixia IxExplorer IxOS <version>')
You will also need to configure the IxLoad machine to start the IXIA
@@ -1155,7 +1129,7 @@ IxLoad
* Go to:
``Start->Programs->Ixia->IxOS->IxOS 8.01-GA-Patch1->Ixia Tcl Server IxOS 8.01-GA-Patch1``
or
- ``"C:\Program Files (x86)\Ixia\IxOS\8.01-GA-Patch1\ixTclServer.exe"``
+ ``C:\Program Files (x86)\Ixia\IxOS\8.01-GA-Patch1\ixTclServer.exe``
4. Create a folder ``Results`` in c:\ and share the folder on the network.
@@ -1163,7 +1137,7 @@ IxLoad
``<repo>/samples/vnf_samples/nsut/vfw/tc_baremetal_http_ixload_1b_Requests-65000_Concurrency.yaml``
IxNetwork
-~~~~~~~~~
+^^^^^^^^^
IxNetwork testcases use IxNetwork API Python Bindings module, which is
installed as part of the requirements of the project.
@@ -1172,14 +1146,16 @@ installed as part of the requirements of the project.
.. code-block:: console
- cp <repo>/etc/yardstick/nodes/pod.yaml.nsb.sample.ixia etc/yardstick/nodes/pod_ixia.yaml
+ cp <repo>/etc/yardstick/nodes/pod.yaml.nsb.sample.ixia \
+ etc/yardstick/nodes/pod_ixia.yaml
- Config pod_ixia.yaml
+ Configure ``pod_ixia.yaml``
.. literalinclude:: code/pod_ixia.yaml
:language: console
- for sriov/ovs_dpdk pod files, please refer to above Standalone Virtualization for ovs-dpdk/sriov configuration
+ for sriov/ovs_dpdk pod files, please refer to above
+ `Standalone Virtualization`_ for ovs-dpdk/sriov configuration
2. Start IxNetwork TCL Server
You will also need to configure the IxNetwork machine to start the IXIA
diff --git a/docs/testing/user/userguide/14-nsb-operation.rst b/docs/testing/user/userguide/14-nsb-operation.rst
index 72b1c4bbc..12e269187 100644
--- a/docs/testing/user/userguide/14-nsb-operation.rst
+++ b/docs/testing/user/userguide/14-nsb-operation.rst
@@ -2,6 +2,16 @@
.. License.
.. http://creativecommons.org/licenses/by/4.0
.. (c) OPNFV, 2016-2018 Intel Corporation.
+..
+ Convention for heading levels in Yardstick documentation:
+
+ ======= Heading 0 (reserved for the title in a document)
+ ------- Heading 1
+ ^^^^^^^ Heading 2
+ +++++++ Heading 3
+ ''''''' Heading 4
+
+ Avoid deeper levels because they do not render well.
Yardstick - NSB Testing - Operation
===================================
@@ -89,9 +99,9 @@ Availability zone
^^^^^^^^^^^^^^^^^
The configuration of the availability zone is requred in cases where location
-of exact compute host/group of compute hosts needs to be specified for SampleVNF
-or traffic generator in the heat test case. If this is the case, please follow
-the instructions below.
+of exact compute host/group of compute hosts needs to be specified for
+:term:`SampleVNF` or traffic generator in the heat test case. If this is the
+case, please follow the instructions below.
.. _`Create a host aggregate`:
@@ -105,7 +115,8 @@ the instructions below.
.. code-block:: bash
# create host aggregate
- openstack aggregate create --zone <AZ_NAME> --property availability_zone=<AZ_NAME> <AGG_NAME>
+ openstack aggregate create --zone <AZ_NAME> \
+ --property availability_zone=<AZ_NAME> <AGG_NAME>
# show available hosts
openstack compute service list --service nova-compute
# add selected host into the host aggregate
@@ -136,8 +147,9 @@ the instructions below.
networks:
...
-There are two example of SampleVNF scale out test case which use the availability zone
-feature to specify the exact location of scaled VNFs and traffic generators.
+There are two example of SampleVNF scale out test case which use the
+``availability zone`` feature to specify the exact location of scaled VNFs and
+traffic generators.
Those are:
@@ -164,21 +176,19 @@ Those are:
| 5 | agg1 | AZ_NAME_1 |
+----+------+-------------------+
-2. If no host aggregates are configured, please use `steps above`__ to
- configure them.
+2. If no host aggregates are configured, please follow the instructions to
+ `Create a host aggregate`_
-__ `Create a host aggregate`_
-
-3. Run the SampleVNF PROX scale-out test case, specifying the availability
- zone of each VNF and traffic generator as a task arguments.
+3. Run the SampleVNF PROX scale-out test case, specifying the
+ ``availability zone`` of each VNF and traffic generator as task arguments.
.. note:: The ``az_0`` and ``az_1`` should be changed according to the host
- aggregates created in the OpenStack.
+ aggregates created in the OpenStack.
.. code-block:: console
- yardstick -d task start\
+ yardstick -d task start \
<repo>/samples/vnf_samples/nsut/prox/tc_prox_heat_context_l2fwd_multiflow-2-scale-out.yaml\
--task-args='{
"num_vnfs": 4, "availability_zone": {
@@ -198,7 +208,7 @@ Collectd KPIs
-------------
NSB can collect KPIs from collected. We have support for various plugins
-enabled by the Barometer project.
+enabled by the :term:`Barometer` project.
The default yardstick-samplevnf has collectd installed. This allows for
collecting KPIs from the VNF.
@@ -208,12 +218,11 @@ We assume that collectd is not installed on the compute nodes.
To collectd KPIs from the NFVi compute nodes:
-
* install_collectd on the compute nodes
* create pod.yaml for the compute nodes
* enable specific plugins depending on the vswitch and DPDK
- example pod.yaml section for Compute node running collectd.
+ example ``pod.yaml`` section for Compute node running collectd.
.. code-block:: yaml
@@ -356,8 +365,8 @@ Scale-Out
VNFs performance data with scale-out helps
- * in capacity planning to meet the given network node requirements
- * in comparison between different VNF vendor offerings
+ * capacity planning to meet the given network node requirements
+ * comparison between different VNF vendor offerings
* better the scale-out index, provides the flexibility in meeting future
capacity requirements
@@ -488,11 +497,11 @@ Default values for OVS-DPDK:
Sample test case file
^^^^^^^^^^^^^^^^^^^^^
- 1. Prepare SampleVNF image and copy it to ``flavor/images``.
- 2. Prepare context files for TREX and SampleVNF under ``contexts/file``.
- 3. Add bridge named ``br-int`` to the baremetal where SampleVNF image is deployed.
- 4. Modify ``networks/phy_port`` accordingly to the baremetal setup.
- 5. Run test from:
+1. Prepare SampleVNF image and copy it to ``flavor/images``.
+2. Prepare context files for TREX and SampleVNF under ``contexts/file``.
+3. Add bridge named ``br-int`` to the baremetal where SampleVNF image is deployed.
+4. Modify ``networks/phy_port`` accordingly to the baremetal setup.
+5. Run test from:
.. literalinclude:: /../samples/vnf_samples/nsut/acl/tc_ovs_rfc2544_ipv4_1rule_1flow_64B_trex.yaml
:language: yaml
diff --git a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml b/samples/vnf_samples/nsut/agnostic/tc_baremetal_rfc2544_latency_ipv4_64B_ixia_L3.yaml
index 0da6e427e..1610193d0 100644
--- a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml
+++ b/samples/vnf_samples/nsut/agnostic/tc_baremetal_rfc2544_latency_ipv4_64B_ixia_L3.yaml
@@ -1,4 +1,4 @@
-# Copyright (c) 2016-2018 Intel Corporation
+# Copyright (c) 2018 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -12,30 +12,38 @@
# See the License for the specific language governing permissions and
# limitations under the License.
+{% set vports = vports or 2 %}
---
schema: yardstick:task:0.1
scenarios:
- type: NSPerf
- traffic_profile: "../../traffic_profiles/ixia_ipv4_latency.yaml"
- topology: firewall_vnf_topology_ixia.yaml
+ traffic_profile: ../../traffic_profiles/ixia_ipv4_latency_L3.yaml
+ topology: agnostic_vnf_topology_ixia_{{ vports }}ports.yaml
+ ixia_config: IxiaL3
+ extra_args:
+ vports: {{ vports }}
nodes:
- tg__0: trafficgen_1.yardstick
- vnf__0: vnf.yardstick
+ tg__0: tg_0.yardstick
+ vnf__0: vnf_0.yardstick
options:
framesize:
- private: {64B: 100}
- public: {64B: 100}
+ uplink: {64B: 100}
+ downlink: {64B: 100}
flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
+ src_ip:
+{% for vport in range(0,vports,2|int) %}
+ - '152.{{ vport }}.0.1-152.{{ vport }}.0.50'
+{% endfor %}
+ dst_ip:
+{% for vport in range(1,vports,2|int) %}
+ - '152.{{ vport }}.1.1-152.{{ vport }}.1.150'
+{% endfor %}
count: 1
traffic_type: 4
rfc2544:
allowed_drop_rate: 0.0001 - 0.0001
vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- nfvi_enable: True
+ []
runner:
type: Iteration
iterations: 10
diff --git a/samples/vnf_samples/nsut/firewall/firewall-tg-topology-4port.yaml b/samples/vnf_samples/nsut/firewall/firewall-tg-topology-4port.yaml
deleted file mode 100644
index 105f85d99..000000000
--- a/samples/vnf_samples/nsut/firewall/firewall-tg-topology-4port.yaml
+++ /dev/null
@@ -1,70 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-nsd:nsd-catalog:
- nsd:
- - id: 3tg-topology
- name: 3tg-topology
- short-name: 3tg-topology
- description: 3tg-topology
- constituent-vnfd:
- - member-vnf-index: '1'
- vnfd-id-ref: tg__0
- VNF model: ../../vnf_descriptors/tg_rfc2544_tpl.yaml #VNF type
- - member-vnf-index: '2'
- vnfd-id-ref: vnf__0
- VNF model: ../../vnf_descriptors/firewall_vnf.yaml #VNF type
-
- vld:
- - id: uplink_0
- name: tg__0 to vnf__0 link 1
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: vnf__0
- - id: downlink_0
- name: vnf__0 to tg__0 link 2
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: tg__0
-
- - id: uplink_1
- name: tg__0 to vnf__0 link 3
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe2
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe2
- vnfd-id-ref: vnf__0
- - id: downlink_1
- name: vnf__0 to tg__0 link 4
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe3
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe3
- vnfd-id-ref: tg__0
diff --git a/samples/vnf_samples/nsut/firewall/firewall-tg-topology.yaml b/samples/vnf_samples/nsut/firewall/firewall-tg-topology.yaml
deleted file mode 100644
index b93137be5..000000000
--- a/samples/vnf_samples/nsut/firewall/firewall-tg-topology.yaml
+++ /dev/null
@@ -1,50 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-nsd:nsd-catalog:
- nsd:
- - id: 2node-topology
- name: 2node-topology
- short-name: 2node-topology
- description: 2node-topology
- constituent-vnfd:
- - member-vnf-index: '1'
- vnfd-id-ref: tg__0
- VNF model: ../../vnf_descriptors/tg_rfc2544_tpl.yaml #VNF type
- - member-vnf-index: '2'
- vnfd-id-ref: vnf__0
- VNF model: ../../vnf_descriptors/firewall_vnf.yaml #VNF type
-
- vld:
- - id: uplink_0
- name: tg__0 to vnf__0 link 1
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: vnf__0
-
- - id: downlink_0
- name: vnf__0 to tg__0 link 2
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: tg__0
diff --git a/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia.yaml b/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia.yaml
deleted file mode 100644
index 9913a0588..000000000
--- a/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia.yaml
+++ /dev/null
@@ -1,50 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-nsd:nsd-catalog:
- nsd:
- - id: vFW
- name: vFW
- short-name: vFW
- description: scenario with vFW VNF
- constituent-vnfd:
- - member-vnf-index: '1'
- vnfd-id-ref: tg__0
- VNF model: ../../vnf_descriptors/ixia_rfc2544_tpl.yaml
- - member-vnf-index: '2'
- vnfd-id-ref: vnf__0
- VNF model: ../../vnf_descriptors/firewall_vnf.yaml
-
- vld:
- - id: uplink_0
- name: tg__0 to vnf__0 link 1
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: vnf__0
-
- - id: downlink_0
- name: vnf__0 to tg__0 link 2
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: tg__0
diff --git a/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia_4port.yaml b/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia_4port.yaml
deleted file mode 100644
index 411c63d8a..000000000
--- a/samples/vnf_samples/nsut/firewall/firewall_vnf_topology_ixia_4port.yaml
+++ /dev/null
@@ -1,72 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-nsd:nsd-catalog:
- nsd:
- - id: vFW
- name: vFW
- short-name: vFW
- description: scenario with vFW VNF
- constituent-vnfd:
- - member-vnf-index: '1'
- vnfd-id-ref: tg__0
- VNF model: ../../vnf_descriptors/ixia_rfc2544_tpl.yaml
- - member-vnf-index: '2'
- vnfd-id-ref: vnf__0
- VNF model: ../../vnf_descriptors/firewall_vnf.yaml
-
- vld:
- - id: uplink_0
- name: tg__0 to vnf__0 link 1
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe0
- vnfd-id-ref: vnf__0
-
- - id: downlink_0
- name: vnf__0 to tg__0 link 2
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe1
- vnfd-id-ref: tg__0
-
- - id: uplink_1
- name: tg__0 to vnf__0 link 3
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe2
- vnfd-id-ref: tg__0
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe2
- vnfd-id-ref: vnf__0
-
- - id: downlink_1
- name: vnf__0 to tg__0 link 4
- type: ELAN
- vnfd-connection-point-ref:
- - member-vnf-index-ref: '2'
- vnfd-connection-point-ref: xe3
- vnfd-id-ref: vnf__0
- - member-vnf-index-ref: '1'
- vnfd-connection-point-ref: xe3
- vnfd-id-ref: tg__0
diff --git a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml b/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml
deleted file mode 100644
index a2595f62a..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml
+++ /dev/null
@@ -1,47 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ipv4_throughput.yaml
- topology: firewall-tg-topology.yaml
- nodes:
- tg__0: trafficgen_1.yardstick
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {64B: 100}
- public: {64B: 100}
- flow:
- src_ip:
- - '152.16.100.181'
- dst_ip:
- - '152.16.40.181'
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- nfvi_enable: True
- runner:
- type: Iteration
- iterations: 2
- interval: 35
-context:
- type: Node
- name: yardstick
- nfvi_type: baremetal
- file: /etc/yardstick/nodes/pod.yaml
diff --git a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml
deleted file mode 100644
index ab2a633a5..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml
+++ /dev/null
@@ -1,47 +0,0 @@
-# Copyright (c) 2016-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: "../../traffic_profiles/ixia_ipv4_latency.yaml"
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {1518B: 100}
- public: {1518B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- nfvi_enable: True
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-context:
- type: Node
- name: yardstick
- nfvi_type: baremetal
- file: /etc/yardstick/nodes/pod_ixia.yaml
diff --git a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia_4port.yaml b/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia_4port.yaml
deleted file mode 100644
index 03ceaafcb..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_1518B_ixia_4port.yaml
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright (c) 2016-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: "../../traffic_profiles/ixia_ipv4_latency.yaml"
- topology: firewall_vnf_topology_ixia_4port.yaml
- nodes:
- tg__0: trafficgen_1.yardstick
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {1518B: 100}
- public: {1518B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}, {'tg__0': 'xe2'}]
- dst_ip: [{'tg__0': 'xe1'}, {'tg__0': 'xe3'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 2, worker_config: '1C/1T', worker_threads: 1}
- nfvi_enable: True
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-context:
- type: Node
- name: yardstick
- nfvi_type: baremetal
- file: /etc/yardstick/nodes/pod_ixia_4port.yaml
-#/etc/yardstick/nodes/pod_ixia.yaml
diff --git a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia_4port.yaml b/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia_4port.yaml
deleted file mode 100644
index 6850fd8eb..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_baremetal_rfc2544_ipv4_1rule_1flow_64B_ixia_4port.yaml
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright (c) 2016-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: "../../traffic_profiles/ixia_ipv4_latency.yaml"
- topology: firewall_vnf_topology_ixia_4port.yaml
- nodes:
- tg__0: trafficgen_1.yardstick
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {64B: 100}
- public: {64B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}, {'tg__0': 'xe2'}]
- dst_ip: [{'tg__0': 'xe1'}, {'tg__0': 'xe3'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 2, worker_config: '1C/1T', worker_threads: 1}
- nfvi_enable: True
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-context:
- type: Node
- name: yardstick
- nfvi_type: baremetal
- file: /etc/yardstick/nodes/pod_ixia_4port.yaml
-#/etc/yardstick/nodes/pod_ixia.yaml
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1024B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1024B_ixia.yaml
deleted file mode 100644
index 235c6fc8e..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1024B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {1024B: 100}
- public: {1024B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1280B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1280B_ixia.yaml
deleted file mode 100644
index 5e56847b5..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1280B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {1280B: 100}
- public: {1280B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_128B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_128B_ixia.yaml
deleted file mode 100644
index 2286fcb6c..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_128B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {128B: 100}
- public: {128B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml
deleted file mode 100644
index 680cf7cab..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_1518B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {1518B: 100}
- public: {1518B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_256B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_256B_ixia.yaml
deleted file mode 100644
index 245236a48..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_256B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {256B: 100}
- public: {256B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_512B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_512B_ixia.yaml
deleted file mode 100644
index 3a100ede7..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_512B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {512B: 100}
- public: {512B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml
deleted file mode 100644
index f334aa916..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_ixia.yaml
+++ /dev/null
@@ -1,81 +0,0 @@
-# Copyright (c) 2017-2018 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ixia_ipv4_latency.yaml
- topology: firewall_vnf_topology_ixia.yaml
- nodes:
- tg__0: trafficgen_1.yardstick1
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {64B: 100}
- public: {64B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: yardstick1
- type: Node
- file: ixia.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- vld_id: downlink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- vld_id: uplink_0
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_trex.yaml b/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_trex.yaml
deleted file mode 100644
index fec585190..000000000
--- a/samples/vnf_samples/nsut/firewall/tc_heat_external_rfc2544_ipv4_1rule_1flow_64B_trex.yaml
+++ /dev/null
@@ -1,79 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
----
-schema: yardstick:task:0.1
-scenarios:
-- type: NSPerf
- traffic_profile: ../../traffic_profiles/ipv4_throughput.yaml
- topology: firewall-tg-topology.yaml
- nodes:
- tg__0: trafficgen_1.baremetal
- vnf__0: vnf.yardstick
- options:
- framesize:
- private: {64B: 100}
- public: {64B: 100}
- flow:
- src_ip: [{'tg__0': 'xe0'}]
- dst_ip: [{'tg__0': 'xe1'}]
- count: 1
- traffic_type: 4
- rfc2544:
- allowed_drop_rate: 0.0001 - 0.0001
- vnf__0:
- rules: acl_1rule.yaml
- vnf_config: {lb_config: 'SW', lb_count: 1, worker_config: '1C/1T', worker_threads: 1}
- runner:
- type: Iteration
- iterations: 10
- interval: 35
-contexts:
- # put node context first, so we don't HEAT deploy if node has errors
- - name: baremetal
- type: Node
- file: trex-baremetal.yml
- - name: yardstick
- image: yardstick-samplevnfs
- flavor:
- vcpus: 10
- ram: 20480
- disk: 6
- extra_specs:
- hw:cpu_sockets: 1
- hw:cpu_cores: 10
- hw:cpu_threads: 1
- user: ubuntu
- placement_groups:
- pgrp1:
- policy: "availability"
- servers:
- vnf:
- floating_ip: true
- placement: "pgrp1"
- networks:
- mgmt:
- cidr: '10.0.1.0/24'
- xe0:
- cidr: '10.0.2.0/24'
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant1
- port_security_enabled: False
- xe1:
- cidr: '10.0.3.0/24'
- gateway_ip: 'null'
- provider: true
- physical_network: phystenant2
- port_security_enabled: False
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_acl-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_acl-scale-up.yaml
new file mode 100644
index 000000000..d71c4cefb
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_acl-scale-up.yaml
@@ -0,0 +1,111 @@
+# Copyright (c) 2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+{% set duration = duration or 300 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ #
+ # In case where we know that all the packets generated by the generator
+ # will bw received. Then use prox_binsearch.
+ #
+ # In the case where some or all the packets generated by the generator may
+ # not be received. Please use prox_acl .. (This generates packets at
+ # a specific rate and does not change rate.
+ #
+ traffic_profile: ../../traffic_profiles/prox_acl.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg_0.yardstick
+ vnf__0: vnf_0.yardstick
+
+ options:
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_acl-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+ prox_files:
+ "configs/acl_rules-2.lua": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_acl-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: {{ duration }}
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneOvsDpdk
+ file: /etc/yardstick/nodes/standalone/host_ovs.yaml
+ vm_deploy: True
+ ovs_properties:
+ version:
+ ovs: 2.8.0
+ dpdk: 17.05.2
+ pmd_threads: 2
+ ram:
+ socket_0: 2048
+ socket_1: 2048
+ queues: 4
+ vpath: "/usr/local"
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ port_num: {{ networks.uplink[port_num].port_num }}
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ port_num: {{ networks.downlink[port_num].port_num }}
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd-scale-up.yaml
new file mode 100644
index 000000000..49ab05a51
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd-scale-up.yaml
@@ -0,0 +1,103 @@
+# Copyright (c) 2018 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_binsearch.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ interface_speed_gbps: 10
+
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_l2fwd-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_l2fwd-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: 600
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ servers:
+ - name: yardstick
+ type: StandaloneOvsDpdk
+ file: /etc/yardstick/nodes/standalone/host_ovs.yaml
+ vm_deploy: True
+ ovs_properties:
+ version:
+ ovs: 2.8.0
+ dpdk: 17.05.2
+ pmd_threads: 2
+ ram:
+ socket_0: 2048
+ socket_1: 2048
+ queues: 4
+ vpath: "/usr/local"
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ port_num: {{networks.uplink[port_num].port_num}}
+ phy_port: "{{networks.uplink[port_num].phy_port}}"
+ vpci: "{{networks.uplink[port_num].vpci}}"
+ cidr: "{{networks.uplink[port_num].cidr}}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ port_num: {{networks.downlink[port_num].port_num}}
+ phy_port: "{{networks.downlink[port_num].phy_port}}"
+ vpci: "{{networks.downlink[port_num].vpci}}"
+ cidr: "{{networks.downlink[port_num].cidr}}"
+ gateway_ip: "{{networks.downlink[port_num].gateway_ip}}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd_multiflow-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd_multiflow-scale-up.yaml
new file mode 100644
index 000000000..e8145bfaa
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l2fwd_multiflow-scale-up.yaml
@@ -0,0 +1,102 @@
+# Copyright (c) 2018-2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_binsearch.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ interface_speed_gbps: 10
+
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_l2fwd_multiflow-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_l2fwd_multiflow-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: 600
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneOvsDpdk
+ file: /etc/yardstick/nodes/standalone/host_ovs.yaml
+ vm_deploy: True
+ ovs_properties:
+ version:
+ ovs: 2.8.0
+ dpdk: 17.05.2
+ pmd_threads: 2
+ ram:
+ socket_0: 2048
+ socket_1: 2048
+ queues: 4
+ vpath: "/usr/local"
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ port_num: {{ networks.uplink[port_num].port_num }}
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ port_num: {{ networks.downlink[port_num].port_num }}
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l3fwd-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l3fwd-scale-up.yaml
index 450775805..f9d9b65a8 100644
--- a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l3fwd-scale-up.yaml
+++ b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_l3fwd-scale-up.yaml
@@ -84,24 +84,24 @@ contexts:
network_ports:
mgmt:
cidr: '1.1.1.62/24'
-{% for port_num in range(1,vports,2|int) %}
- xe{{ loop.index0 * 2 }}:
- - uplink_{{ loop.index0 }}
- xe{{ (loop.index0 * 2) + 1 }}:
- - downlink_{{ loop.index0 }}
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
{% endfor %}
networks:
-{% for port_num in range(1,vports,2|int) %}
- uplink_{{ loop.index0 }}:
- port_num: {{ networks.uplink[loop.index0].port_num }}
- phy_port: "{{ networks.uplink[loop.index0].phy_port }}"
- vpci: "{{ networks.uplink[loop.index0].vpci }}"
- cidr: "{{ networks.uplink[loop.index0].cidr }}"
- gateway_ip: "{{ networks.uplink[loop.index0].gateway_ip }}"
- downlink_{{ loop.index0 }}:
- port_num: {{ networks.downlink[loop.index0].port_num }}
- phy_port: "{{ networks.downlink[loop.index0].phy_port }}"
- vpci: "{{ networks.downlink[loop.index0].vpci }}"
- cidr: "{{ networks.downlink[loop.index0].cidr }}"
- gateway_ip: "{{ networks.downlink[loop.index0].gateway_ip }}"
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ port_num: {{ networks.uplink[port_num].port_num }}
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ port_num: {{ networks.downlink[port_num].port_num }}
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_mpls_tagging-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_mpls_tagging-scale-up.yaml
new file mode 100644
index 000000000..04a6ce659
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_ovs-dpdk_mpls_tagging-scale-up.yaml
@@ -0,0 +1,101 @@
+# Copyright (c) 2018-2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+{% set duration = duration or 400 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_mpls_tag_untag.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_mpls_tag_untag-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_mpls_tag_untag-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: {{ duration }}
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneOvsDpdk
+ file: /etc/yardstick/nodes/standalone/host_ovs.yaml
+ vm_deploy: True
+ ovs_properties:
+ version:
+ ovs: 2.8.0
+ dpdk: 17.05.2
+ pmd_threads: 2
+ ram:
+ socket_0: 2048
+ socket_1: 2048
+ queues: 4
+ vpath: "/usr/local"
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ port_num: {{ networks.uplink[port_num].port_num }}
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ port_num: {{ networks.downlink[port_num].port_num }}
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_sriov_acl-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_sriov_acl-scale-up.yaml
new file mode 100644
index 000000000..7e810886d
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_sriov_acl-scale-up.yaml
@@ -0,0 +1,101 @@
+# Copyright (c) 2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+{% set duration = duration or 300 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ #
+ # In case where we know that all the packets generated by the generator
+ # will bw received. Then use prox_binsearch.
+ #
+ # In the case where some or all the packets generated by the generator may
+ # not be received. Please use prox_acl .. (This generates packets at
+ # a specific rate and does not change rate.
+ #
+ traffic_profile: ../../traffic_profiles/prox_acl.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg_0.yardstick
+ vnf__0: vnf_0.yardstick
+
+ options:
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_acl-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+ prox_files:
+ "configs/acl_rules-2.lua": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_acl-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: {{ duration }}
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneSriov
+ file: /etc/yardstick/nodes/standalone/host_sriov.yaml
+ vm_deploy: True
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ user: ""
+ password: ""
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd-scale-up.yaml
new file mode 100644
index 000000000..045ee77ae
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd-scale-up.yaml
@@ -0,0 +1,92 @@
+# Copyright (c) 2018 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_binsearch.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ interface_speed_gbps: 10
+
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_l2fwd-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_l2fwd-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: 600
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneSriov
+ file: /etc/yardstick/nodes/standalone/host_sriov.yaml
+ vm_deploy: True
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ user: "root"
+ password: ""
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ phy_port: "{{networks.uplink[port_num].phy_port}}"
+ vpci: "{{networks.uplink[port_num].vpci}}"
+ cidr: "{{networks.uplink[port_num].cidr}}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ phy_port: "{{networks.downlink[port_num].phy_port}}"
+ vpci: "{{networks.downlink[port_num].vpci}}"
+ cidr: "{{networks.downlink[port_num].cidr}}"
+ gateway_ip: "{{networks.downlink[port_num].gateway_ip}}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd_multiflow-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd_multiflow-scale-up.yaml
new file mode 100644
index 000000000..20dcc1c9f
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_sriov_l2fwd_multiflow-scale-up.yaml
@@ -0,0 +1,92 @@
+# Copyright (c) 2018-2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_binsearch.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ interface_speed_gbps: 10
+
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_l2fwd_multiflow-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_l2fwd_multiflow-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: 600
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneSriov
+ file: /etc/yardstick/nodes/standalone/host_sriov.yaml
+ vm_deploy: True
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ user: ""
+ password: ""
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/nsut/prox/tc_prox_sriov_mpls_tagging-scale-up.yaml b/samples/vnf_samples/nsut/prox/tc_prox_sriov_mpls_tagging-scale-up.yaml
new file mode 100644
index 000000000..25e7c22af
--- /dev/null
+++ b/samples/vnf_samples/nsut/prox/tc_prox_sriov_mpls_tagging-scale-up.yaml
@@ -0,0 +1,91 @@
+# Copyright (c) 2018-2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+{% set vports = vports or 2 %}
+{% set duration = duration or 400 %}
+---
+schema: "yardstick:task:0.1"
+
+scenarios:
+-
+ type: NSPerf
+ traffic_profile: ../../traffic_profiles/prox_mpls_tag_untag.yaml
+ extra_args:
+ vports: {{ vports }}
+ topology: prox-tg-topology-scale-up.yaml
+
+ nodes:
+ tg__0: tg__0.yardstick
+ vnf__0: vnf__0.yardstick
+
+ options:
+ vnf__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/handle_mpls_tag_untag-{{ vports }}.cfg"
+ prox_args:
+ "-t": ""
+
+ tg__0:
+ prox_path: /opt/nsb_bin/prox
+ prox_config: "configs/gen_mpls_tag_untag-{{ vports }}.cfg"
+ prox_args:
+ "-e": ""
+ "-t": ""
+
+ runner:
+ type: Duration
+ # we kill after duration, independent of test duration, so set this high
+ duration: {{ duration }}
+
+contexts:
+ - name: yardstick
+ type: Node
+ file: prox_tg_bm.yaml
+ - name: yardstick
+ type: StandaloneSriov
+ file: /etc/yardstick/nodes/standalone/host_sriov.yaml
+ vm_deploy: True
+ flavor:
+ images: "/var/lib/libvirt/images/yardstick-nsb-image.img"
+ ram: 16384
+ extra_specs:
+ hw:cpu_sockets: 1
+ hw:cpu_cores: 10
+ hw:cpu_threads: 2
+ user: ""
+ password: ""
+ servers:
+ vnf__0:
+ network_ports:
+ mgmt:
+ cidr: '1.1.1.62/24'
+{% for port_num in range((vports/2)|int) %}
+ xe{{ port_num * 2 }}:
+ - uplink_{{ port_num }}
+ xe{{ (port_num * 2) + 1 }}:
+ - downlink_{{ port_num }}
+{% endfor %}
+ networks:
+{% for port_num in range((vports/2)|int) %}
+ uplink_{{ port_num }}:
+ phy_port: "{{ networks.uplink[port_num].phy_port }}"
+ vpci: "{{ networks.uplink[port_num].vpci }}"
+ cidr: "{{ networks.uplink[port_num].cidr }}"
+ gateway_ip: "{{ networks.uplink[port_num].gateway_ip }}"
+ downlink_{{ port_num }}:
+ phy_port: "{{ networks.downlink[port_num].phy_port }}"
+ vpci: "{{ networks.downlink[port_num].vpci }}"
+ cidr: "{{ networks.downlink[port_num].cidr }}"
+ gateway_ip: "{{ networks.downlink[port_num].gateway_ip }}"
+{% endfor %}
diff --git a/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_L3.yaml b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_L3.yaml
new file mode 100644
index 000000000..24688fe95
--- /dev/null
+++ b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_L3.yaml
@@ -0,0 +1,64 @@
+# Copyright (c) 2018-2019 Intel Corporation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+{% set vports = get(extra_args, 'vports', '2') %}
+---
+schema: "nsb:traffic_profile:0.1"
+
+# This file is a template, it will be filled with values from tc.yaml before passing to the traffic generator
+
+name: rfc2544
+description: Traffic profile to run RFC2544 latency with L3 support
+traffic_profile:
+ traffic_type : IXIARFC2544Profile # defines traffic behavior - constant or look for highest possible throughput
+ frame_rate : 100% # pc of linerate
+ duration: {{ duration }}
+ enable_latency: True
+
+{% for vport in range(vports|int) %}
+uplink_{{ vport }}:
+ ipv4:
+ id: {{ (vport * 2) + 1 }}
+ outer_l2:
+ framesize:
+ 64B: "{{get(imix, 'imix.uplink.64B', '0') }}"
+ 128B: "{{get(imix, 'imix.uplink.128B', '0') }}"
+ 256B: "{{get(imix, 'imix.uplink.256B', '0') }}"
+ 373b: "{{get(imix, 'imix.uplink.373B', '0') }}"
+ 512B: "{{get(imix, 'imix.uplink.512B', '0') }}"
+ 570B: "{{get(imix, 'imix.uplink.570B', '0') }}"
+ 1024B: "{{get(imix, 'imix.uplink.1024B', '0') }}"
+ 1280B: "{{get(imix, 'imix.uplink.1280B', '0') }}"
+ 1400B: "{{get(imix, 'imix.uplink.1400B', '0') }}"
+ 1500B: "{{get(imix, 'imix.uplink.1500B', '0') }}"
+ 1518B: "{{get(imix, 'imix.uplink.1518B', '0') }}"
+
+downlink_{{vport}}:
+ ipv4:
+ id: {{ (vport * 2) + 2 }}
+ outer_l2:
+ framesize:
+ 64B: "{{get(imix, 'imix.downlink.64B', '0') }}"
+ 128B: "{{get(imix, 'imix.downlink.128B', '0') }}"
+ 256B: "{{get(imix, 'imix.downlink.256B', '0') }}"
+ 373b: "{{get(imix, 'imix.downlink.373B', '0') }}"
+ 512B: "{{get(imix, 'imix.downlink.512B', '0') }}"
+ 570B: "{{get(imix, 'imix.downlink.570B', '0') }}"
+ 1024B: "{{get(imix, 'imix.downlink.1024B', '0') }}"
+ 1280B: "{{get(imix, 'imix.downlink.1280B', '0') }}"
+ 1400B: "{{get(imix, 'imix.downlink.1400B', '0') }}"
+ 1500B: "{{get(imix, 'imix.downlink.1500B', '0') }}"
+ 1518B: "{{get(imix, 'imix.downlink.1518B', '0') }}"
+{% endfor %}
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml
index 08037d9fa..1ed3a3ea6 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml
@@ -40,8 +40,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml
index bc7cd3d28..b23855dc1 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml
index 3b04cc4bd..5bbe72610 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml
index d199e5117..a8783d6e8 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml
index 2bca1fb9d..6a4dc8798 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml
index c2a4f9ede..7b5f77813 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml
@@ -36,8 +36,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
-
monitor_type: "openstack-cmd"
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml
index 9194d9d4e..41314be27 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml
@@ -61,8 +61,6 @@ scenarios:
process_name: "{{ attack_process }}"
host: {{attack_host}}
monitor_time: 30
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml
index 06d460032..effb20a48 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml
@@ -37,8 +37,6 @@ scenarios:
host: {{attack_host}}
key: "monitor-recovery"
monitor_time: 30
- sla:
- max_recover_time: 30
-
monitor_type: "general-monitor"
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc088.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc088.yaml
index c2f1cbe33..c1b065711 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc088.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc088.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
operations:
-
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc089.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc089.yaml
index d10650e03..9379d2f75 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc089.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc089.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
operations:
-
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc090.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc090.yaml
index 41372045d..eaf14f60e 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc090.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc090.yaml
@@ -57,8 +57,6 @@ scenarios:
host: {{attack_host}}
monitor_time: {{monitor_time}}
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc091.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc091.yaml
index d952464a1..54ef6f237 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc091.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc091.yaml
@@ -38,8 +38,6 @@ scenarios:
host: {{attack_host}}
monitor_time: 30
monitor_number: 3
- sla:
- max_recover_time: 30
nodes:
{{attack_host}}: {{attack_host}}.LF
diff --git a/yardstick/benchmark/contexts/heat.py b/yardstick/benchmark/contexts/heat.py
index c3c5451bd..f4c48f4a5 100644
--- a/yardstick/benchmark/contexts/heat.py
+++ b/yardstick/benchmark/contexts/heat.py
@@ -508,10 +508,12 @@ class HeatContext(Context):
pkey = pkg_resources.resource_string(
'yardstick.resources',
h_join('files/yardstick_key', self.name)).decode('utf-8')
-
+ key_filename = pkg_resources.resource_filename('yardstick.resources',
+ h_join('files/yardstick_key', self.name))
result = {
"user": server.context.user,
"pkey": pkey,
+ "key_filename": key_filename,
"private_ip": server.private_ip,
"interfaces": server.interfaces,
"routing_table": self.generate_routing_table(server),
diff --git a/yardstick/benchmark/core/report.py b/yardstick/benchmark/core/report.py
index 0bc392fe5..0819cd497 100644
--- a/yardstick/benchmark/core/report.py
+++ b/yardstick/benchmark/core/report.py
@@ -10,13 +10,12 @@
""" Handler for yardstick command 'report' """
-import ast
import re
+import six
import uuid
import jinja2
from api.utils import influx
-from oslo_utils import encodeutils
from oslo_utils import uuidutils
from yardstick.common import constants as consts
from yardstick.common.utils import cliargs
@@ -55,11 +54,9 @@ class JSTree(object):
def format_for_jstree(self, data):
"""Format the data into the required format for jsTree.
- The data format expected is a list of key-value pairs which represent
- the data and label for each metric e.g.:
+ The data format expected is a list of metric names e.g.:
- [{'data': [0, ], 'label': 'tg__0.DropPackets'},
- {'data': [548, ], 'label': 'tg__0.LatencyAvg.5'},]
+ ['tg__0.DropPackets', 'tg__0.LatencyAvg.5']
This data is converted into the format required for jsTree to group and
display the metrics in a hierarchial fashion, including creating a
@@ -76,8 +73,8 @@ class JSTree(object):
self._created_nodes = ['#']
self.jstree_data = []
- for item in data:
- self._create_node(item["label"])
+ for metric in data:
+ self._create_node(metric)
return self.jstree_data
@@ -115,10 +112,10 @@ class Report(object):
else:
raise KeyError("Test case not found.")
- def _get_tasks(self):
- task_cmd = "select * from \"%s\" where task_id= '%s'"
- task_query = task_cmd % (self.yaml_name, self.task_id)
- query_exec = influx.query(task_query)
+ def _get_metrics(self):
+ metrics_cmd = "select * from \"%s\" where task_id = '%s'"
+ metrics_query = metrics_cmd % (self.yaml_name, self.task_id)
+ query_exec = influx.query(metrics_query)
if query_exec:
return query_exec
else:
@@ -132,38 +129,72 @@ class Report(object):
"""
self._validate(args.yaml_name[0], args.task_id[0])
- self.db_fieldkeys = self._get_fieldkeys()
+ db_fieldkeys = self._get_fieldkeys()
+ # list of dicts of:
+ # - PY2: unicode key and unicode value
+ # - PY3: str key and str value
- self.db_task = self._get_tasks()
+ db_metrics = self._get_metrics()
+ # list of dicts of:
+ # - PY2: unicode key and { None | unicode | float | long | int } value
+ # - PY3: str key and { None | str | float | int } value
- field_keys = []
- datasets = []
- table_vals = {}
+ # extract fieldKey entries, and convert them to str where needed
+ field_keys = [key if isinstance(key, str) # PY3: already str
+ else key.encode('utf8') # PY2: unicode to str
+ for key in
+ [field['fieldKey']
+ for field in db_fieldkeys]]
- field_keys = [encodeutils.to_utf8(field['fieldKey'])
- for field in self.db_fieldkeys]
+ # extract timestamps
+ self.Timestamp = []
+ for metric in db_metrics:
+ metric_time = metric['time'] # in RFC3339 format
+ if not isinstance(metric_time, str):
+ metric_time = metric_time.encode('utf8') # PY2: unicode to str
+ metric_time = metric_time[11:] # skip date, keep time
+ head, _, tail = metric_time.partition('.') # split HH:MM:SS and nsZ
+ metric_time = head + '.' + tail[:6] # join HH:MM:SS and .us
+ self.Timestamp.append(metric_time) # HH:MM:SS.micros
+
+ # prepare return values
+ datasets = []
+ table_vals = {'Timestamp': self.Timestamp}
+ # extract and convert field values
for key in field_keys:
- self.Timestamp = []
values = []
- for task in self.db_task:
- task_time = encodeutils.to_utf8(task['time'])
- if not isinstance(task_time, str):
- task_time = str(task_time, 'utf8')
- if not isinstance(key, str):
- key = str(key, 'utf8')
- task_time = task_time[11:]
- head, _, tail = task_time.partition('.')
- task_time = head + "." + tail[:6]
- self.Timestamp.append(task_time)
- if task[key] is None:
- values.append(None)
- elif isinstance(task[key], (int, float)):
- values.append(task[key])
+ for metric in db_metrics:
+ val = metric.get(key, None)
+ if val is None:
+ # keep explicit None or missing entry as is
+ pass
+ elif isinstance(val, (int, float)):
+ # keep plain int or float as is
+ pass
+ elif six.PY2 and isinstance(val,
+ long): # pylint: disable=undefined-variable
+ # PY2: long value would be rendered with trailing L,
+ # which JS does not support, so convert it to float
+ val = float(val)
+ elif isinstance(val, six.string_types):
+ s = val
+ if not isinstance(s, str):
+ s = s.encode('utf8') # PY2: unicode to str
+ try:
+ # convert until failure
+ val = s
+ val = float(s)
+ val = int(s)
+ if six.PY2 and isinstance(val,
+ long): # pylint: disable=undefined-variable
+ val = float(val) # PY2: long to float
+ except ValueError:
+ pass
else:
- values.append(ast.literal_eval(task[key]))
+ raise ValueError("Cannot convert %r" % val)
+ values.append(val)
datasets.append({'label': key, 'data': values})
- table_vals['Timestamp'] = self.Timestamp
table_vals[key] = values
return datasets, table_vals
@@ -197,8 +228,14 @@ class Report(object):
@cliargs("yaml_name", type=str, help=" Yaml file Name", nargs=1)
def generate_nsb(self, args):
"""Start NSB report generation."""
- datasets, table_vals = self._generate_common(args)
- jstree_data = JSTree().format_for_jstree(datasets)
+ _, report_data = self._generate_common(args)
+ report_time = report_data.pop('Timestamp')
+ report_keys = sorted(report_data, key=str.lower)
+ report_tree = JSTree().format_for_jstree(report_keys)
+ report_meta = {
+ "testcase": self.yaml_name,
+ "task_id": self.task_id,
+ }
template_dir = consts.YARDSTICK_ROOT_PATH + "yardstick/common"
template_environment = jinja2.Environment(
@@ -207,10 +244,11 @@ class Report(object):
lstrip_blocks=True)
context = {
- "Timestamps": self.Timestamp,
- "task_id": self.task_id,
- "table": table_vals,
- "jstree_nodes": jstree_data,
+ "report_meta": report_meta,
+ "report_data": report_data,
+ "report_time": report_time,
+ "report_keys": report_keys,
+ "report_tree": report_tree,
}
template_html = template_environment.get_template("nsb_report.html.j2")
diff --git a/yardstick/benchmark/scenarios/availability/monitor/monitor_multi.py b/yardstick/benchmark/scenarios/availability/monitor/monitor_multi.py
index 971bae1e9..8f1f53cde 100644
--- a/yardstick/benchmark/scenarios/availability/monitor/monitor_multi.py
+++ b/yardstick/benchmark/scenarios/availability/monitor/monitor_multi.py
@@ -62,20 +62,19 @@ class MultiMonitor(basemonitor.BaseMonitor):
outage_time = (
last_outage - first_outage if last_outage > first_outage else 0
)
+ self._result = {"outage_time": outage_time}
LOG.debug("outage_time is: %f", outage_time)
max_outage_time = 0
- if "max_outage_time" in self._config["sla"]:
- max_outage_time = self._config["sla"]["max_outage_time"]
- elif "max_recover_time" in self._config["sla"]:
- max_outage_time = self._config["sla"]["max_recover_time"]
- else:
- raise RuntimeError("'max_outage_time' or 'max_recover_time' "
- "config is not found")
- self._result = {"outage_time": outage_time}
-
- if outage_time > max_outage_time:
- LOG.error("SLA failure: %f > %f", outage_time, max_outage_time)
- return False
- else:
- return True
+ if self._config.get("sla"):
+ if "max_outage_time" in self._config["sla"]:
+ max_outage_time = self._config["sla"]["max_outage_time"]
+ elif "max_recover_time" in self._config["sla"]:
+ max_outage_time = self._config["sla"]["max_recover_time"]
+ else:
+ raise RuntimeError("'max_outage_time' or 'max_recover_time' "
+ "config is not found")
+ if outage_time > max_outage_time:
+ LOG.error("SLA failure: %f > %f", outage_time, max_outage_time)
+ return False
+ return True
diff --git a/yardstick/benchmark/scenarios/availability/monitor/monitor_process.py b/yardstick/benchmark/scenarios/availability/monitor/monitor_process.py
index 8d2f2633c..280e5811d 100644
--- a/yardstick/benchmark/scenarios/availability/monitor/monitor_process.py
+++ b/yardstick/benchmark/scenarios/availability/monitor/monitor_process.py
@@ -46,12 +46,12 @@ class MonitorProcess(basemonitor.BaseMonitor):
def verify_SLA(self):
outage_time = self._result.get('outage_time', None)
- max_outage_time = self._config["sla"]["max_recover_time"]
- if outage_time > max_outage_time:
- LOG.info("SLA failure: %f > %f", outage_time, max_outage_time)
- return False
- else:
- return True
+ if self._config.get("sla"):
+ max_outage_time = self._config["sla"]["max_recover_time"]
+ if outage_time > max_outage_time:
+ LOG.info("SLA failure: %f > %f", outage_time, max_outage_time)
+ return False
+ return True
def _test(): # pragma: no cover
diff --git a/yardstick/common/exceptions.py b/yardstick/common/exceptions.py
index 5e0df973a..f62f02f18 100644
--- a/yardstick/common/exceptions.py
+++ b/yardstick/common/exceptions.py
@@ -405,6 +405,10 @@ class IxNetworkFieldNotPresentInStackItem(YardstickException):
message = 'Field "%(field_name)s" not present in stack item %(stack_item)s'
+class IncorrectFlowOption(YardstickException):
+ message = 'Flow option {option} for {link} is incorrect'
+
+
class SLAValidationError(YardstickException):
message = '%(case_name)s SLA validation failed. Error: %(error_msg)s'
diff --git a/yardstick/common/nsb_report.css b/yardstick/common/nsb_report.css
index 2beb91c53..667f865a5 100644
--- a/yardstick/common/nsb_report.css
+++ b/yardstick/common/nsb_report.css
@@ -9,21 +9,26 @@
******************************************************************************/
body {
- font-size: 16pt;
+ font-family: Frutiger, "Helvetica Neue", Helvetica, Arial, sans-serif;
+}
+
+header {
+ padding-top: 5px;
+ text-align: center;
+ font-weight: bold;
}
-table {
+#tblMetrics {
overflow-y: scroll;
height: 360px;
display: block;
}
-header {
- font-family: Frutiger, "Helvetica Neue", Helvetica, Arial, sans-serif;
- clear: left;
- text-align: center;
+#cnvGraph {
+ width: 100%;
+ height: 500px;
}
-.control-pane {
+#divTree {
font-size: 10pt;
}
diff --git a/yardstick/common/nsb_report.html.j2 b/yardstick/common/nsb_report.html.j2
index a3087d746..aa90253f8 100644
--- a/yardstick/common/nsb_report.html.j2
+++ b/yardstick/common/nsb_report.html.j2
@@ -29,53 +29,45 @@
</head>
<body>
- <div class="container" style="width:80%">
+ <div class="container-fluid">
<div class="row">
- <header class="jumbotron">
- <h1>Yardstick User Interface</h1>
- <h4>Report of {{task_id}} Generated</h4>
+ <header>
+ Testcase: {{report_meta.testcase}}<br>
+ Task-ID: {{report_meta.task_id}}<br>
</header>
</div>
<div class="row">
- <div class="col-md-2 control-pane">
- <div id="data_selector"></div>
+ <div class="col-md-2">
+ <div id="divTree"></div>
</div>
- <div class="col-md-10 data-pane">
- <canvas id="cnvGraph" style="width: 100%; height: 500px"></canvas>
+ <div class="col-md-10">
+ <canvas id="cnvGraph"></canvas>
</div>
</div>
<div class="row">
<div class="col-md-12 table-responsive">
- <table class="table table-hover"></table>
+ <table id="tblMetrics" class="table table-condensed table-hover"></table>
</div>
</div>
</div>
<script>
- var arr, jstree_data, timestamps;
- arr = {{table|safe}};
- timestamps = {{Timestamps|safe}};
- jstree_data = {{jstree_nodes|safe}};
+ // Injected metrics, timestamps, keys and hierarchy
+ var report_data = {{report_data|safe}};
+ var report_time = {{report_time|safe}};
+ var report_keys = {{report_keys|safe}};
+ var report_tree = {{report_tree|safe}};
+ // Wait for DOM to be loaded
$(function() {
- create_table(arr);
- create_tree(jstree_data);
- var objGraph = create_graph($('#cnvGraph'), timestamps);
+ var tblMetrics = $('#tblMetrics');
+ var cnvGraph = $('#cnvGraph');
+ var divTree = $('#divTree');
- $('#data_selector').on('check_node.jstree uncheck_node.jstree', function(e, data) {
- var selected_datasets = [];
- for (var i = 0; i < data.selected.length; i++) {
- var node = data.instance.get_node(data.selected[i]);
- if (node.children.length == 0) {
- var dataset = {
- label: node.id,
- data: arr[node.id],
- };
- selected_datasets.push(dataset);
- }
- }
- update_graph(objGraph, selected_datasets);
- });
+ create_table(tblMetrics, report_data, report_time, report_keys);
+ var objGraph = create_graph(cnvGraph, report_time);
+ create_tree(divTree, report_tree);
+ handle_tree(divTree, tblMetrics, objGraph, report_data, report_time);
});
</script>
</body>
diff --git a/yardstick/common/nsb_report.js b/yardstick/common/nsb_report.js
index cc5e14ee7..4de1c8e78 100644
--- a/yardstick/common/nsb_report.js
+++ b/yardstick/common/nsb_report.js
@@ -10,9 +10,9 @@
var None = null;
-function create_tree(jstree_data)
+function create_tree(divTree, jstree_data)
{
- $('#data_selector').jstree({
+ divTree.jstree({
plugins: ['checkbox'],
checkbox: {
three_state: false,
@@ -29,34 +29,33 @@ function create_tree(jstree_data)
});
}
-// may need to pass timestamps too...
-function create_table(table_data)
+function create_table(tblMetrics, table_data, timestamps, table_keys)
{
- var tab, tr, td, tn, tbody, keys, key, curr_data, val;
- // create table
- tab = document.getElementsByTagName('table')[0];
- tbody = document.createElement('tbody');
+ var tbody = $('<tbody></tbody>');
+ var tr0 = $('<tr></tr>');
+ var th0 = $('<th></th>');
+ var td0 = $('<td></td>');
+ var tr;
+
+ // create table headings using timestamps
+ tr = tr0.clone().append(th0.clone().text('Timestamp'));
+ timestamps.forEach(function(t) {
+ tr.append(th0.clone().text(t));
+ });
+ tbody.append(tr);
+
// for each metric
- keys = Object.keys(table_data);
- for (var i = 0; i < keys.length; i++) {
- key = keys[i];
- tr = document.createElement('tr');
- td = document.createElement('td');
- tn = document.createTextNode(key);
- td.appendChild(tn);
- tr.appendChild(td);
+ table_keys.forEach(function(key) {
+ tr = tr0.clone().append(td0.clone().text(key));
// add each piece of data as its own column
- curr_data = table_data[key];
- for (var j = 0; j < curr_data.length; j++) {
- val = curr_data[j];
- td = document.createElement('td');
- tn = document.createTextNode(val === None ? '' : val);
- td.appendChild(tn);
- tr.appendChild(td);
- }
- tbody.appendChild(tr);
- }
- tab.appendChild(tbody);
+ table_data[key].forEach(function(val) {
+ tr.append(td0.clone().text(val === None ? '' : val));
+ });
+ tbody.append(tr);
+ });
+
+ // re-create table
+ tblMetrics.empty().append(tbody);
}
function create_graph(cnvGraph, timestamps)
@@ -144,3 +143,23 @@ function update_graph(objGraph, datasets)
objGraph.data.datasets = datasets;
objGraph.update();
}
+
+function handle_tree(divTree, tblMetrics, objGraph, table_data, timestamps)
+{
+ divTree.on('check_node.jstree uncheck_node.jstree', function(e, data) {
+ var selected_keys = [];
+ var selected_datasets = [];
+ data.selected.forEach(function(sel) {
+ var node = data.instance.get_node(sel);
+ if (node.children.length == 0) {
+ selected_keys.push(node.id);
+ selected_datasets.push({
+ label: node.id,
+ data: table_data[node.id],
+ });
+ }
+ });
+ create_table(tblMetrics, table_data, timestamps, selected_keys);
+ update_graph(objGraph, selected_datasets);
+ });
+}
diff --git a/yardstick/common/utils.py b/yardstick/common/utils.py
index 51313ef47..9eba896e2 100644
--- a/yardstick/common/utils.py
+++ b/yardstick/common/utils.py
@@ -293,6 +293,17 @@ def make_ipv4_address(ip_addr):
return ipaddress.IPv4Address(six.text_type(ip_addr))
+def get_ip_range_count(iprange):
+ start_range, end_range = iprange.split("-")
+ start = int(make_ipv4_address(start_range))
+ end = int(make_ipv4_address(end_range))
+ return end - start
+
+
+def get_ip_range_start(iprange):
+ return str(make_ipv4_address(iprange.split("-")[0]))
+
+
def safe_ip_address(ip_addr):
""" get ip address version v6 or v4 """
try:
diff --git a/yardstick/network_services/libs/ixia_libs/ixnet/ixnet_api.py b/yardstick/network_services/libs/ixia_libs/ixnet/ixnet_api.py
index d41dd028f..cc627ef78 100644
--- a/yardstick/network_services/libs/ixia_libs/ixnet/ixnet_api.py
+++ b/yardstick/network_services/libs/ixia_libs/ixnet/ixnet_api.py
@@ -152,6 +152,9 @@ class IxNextgen(object): # pragma: no cover
vports = self.ixnet.getList(self.ixnet.getRoot(), 'vport')
return vports
+ def get_static_interface(self, vport):
+ return self.ixnet.getList(vport, 'interface')
+
def _get_config_element_by_flow_group_name(self, flow_group_name):
"""Get a config element using the flow group name
diff --git a/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py b/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
index 1d37f8f6f..ae95843a5 100644
--- a/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
+++ b/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
@@ -1,4 +1,4 @@
-# Copyright (c) 2016-2017 Intel Corporation
+# Copyright (c) 2016-2019 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -17,6 +17,7 @@ import logging
import six
from yardstick.common import utils
+from yardstick.common import exceptions
from yardstick.network_services.libs.ixia_libs.ixnet import ixnet_api
from yardstick.network_services.vnf_generic.vnf.sample_vnf import SampleVNFTrafficGen
from yardstick.network_services.vnf_generic.vnf.sample_vnf import ClientResourceHelper
@@ -31,6 +32,8 @@ WAIT_PROTOCOLS_STARTED = 360
class IxiaBasicScenario(object):
+ """Ixia Basic scenario for flow from port to port"""
+
def __init__(self, client, context_cfg, ixia_cfg):
self.client = client
@@ -43,6 +46,12 @@ class IxiaBasicScenario(object):
def apply_config(self):
pass
+ def run_protocols(self):
+ pass
+
+ def stop_protocols(self):
+ pass
+
def create_traffic_model(self, traffic_profile=None):
# pylint: disable=unused-argument
vports = self.client.get_vports()
@@ -51,11 +60,81 @@ class IxiaBasicScenario(object):
self.client.create_traffic_model(self._uplink_vports,
self._downlink_vports)
- def run_protocols(self):
- pass
- def stop_protocols(self):
- pass
+class IxiaL3Scenario(IxiaBasicScenario):
+ """Ixia scenario for L3 flow between static ip's"""
+
+ def _add_static_ips(self):
+ vports = self.client.get_vports()
+ uplink_intf_vport = [(self.client.get_static_interface(vport), vport)
+ for vport in vports[::2]]
+ downlink_intf_vport = [(self.client.get_static_interface(vport), vport)
+ for vport in vports[1::2]]
+
+ for index in range(len(uplink_intf_vport)):
+ intf, vport = uplink_intf_vport[index]
+ try:
+ iprange = self.ixia_cfg['flow'].get('src_ip')[index]
+ start_ip = utils.get_ip_range_start(iprange)
+ count = utils.get_ip_range_count(iprange)
+ self.client.add_static_ipv4(intf, vport, start_ip, count, '32')
+ except IndexError:
+ raise exceptions.IncorrectFlowOption(
+ option="src_ip", link="uplink_{}".format(index))
+
+ intf, vport = downlink_intf_vport[index]
+ try:
+ iprange = self.ixia_cfg['flow'].get('dst_ip')[index]
+ start_ip = utils.get_ip_range_start(iprange)
+ count = utils.get_ip_range_count(iprange)
+ self.client.add_static_ipv4(intf, vport, start_ip, count, '32')
+ except IndexError:
+ raise exceptions.IncorrectFlowOption(
+ option="dst_ip", link="downlink_{}".format(index))
+
+ def _add_interfaces(self):
+ vports = self.client.get_vports()
+ uplink_vports = (vport for vport in vports[::2])
+ downlink_vports = (vport for vport in vports[1::2])
+
+ ix_node = next(node for _, node in self.context_cfg['nodes'].items()
+ if node['role'] == 'IxNet')
+
+ for intf in ix_node['interfaces'].values():
+ ip = intf.get('local_ip')
+ mac = intf.get('local_mac')
+ gateway = None
+ try:
+ gateway = next(route.get('gateway')
+ for route in ix_node.get('routing_table')
+ if route.get('if') == intf.get('ifname'))
+ except StopIteration:
+ LOG.debug("Gateway not provided")
+
+ if 'uplink' in intf.get('vld_id'):
+ self.client.add_interface(next(uplink_vports),
+ ip, mac, gateway)
+ else:
+ self.client.add_interface(next(downlink_vports),
+ ip, mac, gateway)
+
+ def apply_config(self):
+ self._add_interfaces()
+ self._add_static_ips()
+
+ def create_traffic_model(self, traffic_profile=None):
+ # pylint: disable=unused-argument
+ vports = self.client.get_vports()
+ self._uplink_vports = vports[::2]
+ self._downlink_vports = vports[1::2]
+
+ uplink_endpoints = [port + '/protocols/static'
+ for port in self._uplink_vports]
+ downlink_endpoints = [port + '/protocols/static'
+ for port in self._downlink_vports]
+
+ self.client.create_ipv4_traffic_model(uplink_endpoints,
+ downlink_endpoints)
class IxiaPppoeClientScenario(object):
@@ -370,6 +449,7 @@ class IxiaResourceHelper(ClientResourceHelper):
self._ixia_scenarios = {
"IxiaBasic": IxiaBasicScenario,
+ "IxiaL3": IxiaL3Scenario,
"IxiaPppoeClient": IxiaPppoeClientScenario,
}
diff --git a/yardstick/ssh.py b/yardstick/ssh.py
index 8bdc32c7c..2ebf40e98 100644
--- a/yardstick/ssh.py
+++ b/yardstick/ssh.py
@@ -89,14 +89,6 @@ def convert_key_to_str(key):
return k.getvalue()
-# class SSHError(Exception):
-# pass
-#
-#
-# class SSHTimeout(SSHError):
-# pass
-
-
class SSH(object):
"""Represent ssh connection."""
diff --git a/yardstick/tests/functional/benchmark/core/__init__.py b/yardstick/tests/functional/benchmark/core/__init__.py
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/yardstick/tests/functional/benchmark/core/__init__.py
diff --git a/yardstick/tests/functional/benchmark/core/test_report.py b/yardstick/tests/functional/benchmark/core/test_report.py
new file mode 100644
index 000000000..5f060dd1e
--- /dev/null
+++ b/yardstick/tests/functional/benchmark/core/test_report.py
@@ -0,0 +1,114 @@
+##############################################################################
+# Copyright (c) 2018 Intel Corporation.
+#
+# All rights reserved. This program and the accompanying materials
+# are made available under the terms of the Apache License, Version 2.0
+# which accompanies this distribution, and is available at
+# http://www.apache.org/licenses/LICENSE-2.0
+##############################################################################
+
+import ast
+import tempfile
+import unittest
+
+import mock
+from six.moves import configparser
+
+from yardstick.benchmark import core
+from yardstick.benchmark.core import report
+from yardstick.cmd.commands import change_osloobj_to_paras
+
+
+GOOD_YAML_NAME = 'fake_name'
+GOOD_TASK_ID = "9cbe74b6-df09-4535-8bdc-dc3a43b8a4e2"
+GOOD_DB_FIELDKEYS = [
+ {u'fieldKey': u'metric1', u'fieldType': u'integer'},
+ {u'fieldKey': u'metric4', u'fieldType': u'integer'},
+ {u'fieldKey': u'metric2', u'fieldType': u'integer'},
+ {u'fieldKey': u'metric3', u'fieldType': u'integer'},
+]
+GOOD_DB_METRICS = [
+ {u'time': u'2018-08-20T16:49:26.372662016Z',
+ u'metric1': 1, u'metric2': 0, u'metric3': 8, u'metric4': 5},
+ {u'time': u'2018-08-20T16:49:27.374208000Z',
+ u'metric1': 1, u'metric2': 1, u'metric3': 5, u'metric4': 4},
+ {u'time': u'2018-08-20T16:49:28.375742976Z',
+ u'metric1': 2, u'metric2': 2, u'metric3': 3, u'metric4': 3},
+ {u'time': u'2018-08-20T16:49:29.377299968Z',
+ u'metric1': 3, u'metric2': 3, u'metric3': 2, u'metric4': 2},
+ {u'time': u'2018-08-20T16:49:30.378252032Z',
+ u'metric1': 5, u'metric2': 4, u'metric3': 1, u'metric4': 1},
+ {u'time': u'2018-08-20T16:49:30.379359421Z',
+ u'metric1': 8, u'metric2': 5, u'metric3': 1, u'metric4': 0},
+]
+
+yardstick_config = """
+[DEFAULT]
+dispatcher = influxdb
+"""
+
+
+def my_query(query_sql):
+ get_fieldkeys_cmd = 'show field keys'
+ get_metrics_cmd = 'select * from'
+
+ if get_fieldkeys_cmd in query_sql:
+ return GOOD_DB_FIELDKEYS
+ elif get_metrics_cmd in query_sql:
+ return GOOD_DB_METRICS
+ return []
+
+
+class ReportTestCase(unittest.TestCase):
+
+ @mock.patch.object(report.influx, 'query', new=my_query)
+ @mock.patch.object(configparser.ConfigParser,
+ 'read', side_effect=mock.mock_open(read_data=yardstick_config))
+ def test_report_generate_nsb_simple(self, *args):
+ tmpfile = tempfile.NamedTemporaryFile(delete=True)
+
+ args = core.Param({"task_id": [GOOD_TASK_ID], "yaml_name": [GOOD_YAML_NAME]})
+ params = change_osloobj_to_paras(args)
+
+ with mock.patch.object(report.consts, 'DEFAULT_HTML_FILE', tmpfile.name):
+ report.Report().generate_nsb(params)
+
+ data_act = None
+ time_act = None
+ keys_act = None
+ tree_act = None
+ with open(tmpfile.name) as f:
+ for l in f.readlines():
+ if "var report_data = {" in l:
+ data_act = ast.literal_eval(l.strip()[18:-1])
+ elif "var report_time = [" in l:
+ time_act = ast.literal_eval(l.strip()[18:-1])
+ elif "var report_keys = [" in l:
+ keys_act = ast.literal_eval(l.strip()[18:-1])
+ elif "var report_tree = [" in l:
+ tree_act = ast.literal_eval(l.strip()[18:-1])
+
+ data_exp = {
+ 'metric1': [1, 1, 2, 3, 5, 8],
+ 'metric2': [0, 1, 2, 3, 4, 5],
+ 'metric3': [8, 5, 3, 2, 1, 1],
+ 'metric4': [5, 4, 3, 2, 1, 0],
+ }
+ time_exp = [
+ '16:49:26.372662', '16:49:27.374208', '16:49:28.375742',
+ '16:49:29.377299', '16:49:30.378252', '16:49:30.379359',
+ ]
+ keys_exp = [
+ 'metric1', 'metric2', 'metric3', 'metric4',
+ ]
+ tree_exp = [
+ {'parent': '#', 'text': 'metric1', 'id': 'metric1'},
+ {'parent': '#', 'text': 'metric2', 'id': 'metric2'},
+ {'parent': '#', 'text': 'metric3', 'id': 'metric3'},
+ {'parent': '#', 'text': 'metric4', 'id': 'metric4'},
+ ]
+
+ self.assertEqual(data_exp, data_act)
+ self.assertEqual(time_exp, time_act)
+ self.assertEqual(keys_exp, keys_act)
+ self.assertEqual(tree_exp, tree_act)
diff --git a/yardstick/tests/unit/benchmark/core/test_report.py b/yardstick/tests/unit/benchmark/core/test_report.py
index 11d017ff0..4683c26b0 100644
--- a/yardstick/tests/unit/benchmark/core/test_report.py
+++ b/yardstick/tests/unit/benchmark/core/test_report.py
@@ -9,6 +9,7 @@
##############################################################################
import mock
+import six
import unittest
import uuid
@@ -19,13 +20,82 @@ from yardstick.cmd.commands import change_osloobj_to_paras
GOOD_YAML_NAME = 'fake_name'
GOOD_TASK_ID = str(uuid.uuid4())
GOOD_DB_FIELDKEYS = [{'fieldKey': 'fake_key'}]
-GOOD_DB_TASK = [{
+GOOD_DB_METRICS = [{
'fake_key': 1.234,
'time': '0000-00-00T12:34:56.789012Z',
}]
GOOD_TIMESTAMP = ['12:34:56.789012']
BAD_YAML_NAME = 'F@KE_NAME'
BAD_TASK_ID = 'aaaaaa-aaaaaaaa-aaaaaaaaaa-aaaaaa'
+MORE_DB_FIELDKEYS = [
+ {'fieldKey': 'fake_key'},
+ {'fieldKey': 'str_str'},
+ {'fieldKey': u'str_unicode'},
+ {u'fieldKey': 'unicode_str'},
+ {u'fieldKey': u'unicode_unicode'},
+ ]
+MORE_DB_METRICS = [{
+ 'fake_key': None,
+ 'time': '0000-00-00T00:00:00.000000Z',
+ }, {
+ 'fake_key': 123,
+ 'time': '0000-00-00T00:00:01.000000Z',
+ }, {
+ 'fake_key': 4.56,
+ 'time': '0000-00-00T00:00:02.000000Z',
+ }, {
+ 'fake_key': 9876543210987654321,
+ 'time': '0000-00-00T00:00:03.000000Z',
+ }, {
+ 'fake_key': 'str_str value',
+ 'time': '0000-00-00T00:00:04.000000Z',
+ }, {
+ 'fake_key': u'str_unicode value',
+ 'time': '0000-00-00T00:00:05.000000Z',
+ }, {
+ u'fake_key': 'unicode_str value',
+ 'time': '0000-00-00T00:00:06.000000Z',
+ }, {
+ u'fake_key': u'unicode_unicode value',
+ 'time': '0000-00-00T00:00:07.000000Z',
+ }, {
+ 'fake_key': '7.89',
+ 'time': '0000-00-00T00:00:08.000000Z',
+ }, {
+ 'fake_key': '1011',
+ 'time': '0000-00-00T00:00:09.000000Z',
+ }, {
+ 'fake_key': '9876543210123456789',
+ 'time': '0000-00-00T00:00:10.000000Z',
+ }]
+MORE_TIMESTAMP = ['00:00:%02d.000000' % n for n in range(len(MORE_DB_METRICS))]
+MORE_EMPTY_DATA = [None] * len(MORE_DB_METRICS)
+MORE_EXPECTED_TABLE_VALS = {
+ 'Timestamp': MORE_TIMESTAMP,
+ 'fake_key': [
+ None,
+ 123,
+ 4.56,
+ 9876543210987654321 if six.PY3 else 9.876543210987655e+18,
+ 'str_str value',
+ 'str_unicode value',
+ 'unicode_str value',
+ 'unicode_unicode value',
+ 7.89,
+ 1011,
+ 9876543210123456789 if six.PY3 else 9.876543210123457e+18,
+ ],
+ 'str_str': MORE_EMPTY_DATA,
+ 'str_unicode': MORE_EMPTY_DATA,
+ 'unicode_str': MORE_EMPTY_DATA,
+ 'unicode_unicode': MORE_EMPTY_DATA,
+ }
+MORE_EXPECTED_DATASETS = [{
+ 'label': key,
+ 'data': MORE_EXPECTED_TABLE_VALS[key],
+ }
+ for key in map(str, [field['fieldKey'] for field in MORE_DB_FIELDKEYS])
+ ]
class JSTreeTestCase(unittest.TestCase):
@@ -47,23 +117,15 @@ class JSTreeTestCase(unittest.TestCase):
def test_format_for_jstree(self):
data = [
- {'data': [0, ], 'label': 'tg__0.DropPackets'},
- {'data': [548, ], 'label': 'tg__0.LatencyAvg.5'},
- {'data': [1172, ], 'label': 'tg__0.LatencyAvg.6'},
- {'data': [1001, ], 'label': 'tg__0.LatencyMax.5'},
- {'data': [1468, ], 'label': 'tg__0.LatencyMax.6'},
- {'data': [18.11, ], 'label': 'tg__0.RxThroughput'},
- {'data': [18.11, ], 'label': 'tg__0.TxThroughput'},
- {'data': [0, ], 'label': 'tg__1.DropPackets'},
- {'data': [548, ], 'label': 'tg__1.LatencyAvg.5'},
- {'data': [1172, ], 'label': 'tg__1.LatencyAvg.6'},
- {'data': [1001, ], 'label': 'tg__1.LatencyMax.5'},
- {'data': [1468, ], 'label': 'tg__1.LatencyMax.6'},
- {'data': [18.1132084505, ], 'label': 'tg__1.RxThroughput'},
- {'data': [18.1157260383, ], 'label': 'tg__1.TxThroughput'},
- {'data': [9057888, ], 'label': 'vnf__0.curr_packets_in'},
- {'data': [0, ], 'label': 'vnf__0.packets_dropped'},
- {'data': [617825443, ], 'label': 'vnf__0.packets_fwd'},
+ 'tg__0.DropPackets',
+ 'tg__0.LatencyAvg.5', 'tg__0.LatencyAvg.6',
+ 'tg__0.LatencyMax.5', 'tg__0.LatencyMax.6',
+ 'tg__0.RxThroughput', 'tg__0.TxThroughput',
+ 'tg__1.DropPackets',
+ 'tg__1.LatencyAvg.5', 'tg__1.LatencyAvg.6',
+ 'tg__1.LatencyMax.5', 'tg__1.LatencyMax.6',
+ 'tg__1.RxThroughput', 'tg__1.TxThroughput',
+ 'vnf__0.curr_packets_in', 'vnf__0.packets_dropped', 'vnf__0.packets_fwd',
]
expected_output = [
@@ -117,11 +179,11 @@ class ReportTestCase(unittest.TestCase):
self.assertEqual(GOOD_TASK_ID, str(self.rep.task_id))
def test__validate_invalid_yaml_name(self):
- with self.assertRaisesRegexp(ValueError, "yaml*"):
+ with six.assertRaisesRegex(self, ValueError, "yaml*"):
self.rep._validate(BAD_YAML_NAME, GOOD_TASK_ID)
def test__validate_invalid_task_id(self):
- with self.assertRaisesRegexp(ValueError, "task*"):
+ with six.assertRaisesRegex(self, ValueError, "task*"):
self.rep._validate(GOOD_YAML_NAME, BAD_TASK_ID)
@mock.patch.object(influx, 'query')
@@ -141,42 +203,51 @@ class ReportTestCase(unittest.TestCase):
mock_query.return_value = []
self.rep.yaml_name = GOOD_YAML_NAME
self.rep.task_id = GOOD_TASK_ID
- self.assertRaisesRegexp(KeyError, "Test case", self.rep._get_fieldkeys)
+ six.assertRaisesRegex(self, KeyError, "Test case", self.rep._get_fieldkeys)
@mock.patch.object(influx, 'query')
- def test__get_tasks(self, mock_query):
- mock_query.return_value = GOOD_DB_TASK
+ def test__get_metrics(self, mock_query):
+ mock_query.return_value = GOOD_DB_METRICS
self.rep.yaml_name = GOOD_YAML_NAME
self.rep.task_id = GOOD_TASK_ID
- self.assertEqual(GOOD_DB_TASK, self.rep._get_tasks())
+ self.assertEqual(GOOD_DB_METRICS, self.rep._get_metrics())
@mock.patch.object(influx, 'query')
- def test__get_tasks_task_not_found(self, mock_query):
+ def test__get_metrics_task_not_found(self, mock_query):
mock_query.return_value = []
self.rep.yaml_name = GOOD_YAML_NAME
self.rep.task_id = GOOD_TASK_ID
- self.assertRaisesRegexp(KeyError, "Task ID", self.rep._get_tasks)
+ six.assertRaisesRegex(self, KeyError, "Task ID", self.rep._get_metrics)
- @mock.patch.object(report.Report, '_get_tasks')
+ @mock.patch.object(report.Report, '_get_metrics')
+ @mock.patch.object(report.Report, '_get_fieldkeys')
+ def test__generate_common(self, mock_keys, mock_metrics):
+ mock_metrics.return_value = MORE_DB_METRICS
+ mock_keys.return_value = MORE_DB_FIELDKEYS
+ datasets, table_vals = self.rep._generate_common(self.param)
+ self.assertEqual(MORE_EXPECTED_DATASETS, datasets)
+ self.assertEqual(MORE_EXPECTED_TABLE_VALS, table_vals)
+
+ @mock.patch.object(report.Report, '_get_metrics')
@mock.patch.object(report.Report, '_get_fieldkeys')
@mock.patch.object(report.Report, '_validate')
- def test_generate(self, mock_valid, mock_keys, mock_tasks):
- mock_tasks.return_value = GOOD_DB_TASK
+ def test_generate(self, mock_valid, mock_keys, mock_metrics):
+ mock_metrics.return_value = GOOD_DB_METRICS
mock_keys.return_value = GOOD_DB_FIELDKEYS
self.rep.generate(self.param)
mock_valid.assert_called_once_with(GOOD_YAML_NAME, GOOD_TASK_ID)
- mock_tasks.assert_called_once_with()
+ mock_metrics.assert_called_once_with()
mock_keys.assert_called_once_with()
self.assertEqual(GOOD_TIMESTAMP, self.rep.Timestamp)
- @mock.patch.object(report.Report, '_get_tasks')
+ @mock.patch.object(report.Report, '_get_metrics')
@mock.patch.object(report.Report, '_get_fieldkeys')
@mock.patch.object(report.Report, '_validate')
- def test_generate_nsb(self, mock_valid, mock_keys, mock_tasks):
- mock_tasks.return_value = GOOD_DB_TASK
+ def test_generate_nsb(self, mock_valid, mock_keys, mock_metrics):
+ mock_metrics.return_value = GOOD_DB_METRICS
mock_keys.return_value = GOOD_DB_FIELDKEYS
self.rep.generate_nsb(self.param)
mock_valid.assert_called_once_with(GOOD_YAML_NAME, GOOD_TASK_ID)
- mock_tasks.assert_called_once_with()
+ mock_metrics.assert_called_once_with()
mock_keys.assert_called_once_with()
self.assertEqual(GOOD_TIMESTAMP, self.rep.Timestamp)
diff --git a/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_multi.py b/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_multi.py
index e9c680257..dc3a4b99a 100644
--- a/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_multi.py
+++ b/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_multi.py
@@ -63,3 +63,20 @@ class MultiMonitorServiceTestCase(unittest.TestCase):
ins.start_monitor()
ins.wait_monitor()
ins.verify_SLA()
+
+ def test__monitor_multi_no_sla(self, mock_open, mock_ssh):
+ monitor_cfg = {
+ 'monitor_type': 'general-monitor',
+ 'monitor_number': 3,
+ 'key': 'service-status',
+ 'monitor_key': 'service-status',
+ 'host': 'node1',
+ 'monitor_time': 0.1,
+ 'parameter': {'serviceName': 'haproxy'}
+ }
+ ins = monitor_multi.MultiMonitor(
+ monitor_cfg, self.context, {"nova-api": 10})
+ mock_ssh.SSH.from_node().execute.return_value = (0, "running", '')
+ ins.start_monitor()
+ ins.wait_monitor()
+ self.assertTrue(ins.verify_SLA())
diff --git a/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_process.py b/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_process.py
index a6d2ca398..8c73bf221 100644
--- a/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_process.py
+++ b/yardstick/tests/unit/benchmark/scenarios/availability/test_monitor_process.py
@@ -55,3 +55,19 @@ class MonitorProcessTestCase(unittest.TestCase):
ins.monitor_func()
ins._result = {"outage_time": 10}
ins.verify_SLA()
+
+ def test__monitor_process_no_sla(self, mock_ssh):
+
+ monitor_cfg = {
+ 'monitor_type': 'process',
+ 'process_name': 'nova-api',
+ 'host': "node1",
+ 'monitor_time': 1,
+ }
+ ins = monitor_process.MonitorProcess(monitor_cfg, self.context, {"nova-api": 10})
+
+ mock_ssh.SSH.from_node().execute.return_value = (0, "0", '')
+ ins.setup()
+ ins.monitor_func()
+ ins._result = {"outage_time": 10}
+ self.assertTrue(ins.verify_SLA())
diff --git a/yardstick/tests/unit/common/test_utils.py b/yardstick/tests/unit/common/test_utils.py
index c0c928916..6b8d81907 100644
--- a/yardstick/tests/unit/common/test_utils.py
+++ b/yardstick/tests/unit/common/test_utils.py
@@ -1135,6 +1135,15 @@ class TestUtilsIpAddrMethods(ut_base.BaseUnitTestCase):
for addr in addr_list:
self.assertRaises(Exception, utils.make_ipv4_address, addr)
+ def test_get_ip_range_count(self):
+ iprange = "192.168.0.1-192.168.0.25"
+ count = utils.get_ip_range_count(iprange)
+ self.assertEqual(count, 24)
+
+ def test_get_ip_range_start(self):
+ iprange = "192.168.0.1-192.168.0.25"
+ start = utils.get_ip_range_start(iprange)
+ self.assertEqual(start, "192.168.0.1")
def test_safe_ip_address(self):
addr_list = self.GOOD_IP_V4_ADDRESS_STR_LIST
diff --git a/yardstick/tests/unit/network_services/libs/ixia_libs/test_ixnet_api.py b/yardstick/tests/unit/network_services/libs/ixia_libs/test_ixnet_api.py
index 5b32a4297..110224742 100644
--- a/yardstick/tests/unit/network_services/libs/ixia_libs/test_ixnet_api.py
+++ b/yardstick/tests/unit/network_services/libs/ixia_libs/test_ixnet_api.py
@@ -103,6 +103,12 @@ class TestIxNextgen(unittest.TestCase):
self.ixnet.getRoot.return_value = 'my_root'
self.ixnet_gen = ixnet_api.IxNextgen()
self.ixnet_gen._ixnet = self.ixnet
+ self._mock_log = mock.patch.object(ixnet_api.log, 'info')
+ self.mock_log = self._mock_log.start()
+ self.addCleanup(self._stop_mocks)
+
+ def _stop_mocks(self):
+ self.mock_log.stop()
def test_get_config(self):
tg_cfg = {
diff --git a/yardstick/tests/unit/network_services/vnf_generic/vnf/test_sample_vnf.py b/yardstick/tests/unit/network_services/vnf_generic/vnf/test_sample_vnf.py
index 43682dd07..a1802aa55 100644
--- a/yardstick/tests/unit/network_services/vnf_generic/vnf/test_sample_vnf.py
+++ b/yardstick/tests/unit/network_services/vnf_generic/vnf/test_sample_vnf.py
@@ -17,12 +17,14 @@ from copy import deepcopy
import unittest
import mock
+import paramiko
+
from yardstick.common import exceptions as y_exceptions
from yardstick.common import utils
from yardstick.network_services.nfvi.resource import ResourceProfile
from yardstick.network_services.vnf_generic.vnf.base import VnfdHelper
from yardstick.network_services.vnf_generic.vnf import sample_vnf
-from yardstick.network_services.vnf_generic.vnf.vnf_ssh_helper import VnfSshHelper
+from yardstick.network_services.vnf_generic.vnf import vnf_ssh_helper
from yardstick.network_services.vnf_generic.vnf.sample_vnf import SampleVNFDeployHelper
from yardstick.network_services.vnf_generic.vnf.sample_vnf import ScenarioHelper
from yardstick.network_services.vnf_generic.vnf.sample_vnf import ResourceHelper
@@ -34,6 +36,7 @@ from yardstick.network_services.vnf_generic.vnf.sample_vnf import SampleVNFTraff
from yardstick.network_services.vnf_generic.vnf.sample_vnf import DpdkVnfSetupEnvHelper
from yardstick.tests.unit.network_services.vnf_generic.vnf import test_base
from yardstick.benchmark.contexts import base as ctx_base
+from yardstick import ssh
class MockError(Exception):
@@ -82,10 +85,11 @@ class TestVnfSshHelper(unittest.TestCase):
'virtual-interface': {
'dst_mac': '00:00:00:00:00:03',
'vpci': '0000:05:00.0',
+ 'dpdk_port_num': 0,
+ 'driver': 'i40e',
'local_ip': '152.16.100.19',
'type': 'PCI-PASSTHROUGH',
'netmask': '255.255.255.0',
- 'dpdk_port_num': 0,
'bandwidth': '10 Gbps',
'dst_ip': '152.16.100.20',
'local_mac': '00:00:00:00:00:01',
@@ -99,10 +103,11 @@ class TestVnfSshHelper(unittest.TestCase):
'virtual-interface': {
'dst_mac': '00:00:00:00:00:04',
'vpci': '0000:05:00.1',
+ 'dpdk_port_num': 1,
+ 'driver': 'ixgbe',
'local_ip': '152.16.40.19',
'type': 'PCI-PASSTHROUGH',
'netmask': '255.255.255.0',
- 'dpdk_port_num': 1,
'bandwidth': '10 Gbps',
'dst_ip': '152.16.40.20',
'local_mac': '00:00:00:00:00:02',
@@ -151,90 +156,88 @@ class TestVnfSshHelper(unittest.TestCase):
}
}
+ def setUp(self):
+ self.ssh_helper = vnf_ssh_helper.VnfSshHelper(
+ self.VNFD_0['mgmt-interface'], 'my/bin/path')
+ self.ssh_helper._run = mock.Mock()
+
def assertAll(self, iterable, message=None):
self.assertTrue(all(iterable), message)
def test_get_class(self):
- self.assertIs(VnfSshHelper.get_class(), VnfSshHelper)
+ self.assertIs(vnf_ssh_helper.VnfSshHelper.get_class(),
+ vnf_ssh_helper.VnfSshHelper)
- @mock.patch('yardstick.ssh.paramiko')
+ @mock.patch.object(ssh, 'paramiko')
def test_copy(self, _):
- ssh_helper = VnfSshHelper(self.VNFD_0['mgmt-interface'], 'my/bin/path')
- ssh_helper._run = mock.Mock()
-
- ssh_helper.execute('ls')
- self.assertTrue(ssh_helper.is_connected)
- result = ssh_helper.copy()
- self.assertIsInstance(result, VnfSshHelper)
+ self.ssh_helper.execute('ls')
+ self.assertTrue(self.ssh_helper.is_connected)
+ result = self.ssh_helper.copy()
+ self.assertIsInstance(result, vnf_ssh_helper.VnfSshHelper)
self.assertFalse(result.is_connected)
- self.assertEqual(result.bin_path, ssh_helper.bin_path)
- self.assertEqual(result.host, ssh_helper.host)
- self.assertEqual(result.port, ssh_helper.port)
- self.assertEqual(result.user, ssh_helper.user)
- self.assertEqual(result.password, ssh_helper.password)
- self.assertEqual(result.key_filename, ssh_helper.key_filename)
-
- @mock.patch('yardstick.ssh.paramiko')
+ self.assertEqual(result.bin_path, self.ssh_helper.bin_path)
+ self.assertEqual(result.host, self.ssh_helper.host)
+ self.assertEqual(result.port, self.ssh_helper.port)
+ self.assertEqual(result.user, self.ssh_helper.user)
+ self.assertEqual(result.password, self.ssh_helper.password)
+ self.assertEqual(result.key_filename, self.ssh_helper.key_filename)
+
+ @mock.patch.object(paramiko, 'SSHClient')
def test_upload_config_file(self, mock_paramiko):
- ssh_helper = VnfSshHelper(self.VNFD_0['mgmt-interface'], 'my/bin/path')
- ssh_helper._run = mock.MagicMock()
+ self.assertFalse(self.ssh_helper.is_connected)
+ cfg_file = self.ssh_helper.upload_config_file('/my/prefix', 'my content')
+ self.assertTrue(self.ssh_helper.is_connected)
+ mock_paramiko.assert_called_once()
+ self.assertEqual(cfg_file, '/my/prefix')
- self.assertFalse(ssh_helper.is_connected)
- cfg_file = ssh_helper.upload_config_file('my/prefix', 'my content')
- self.assertTrue(ssh_helper.is_connected)
- mock_paramiko.SSHClient.assert_called_once()
+ @mock.patch.object(paramiko, 'SSHClient')
+ def test_upload_config_file_path_does_not_exist(self, mock_paramiko):
+ self.assertFalse(self.ssh_helper.is_connected)
+ cfg_file = self.ssh_helper.upload_config_file('my/prefix', 'my content')
+ self.assertTrue(self.ssh_helper.is_connected)
+ mock_paramiko.assert_called_once()
self.assertTrue(cfg_file.startswith('/tmp'))
- cfg_file = ssh_helper.upload_config_file('/my/prefix', 'my content')
- self.assertTrue(ssh_helper.is_connected)
- mock_paramiko.SSHClient.assert_called_once()
- self.assertEqual(cfg_file, '/my/prefix')
-
def test_join_bin_path(self):
- ssh_helper = VnfSshHelper(self.VNFD_0['mgmt-interface'], 'my/bin/path')
-
expected_start = 'my'
expected_middle_list = ['bin']
expected_end = 'path'
- result = ssh_helper.join_bin_path()
+ result = self.ssh_helper.join_bin_path()
self.assertTrue(result.startswith(expected_start))
self.assertAll(middle in result for middle in expected_middle_list)
self.assertTrue(result.endswith(expected_end))
expected_middle_list.append(expected_end)
expected_end = 'some_file.sh'
- result = ssh_helper.join_bin_path('some_file.sh')
+ result = self.ssh_helper.join_bin_path('some_file.sh')
self.assertTrue(result.startswith(expected_start))
self.assertAll(middle in result for middle in expected_middle_list)
self.assertTrue(result.endswith(expected_end))
expected_middle_list.append('some_dir')
expected_end = 'some_file.sh'
- result = ssh_helper.join_bin_path('some_dir', 'some_file.sh')
+ result = self.ssh_helper.join_bin_path('some_dir', 'some_file.sh')
self.assertTrue(result.startswith(expected_start))
self.assertAll(middle in result for middle in expected_middle_list)
self.assertTrue(result.endswith(expected_end))
- @mock.patch('yardstick.ssh.paramiko')
- @mock.patch('yardstick.ssh.provision_tool')
+ @mock.patch.object(paramiko, 'SSHClient')
+ @mock.patch.object(ssh, 'provision_tool')
def test_provision_tool(self, mock_provision_tool, mock_paramiko):
- ssh_helper = VnfSshHelper(self.VNFD_0['mgmt-interface'], 'my/bin/path')
- ssh_helper._run = mock.MagicMock()
-
- self.assertFalse(ssh_helper.is_connected)
- ssh_helper.provision_tool()
- self.assertTrue(ssh_helper.is_connected)
- mock_paramiko.SSHClient.assert_called_once()
+ self.assertFalse(self.ssh_helper.is_connected)
+ self.ssh_helper.provision_tool()
+ self.assertTrue(self.ssh_helper.is_connected)
+ mock_paramiko.assert_called_once()
mock_provision_tool.assert_called_once()
- ssh_helper.provision_tool(tool_file='my_tool.sh')
- self.assertTrue(ssh_helper.is_connected)
- mock_paramiko.SSHClient.assert_called_once()
+ self.ssh_helper.provision_tool(tool_file='my_tool.sh')
+ self.assertTrue(self.ssh_helper.is_connected)
+ mock_paramiko.assert_called_once()
self.assertEqual(mock_provision_tool.call_count, 2)
- ssh_helper.provision_tool('tool_path', 'my_tool.sh')
- self.assertTrue(ssh_helper.is_connected)
- mock_paramiko.SSHClient.assert_called_once()
+ self.ssh_helper.provision_tool('tool_path', 'my_tool.sh')
+ self.assertTrue(self.ssh_helper.is_connected)
+ mock_paramiko.assert_called_once()
self.assertEqual(mock_provision_tool.call_count, 3)
diff --git a/yardstick/tests/unit/network_services/vnf_generic/vnf/test_tg_rfc2544_ixia.py b/yardstick/tests/unit/network_services/vnf_generic/vnf/test_tg_rfc2544_ixia.py
index 65bf56f1e..42cd71b16 100644
--- a/yardstick/tests/unit/network_services/vnf_generic/vnf/test_tg_rfc2544_ixia.py
+++ b/yardstick/tests/unit/network_services/vnf_generic/vnf/test_tg_rfc2544_ixia.py
@@ -1,4 +1,4 @@
-# Copyright (c) 2016-2017 Intel Corporation
+# Copyright (c) 2016-2019 Intel Corporation
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -432,7 +432,6 @@ class TestIXIATrafficGen(unittest.TestCase):
class TestIxiaBasicScenario(unittest.TestCase):
-
def setUp(self):
self._mock_IxNextgen = mock.patch.object(ixnet_api, 'IxNextgen')
self.mock_IxNextgen = self._mock_IxNextgen.start()
@@ -450,15 +449,15 @@ class TestIxiaBasicScenario(unittest.TestCase):
self.assertIsInstance(self.scenario, tg_rfc2544_ixia.IxiaBasicScenario)
self.assertEqual(self.scenario.client, self.mock_IxNextgen)
- def test_apply_config(self):
- self.assertIsNone(self.scenario.apply_config())
-
def test_create_traffic_model(self):
self.mock_IxNextgen.get_vports.return_value = [1, 2, 3, 4]
self.scenario.create_traffic_model()
self.scenario.client.get_vports.assert_called_once()
self.scenario.client.create_traffic_model.assert_called_once_with([1, 3], [2, 4])
+ def test_apply_config(self):
+ self.assertIsNone(self.scenario.apply_config())
+
def test_run_protocols(self):
self.assertIsNone(self.scenario.run_protocols())
@@ -466,6 +465,97 @@ class TestIxiaBasicScenario(unittest.TestCase):
self.assertIsNone(self.scenario.stop_protocols())
+class TestIxiaL3Scenario(TestIxiaBasicScenario):
+ IXIA_CFG = {
+ 'flow': {
+ 'src_ip': ['192.168.0.1-192.168.0.50'],
+ 'dst_ip': ['192.168.1.1-192.168.1.150']
+ }
+ }
+
+ CONTEXT_CFG = {
+ 'nodes': {
+ 'tg__0': {
+ 'role': 'IxNet',
+ 'interfaces': {
+ 'xe0': {
+ 'vld_id': 'uplink_0',
+ 'local_ip': '10.1.1.1',
+ 'local_mac': 'aa:bb:cc:dd:ee:ff',
+ 'ifname': 'xe0'
+ },
+ 'xe1': {
+ 'vld_id': 'downlink_0',
+ 'local_ip': '20.2.2.2',
+ 'local_mac': 'bb:bb:cc:dd:ee:ee',
+ 'ifname': 'xe1'
+ }
+ },
+ 'routing_table': [{
+ 'network': "152.16.100.20",
+ 'netmask': '255.255.0.0',
+ 'gateway': '152.16.100.21',
+ 'if': 'xe0'
+ }]
+ }
+ }
+ }
+
+ def setUp(self):
+ super(TestIxiaL3Scenario, self).setUp()
+ self.ixia_cfg = self.IXIA_CFG
+ self.context_cfg = self.CONTEXT_CFG
+ self.scenario = tg_rfc2544_ixia.IxiaL3Scenario(self.mock_IxNextgen,
+ self.context_cfg,
+ self.ixia_cfg)
+
+ def test___init___(self):
+ self.assertIsInstance(self.scenario, tg_rfc2544_ixia.IxiaL3Scenario)
+ self.assertEqual(self.scenario.client, self.mock_IxNextgen)
+
+ def test_create_traffic_model(self):
+ self.mock_IxNextgen.get_vports.return_value = ['1', '2']
+ self.scenario.create_traffic_model()
+ self.scenario.client.get_vports.assert_called_once()
+ self.scenario.client.create_ipv4_traffic_model.\
+ assert_called_once_with(['1/protocols/static'],
+ ['2/protocols/static'])
+
+ def test_apply_config(self):
+ self.scenario._add_interfaces = mock.Mock()
+ self.scenario._add_static_ips = mock.Mock()
+ self.assertIsNone(self.scenario.apply_config())
+
+ def test__add_static(self):
+ self.mock_IxNextgen.get_vports.return_value = ['1', '2']
+ self.mock_IxNextgen.get_static_interface.side_effect = ['intf1',
+ 'intf2']
+
+ self.scenario._add_static_ips()
+
+ self.mock_IxNextgen.get_static_interface.assert_any_call('1')
+ self.mock_IxNextgen.get_static_interface.assert_any_call('2')
+
+ self.scenario.client.add_static_ipv4.assert_any_call(
+ 'intf1', '1', '192.168.0.1', 49, '32')
+ self.scenario.client.add_static_ipv4.assert_any_call(
+ 'intf2', '2', '192.168.1.1', 149, '32')
+
+ def test__add_interfaces(self):
+ self.mock_IxNextgen.get_vports.return_value = ['1', '2']
+
+ self.scenario._add_interfaces()
+
+ self.mock_IxNextgen.add_interface.assert_any_call('1',
+ '10.1.1.1',
+ 'aa:bb:cc:dd:ee:ff',
+ '152.16.100.21')
+ self.mock_IxNextgen.add_interface.assert_any_call('2',
+ '20.2.2.2',
+ 'bb:bb:cc:dd:ee:ee',
+ None)
+
+
class TestIxiaPppoeClientScenario(unittest.TestCase):
IXIA_CFG = {