Merge "Suppress log outputs in test_task.py"
[yardstick.git] / docs / testing / user / userguide / 14-nsb-operation.rst
index 1180429..69ffb8a 100644 (file)
@@ -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
 ===================================
@@ -126,7 +136,7 @@ case, please follow the instructions below.
        image: yardstick-samplevnfs
        ...
        servers:
-         vnf__0:
+         vnf_0:
            ...
            availability_zone: <AZ_NAME>
            ...
@@ -322,8 +332,8 @@ Baremetal
        traffic_profile: ../../traffic_profiles/ipv4_throughput.yaml
        topology: vfw-tg-topology.yaml
        nodes:
-         tg__0: trafficgen_1.yardstick
-         vnf__0: vnf.yardstick
+         tg__0: trafficgen_0.yardstick
+         vnf__0: vnf_0.yardstick
        options:
          framesize:
            uplink: {64B: 100}
@@ -417,7 +427,7 @@ options section.
   scenarios:
     - type: NSPerf
       nodes:
-        tg__0: tg_0.yardstick
+        tg__0: trafficgen_0.yardstick
 
       options:
         tg_0:
@@ -600,3 +610,67 @@ may be changed.
 
 2. Subsection ``runner``: specifies the test duration and the interval of
 TG and VNF side KPIs polling. For more details, refer to :doc:`03-architecture`.
+
+Preparing test run of vPE test case
+-----------------------------------
+The vPE (Provider Edge Router) is a :term: `VNF` approximation
+serving as an Edge Router. The vPE is approximated using the
+``ip_pipeline`` dpdk application.
+
+         .. image:: images/vPE_Diagram.png
+            :width: 800px
+            :alt: NSB vPE Diagram
+
+The ``vpe_config`` file must be passed as it is not auto generated.
+The ``vpe_script`` defines the rules applied to each of the pipelines. This can be
+auto generated or a file can be passed using the ``script_file`` option in
+``vnf_config`` as shown below. The ``full_tm_profile_file`` option must be
+used if a traffic manager is defined in ``vpe_config``.
+
+.. code-block:: yaml
+
+     vnf_config: { file: './vpe_config/vpe_config_2_ports',
+                   action_bulk_file: './vpe_config/action_bulk_512.txt',
+                   full_tm_profile_file: './vpe_config/full_tm_profile_10G.cfg',
+                   script_file: './vpe_config/vpe_script_sample' }
+
+Testcases for vPE can be found in the ``vnf_samples/nsut/vpe`` directory.
+A testcase can be started with the following command as an example:
+
+.. code-block:: bash
+
+    yardstick task start /yardstick/samples/vnf_samples/nsut/vpe/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml
+
+Preparing test run of vIPSEC test case
+------------------------------------
+
+Location of vIPSEC test cases: ``samples/vnf_samples/nsut/ipsec/``.
+
+Before running a specific vIPSEC test case using NSB, some dependencies have to be
+preinstalled and properly configured.
+- VPP
+
+.. code-block:: console
+
+    export UBUNTU="xenial"
+    export RELEASE=".stable.1810"
+    sudo rm /etc/apt/sources.list.d/99fd.io.list
+    echo "deb [trusted=yes] https://nexus.fd.io/content/repositories/fd.io$RELEASE.ubuntu.$UBUNTU.main/ ./" | sudo tee -a /etc/apt/sources.list.d/99fd.io.list
+    sudo apt-get update
+    sudo apt-get install vpp vpp-lib vpp-plugin vpp-dbg vpp-dev vpp-api-java vpp-api-python vpp-api-lua
+
+- VAT templates
+
+    VAT templates is required for the VPP API.
+
+.. code-block:: console
+
+    mkdir -p /opt/nsb_bin/vpp/templates/
+    echo 'exec trace add dpdk-input 50' > /opt/nsb_bin/vpp/templates/enable_dpdk_traces.vat
+    echo 'exec trace add vhost-user-input 50' > /opt/nsb_bin/vpp/templates/enable_vhost_user_traces.vat
+    echo 'exec trace add memif-input 50' > /opt/nsb_bin/vpp/templates/enable_memif_traces.vat
+    cat > /opt/nsb_bin/vpp/templates/dump_interfaces.vat << EOL
+    sw_interface_dump
+    dump_interface_table
+    quit
+    EOL