diff options
107 files changed, 8470 insertions, 321 deletions
diff --git a/README.rst b/README.rst index 76ea9723c..5cf4fec00 100644 --- a/README.rst +++ b/README.rst @@ -48,7 +48,8 @@ For more information on Yardstick architecture, please read: Installation ------------ -Yardstick supports installation on Ubuntu 14.04 or via a Docker image. +Yardstick supports installation on Ubuntu 14.04, OpenSUSE Leap 42.2, 42.3 and +Tumbleweed or via a Docker image. To learn how to install Yardstick, consult the documentation available online at: diff --git a/ansible/roles/archive_spec_cpu2006_result/tasks/main.yaml b/ansible/roles/archive_spec_cpu2006_result/tasks/main.yaml index 7f72e1394..0282244ae 100644 --- a/ansible/roles/archive_spec_cpu2006_result/tasks/main.yaml +++ b/ansible/roles/archive_spec_cpu2006_result/tasks/main.yaml @@ -10,6 +10,5 @@ - name: archive_spec_cpu2006_result archive: - path: /usr/cpu2006/result - dest: /usr/cpu2006/spec_cpu2006_result.zip - become: true + path: ~/cpu2006/result + dest: ~/cpu2006/spec_cpu2006_result.zip diff --git a/ansible/roles/fetch_spec_cpu2006_result/tasks/main.yaml b/ansible/roles/fetch_spec_cpu2006_result/tasks/main.yaml index 370ec7a0c..ccc89000c 100644 --- a/ansible/roles/fetch_spec_cpu2006_result/tasks/main.yaml +++ b/ansible/roles/fetch_spec_cpu2006_result/tasks/main.yaml @@ -10,7 +10,6 @@ - name: fetch_spec_cpu2006_result fetch: - src: /usr/cpu2006/spec_cpu2006_result.zip + src: ~/cpu2006/spec_cpu2006_result.zip dest: /tmp/ flat: yes - become: true diff --git a/ansible/roles/install_spec_cpu2006/tasks/main.yaml b/ansible/roles/install_spec_cpu2006/tasks/main.yaml index baa9f6ca0..ea698f5a2 100644 --- a/ansible/roles/install_spec_cpu2006/tasks/main.yaml +++ b/ansible/roles/install_spec_cpu2006/tasks/main.yaml @@ -12,13 +12,11 @@ copy: src: /home/opnfv/repos/yardstick/yardstick/resources/cpu2006-1.2.iso dest: ~/cpu2006-1.2.iso - become: true - name: install SPEC CPU2006 shell: - mount -t iso9660 -o ro,exec ~/cpu2006-1.2.iso /mnt; + sudo mount -t iso9660 -o ro,exec ~/cpu2006-1.2.iso /mnt; cd /mnt; - ./install.sh -fd /usr/cpu2006; + ./install.sh -fd ~/cpu2006; args: executable: /bin/bash - become: true diff --git a/ansible/roles/unarchive_spec_cpu2006_result/tasks/main.yaml b/ansible/roles/unarchive_spec_cpu2006_result/tasks/main.yaml index 86dcc1aeb..07d15d1a9 100644 --- a/ansible/roles/unarchive_spec_cpu2006_result/tasks/main.yaml +++ b/ansible/roles/unarchive_spec_cpu2006_result/tasks/main.yaml @@ -13,4 +13,3 @@ src: /tmp/spec_cpu2006_result.zip dest: /tmp/ remote_src: True - become: true diff --git a/ansible/roles/uninstall_spec_cpu2006/tasks/main.yaml b/ansible/roles/uninstall_spec_cpu2006/tasks/main.yaml index 72d8c93ee..b2a50896e 100644 --- a/ansible/roles/uninstall_spec_cpu2006/tasks/main.yaml +++ b/ansible/roles/uninstall_spec_cpu2006/tasks/main.yaml @@ -10,9 +10,8 @@ - name: remove SPEC CPU 2006 file: - path: /usr/cpu2006 + path: ~/cpu2006 state: absent - become: true - name: umount SPEC CPU 2006 ISO shell: @@ -25,4 +24,3 @@ file: path: ~/cpu2006-1.2.iso state: absent - become: true diff --git a/docs/release/release-notes/release-notes.rst b/docs/release/release-notes/release-notes.rst index 873a35cf9..4ebf0eceb 100644 --- a/docs/release/release-notes/release-notes.rst +++ b/docs/release/release-notes/release-notes.rst @@ -30,13 +30,16 @@ This document describes the release note of Yardstick project. Version History --------------- -+------------------+-----------+---------------------------------+ -| *Date* | *Version* | *Comment* | -| | | | -+------------------+-----------+---------------------------------+ -| October 20, 2017 | 5.0.0 | Yardstick for Euphrates release | -| | | | -+------------------+-----------+---------------------------------+ ++-------------------+-----------+---------------------------------+ +| *Date* | *Version* | *Comment* | +| | | | ++-------------------+-----------+---------------------------------+ +| December 15, 2017 | 5.1.0 | Yardstick for Euphrates release | +| | | | ++-------------------+-----------+---------------------------------+ +| October 20, 2017 | 5.0.0 | Yardstick for Euphrates release | +| | | | ++-------------------+-----------+---------------------------------+ Important Notes @@ -129,19 +132,19 @@ Release Data | **Project** | Yardstick | | | | +--------------------------------+-----------------------+ -| **Repo/tag** | yardstick/opnfv-5.0.0 | +| **Repo/tag** | yardstick/opnfv-5.1.0 | | | | +--------------------------------+-----------------------+ -| **Yardstick Docker image tag** | opnfv-5.0.0 | +| **Yardstick Docker image tag** | opnfv-5.1.0 | | | | +--------------------------------+-----------------------+ | **Release designation** | Euphrates | | | | +--------------------------------+-----------------------+ -| **Release date** | October 20, 2017 | +| **Release date** | December 15, 2017 | | | | +--------------------------------+-----------------------+ -| **Purpose of the delivery** | OPNFV Euphrates 5.0.0 | +| **Purpose of the delivery** | OPNFV Euphrates 5.1.0 | | | | +--------------------------------+-----------------------+ @@ -161,7 +164,7 @@ Software Deliverables ^^^^^^^^^^^^^^^^^^^^^ - - The Yardstick Docker image: https://hub.docker.com/r/opnfv/yardstick (tag: opnfv-5.0.0) + - The Yardstick Docker image: https://hub.docker.com/r/opnfv/yardstick (tag: opnfv-5.1.0) New Contexts @@ -475,6 +478,52 @@ Known Issues/Faults Corrected Faults ^^^^^^^^^^^^^^^^ +Euphrates 5.1.0: + ++---------------------+-------------------------------------------------------------------------+ +| **JIRA REFERENCE** | **DESCRIPTION** | +| | | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-841 | Fix various NSB license issues | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-73 | How To Work with Test Cases | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-500 | VNF testing documentation | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-826 | Allow overriding Heat IP addresses to match traffic generator profile | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-828 | Refactor doc/testing/user/userguide "Yardstick Installation" | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-830 | build_yardstick_image Ansible mount module doesn't work on Ubuntu 14.04 | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-833 | ansible_common transform password into lower case | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-847 | tc006, tc079, tc082 miss grafana dashboard in local deployment | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-849 | kill process do not accurately kill the process like "nova-api" | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-850 | tc023 miss description and tc050-58 wrong description | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-852 | tc078 cpu2006 fails in some situation | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-854 | yardstick docker lack of trex_client | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-867 | testcase tc078 have no data stored or dashboard to show results | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-871 | Remove img_modify_playbook assignation in build_yardstick_image.yml | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-829 | "nsb_setup.sh" doesn't parse the controller IP correctly | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-839 | NSB Prox BM test cases to be fixed for incorporating scale-up | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-840 | NSB Prox test documentation of vPE and LW-AFTR test cases | ++---------------------+-------------------------------------------------------------------------+ +| JIRA: YARDSTICK-848 | NSB "Prox" : Cleanup duplicated traffic profile | ++---------------------+-------------------------------------------------------------------------+ + + + + Euphrates 5.0.0: +---------------------+--------------------------------------------+ @@ -507,18 +556,6 @@ Euphratess 5.0.0 known restrictions/issues +-----------+-----------+----------------------------------------------+ -Open JIRA tickets ------------------ - -+---------------------+----------------------------------------------+ -| **JIRA REFERENCE** | **DESCRIPTION** | -| | | -+---------------------+----------------------------------------------+ -| JIRA: YARDSTICK-412 | IPv6 test case should add support for newton | -| | | -+---------------------+----------------------------------------------+ - - Useful links ------------ diff --git a/docs/testing/developer/devguide/devguide.rst b/docs/testing/developer/devguide/devguide.rst index 1d47e5605..dade49b75 100755 --- a/docs/testing/developer/devguide/devguide.rst +++ b/docs/testing/developer/devguide/devguide.rst @@ -361,7 +361,7 @@ Verify your patch locally before submitting Once you finish a patch, you can submit it to Gerrit for code review. A developer sends a new patch to Gerrit will trigger patch verify job on Jenkins -CI. The yardstick patch verify job includes python flake8 check, unit test and +CI. The yardstick patch verify job includes python pylint check, unit test and code coverage test. Before you submit your patch, it is recommended to run the patch verification in your local environment first. diff --git a/docs/testing/user/userguide/04-installation.rst b/docs/testing/user/userguide/04-installation.rst index dc528db6c..828c49581 100644 --- a/docs/testing/user/userguide/04-installation.rst +++ b/docs/testing/user/userguide/04-installation.rst @@ -331,6 +331,91 @@ For uninstalling Yardstick, just delete the virtual environment:: rm -rf ~/yardstick_venv +Install Yardstick directly in OpenSUSE +-------------------------------------- + +.. _install-framework: + +You can install Yardstick framework directly in OpenSUSE. + + +Install Yardstick +^^^^^^^^^^^^^^^^^ + +Prerequisite preparation:: + + sudo -EH zypper -n install -y gcc \ + wget \ + git \ + sshpass \ + qemu-tools \ + kpartx \ + libffi-devel \ + libopenssl-devel \ + python \ + python-devel \ + python-virtualenv \ + libxml2-devel \ + libxslt-devel \ + python-setuptools-git + +Create a virtual environment:: + + virtualenv ~/yardstick_venv + export YARDSTICK_VENV=~/yardstick_venv + source ~/yardstick_venv/bin/activate + sudo -EH easy_install -U setuptools + +Download the source code and install Yardstick from it:: + + git clone https://gerrit.opnfv.org/gerrit/yardstick + export YARDSTICK_REPO_DIR=~/yardstick + cd yardstick + sudo -EH python setup.py install + sudo -EH pip install -r requirements.txt + +Install missing python modules:: + + sudo -EH pip install pyyaml \ + oslo_utils \ + oslo_serialization \ + oslo_config \ + paramiko \ + python.heatclient \ + python.novaclient \ + python.glanceclient \ + python.neutronclient \ + scp \ + jinja2 + + +Configure the Yardstick environment +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Source the OpenStack environment variables:: + + source DEVSTACK_DIRECTORY/openrc + +Export the Openstack external network. The default installation of Devstack +names the external network public:: + + export EXTERNAL_NETWORK=public + export OS_USERNAME=demo + +Change the API version used by Yardstick to v2.0 (the devstack openrc sets it +to v3):: + + export OS_AUTH_URL=http://PUBLIC_IP_ADDRESS:5000/v2.0 + + +Uninstall Yardstick +^^^^^^^^^^^^^^^^^^^ + +For unistalling Yardstick, just delete the virtual environment:: + + rm -rf ~/yardstick_venv + + Verify the installation ----------------------- diff --git a/docs/testing/user/userguide/nsb/nsb-list-of-tcs.rst b/docs/testing/user/userguide/nsb/nsb-list-of-tcs.rst index 43aa3d69a..895837283 100644 --- a/docs/testing/user/userguide/nsb/nsb-list-of-tcs.rst +++ b/docs/testing/user/userguide/nsb/nsb-list-of-tcs.rst @@ -26,3 +26,5 @@ NSB PROX Test Case Descriptions tc_prox_context_mpls_tagging_port tc_prox_context_buffering_port tc_prox_context_load_balancer_port + tc_prox_context_vpe_port + tc_prox_context_lw_after_port diff --git a/docs/testing/user/userguide/nsb/tc_prox_context_lw_aftr_port.rst b/docs/testing/user/userguide/nsb/tc_prox_context_lw_aftr_port.rst new file mode 100644 index 000000000..5a1fada05 --- /dev/null +++ b/docs/testing/user/userguide/nsb/tc_prox_context_lw_aftr_port.rst @@ -0,0 +1,107 @@ +.. This work is licensed under a Creative Commons Attribution 4.0 International +.. License. +.. http://creativecommons.org/licenses/by/4.0 +.. (c) OPNFV, 2017 Intel Corporation. + +************************************************ +Yardstick Test Case Description: NSB PROX LwAFTR +************************************************ + ++-----------------------------------------------------------------------------+ +|NSB PROX test for NFVI characterization | +| | ++--------------+--------------------------------------------------------------+ +|test case id | tc_prox_{context}_lw_aftr-{port_num} | +| | | +| | * context = baremetal or heat_context; | +| | * port_num = 4; | +| | | ++--------------+--------------------------------------------------------------+ +|metric | * Network Throughput; | +| | * TG Packets Out; | +| | * TG Packets In; | +| | * VNF Packets Out; | +| | * VNF Packets In; | +| | * Dropped packets; | +| | | ++--------------+--------------------------------------------------------------+ +|test purpose | The PROX LW_AFTR test will take packets in from one | +| | port and remove the ipv6 encapsulation and forward them to | +| | another port. While forwarded packets in other direction | +| | will be encapsulated in an ipv6 header. | +| | | +| | The lw_aftr test cases are implemented to run in baremetal | +| | and heat context an require 4 port topology to run the | +| | default configuration. | +| | | ++--------------+--------------------------------------------------------------+ +|configuration | The LW_AFTR test cases are listed below: | +| | | +| | * tc_prox_baremetal_lw_aftr-4.yaml | +| | * tc_prox_heat_context_lw_aftr-4.yaml | +| | | +| | Test duration is set as 300sec for each test. | +| | The minimum packet size for MPLS test is 68 bytes. This is | +| | set in the traffic profile and can be configured to use | +| | higher packet sizes. | +| | | ++--------------+--------------------------------------------------------------+ +|test tool | PROX | +| | PROX is a DPDK application that can simulate VNF workloads | +| | and can generate traffic and used for NFVI characterization | +| | | ++--------------+--------------------------------------------------------------+ +|applicability | The PROX lwAFTR test cases can be configured with | +| | different: | +| | | +| | * packet sizes; | +| | * test durations; | +| | * tolerated loss; | +| | | +| | Default values exist. | +| | | ++--------------+--------------------------------------------------------------+ +|pre-test | For Openstack test case image (yardstick-samplevnfs) needs | +|conditions | to be installed into Glance with Prox and Dpdk included in | +| | it. | +| | | +| | For Baremetal tests cases Prox and Dpdk must be installed in | +| | the hosts where the test is executed. The pod.yaml file must | +| | have the necessary system and NIC information | +| | | ++--------------+--------------------------------------------------------------+ +|test sequence | description and expected result | +| | | ++--------------+--------------------------------------------------------------+ +|step 1 | For Baremetal test: The TG and VNF are started on the hosts | +| | based on the pod file. | +| | | +| | For Heat test: Two host VMs are booted, as Traffic generator | +| | and VNF(LW_AFTR workload) based on the test flavor. | +| | | ++--------------+--------------------------------------------------------------+ +|step 2 | Yardstick is connected with the TG and VNF by using ssh. | +| | The test will resolve the topology and instantiate the VNF | +| | and TG and collect the KPI's/metrics. | +| | | ++--------------+--------------------------------------------------------------+ +|step 3 | The TG will send packets to the VNF. If the number of | +| | dropped packets is more than the tolerated loss the line | +| | rate or throughput is halved. This is done until the dropped | +| | packets are within an acceptable tolerated loss. | +| | | +| | The KPI is the number of packets per second for 86 bytes | +| | packet size with an accepted minimal packet loss for the | +| | default configuration. | +| | | ++--------------+--------------------------------------------------------------+ +|step 4 | In Baremetal test: The test quits the application and unbind | +| | the dpdk ports. | +| | | +| | In Heat test: Two host VMs are deleted on test completion. | +| | | ++--------------+--------------------------------------------------------------+ +|test verdict | The test case will achieve a Throughput with an accepted | +| | minimal tolerated packet loss. | ++--------------+--------------------------------------------------------------+ + diff --git a/docs/testing/user/userguide/nsb/tc_prox_context_vpe_port.rst b/docs/testing/user/userguide/nsb/tc_prox_context_vpe_port.rst new file mode 100644 index 000000000..6827b0525 --- /dev/null +++ b/docs/testing/user/userguide/nsb/tc_prox_context_vpe_port.rst @@ -0,0 +1,108 @@ +.. This work is licensed under a Creative Commons Attribution 4.0 International +.. License. +.. http://creativecommons.org/licenses/by/4.0 +.. (c) OPNFV, 2017 Intel Corporation. + +********************************************** +Yardstick Test Case Description: NSB PROXi VPE +********************************************** + ++-----------------------------------------------------------------------------+ +|NSB PROX test for NFVI characterization | +| | ++--------------+--------------------------------------------------------------+ +|test case id | tc_prox_{context}_vpe-{port_num} | +| | | +| | * context = baremetal or heat_context; | +| | * port_num = 4; | +| | | ++--------------+--------------------------------------------------------------+ +|metric | * Network Throughput; | +| | * TG Packets Out; | +| | * TG Packets In; | +| | * VNF Packets Out; | +| | * VNF Packets In; | +| | * Dropped packets; | +| | | ++--------------+--------------------------------------------------------------+ +|test purpose | The PROX VPE test handles packet processing, routing, QinQ | +| | encapsulation, flows, ACL rules, adds/removes MPLS tagging | +| | and performs QoS before forwarding packet to another port. | +| | The reverse applies to forwarded packets in the other | +| | direction. | +| | | +| | The VPE test cases are implemented to run in baremetal | +| | and heat context an require 4 port topology to run the | +| | default configuration. | +| | | ++--------------+--------------------------------------------------------------+ +|configuration | The VPE test cases are listed below: | +| | | +| | * tc_prox_baremetal_vpe-4.yaml | +| | * tc_prox_heat_context_vpe-4.yaml | +| | | +| | Test duration is set as 300sec for each test. | +| | The minimum packet size for VPE test is 68 bytes. This is | +| | set in the traffic profile and can be configured to use | +| | higher packet sizes. | +| | | ++--------------+--------------------------------------------------------------+ +|test tool | PROX | +| | PROX is a DPDK application that can simulate VNF workloads | +| | and can generate traffic and used for NFVI characterization | +| | | ++--------------+--------------------------------------------------------------+ +|applicability | The PROX VPE test cases can be configured with | +| | different: | +| | | +| | * packet sizes; | +| | * test durations; | +| | * tolerated loss; | +| | | +| | Default values exist. | +| | | ++--------------+--------------------------------------------------------------+ +|pre-test | For Openstack test case image (yardstick-samplevnfs) needs | +|conditions | to be installed into Glance with Prox and Dpdk included in | +| | it. | +| | | +| | For Baremetal tests cases Prox and Dpdk must be installed in | +| | the hosts where the test is executed. The pod.yaml file must | +| | have the necessary system and NIC information | +| | | ++--------------+--------------------------------------------------------------+ +|test sequence | description and expected result | +| | | ++--------------+--------------------------------------------------------------+ +|step 1 | For Baremetal test: The TG and VNF are started on the hosts | +| | based on the pod file. | +| | | +| | For Heat test: Two host VMs are booted, as Traffic generator | +| | and VNF(VPE workload) based on the test flavor. | +| | | ++--------------+--------------------------------------------------------------+ +|step 2 | Yardstick is connected with the TG and VNF by using ssh. | +| | The test will resolve the topology and instantiate the VNF | +| | and TG and collect the KPI's/metrics. | +| | | ++--------------+--------------------------------------------------------------+ +|step 3 | The TG will send packets to the VNF. If the number of | +| | dropped packets is more than the tolerated loss the line | +| | rate or throughput is halved. This is done until the dropped | +| | packets are within an acceptable tolerated loss. | +| | | +| | The KPI is the number of packets per second for 68 bytes | +| | packet size with an accepted minimal packet loss for the | +| | default configuration. | +| | | ++--------------+--------------------------------------------------------------+ +|step 4 | In Baremetal test: The test quits the application and unbind | +| | the dpdk ports. | +| | | +| | In Heat test: Two host VMs are deleted on test completion. | +| | | ++--------------+--------------------------------------------------------------+ +|test verdict | The test case will achieve a Throughput with an accepted | +| | minimal tolerated packet loss. | ++--------------+--------------------------------------------------------------+ + diff --git a/requirements.txt b/requirements.txt index 7715f8510..dec58b6b6 100644 --- a/requirements.txt +++ b/requirements.txt @@ -10,6 +10,7 @@ Babel==2.3.4 # BSD; OSI Approved BSD License Jinja2==2.8.1 # BSD; OSI Approved BSD License MarkupSafe==0.23 # BSD; OSI Approved BSD License +PTable==0.9.2 # BSD (3 clause); OSI Approved BSD License PyYAML==3.12 # MIT; OSI Approved MIT License SQLAlchemy==1.1.4 # MIT License; OSI Approved MIT License ansible==2.3.2 # GPLv3; OSI Approved GNU General Public License v3 or later (GPLv3+) @@ -58,7 +59,6 @@ pbr==1.10.0 # OSI Approved Apache Software License; Apache License, # version 14.5.0 for compatibility with trex traffic generator pika==0.10.0 # BSD; OSI Approved BSD License positional==1.1.1 # OSI Approved Apache Software License -prettytable==0.7.2 # BSD (3 clause); OSI Approved BSD License pycrypto==2.6.1 # Public Domain pyparsing==2.1.10 # MIT License; OSI Approved MIT License pyroute2==0.4.12 # dual license GPLv2+ and Apache v2; OSI Approved GNU General Public License v2 or later (GPLv2+); OSI Approved Apache Software License diff --git a/samples/vnf_samples/nsut/router/router-tg-topology-4port.yaml b/samples/vnf_samples/nsut/router/router-tg-topology-4port.yaml new file mode 100644 index 000000000..94c64e800 --- /dev/null +++ b/samples/vnf_samples/nsut/router/router-tg-topology-4port.yaml @@ -0,0 +1,70 @@ +# 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: router-tg-topology + name: router-tg-topology + short-name: router-tg-topology + description: router-tg-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/router_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/router/router-tg-topology-6port.yaml b/samples/vnf_samples/nsut/router/router-tg-topology-6port.yaml new file mode 100644 index 000000000..57695784e --- /dev/null +++ b/samples/vnf_samples/nsut/router/router-tg-topology-6port.yaml @@ -0,0 +1,90 @@ +# 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: router-tg-topology + name: router-tg-topology + short-name: router-tg-topology + description: router-tg-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/router_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 + - id: uplink_2 + name: tg__0 to vnf__0 link 5 + type: ELAN + vnfd-connection-point-ref: + - member-vnf-index-ref: '1' + vnfd-connection-point-ref: xe4 + vnfd-id-ref: tg__0 + - member-vnf-index-ref: '2' + vnfd-connection-point-ref: xe4 + vnfd-id-ref: vnf__0 + - id: downlink_2 + name: vnf__0 to tg__0 link 6 + type: ELAN + vnfd-connection-point-ref: + - member-vnf-index-ref: '2' + vnfd-connection-point-ref: xe5 + vnfd-id-ref: vnf__0 + - member-vnf-index-ref: '1' + vnfd-connection-point-ref: xe5 + vnfd-id-ref: tg__0 diff --git a/samples/vnf_samples/nsut/router/router-tg-topology.yaml b/samples/vnf_samples/nsut/router/router-tg-topology.yaml new file mode 100644 index 000000000..6e63760eb --- /dev/null +++ b/samples/vnf_samples/nsut/router/router-tg-topology.yaml @@ -0,0 +1,50 @@ +# 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/router_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/router/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml new file mode 100644 index 000000000..7b4db0e64 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_baremetal_rfc2544_ipv4_1flow_64B_trex.yaml @@ -0,0 +1,49 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26' + dst_ip: + - '152.16.40.26' + count: 1 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.0001 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +context: + type: Node + name: yardstick + nfvi_type: baremetal + file: /etc/yardstick/nodes/pod.yaml diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1024B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1024B.yaml new file mode 100644 index 000000000..5b268d09e --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1024B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1280B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1280B.yaml new file mode 100644 index 000000000..20305df7c --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1280B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_128B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_128B.yaml new file mode 100644 index 000000000..73459c340 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_128B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1518B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1518B.yaml new file mode 100644 index 000000000..fb7f48a2f --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_1518B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 2 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_256B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_256B.yaml new file mode 100644 index 000000000..c2bc0b7d2 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_256B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_512B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_512B.yaml new file mode 100644 index 000000000..bb17eb4b2 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_512B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_64B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_64B.yaml new file mode 100644 index 000000000..0726e1063 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_5cores_2ports_64B.yaml @@ -0,0 +1,102 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod.yaml + + - name: yardstick + image: vrouter_affinity_2c2p + flavor: + vcpus: 5 + ram: 20480 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 1 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_mem.0: 20480 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1024B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1024B.yaml new file mode 100644 index 000000000..6efc69c40 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1024B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1280B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1280B.yaml new file mode 100644 index 000000000..be08b5b39 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1280B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_128B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_128B.yaml new file mode 100644 index 000000000..afc4a6839 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_128B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1518B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1518B.yaml new file mode 100644 index 000000000..c0bbc8cdc --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_1518B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_256B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_256B.yaml new file mode 100644 index 000000000..c78f0c2c1 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_256B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_512B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_512B.yaml new file mode 100644 index 000000000..9d223299a --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_512B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_64B.yaml b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_64B.yaml new file mode 100644 index 000000000..45a8c2c5a --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_heat_external_rfc2544_ipv4_128Kflows_9cores_4ports_64B.yaml @@ -0,0 +1,120 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.baremetal + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: compute_0.compute_nodes + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '10.0.2.26-10.0.2.105' + - '10.0.4.26-10.0.4.105' + dst_ip: + - '10.0.3.26-10.0.3.105' + - '10.0.5.26-10.0.5.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: compute_nodes + type: Node + file: /etc/yardstick/nodes/compute.yaml + + - name: baremetal + type: Node + file: /etc/yardstick/nodes/pod_4p.yaml + + - name: yardstick + image: vrouter_affinity_2c4p + flavor: + vcpus: 9 + ram: 8192 + disk: 10 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + hw:mem_page_size: large + hw:cpu_policy: dedicated + hw:cpu_thread_policy: prefer + hw:numa_nodes: 2 + hw:numa_mempolicy: preffered + hw:numa_cpus.0: 0,1,2,3,4 + hw:numa_cpus.1: 5,6,7,8 + hw:numa_mem.0: 4096 + hw:numa_mem.1: 4096 + user: "root" + password: "password" + 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: phystenant2 + port_security_enabled: False + enable_dhcp: 'false' + xe1: + cidr: '10.0.3.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant3 + port_security_enabled: False + enable_dhcp: 'false' + xe2: + cidr: '10.0.4.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant4 + port_security_enabled: False + enable_dhcp: 'false' + xe3: + cidr: '10.0.5.0/24' + gateway_ip: 'null' + provider: true + physical_network: phystenant5 + port_security_enabled: False + enable_dhcp: 'false' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1024B_trex.yaml new file mode 100644 index 000000000..b3e4157f5 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1024B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads; use specific cpus + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1280B_trex.yaml new file mode 100644 index 000000000..6d1353297 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1280B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads; Use specific cpus + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_128B_trex.yaml new file mode 100644 index 000000000..99e9b8d0e --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_128B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads; use specific CPUs + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1518B_trex.yaml new file mode 100644 index 000000000..1a1be3732 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_1518B_trex.yaml @@ -0,0 +1,115 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 2 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_256B_trex.yaml new file mode 100644 index 000000000..6c30b621e --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_256B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads to use specific cpus + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_512B_trex.yaml new file mode 100644 index 000000000..ddb59cbe6 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_512B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads to use specific cpus + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_64B_trex.yaml new file mode 100644 index 000000000..c141f4e57 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_5cores_2ports_64B_trex.yaml @@ -0,0 +1,116 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + # override pmd_threads to use specific cpus + pmd_cpu_mask: "0x78" + lcore_mask: "0x4" + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_5cores.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 5 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='11'/> + <vcpupin vcpu='1' cpuset='12'/> + <vcpupin vcpu='2' cpuset='13'/> + <vcpupin vcpu='3' cpuset='14'/> + <vcpupin vcpu='4' cpuset='15'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml new file mode 100644 index 000000000..bfa5ba4f0 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml new file mode 100644 index 000000000..ea5fb16a9 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml new file mode 100644 index 000000000..fea64f5e7 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml new file mode 100644 index 000000000..ac38751e9 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml new file mode 100644 index 000000000..145f69d89 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml new file mode 100644 index 000000000..6417d9342 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml new file mode 100644 index 000000000..ae46b865f --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml @@ -0,0 +1,106 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 7 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 4 + ram: + socket_0: 2048 + socket_1: 2048 + queues: 4 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:1a:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:18:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml new file mode 100644 index 000000000..d947e254f --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml @@ -0,0 +1,141 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml new file mode 100644 index 000000000..0467436ba --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml @@ -0,0 +1,141 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + #gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + #gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml new file mode 100644 index 000000000..30119c76d --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml @@ -0,0 +1,141 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml new file mode 100644 index 000000000..ac52c29c5 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml @@ -0,0 +1,142 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 5 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + # 8 cores (CPU 22-29) in NUMA 1 of a 2 socket 20 cpus per socket + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml new file mode 100644 index 000000000..2767851a6 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml @@ -0,0 +1,141 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml new file mode 100644 index 000000000..006718fa2 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml @@ -0,0 +1,141 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml new file mode 100644 index 000000000..601d30891 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_ovs_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml @@ -0,0 +1,140 @@ +# 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-2.yaml + topology: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: ovs_dpdk.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + + - name: yardstick + type: StandaloneOvsDpdk + file: /etc/yardstick/nodes/standalone/pod_ovs.yaml + vm_deploy: True + ovs_properties: + version: + ovs: 2.7.0 + dpdk: 16.11.1 + pmd_threads: 8 + # override pmd_threads to use NUMA 1 vcpus + pmd_cpu_mask: "0x3FC00000" + lcore_mask: "0x200000" + ram: + socket_0: 0 + socket_1: 4096 + queues: 2 + vpath: "/usr/local" + + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + port_num: 0 + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + port_num: 1 + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + port_num: 2 + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + port_num: 3 + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1024B_trex.yaml new file mode 100644 index 000000000..18e25e25d --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1024B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1280B_trex.yaml new file mode 100644 index 000000000..bfaf74b5c --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1280B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_128B_trex.yaml new file mode 100644 index 000000000..529c8a5ef --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_128B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1518B_trex.yaml new file mode 100644 index 000000000..0d2cdfbc0 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_1518B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_256B_trex.yaml new file mode 100644 index 000000000..9e1e8ebd3 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_256B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_512B_trex.yaml new file mode 100644 index 000000000..4b3fbe4b3 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_512B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_64B_trex.yaml new file mode 100644 index 000000000..d23ab4e69 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_4ports_64B_trex.yaml @@ -0,0 +1,125 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_6ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_6ports_1518B_trex.yaml new file mode 100644 index 000000000..0353b3875 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_13cores_6ports_1518B_trex.yaml @@ -0,0 +1,141 @@ +# 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-3.yaml + topology: router-tg-topology-6port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + - '152.16.102.26-152.16.102.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + - '152.16.42.26-152.16.42.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_6ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_13cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 13 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='27'/> + <vcpupin vcpu='1' cpuset='28'/> + <vcpupin vcpu='2' cpuset='29'/> + <vcpupin vcpu='3' cpuset='30'/> + <vcpupin vcpu='4' cpuset='31'/> + <vcpupin vcpu='5' cpuset='32'/> + <vcpupin vcpu='6' cpuset='33'/> + <vcpupin vcpu='7' cpuset='34'/> + <vcpupin vcpu='8' cpuset='35'/> + <vcpupin vcpu='9' cpuset='36'/> + <vcpupin vcpu='10' cpuset='37'/> + <vcpupin vcpu='11' cpuset='38'/> + <vcpupin vcpu='12' cpuset='39'/> + <emulatorpin cpuset='27-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + xe4: + - uplink_2 + xe5: + - downlink_2 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:81:00.1" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + uplink_2: + phy_port: "0000:86:00.0" + vpci: "0000:00:0b.0" + cidr: '152.16.102.19/24' + gateway_ip: '152.16.102.20' + downlink_2: + phy_port: "0000:86:00.1" + vpci: "0000:00:0c.0" + cidr: '152.16.42.19/24' + gateway_ip: '152.16.42.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml new file mode 100644 index 000000000..4fa22975f --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1024B_trex.yaml @@ -0,0 +1,93 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 6 + hw:cpu_threads: 2 + user: "root" + password: "password" + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml new file mode 100644 index 000000000..a7acbafdd --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1280B_trex.yaml @@ -0,0 +1,93 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml new file mode 100644 index 000000000..121aaec4b --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_128B_trex.yaml @@ -0,0 +1,93 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml new file mode 100644 index 000000000..6e856c80e --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_1518B_trex.yaml @@ -0,0 +1,93 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml new file mode 100644 index 000000000..54a26bc49 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_256B_trex.yaml @@ -0,0 +1,92 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml new file mode 100644 index 000000000..1ed39c236 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_512B_trex.yaml @@ -0,0 +1,93 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml new file mode 100644 index 000000000..c128df37b --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_7cores_2ports_64B_trex.yaml @@ -0,0 +1,92 @@ +# 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: router-tg-topology.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick + cpt__0: sriov.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 4 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex.yaml + + - name: yardstick + type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu.qcow2" + ram: 4096 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 7 + hw:cpu_threads: 1 + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '192.168.18.185' + cidr: '192.168.18.185/30' + xe0: + - uplink_0 + xe1: + - downlink_0 + networks: + uplink_0: + phy_port: "0000:07:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:07:00.1" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.100.20' diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml new file mode 100644 index 000000000..7be7c991c --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1024B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1024B: 100} + downlink: {1024B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml new file mode 100644 index 000000000..cf73e1690 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1280B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1280B: 100} + downlink: {1280B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml new file mode 100644 index 000000000..493acb20b --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_128B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {128B: 100} + downlink: {128B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml new file mode 100644 index 000000000..6a88e3b8c --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_1518B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {1518B: 100} + downlink: {1518B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml new file mode 100644 index 000000000..79aba6043 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_256B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {256B: 100} + downlink: {256B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml new file mode 100644 index 000000000..f83c78872 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_512B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {512B: 100} + downlink: {512B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml new file mode 100644 index 000000000..2c4397233 --- /dev/null +++ b/samples/vnf_samples/nsut/router/tc_sriov_rfc2544_ipv4_128Kflows_9cores_4ports_64B_trex.yaml @@ -0,0 +1,121 @@ +# 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: router-tg-topology-4port.yaml + nodes: + tg__0: trafficgen_1.yardstick + vnf__0: vnf.yardstick +# Required for enabling NFVi collection + cpt__0: sriov.yardstick + options: + framesize: + uplink: {64B: 100} + downlink: {64B: 100} + flow: + src_ip: + - '152.16.100.26-152.16.100.105' + - '152.16.101.26-152.16.101.105' + dst_ip: + - '152.16.40.26-152.16.40.105' + - '152.16.41.26-152.16.41.105' + src_port: + - '1234-1238' + dst_port: + - '2001-2004' + count: 128000 + traffic_type: 4 + rfc2544: + allowed_drop_rate: 0.0001 - 0.1 + tg__0: + queues_per_port: 8 + vnf__0: + nfvi_enable: True + runner: + type: Iteration + iterations: 10 + interval: 35 +contexts: + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + - name: yardstick + type: Node + file: /etc/yardstick/nodes/standalone/pod_trex_4ports.yaml + - type: StandaloneSriov + file: /etc/yardstick/nodes/standalone/host_sriov.yaml + name: yardstick + vm_deploy: True + flavor: + images: "/var/lib/libvirt/images/ubuntu_9cores.qcow2" + ram: 4096 + hw_socket: 1 + extra_specs: + hw:cpu_sockets: 1 + hw:cpu_cores: 9 + hw:cpu_threads: 1 + cputune: "<cputune> + <vcpupin vcpu='0' cpuset='31'/> + <vcpupin vcpu='1' cpuset='32'/> + <vcpupin vcpu='2' cpuset='33'/> + <vcpupin vcpu='3' cpuset='34'/> + <vcpupin vcpu='4' cpuset='35'/> + <vcpupin vcpu='5' cpuset='36'/> + <vcpupin vcpu='6' cpuset='37'/> + <vcpupin vcpu='7' cpuset='38'/> + <vcpupin vcpu='8' cpuset='39'/> + <emulatorpin cpuset='31-39'/> + </cputune>" + user: root + password: password + servers: + vnf: + network_ports: + mgmt: + ip: '10.166.31.252' + cidr: '10.166.31.252/28' + xe0: + - uplink_0 + xe1: + - downlink_0 + xe2: + - uplink_1 + xe3: + - downlink_1 + networks: + uplink_0: + phy_port: "0000:88:00.0" + vpci: "0000:00:07.0" + cidr: '152.16.100.19/24' + gateway_ip: '152.16.100.20' + downlink_0: + phy_port: "0000:d8:00.0" + vpci: "0000:00:08.0" + cidr: '152.16.40.19/24' + gateway_ip: '152.16.40.20' + uplink_1: + phy_port: "0000:81:00.0" + vpci: "0000:00:09.0" + cidr: '152.16.101.19/24' + gateway_ip: '152.16.101.20' + downlink_1: + phy_port: "0000:86:00.0" + vpci: "0000:00:0a.0" + cidr: '152.16.41.19/24' + gateway_ip: '152.16.41.20' + diff --git a/samples/vnf_samples/traffic_profiles/ipv4_throughput-2.yaml b/samples/vnf_samples/traffic_profiles/ipv4_throughput-2.yaml index 328e76fb6..a3218879b 100644 --- a/samples/vnf_samples/traffic_profiles/ipv4_throughput-2.yaml +++ b/samples/vnf_samples/traffic_profiles/ipv4_throughput-2.yaml @@ -57,6 +57,8 @@ uplink_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') }}" @@ -82,6 +84,8 @@ downlink_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') }}" @@ -108,6 +112,8 @@ uplink_1: 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') }}" @@ -133,6 +139,8 @@ downlink_1: 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') }}" diff --git a/samples/vnf_samples/traffic_profiles/ipv4_throughput-3.yaml b/samples/vnf_samples/traffic_profiles/ipv4_throughput-3.yaml new file mode 100644 index 000000000..d849ed8ab --- /dev/null +++ b/samples/vnf_samples/traffic_profiles/ipv4_throughput-3.yaml @@ -0,0 +1,213 @@ +# 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. + +# flow definition for ACL tests - 1K flows - ipv4 only +# +# the number of flows defines the widest range of parameters +# for example if srcip_range=1.0.0.1-1.0.0.255 and dst_ip_range=10.0.0.1-10.0.1.255 +# and it should define only 16 flows +# +# there is assumption that packets generated will have a random sequences of following addresses pairs +# in the packets +# 1. src=1.x.x.x(x.x.x =random from 1..255) dst=10.x.x.x (random from 1..512) +# 2. src=1.x.x.x(x.x.x =random from 1..255) dst=10.x.x.x (random from 1..512) +# ... +# 512. src=1.x.x.x(x.x.x =random from 1..255) dst=10.x.x.x (random from 1..512) +# +# not all combination should be filled +# Any other field with random range will be added to flow definition +# +# the example.yaml provides all possibilities for traffic generation +# +# the profile defines a public and private side to make limited traffic correlation +# between private and public side same way as it is made by IXIA solution. +# +--- +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 +traffic_profile: + traffic_type: RFC2544Profile # defines traffic behavior - constant or look for highest possible throughput + frame_rate: 100 # pc of linerate + # that specifies a range (e.g. ipv4 address, port) + + +uplink_0: + ipv4: + id: 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') }}" + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.src_ip_0', '1.1.1.1-1.1.255.255') }}" + dstip4: "{{get(flow, 'flow.dst_ip_0', '90.90.1.1-90.90.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.src_port_0', '1234-4321') }}" + dstport: "{{get(flow, 'flow.dst_port_0', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" +downlink_0: + ipv4: + id: 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') }}" + + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.dst_ip_0', '90.90.1.1-90.90.255.255') }}" + dstip4: "{{get(flow, 'flow.src_ip_0', '1.1.1.1-1.1.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.dst_port_0', '1234-4321') }}" + dstport: "{{get(flow, 'flow.src_port_0', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" +uplink_1: + ipv4: + id: 3 + 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') }}" + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.src_ip_1', '1.1.1.1-1.1.255.255') }}" + dstip4: "{{get(flow, 'flow.dst_ip_1', '90.90.1.1-90.90.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.src_port_1', '1234-4321') }}" + dstport: "{{get(flow, 'flow.dst_port_1', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" +downlink_1: + ipv4: + id: 4 + 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') }}" + + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.dst_ip_1', '90.90.1.1-90.90.255.255') }}" + dstip4: "{{get(flow, 'flow.src_ip_1', '1.1.1.1-1.1.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.dst_port_1', '1234-4321') }}" + dstport: "{{get(flow, 'flow.src_port_1', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" +uplink_2: + ipv4: + id: 5 + 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') }}" + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.src_ip_1', '1.1.1.1-1.1.255.255') }}" + dstip4: "{{get(flow, 'flow.dst_ip_1', '90.90.1.1-90.90.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.src_port_1', '1234-4321') }}" + dstport: "{{get(flow, 'flow.dst_port_1', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" +downlink_2: + ipv4: + id: 6 + 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') }}" + + outer_l3v4: + proto: "udp" + srcip4: "{{get(flow, 'flow.dst_ip_1', '90.90.1.1-90.90.255.255') }}" + dstip4: "{{get(flow, 'flow.src_ip_1', '1.1.1.1-1.1.255.255') }}" + count: "{{get(flow, 'flow.count', '1') }}" + ttl: 32 + dscp: 0 + outer_l4: + srcport: "{{get(flow, 'flow.dst_port_1', '1234-4321') }}" + dstport: "{{get(flow, 'flow.src_port_1', '2001-4001') }}" + count: "{{get(flow, 'flow.count', '1') }}" diff --git a/samples/vnf_samples/vnf_descriptors/router_vnf.yaml b/samples/vnf_samples/vnf_descriptors/router_vnf.yaml new file mode 100644 index 000000000..3325540b3 --- /dev/null +++ b/samples/vnf_samples/vnf_descriptors/router_vnf.yaml @@ -0,0 +1,48 @@ +# 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. + +vnfd:vnfd-catalog: + vnfd: + - id: RouterVNF + name: RouterVNF + short-name: RouterVnf + description: RouterVNF + mgmt-interface: + vdu-id: routervnf-baremetal + {% if user is defined %} + user: '{{user}}' # Value filled by vnfdgen + {% endif %} + {% if password is defined %} + password: '{{password}}' # Value filled by vnfdgen + {% endif %} + {% if ip is defined %} + ip: '{{ip}}' # Value filled by vnfdgen + {% endif %} + {% if key_filename is defined %} + key_filename: '{{key_filename}}' # Value filled by vnfdgen + {% endif %} + vdu: + - id: routervnf-baremetal + name: routervnf-baremetal + description: RouterVNF + vm-flavor: + vcpu-count: '4' + memory-mb: '4096' + routing_table: {{ routing_table }} + nd_route_tbl: {{ nd_route_tbl }} + benchmark: + kpi: + - packets_in + - packets_fwd + - packets_dropped diff --git a/test-requirements.txt b/test-requirements.txt index a635bd1d6..8c59e4595 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -4,11 +4,9 @@ coverage==4.3.4 # Apache 2.0; OSI Approved Apache Software License; http://www.apache.org/licenses/LICENSE-2.0; http://www.apache.org/licenses/LICENSE-2.0 fixtures==3.0.0 # OSI Approved BSD License; OSI Approved Apache Software License -flake8==2.5.4 # MIT; OSI Approved MIT License packaging==16.8.0 # BSD or Apache License, Version 2.0 -pep8==1.7.0 # Expat license; OSI Approved MIT License pyflakes==1.0.0 # MIT; OSI Approved MIT License -pylint +pylint==1.8.1 # GPLv2 python-subunit==1.2.0 # OSI Approved Apache Software License; OSI Approved BSD License testrepository==0.0.20 # OSI Approved BSD License; OSI Approved Apache Software License testtools==2.2.0 # OSI Approved MIT License diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml index d729169a6..08037d9fa 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc019.yaml @@ -16,6 +16,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "nova-api" %} scenarios: - @@ -23,7 +24,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "nova-api" + process_name: "{{ attack_process }}" host: {{attack_host}} wait_time: 10 @@ -35,7 +36,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "nova-api" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml index 6a3465cc9..bc7cd3d28 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc045.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "neutron-server" %} scenarios: - @@ -22,7 +23,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "neutron-server" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -33,7 +34,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "neutron-server" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml index 200bdfc81..3b04cc4bd 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc046.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "keystone" %} scenarios: - @@ -22,7 +23,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "keystone" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -33,7 +34,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "keystone" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml index d7c69c0d3..d199e5117 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc047.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "glance-api" %} scenarios: - @@ -22,7 +23,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "glance-api" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -33,7 +34,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "glance-api" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml index ddc62bb16..2bca1fb9d 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc048.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "cinder-api" %} scenarios: - @@ -22,7 +23,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "cinder-api" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -33,7 +34,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "cinder-api" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc049.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc049.yaml index b23bb330f..a3df57ce8 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc049.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc049.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "swift-proxy" %} scenarios: - @@ -22,7 +23,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "swift-proxy" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -33,7 +34,7 @@ scenarios: sla: max_outage_time: 5 - monitor_type: "process" - process_name: "swift-proxy" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml index bcf5902fa..c2a4f9ede 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc053.yaml @@ -15,6 +15,7 @@ description: > {% set file = file or '/etc/yardstick/pod.yaml' %} {% set attack_host = attack_host or "node1" %} +{% set attack_process = attack_process or "haproxy" %} scenarios: - @@ -25,13 +26,13 @@ scenarios: fault_type: "kill-process" host: {{attack_host}} key: "kill-process" - process_name: "haproxy" + process_name: "{{ attack_process }}" monitors: - monitor_type: "process" key: "service-status" - process_name: "haproxy" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 monitor_number: 3 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml index 0035a1f07..9194d9d4e 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc056.yaml @@ -17,6 +17,7 @@ description: > {% set attack_host = attack_host or 'node1' %} {% set monitor_time = monitor_time or 10 %} {% set monitor_number = monitor_number or 3 %} +{% set attack_process = attack_process or "rabbitmq-server" %} scenarios: - @@ -24,7 +25,7 @@ scenarios: options: attackers: - fault_type: "kill-process" - process_name: "rabbitmq-server" + process_name: "{{ attack_process }}" host: {{attack_host}} monitors: @@ -57,7 +58,7 @@ scenarios: max_outage_time: 5 - monitor_type: "process" - process_name: "rabbitmq-server" + process_name: "{{ attack_process }}" host: {{attack_host}} monitor_time: 30 sla: diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc057.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc057.yaml index 6d710910a..f6a35e915 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc057.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc057.yaml @@ -20,6 +20,7 @@ description: > {% set check_host = check_host or 'node2' %} {% set monitor_time = monitor_time or 10 %} {% set monitor_number = monitor_number or 3 %} +{% set attack_process = attack_process or "corosync" %} scenarios: - @@ -32,7 +33,7 @@ scenarios: key: "kill-process" attack_key: "kill-corosync" action_parameter: - process_name: "corosync" + process_name: "{{ attack_process }}" monitors: - diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml index 77b9172a9..06d460032 100644 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc058.yaml @@ -17,6 +17,7 @@ description: > {% set image = image or 'yardstick-image' %} {% set flavor = flavor or 'yardstick-flavor' %} {% set attack_host = attack_host or 'node1' %} +{% set attack_process = attack_process or "neutron-l3-agent" %} scenarios: - @@ -27,12 +28,12 @@ scenarios: fault_type: "kill-process" host: {{attack_host}} key: "kill-process" - process_name: "neutron-l3-agent" + process_name: "{{ attack_process }}" monitors: - monitor_type: "process" - process_name: "neutron-l3-agent" + process_name: "{{ attack_process }}" host: {{attack_host}} key: "monitor-recovery" monitor_time: 30 diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc078.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc078.yaml index d20045b25..e5cf6ce36 100644..100755 --- a/tests/opnfv/test_cases/opnfv_yardstick_tc078.yaml +++ b/tests/opnfv/test_cases/opnfv_yardstick_tc078.yaml @@ -10,22 +10,26 @@ schema: "yardstick:task:0.1" description: > - Yardstick TC078 config file; Measure CPU performance using SPEC CPU2006; {% set file = file or "/etc/yardstick/pod.yaml" %} {% set host = host or 'node1' %} +{% set benchmark = benchmark or 'int' %} +{% set runspec_iterations = runspec_iterations or 1 %} +{% set runspec_tune = runspec_tune or 'base' %} +{% set runspec_size = runspec_size or 'ref' %} +{% set runspec_rate = runspec_rate or 1 %} scenarios: - type: SpecCPU2006 options: - SPECint_benchmark: int^429 - runspec_iterations: 1 - runspec_tune: base - runspec_size: ref - runspec_rate: 1 + SPECint_benchmark: {{benchmark}} + runspec_iterations: {{runspec_iterations}} + runspec_tune: {{runspec_tune}} + runspec_size: {{runspec_size}} + runspec_rate: {{runspec_rate}} host: {{host}}.yardstick-TC078 diff --git a/tests/unit/benchmark/contexts/standalone/test_model.py b/tests/unit/benchmark/contexts/standalone/test_model.py index 6899a0af6..31ec2b7d1 100644 --- a/tests/unit/benchmark/contexts/standalone/test_model.py +++ b/tests/unit/benchmark/contexts/standalone/test_model.py @@ -16,70 +16,137 @@ # Unittest for yardstick.benchmark.contexts.standalone.model - from __future__ import absolute_import +import copy import os import unittest -import errno import mock -from yardstick.common import constants as consts -from yardstick.benchmark.contexts.standalone.model import Libvirt -from yardstick.benchmark.contexts.standalone.model import StandaloneContextHelper -from yardstick.benchmark.contexts.standalone import model -from yardstick.network_services.utils import PciAddress +from xml.etree import ElementTree +from yardstick.benchmark.contexts.standalone import model +from yardstick.network_services import utils +from yardstick.network_services.helpers import cpu + + +XML_SAMPLE = """<?xml version="1.0"?> +<domain type="kvm"> + <devices> + </devices> +</domain> +""" + +XML_SAMPLE_INTERFACE = """<?xml version="1.0"?> +<domain type="kvm"> + <devices> + <interface> + </interface> + </devices> +</domain> +""" class ModelLibvirtTestCase(unittest.TestCase): + def setUp(self): + self.xml = ElementTree.ElementTree( + element=ElementTree.fromstring(XML_SAMPLE)) + self.pci_address_str = '0001:04:03.2' + self.pci_address = utils.PciAddress(self.pci_address_str) + self.mac = '00:00:00:00:00:01' + self._mock_write_xml = mock.patch.object(ElementTree.ElementTree, + 'write') + self.mock_write_xml = self._mock_write_xml.start() + + self.addCleanup(self._cleanup) + + def _cleanup(self): + self._mock_write_xml.stop() + def test_check_if_vm_exists_and_delete(self): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) + ssh_mock.execute = mock.Mock(return_value=(0, "a", "")) ssh.return_value = ssh_mock - result = Libvirt.check_if_vm_exists_and_delete("vm_0", ssh_mock) - self.assertIsNone(result) + # NOTE(ralonsoh): this test doesn't cover function execution. + model.Libvirt.check_if_vm_exists_and_delete("vm_0", ssh_mock) def test_virsh_create_vm(self): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) + ssh_mock.execute = mock.Mock(return_value=(0, "a", "")) ssh.return_value = ssh_mock - result = Libvirt.virsh_create_vm(ssh_mock, "vm_0") - self.assertIsNone(result) + # NOTE(ralonsoh): this test doesn't cover function execution. + model.Libvirt.virsh_create_vm(ssh_mock, "vm_0") def test_virsh_destroy_vm(self): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) + ssh_mock.execute = mock.Mock(return_value=(0, "a", "")) ssh.return_value = ssh_mock - result = Libvirt.virsh_destroy_vm("vm_0", ssh_mock) - self.assertIsNone(result) - - @mock.patch('yardstick.benchmark.contexts.standalone.model.ET') - def test_add_interface_address(self, mock_et): - pci_address = PciAddress.parse_address("0000:00:04.0", multi_line=True) - result = Libvirt.add_interface_address("<interface/>", pci_address) - self.assertIsNotNone(result) - - @mock.patch('yardstick.benchmark.contexts.standalone.model.Libvirt.add_interface_address') - @mock.patch('yardstick.benchmark.contexts.standalone.model.ET') - def test_add_ovs_interfaces(self, mock_et, mock_add_interface_address): - pci_address = PciAddress.parse_address("0000:00:04.0", multi_line=True) - result = Libvirt.add_ovs_interface("/usr/local", 0, "0000:00:04.0", - "00:00:00:00:00:01", "xml") - self.assertIsNone(result) - - @mock.patch('yardstick.benchmark.contexts.standalone.model.Libvirt.add_interface_address') - @mock.patch('yardstick.benchmark.contexts.standalone.model.ET') - def test_add_sriov_interfaces(self, mock_et, mock_add_interface_address): - pci_address = PciAddress.parse_address("0000:00:04.0", multi_line=True) - result = Libvirt.add_sriov_interfaces("0000:00:05.0", "0000:00:04.0", - "00:00:00:00:00:01", "xml") - self.assertIsNone(result) + # NOTE(ralonsoh): this test doesn't cover function execution. + model.Libvirt.virsh_destroy_vm("vm_0", ssh_mock) + + def test_add_interface_address(self): + xml = ElementTree.ElementTree( + element=ElementTree.fromstring(XML_SAMPLE_INTERFACE)) + interface = xml.find('devices').find('interface') + result = model.Libvirt._add_interface_address(interface, self.pci_address) + self.assertEqual('pci', result.get('type')) + self.assertEqual('0x{}'.format(self.pci_address.domain), + result.get('domain')) + self.assertEqual('0x{}'.format(self.pci_address.bus), + result.get('bus')) + self.assertEqual('0x{}'.format(self.pci_address.slot), + result.get('slot')) + self.assertEqual('0x{}'.format(self.pci_address.function), + result.get('function')) + + def test_add_ovs_interfaces(self): + xml_input = mock.Mock() + with mock.patch.object(ElementTree, 'parse', return_value=self.xml) \ + as mock_parse: + xml = copy.deepcopy(self.xml) + mock_parse.return_value = xml + model.Libvirt.add_ovs_interface( + '/usr/local', 0, self.pci_address_str, self.mac, xml_input) + mock_parse.assert_called_once_with(xml_input) + self.mock_write_xml.assert_called_once_with(xml_input) + interface = xml.find('devices').find('interface') + self.assertEqual('vhostuser', interface.get('type')) + mac = interface.find('mac') + self.assertEqual(self.mac, mac.get('address')) + source = interface.find('source') + self.assertEqual('unix', source.get('type')) + self.assertEqual('/usr/local/var/run/openvswitch/dpdkvhostuser0', + source.get('path')) + self.assertEqual('client', source.get('mode')) + _model = interface.find('model') + self.assertEqual('virtio', _model.get('type')) + driver = interface.find('driver') + self.assertEqual('4', driver.get('queues')) + host = driver.find('host') + self.assertEqual('off', host.get('mrg_rxbuf')) + self.assertIsNotNone(interface.find('address')) + + def test_add_sriov_interfaces(self): + xml_input = mock.Mock() + with mock.patch.object(ElementTree, 'parse', return_value=self.xml) \ + as mock_parse: + xml = copy.deepcopy(self.xml) + mock_parse.return_value = xml + vf_pci = '0001:05:04.2' + model.Libvirt.add_sriov_interfaces( + self.pci_address_str, vf_pci, self.mac, xml_input) + mock_parse.assert_called_once_with(xml_input) + self.mock_write_xml.assert_called_once_with(xml_input) + interface = xml.find('devices').find('interface') + self.assertEqual('yes', interface.get('managed')) + self.assertEqual('hostdev', interface.get('type')) + mac = interface.find('mac') + self.assertEqual(self.mac, mac.get('address')) + source = interface.find('source') + self.assertIsNotNone(source.find('address')) + self.assertIsNotNone(interface.find('address')) def test_create_snapshot_qemu(self): result = "/var/lib/libvirt/images/0.qcow2" @@ -88,15 +155,15 @@ class ModelLibvirtTestCase(unittest.TestCase): ssh_mock.execute = \ mock.Mock(return_value=(0, "a", "")) ssh.return_value = ssh_mock - image = Libvirt.create_snapshot_qemu(ssh_mock, "0", "ubuntu.img") + image = model.Libvirt.create_snapshot_qemu(ssh_mock, "0", "ubuntu.img") self.assertEqual(image, result) - @mock.patch("yardstick.benchmark.contexts.standalone.model.Libvirt.pin_vcpu_for_perf") - @mock.patch("yardstick.benchmark.contexts.standalone.model.Libvirt.create_snapshot_qemu") - @mock.patch('yardstick.benchmark.contexts.standalone.model.open') - @mock.patch('yardstick.benchmark.contexts.standalone.model.write_file') - def test_build_vm_xml(self, mock_open, mock_write_file, mock_create_snapshot_qemu, - mock_pin_vcpu_for_perf): + @mock.patch.object(model.Libvirt, 'pin_vcpu_for_perf') + @mock.patch.object(model.Libvirt, 'create_snapshot_qemu') + def test_build_vm_xml(self, mock_create_snapshot_qemu, + *args): + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. result = [4] with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) @@ -105,7 +172,7 @@ class ModelLibvirtTestCase(unittest.TestCase): ssh.return_value = ssh_mock mock_create_snapshot_qemu.return_value = "0.img" - status = Libvirt.build_vm_xml(ssh_mock, {}, "test", "vm_0", 0) + status = model.Libvirt.build_vm_xml(ssh_mock, {}, "test", "vm_0", 0) self.assertEqual(status[0], result[0]) def test_update_interrupts_hugepages_perf(self): @@ -114,19 +181,21 @@ class ModelLibvirtTestCase(unittest.TestCase): ssh_mock.execute = \ mock.Mock(return_value=(0, "a", "")) ssh.return_value = ssh_mock - status = Libvirt.update_interrupts_hugepages_perf(ssh_mock) - self.assertIsNone(status) + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + model.Libvirt.update_interrupts_hugepages_perf(ssh_mock) + + @mock.patch.object(cpu.CpuSysCores, 'get_core_socket') + def test_pin_vcpu_for_perf(self, mock_get_core_socket): + mock_get_core_socket.return_value = { + 'cores_per_socket': 1, + 'thread_per_core': 1, + '0': [1, 2] + } + # NOTE(ralonsoh): this test doesn't cover function execution. This + # function needs more tests. + model.Libvirt.pin_vcpu_for_perf(mock.Mock()) - @mock.patch("yardstick.benchmark.contexts.standalone.model.CpuSysCores") - @mock.patch("yardstick.benchmark.contexts.standalone.model.Libvirt.update_interrupts_hugepages_perf") - def test_pin_vcpu_for_perf(self, mock_update_interrupts_hugepages_perf, mock_CpuSysCores): - with mock.patch("yardstick.ssh.SSH") as ssh: - ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) - ssh.return_value = ssh_mock - status = Libvirt.pin_vcpu_for_perf(ssh_mock, "vm_0", 4) - self.assertIsNotNone(status) class StandaloneContextHelperTestCase(unittest.TestCase): @@ -148,7 +217,7 @@ class StandaloneContextHelperTestCase(unittest.TestCase): } def setUp(self): - self.helper = StandaloneContextHelper() + self.helper = model.StandaloneContextHelper() def test___init__(self): self.assertIsNone(self.helper.file_path) @@ -159,8 +228,9 @@ class StandaloneContextHelperTestCase(unittest.TestCase): ssh_mock.execute = \ mock.Mock(return_value=(1, "a", "")) ssh.return_value = ssh_mock - status = StandaloneContextHelper.install_req_libs(ssh_mock) - self.assertIsNone(status) + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + model.StandaloneContextHelper.install_req_libs(ssh_mock) def test_get_kernel_module(self): with mock.patch("yardstick.ssh.SSH") as ssh: @@ -168,10 +238,12 @@ class StandaloneContextHelperTestCase(unittest.TestCase): ssh_mock.execute = \ mock.Mock(return_value=(1, "i40e", "")) ssh.return_value = ssh_mock - status = StandaloneContextHelper.get_kernel_module(ssh_mock, "05:00.0", None) - self.assertEqual(status, "i40e") + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + model.StandaloneContextHelper.get_kernel_module( + ssh_mock, "05:00.0", None) - @mock.patch('yardstick.benchmark.contexts.standalone.model.StandaloneContextHelper.get_kernel_module') + @mock.patch.object(model.StandaloneContextHelper, 'get_kernel_module') def test_get_nic_details(self, mock_get_kernel_module): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) @@ -179,8 +251,10 @@ class StandaloneContextHelperTestCase(unittest.TestCase): mock.Mock(return_value=(1, "i40e ixgbe", "")) ssh.return_value = ssh_mock mock_get_kernel_module.return_value = "i40e" - status = StandaloneContextHelper.get_nic_details(ssh_mock, self.NETWORKS, "dpdk-devbind.py") - self.assertIsNotNone(status) + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + model.StandaloneContextHelper.get_nic_details( + ssh_mock, self.NETWORKS, 'dpdk-devbind.py') def test_get_virtual_devices(self): pattern = "PCI_SLOT_NAME=0000:05:00.0" @@ -189,8 +263,10 @@ class StandaloneContextHelperTestCase(unittest.TestCase): ssh_mock.execute = \ mock.Mock(return_value=(1, pattern, "")) ssh.return_value = ssh_mock - status = StandaloneContextHelper.get_virtual_devices(ssh_mock, "0000:00:05.0") - self.assertIsNotNone(status) + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + model.StandaloneContextHelper.get_virtual_devices( + ssh_mock, '0000:00:05.0') def _get_file_abspath(self, filename): curr_path = os.path.dirname(os.path.abspath(__file__)) @@ -204,40 +280,48 @@ class StandaloneContextHelperTestCase(unittest.TestCase): def test_parse_pod_file(self): self.helper.file_path = self._get_file_abspath("dummy") - self.assertRaises(IOError, self.helper.parse_pod_file, self.helper.file_path) + self.assertRaises(IOError, self.helper.parse_pod_file, + self.helper.file_path) self.helper.file_path = self._get_file_abspath(self.NODE_SAMPLE) - self.assertRaises(TypeError, self.helper.parse_pod_file, self.helper.file_path) + self.assertRaises(TypeError, self.helper.parse_pod_file, + self.helper.file_path) self.helper.file_path = self._get_file_abspath(self.NODE_SRIOV_SAMPLE) self.assertIsNotNone(self.helper.parse_pod_file(self.helper.file_path)) def test_get_mac_address(self): - status = StandaloneContextHelper.get_mac_address() + status = model.StandaloneContextHelper.get_mac_address() self.assertIsNotNone(status) @mock.patch('yardstick.ssh.SSH') - def test_get_mgmt_ip(self, mock_ssh): + def test_get_mgmt_ip(self, *args): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(1, "1.2.3.4 00:00:00:00:00:01", "")) + ssh_mock.execute = mock.Mock( + return_value=(1, "1.2.3.4 00:00:00:00:00:01", "")) ssh.return_value = ssh_mock - status = StandaloneContextHelper.get_mgmt_ip(ssh_mock, "00:00:00:00:00:01", "1.1.1.1/24", {}) + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. + status = model.StandaloneContextHelper.get_mgmt_ip( + ssh_mock, "00:00:00:00:00:01", "1.1.1.1/24", {}) self.assertIsNotNone(status) @mock.patch('yardstick.ssh.SSH') - def test_get_mgmt_ip_no(self, mock_ssh): + def test_get_mgmt_ip_no(self, *args): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) ssh_mock.execute = \ mock.Mock(return_value=(1, "", "")) ssh.return_value = ssh_mock - + # NOTE(ralonsoh): this test doesn't cover function execution. This test + # should also check mocked function calls. model.WAIT_FOR_BOOT = 0 - status = StandaloneContextHelper.get_mgmt_ip(ssh_mock, "99", "1.1.1.1/24", {}) + status = model.StandaloneContextHelper.get_mgmt_ip( + ssh_mock, "99", "1.1.1.1/24", {}) self.assertIsNone(status) + class ServerTestCase(unittest.TestCase): NETWORKS = { @@ -257,6 +341,7 @@ class ServerTestCase(unittest.TestCase): 'cidr': '152.16.40.10/24', 'gateway_ip': '152.16.100.20'} } + def setUp(self): self.server = model.Server() @@ -282,7 +367,8 @@ class ServerTestCase(unittest.TestCase): 'xe1': ['public_0'], } } - status = self.server.generate_vnf_instance({}, self.NETWORKS, "1.1.1.1/24", 'vm_0', vnf, '00:00:00:00:00:01') + status = self.server.generate_vnf_instance( + {}, self.NETWORKS, '1.1.1.1/24', 'vm_0', vnf, '00:00:00:00:00:01') self.assertIsNotNone(status) class OvsDeployTestCase(unittest.TestCase): @@ -312,14 +398,17 @@ class OvsDeployTestCase(unittest.TestCase): self.assertIsNotNone(self.ovs_deploy.connection) @mock.patch('yardstick.benchmark.contexts.standalone.model.os') - def test_prerequisite(self, mock_ssh): + def test_prerequisite(self, *args): + # NOTE(ralonsoh): this test should check mocked function calls. self.ovs_deploy.helper = mock.Mock() self.assertIsNone(self.ovs_deploy.prerequisite()) @mock.patch('yardstick.benchmark.contexts.standalone.model.os') - def test_prerequisite(self, mock_ssh): + def test_prerequisite_2(self, *args): + # NOTE(ralonsoh): this test should check mocked function calls. Rename + # this test properly. self.ovs_deploy.helper = mock.Mock() - self.ovs_deploy.connection.execute = \ - mock.Mock(return_value=(1, "1.2.3.4 00:00:00:00:00:01", "")) + self.ovs_deploy.connection.execute = mock.Mock( + return_value=(1, '1.2.3.4 00:00:00:00:00:01', '')) self.ovs_deploy.prerequisite = mock.Mock() self.assertIsNone(self.ovs_deploy.ovs_deploy()) diff --git a/tests/unit/benchmark/contexts/standalone/test_sriov.py b/tests/unit/benchmark/contexts/standalone/test_sriov.py index 50ae5fe13..3ea673abc 100644 --- a/tests/unit/benchmark/contexts/standalone/test_sriov.py +++ b/tests/unit/benchmark/contexts/standalone/test_sriov.py @@ -17,12 +17,10 @@ from __future__ import absolute_import import os import unittest -import errno import mock -from yardstick.common import constants as consts +from yardstick import ssh from yardstick.benchmark.contexts.standalone import sriov -from yardstick.network_services.utils import PciAddress class SriovContextTestCase(unittest.TestCase): @@ -66,6 +64,9 @@ class SriovContextTestCase(unittest.TestCase): @mock.patch('yardstick.benchmark.contexts.standalone.sriov.Libvirt') @mock.patch('yardstick.benchmark.contexts.standalone.model.Server') def test___init__(self, mock_helper, mock_libvirt, mock_server): + # pylint: disable=unused-argument + # NOTE(ralonsoh): this test doesn't cover function execution. + # The pylint exception should be removed. self.sriov.helper = mock_helper self.sriov.vnf_node = mock_server self.assertIsNone(self.sriov.file_path) @@ -75,14 +76,11 @@ class SriovContextTestCase(unittest.TestCase): self.sriov.helper.parse_pod_file = mock.Mock(return_value=[{}, {}, {}]) self.assertIsNone(self.sriov.init(self.ATTRS)) - @mock.patch('yardstick.ssh.SSH') + @mock.patch.object(ssh, 'SSH', return_value=(0, "a", "")) def test_deploy(self, mock_ssh): - with mock.patch("yardstick.ssh.SSH") as ssh: - ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) - ssh.return_value = ssh_mock - + # pylint: disable=unused-argument + # NOTE(ralonsoh): this test doesn't cover function execution. + # The pylint exception should be removed. self.sriov.vm_deploy = False self.assertIsNone(self.sriov.deploy()) @@ -94,20 +92,16 @@ class SriovContextTestCase(unittest.TestCase): self.sriov.wait_for_vnfs_to_start = mock.Mock(return_value={}) self.assertIsNone(self.sriov.deploy()) - @mock.patch('yardstick.ssh.SSH') + @mock.patch.object(ssh, 'SSH', return_value=(0, "a", "")) @mock.patch('yardstick.benchmark.contexts.standalone.sriov.Libvirt') def test_undeploy(self, mock_libvirt, mock_ssh): - with mock.patch("yardstick.ssh.SSH") as ssh: - ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) - ssh.return_value = ssh_mock - + # pylint: disable=unused-argument + # NOTE(ralonsoh): the pylint exception should be removed. self.sriov.vm_deploy = False self.assertIsNone(self.sriov.undeploy()) self.sriov.vm_deploy = True - self.sriov.connection = ssh_mock + self.sriov.connection = mock_ssh self.sriov.vm_names = ['vm_0', 'vm_1'] self.sriov.drivers = ['vm_0', 'vm_1'] self.assertIsNone(self.sriov.undeploy()) @@ -246,27 +240,27 @@ class SriovContextTestCase(unittest.TestCase): self.sriov.drivers = [] self.sriov.networks = self.NETWORKS self.sriov.helper.get_mac_address = mock.Mock(return_value="") - self.sriov.get_vf_data = mock.Mock(return_value="") + self.sriov._get_vf_data = mock.Mock(return_value="") self.assertIsNone(self.sriov.configure_nics_for_sriov()) + @mock.patch.object(ssh, 'SSH', return_value=(0, "a", "")) @mock.patch('yardstick.benchmark.contexts.standalone.sriov.Libvirt') - def test__enable_interfaces(self, mock_libvirt): - with mock.patch("yardstick.ssh.SSH") as ssh: - ssh_mock = mock.Mock(autospec=ssh.SSH) - ssh_mock.execute = \ - mock.Mock(return_value=(0, "a", "")) - ssh.return_value = ssh_mock + def test__enable_interfaces(self, mock_libvirt, mock_ssh): + # pylint: disable=unused-argument + # NOTE(ralonsoh): the pylint exception should be removed. self.sriov.vm_deploy = True - self.sriov.connection = ssh_mock + self.sriov.connection = mock_ssh self.sriov.vm_names = ['vm_0', 'vm_1'] self.sriov.drivers = [] self.sriov.networks = self.NETWORKS - self.sriov.get_vf_data = mock.Mock(return_value="") + self.sriov._get_vf_data = mock.Mock(return_value="") self.assertIsNone(self.sriov._enable_interfaces(0, 0, ["private_0"], 'test')) @mock.patch('yardstick.benchmark.contexts.standalone.model.Server') @mock.patch('yardstick.benchmark.contexts.standalone.sriov.Libvirt') def test_setup_sriov_context(self, mock_libvirt, mock_server): + # pylint: disable=unused-argument + # NOTE(ralonsoh): the pylint exception should be removed. with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) ssh_mock.execute = \ @@ -296,7 +290,7 @@ class SriovContextTestCase(unittest.TestCase): self.sriov.vnf_node.generate_vnf_instance = mock.Mock(return_value={}) self.assertIsNotNone(self.sriov.setup_sriov_context()) - def test_get_vf_data(self): + def test__get_vf_data(self): with mock.patch("yardstick.ssh.SSH") as ssh: ssh_mock = mock.Mock(autospec=ssh.SSH) ssh_mock.execute = \ @@ -318,5 +312,7 @@ class SriovContextTestCase(unittest.TestCase): } } self.sriov.networks = self.NETWORKS - self.sriov.helper.get_virtual_devices = mock.Mock(return_value={"0000:00:01.0": ""}) - self.assertIsNotNone(self.sriov.get_vf_data("", "0000:00:01.0", "00:00:00:00:00:01", "if0")) + self.sriov.helper.get_virtual_devices = mock.Mock( + return_value={'0000:00:01.0': ''}) + self.assertIsNotNone(self.sriov._get_vf_data( + '0000:00:01.0', '00:00:00:00:00:01', 'if0')) diff --git a/tests/unit/network_services/test_utils.py b/tests/unit/network_services/test_utils.py index 993adbeae..bf98a4474 100644 --- a/tests/unit/network_services/test_utils.py +++ b/tests/unit/network_services/test_utils.py @@ -15,8 +15,6 @@ # Unittest for yardstick.network_services.utils -from __future__ import absolute_import - import os import unittest import mock @@ -62,3 +60,84 @@ class UtilsTestCase(unittest.TestCase): ssh.return_value = ssh_mock tool_path = utils.provision_tool(ssh_mock, self.DPDK_PATH) self.assertEqual(tool_path, self.DPDK_PATH) + + +class PciAddressTestCase(unittest.TestCase): + + PCI_ADDRESS_DBSF = '000A:07:03.2' + PCI_ADDRESS_BSF = '06:02.1' + PCI_ADDRESS_DBSF_MULTILINE_1 = '0001:08:04.3\nother text\n' + PCI_ADDRESS_DBSF_MULTILINE_2 = 'first line\n 0001:08:04.3 \nother text\n' + # Will match and return the first address found. + PCI_ADDRESS_DBSF_MULTILINE_3 = ' 0001:08:04.1 \n 05:03.1 \nother\n' + PCI_ADDRESS_BSF_MULTILINE_1 = 'first line\n 08:04.3 \n 0002:05:03.1\n' + BAD_INPUT_1 = 'no address found' + BAD_INPUT_2 = '001:08:04.1' + BAD_INPUT_3 = '08:4.1' + + def test_pciaddress_dbsf(self): + pci_address = utils.PciAddress(PciAddressTestCase.PCI_ADDRESS_DBSF) + self.assertEqual('000a', pci_address.domain) + self.assertEqual('07', pci_address.bus) + self.assertEqual('03', pci_address.slot) + self.assertEqual('2', pci_address.function) + + def test_pciaddress_bsf(self): + pci_address = utils.PciAddress(PciAddressTestCase.PCI_ADDRESS_BSF) + self.assertEqual('0000', pci_address.domain) + self.assertEqual('06', pci_address.bus) + self.assertEqual('02', pci_address.slot) + self.assertEqual('1', pci_address.function) + + def test_pciaddress_dbsf_multiline_1(self): + pci_address = utils.PciAddress( + PciAddressTestCase.PCI_ADDRESS_DBSF_MULTILINE_1) + self.assertEqual('0001', pci_address.domain) + self.assertEqual('08', pci_address.bus) + self.assertEqual('04', pci_address.slot) + self.assertEqual('3', pci_address.function) + + def test_pciaddress_dbsf_multiline_2(self): + pci_address = utils.PciAddress( + PciAddressTestCase.PCI_ADDRESS_DBSF_MULTILINE_2) + self.assertEqual('0001', pci_address.domain) + self.assertEqual('08', pci_address.bus) + self.assertEqual('04', pci_address.slot) + self.assertEqual('3', pci_address.function) + + def test_pciaddress_dbsf_multiline_3(self): + pci_address = utils.PciAddress( + PciAddressTestCase.PCI_ADDRESS_DBSF_MULTILINE_3) + self.assertEqual('0001', pci_address.domain) + self.assertEqual('08', pci_address.bus) + self.assertEqual('04', pci_address.slot) + self.assertEqual('1', pci_address.function) + + def test_pciaddress_bsf_multiline_1(self): + pci_address = utils.PciAddress( + PciAddressTestCase.PCI_ADDRESS_BSF_MULTILINE_1) + self.assertEqual('0000', pci_address.domain) + self.assertEqual('08', pci_address.bus) + self.assertEqual('04', pci_address.slot) + self.assertEqual('3', pci_address.function) + + def test_pciaddress_bad_input_no_address(self): + with self.assertRaises(ValueError) as exception: + utils.PciAddress(PciAddressTestCase.BAD_INPUT_1) + self.assertEqual('Invalid PCI address: {}'.format( + PciAddressTestCase.BAD_INPUT_1), str(exception.exception)) + + def test_pciaddress_bad_input_dbsf_bad_formatted(self): + # In this test case, the domain has only 3 characters instead of 4. + pci_address = utils.PciAddress( + PciAddressTestCase.BAD_INPUT_2) + self.assertEqual('0000', pci_address.domain) + self.assertEqual('08', pci_address.bus) + self.assertEqual('04', pci_address.slot) + self.assertEqual('1', pci_address.function) + + def test_pciaddress_bad_input_bsf_bad_formatted(self): + with self.assertRaises(ValueError) as exception: + utils.PciAddress(PciAddressTestCase.BAD_INPUT_3) + self.assertEqual('Invalid PCI address: {}'.format( + PciAddressTestCase.BAD_INPUT_3), str(exception.exception)) diff --git a/tests/unit/network_services/vnf_generic/vnf/test_router_vnf.py b/tests/unit/network_services/vnf_generic/vnf/test_router_vnf.py new file mode 100644 index 000000000..9ed6fd5b3 --- /dev/null +++ b/tests/unit/network_services/vnf_generic/vnf/test_router_vnf.py @@ -0,0 +1,267 @@ +#!/usr/bin/env python + +# 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. +# + +from __future__ import absolute_import + +import unittest +import mock + +from tests.unit import STL_MOCKS +from tests.unit.network_services.vnf_generic.vnf.test_base import mock_ssh + + +STLClient = mock.MagicMock() +stl_patch = mock.patch.dict("sys.modules", STL_MOCKS) +stl_patch.start() + +if stl_patch: + from yardstick.network_services.vnf_generic.vnf.router_vnf import RouterVNF + + +TEST_FILE_YAML = 'nsb_test_case.yaml' +SSH_HELPER = 'yardstick.network_services.vnf_generic.vnf.sample_vnf.VnfSshHelper' + + +name = 'vnf__1' + + +class TestRouterVNF(unittest.TestCase): + VNFD = {'vnfd:vnfd-catalog': + {'vnfd': + [{'short-name': 'RouterVNF', + 'vdu': + [{'routing_table': [], + 'description': 'RouterVNF', + 'name': 'router-baremetal', + 'nd_route_tbl': [], + 'id': 'router-baremetal', + 'external-interface': + [{'virtual-interface': + {'dst_mac': '00:00:00:00:00:04', + 'vpci': '0000:05:00.0', + 'local_ip': '152.16.100.19', + 'type': 'PCI-PASSTHROUGH', + 'netmask': '255.255.255.0', + 'dpdk_port_num': 0, + 'bandwidth': '10 Gbps', + 'driver': "i40e", + 'dst_ip': '152.16.100.20', + 'local_iface_name': 'xe0', + 'local_mac': '00:00:00:00:00:02'}, + 'vnfd-connection-point-ref': 'xe0', + 'name': 'xe0'}, + {'virtual-interface': + {'dst_mac': '00:00:00:00:00:03', + 'vpci': '0000:05:00.1', + 'local_ip': '152.16.40.19', + 'type': 'PCI-PASSTHROUGH', + 'driver': "i40e", + 'netmask': '255.255.255.0', + 'dpdk_port_num': 1, + 'bandwidth': '10 Gbps', + 'dst_ip': '152.16.40.20', + 'local_iface_name': 'xe1', + 'local_mac': '00:00:00:00:00:01'}, + 'vnfd-connection-point-ref': 'xe1', + 'name': 'xe1'}]}], + 'description': 'RouterVNF', + 'mgmt-interface': + {'vdu-id': 'router-baremetal', + 'host': '1.2.1.1', + 'password': 'r00t', + 'user': 'root', + 'ip': '1.2.1.1'}, + 'benchmark': + {'kpi': ['packets_in', 'packets_fwd', 'packets_dropped']}, + 'connection-point': [{'type': 'VPORT', 'name': 'xe0'}, + {'type': 'VPORT', 'name': 'xe1'}], + 'id': 'RouterVNF', 'name': 'VPEVnfSsh'}]}} + + scenario_cfg = {'nodes': {'cpt__0': 'compute_0.compute_nodes', + 'tg__0': 'trafficgen_1.baremetal', + 'vnf__0': 'vnf.yardstick'}, + 'options': {'flow': {'count': 128000, + 'dst_ip': ['10.0.3.26-10.0.3.105'], + 'dst_port': ['2001-2004'], + 'src_ip': ['10.0.2.26-10.0.2.105'], + 'src_port': ['1234-1238']}, + 'framesize': {'downlink': {'1024B': 100}, + 'uplink': {'1024B': 100}}, + 'rfc2544': {'allowed_drop_rate': '0.0001 - 0.1'}, + 'tg__0': {'queues_per_port': 7}, + 'traffic_type': 4, + 'vnf__0': {'nfvi_enable': True}}, + 'runner': {'interval': 35, + 'iterations': 10, + 'type': 'Iteration'}, + 'topology': 'router-tg-topology.yaml', + 'traffic_profile': '../../traffic_profiles/ipv4_throughput.yaml', + 'type': 'NSPerf'} + + context_cfg = {'nodes': {'tg__1': + {'member-vnf-index': '1', + 'role': 'TrafficGen', + 'name': 'trafficgen_1.yardstick', + 'vnfd-id-ref': 'tg__1', + 'ip': '1.2.1.1', + 'interfaces': + {'xe0': {'local_iface_name': 'ens785f0', + 'vld_id': RouterVNF.UPLINK, + 'netmask': '255.255.255.0', + 'local_ip': '152.16.100.20', + 'dst_mac': '00:00:00:00:00:02', + 'local_mac': '00:00:00:00:00:04', + 'dst_ip': '152.16.100.19', + 'driver': 'i40e', + 'vpci': '0000:05:00.0', + 'dpdk_port_num': 0}, + 'xe1': {'local_iface_name': 'ens785f1', + 'netmask': '255.255.255.0', + 'local_ip': '152.16.100.21', + 'local_mac': '00:00:00:00:00:01', + 'driver': 'i40e', + 'vpci': '0000:05:00.1', + 'dpdk_port_num': 1}}, + 'password': 'r00t', + 'VNF model': 'tg_rfc2544_tpl.yaml', + 'user': 'root'}, + 'vnf__1': + {'name': 'vnf.yardstick', + 'vnfd-id-ref': 'vnf__1', + 'ip': '1.2.1.1', + 'interfaces': + {'xe0': {'local_iface_name': 'ens786f0', + 'vld_id': RouterVNF.UPLINK, + 'netmask': '255.255.255.0', + 'local_ip': '152.16.100.19', + 'dst_mac': '00:00:00:00:00:04', + 'local_mac': '00:00:00:00:00:02', + 'dst_ip': '152.16.100.20', + 'driver': 'i40e', + 'vpci': '0000:05:00.0', + 'dpdk_port_num': 0}, + 'xe1': {'local_iface_name': 'ens786f1', + 'vld_id': RouterVNF.DOWNLINK, + 'netmask': '255.255.255.0', + 'local_ip': '152.16.40.19', + 'dst_mac': '00:00:00:00:00:03', + 'local_mac': '00:00:00:00:00:01', + 'dst_ip': '152.16.40.20', + 'driver': 'i40e', + 'vpci': '0000:05:00.1', + 'dpdk_port_num': 1}}, + 'routing_table': [], + 'member-vnf-index': '2', + 'host': '1.2.1.1', + 'role': 'vnf', + 'user': 'root', + 'nd_route_tbl': [], + 'password': 'r00t', + 'VNF model': 'router_vnf.yaml'}}} + + IP_SHOW_STATS_OUTPUT = """\ +2: em1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP mode DEFAULT group default qlen 1000 + link/ether d4:c9:ef:52:7c:4d brd ff:ff:ff:ff:ff:ff + RX: bytes packets errors dropped overrun mcast + 2781945429 3202213 0 0 0 30131 + RX errors: length crc frame fifo missed + 0 0 0 0 0 + TX: bytes packets errors dropped carrier collsns + 646221183 2145799 0 0 0 0 + TX errors: aborted fifo window heartbeat + 0 0 0 0 +""" + STATS = { + 'RX:bytes': '2781945429', + 'RX:dropped': '0', + 'RX:errors': '0', + 'RX:mcast': '30131', + 'RX:overrun': '0', + 'RX:packets': '3202213', + 'RX errors:length': '0', + 'RX errors:crc': '0', + 'RX errors:frame': '0', + 'RX errors:fifo': '0', + 'RX errors:missed': '0', + 'TX:bytes': '646221183', + 'TX:carrier': '0', + 'TX:collsns': '0', + 'TX:dropped': '0', + 'TX:errors': '0', + 'TX:packets': '2145799', + 'TX errors:aborted': '0', + 'TX errors:fifo': '0', + 'TX errors:window': '0', + 'TX errors:heartbeat': '0', + } + + def test___init__(self): + vnfd = self.VNFD['vnfd:vnfd-catalog']['vnfd'][0] + router_vnf = RouterVNF(name, vnfd) + self.assertIsNone(router_vnf._vnf_process) + + def test_get_stats(self): + stats = RouterVNF.get_stats(self.IP_SHOW_STATS_OUTPUT) + self.assertDictEqual(stats, self.STATS) + + @mock.patch("yardstick.network_services.vnf_generic.vnf.sample_vnf.time") + @mock.patch(SSH_HELPER) + def test_collect_kpi(self, ssh, _): + m = mock_ssh(ssh) + + vnfd = self.VNFD['vnfd:vnfd-catalog']['vnfd'][0] + router_vnf = RouterVNF(name, vnfd) + router_vnf.ssh_helper = m + result = {'packets_dropped': 0, 'packets_fwd': 0, 'packets_in': 0, 'link_stats': {}} + self.assertEqual(result, router_vnf.collect_kpi()) + + @mock.patch(SSH_HELPER) + def test_run_router(self, ssh): + mock_ssh(ssh) + + vnfd = self.VNFD['vnfd:vnfd-catalog']['vnfd'][0] + router_vnf = RouterVNF(name, vnfd) + router_vnf.scenario_helper.scenario_cfg = self.scenario_cfg + router_vnf._run() + router_vnf.ssh_helper.drop_connection.assert_called_once() + + @mock.patch("yardstick.network_services.vnf_generic.vnf.router_vnf.Context") + @mock.patch(SSH_HELPER) + def test_instantiate(self, ssh, _): + mock_ssh(ssh) + + vnfd = self.VNFD['vnfd:vnfd-catalog']['vnfd'][0] + router_vnf = RouterVNF(name, vnfd) + router_vnf.WAIT_TIME = 0 + router_vnf.INTERFACE_WAIT = 0 + self.scenario_cfg.update({"nodes": {"vnf__1": ""}}) + self.assertIsNone(router_vnf.instantiate(self.scenario_cfg, + self.context_cfg)) + + @mock.patch("yardstick.network_services.vnf_generic.vnf.sample_vnf.time") + @mock.patch(SSH_HELPER) + def test_terminate(self, ssh, _): + mock_ssh(ssh) + + vnfd = self.VNFD['vnfd:vnfd-catalog']['vnfd'][0] + router_vnf = RouterVNF(name, vnfd) + router_vnf._vnf_process = mock.MagicMock() + router_vnf._vnf_process.terminate = mock.Mock() + self.assertEqual(None, router_vnf.terminate()) + +if __name__ == '__main__': + unittest.main() diff --git a/tests/unit/network_services/vnf_generic/vnf/test_tg_ping.py b/tests/unit/network_services/vnf_generic/vnf/test_tg_ping.py index c1b2d27eb..ab3570740 100644 --- a/tests/unit/network_services/vnf_generic/vnf/test_tg_ping.py +++ b/tests/unit/network_services/vnf_generic/vnf/test_tg_ping.py @@ -228,7 +228,7 @@ class TestPingTrafficGen(unittest.TestCase): CMD_KWARGS = { 'target_ip': u'152.16.100.20', 'local_ip': u'152.16.100.19', - 'local_if_name': u'xe0', + 'local_if_name': u'xe0_fake', } @mock.patch("yardstick.ssh.SSH") @@ -270,7 +270,7 @@ class TestPingTrafficGen(unittest.TestCase): mock_ssh(ssh, spec=VnfSshHelper, exec_result=(0, "success", "")) ping_traffic_gen = PingTrafficGen('vnf1', self.VNFD_0) ping_traffic_gen.setup_helper.ssh_helper = mock.MagicMock( - **{"execute.return_value": (0, "success", "")}) + **{"execute.return_value": (0, "xe0_fake", "")}) self.assertIsInstance(ping_traffic_gen.ssh_helper, mock.Mock) self.assertEqual(ping_traffic_gen._result, {}) @@ -278,12 +278,12 @@ class TestPingTrafficGen(unittest.TestCase): self.assertEqual( ping_traffic_gen.vnfd_helper.interfaces[0]['virtual-interface']['local_iface_name'], - 'success') + 'xe0_fake') self.assertEqual(self.CMD_KWARGS, ping_traffic_gen.resource_helper.cmd_kwargs) self.assertIsNotNone(ping_traffic_gen._result) @mock.patch("yardstick.ssh.SSH") - def test_listen_traffic(self, ssh): + def test_listen_traffic(self, *args): ping_traffic_gen = PingTrafficGen('vnf1', self.VNFD_0) self.assertIsNone(ping_traffic_gen.listen_traffic({})) diff --git a/yardstick/benchmark/contexts/standalone/model.py b/yardstick/benchmark/contexts/standalone/model.py index 45ae3c18a..85ae14b1d 100644 --- a/yardstick/benchmark/contexts/standalone/model.py +++ b/yardstick/benchmark/contexts/standalone/model.py @@ -43,6 +43,7 @@ VM_TEMPLATE = """ <hugepages /> </memoryBacking> <vcpu cpuset='{cpuset}'>{vcpu}</vcpu> + {cputune} <os> <type arch="x86_64" machine="pc-i440fx-utopic">hvm</type> <boot dev="hd" /> @@ -94,33 +95,63 @@ class Libvirt(object): cmd_template = "virsh list --name | grep -i %s" status = connection.execute(cmd_template % vm_name)[0] if status == 0: - LOG.info("VM '%s' is already present.. destroying" % vm_name) + LOG.info("VM '%s' is already present... destroying", vm_name) connection.execute("virsh destroy %s" % vm_name) @staticmethod def virsh_create_vm(connection, cfg): err = connection.execute("virsh create %s" % cfg)[0] - LOG.info("VM create status: %s" % (err)) + LOG.info("VM create status: %s", err) @staticmethod def virsh_destroy_vm(vm_name, connection): connection.execute("virsh destroy %s" % vm_name) @staticmethod - def add_interface_address(interface, pci_address): + def _add_interface_address(interface, pci_address): + """Add a PCI 'address' XML node + + <address type='pci' domain='0x0000' bus='0x00' slot='0x08' + function='0x0'/> + + Refence: https://software.intel.com/en-us/articles/ + configure-sr-iov-network-virtual-functions-in-linux-kvm + """ vm_pci = ET.SubElement(interface, 'address') vm_pci.set('type', 'pci') - vm_pci.set('domain', '0x%s' % pci_address.domain) - vm_pci.set('bus', '0x%s' % pci_address.bus) - vm_pci.set('slot', '0x%s' % pci_address.slot) - vm_pci.set('function', '0x%s' % pci_address.function) + vm_pci.set('domain', '0x{}'.format(pci_address.domain)) + vm_pci.set('bus', '0x{}'.format(pci_address.bus)) + vm_pci.set('slot', '0x{}'.format(pci_address.slot)) + vm_pci.set('function', '0x{}'.format(pci_address.function)) return vm_pci @classmethod def add_ovs_interface(cls, vpath, port_num, vpci, vports_mac, xml): - vhost_path = '{0}/var/run/openvswitch/dpdkvhostuser{1}' + """Add a DPDK OVS 'interface' XML node in 'devices' node + + <devices> + <interface type='vhostuser'> + <mac address='00:00:00:00:00:01'/> + <source type='unix' path='/usr/local/var/run/openvswitch/ + dpdkvhostuser0' mode='client'/> + <model type='virtio'/> + <driver queues='4'> + <host mrg_rxbuf='off'/> + </driver> + <address type='pci' domain='0x0000' bus='0x00' slot='0x03' + function='0x0'/> + </interface> + ... + </devices> + + Reference: http://docs.openvswitch.org/en/latest/topics/dpdk/ + vhost-user/ + """ + + vhost_path = ('{0}/var/run/openvswitch/dpdkvhostuser{1}'. + format(vpath, port_num)) root = ET.parse(xml) - pci_address = PciAddress.parse_address(vpci.strip(), multi_line=True) + pci_address = PciAddress(vpci.strip()) device = root.find('devices') interface = ET.SubElement(device, 'interface') @@ -130,7 +161,7 @@ class Libvirt(object): source = ET.SubElement(interface, 'source') source.set('type', 'unix') - source.set('path', vhost_path.format(vpath, port_num)) + source.set('path', vhost_path) source.set('mode', 'client') model = ET.SubElement(interface, 'model') @@ -142,14 +173,35 @@ class Libvirt(object): host = ET.SubElement(driver, 'host') host.set('mrg_rxbuf', 'off') - cls.add_interface_address(interface, pci_address) + cls._add_interface_address(interface, pci_address) root.write(xml) @classmethod - def add_sriov_interfaces(cls, vm_pci, vf_pci, vfmac, xml): + def add_sriov_interfaces(cls, vm_pci, vf_pci, vf_mac, xml): + """Add a SR-IOV 'interface' XML node in 'devices' node + + <devices> + <interface type='hostdev' managed='yes'> + <source> + <address type='pci' domain='0x0000' bus='0x00' slot='0x03' + function='0x0'/> + </source> + <mac address='52:54:00:6d:90:02'> + <address type='pci' domain='0x0000' bus='0x02' slot='0x04' + function='0x1'/> + </interface> + ... + </devices> + + Reference: https://access.redhat.com/documentation/en-us/ + red_hat_enterprise_linux/6/html/ + virtualization_host_configuration_and_guest_installation_guide/ + sect-virtualization_host_configuration_and_guest_installation_guide + -sr_iov-how_sr_iov_libvirt_works + """ + root = ET.parse(xml) - pci_address = PciAddress.parse_address(vf_pci.strip(), multi_line=True) device = root.find('devices') interface = ET.SubElement(device, 'interface') @@ -157,18 +209,15 @@ class Libvirt(object): interface.set('type', 'hostdev') mac = ET.SubElement(interface, 'mac') - mac.set('address', vfmac) - source = ET.SubElement(interface, 'source') + mac.set('address', vf_mac) - addr = ET.SubElement(source, "address") - addr.set('domain', "0x0") - addr.set('bus', "{0}".format(pci_address.bus)) - addr.set('function', "{0}".format(pci_address.function)) - addr.set('slot', "0x{0}".format(pci_address.slot)) - addr.set('type', "pci") + source = ET.SubElement(interface, 'source') + addr = ET.SubElement(source, 'address') + pci_address = PciAddress(vf_pci.strip()) + cls._add_interface_address(addr, pci_address) - pci_vm_address = PciAddress.parse_address(vm_pci.strip(), multi_line=True) - cls.add_interface_address(interface, pci_vm_address) + pci_vm_address = PciAddress(vm_pci.strip()) + cls._add_interface_address(interface, pci_vm_address) root.write(xml) @@ -192,8 +241,9 @@ class Libvirt(object): vcpu = int(cpu) * int(threads) numa_cpus = '0-%s' % (vcpu - 1) hw_socket = flavor.get('hw_socket', '0') - cpuset = Libvirt.pin_vcpu_for_perf(connection, vm_name, vcpu, hw_socket) + cpuset = Libvirt.pin_vcpu_for_perf(connection, hw_socket) + cputune = extra_spec.get('cputune', '') mac = StandaloneContextHelper.get_mac_address(0x00) image = cls.create_snapshot_qemu(connection, index, flavor.get("images", None)) @@ -204,7 +254,7 @@ class Libvirt(object): memory=memory, vcpu=vcpu, cpu=cpu, numa_cpus=numa_cpus, socket=socket, threads=threads, - vm_image=image, cpuset=cpuset) + vm_image=image, cpuset=cpuset, cputune=cputune) write_file(cfg, vm_xml) @@ -216,11 +266,12 @@ class Libvirt(object): connection.execute("echo never > /sys/kernel/mm/transparent_hugepage/enabled") @classmethod - def pin_vcpu_for_perf(cls, connection, vm_name, cpu, socket="0"): + def pin_vcpu_for_perf(cls, connection, socket='0'): threads = "" sys_obj = CpuSysCores(connection) soc_cpu = sys_obj.get_core_socket() sys_cpu = int(soc_cpu["cores_per_socket"]) + socket = str(socket) cores = "%s-%s" % (soc_cpu[socket][0], soc_cpu[socket][sys_cpu - 1]) if int(soc_cpu["thread_per_core"]) > 1: threads = "%s-%s" % (soc_cpu[socket][sys_cpu], soc_cpu[socket][-1]) @@ -244,9 +295,6 @@ class StandaloneContextHelper(object): if connection.execute(cmd_template % pkg)[0]: connection.execute("apt-get update") connection.execute("apt-get -y install %s" % pkg) - else: - # all installed - return @staticmethod def get_kernel_module(connection, pci, driver): @@ -283,7 +331,7 @@ class StandaloneContextHelper(object): 'interface': str(interface), 'driver': driver }) - LOG.info("{0}".format(networks)) + LOG.info(networks) return networks @@ -352,7 +400,7 @@ class StandaloneContextHelper(object): while not mgmtip and times: connection.execute("fping -c 1 -g %s > /dev/null 2>&1" % cidr) out = connection.execute("ip neighbor | grep '%s'" % mac)[1] - LOG.info("fping -c 1 -g %s > /dev/null 2>&1" % cidr) + LOG.info("fping -c 1 -g %s > /dev/null 2>&1", cidr) if out.strip(): mgmtip = str(out.split(" ")[0]).strip() client = ssh.SSH.from_node(node, overrides={"ip": mgmtip}) diff --git a/yardstick/benchmark/contexts/standalone/ovs_dpdk.py b/yardstick/benchmark/contexts/standalone/ovs_dpdk.py index fcb7bb66c..3755b84e9 100644 --- a/yardstick/benchmark/contexts/standalone/ovs_dpdk.py +++ b/yardstick/benchmark/contexts/standalone/ovs_dpdk.py @@ -118,7 +118,7 @@ class OvsDpdkContext(Context): self.connection.execute(cmd) bind_cmd = "{dpdk_nic_bind} --force -b {driver} {port}" phy_driver = "vfio-pci" - for key, port in self.networks.items(): + for _, port in self.networks.items(): vpci = port.get("phy_port") self.connection.execute(bind_cmd.format(dpdk_nic_bind=self.dpdk_nic_bind, driver=phy_driver, port=vpci)) @@ -129,13 +129,21 @@ class OvsDpdkContext(Context): ovs_sock_path = '/var/run/openvswitch/db.sock' log_path = '/var/log/openvswitch/ovs-vswitchd.log' + pmd_cpu_mask = self.ovs_properties.get("pmd_cpu_mask", '') pmd_mask = hex(sum(2 ** num for num in range(pmd_nums)) << 1) + if pmd_cpu_mask: + pmd_mask = pmd_cpu_mask + socket0 = self.ovs_properties.get("ram", {}).get("socket_0", "2048") socket1 = self.ovs_properties.get("ram", {}).get("socket_1", "2048") ovs_other_config = "ovs-vsctl {0}set Open_vSwitch . other_config:{1}" detach_cmd = "ovs-vswitchd unix:{0}{1} --pidfile --detach --log-file={2}" + lcore_mask = self.ovs_properties.get("lcore_mask", '') + if lcore_mask: + lcore_mask = ovs_other_config.format("--no-wait ", "dpdk-lcore-mask='%s'" % lcore_mask) + cmd_list = [ "mkdir -p /usr/local/var/run/openvswitch", "mkdir -p {}".format(os.path.dirname(log_path)), @@ -143,6 +151,7 @@ class OvsDpdkContext(Context): ovs_sock_path), ovs_other_config.format("--no-wait ", "dpdk-init=true"), ovs_other_config.format("--no-wait ", "dpdk-socket-mem='%s,%s'" % (socket0, socket1)), + lcore_mask, detach_cmd.format(vpath, ovs_sock_path, log_path), ovs_other_config.format("", "pmd-cpu-mask=%s" % pmd_mask), ] @@ -170,7 +179,7 @@ class OvsDpdkContext(Context): ] ordered_network = OrderedDict(self.networks) - for index, (key, vnf) in enumerate(ordered_network.items()): + for index, vnf in enumerate(ordered_network.values()): if ovs_ver >= [2, 7, 0]: dpdk_args = " options:dpdk-devargs=%s" % vnf.get("phy_port") dpdk_list.append(ovs_add_port.format(br='br0', port='dpdk%s' % vnf.get("port_num", 0), @@ -263,7 +272,7 @@ class OvsDpdkContext(Context): # Bind nics back to kernel bind_cmd = "{dpdk_nic_bind} --force -b {driver} {port}" - for key, port in self.networks.items(): + for port in self.networks.values(): vpci = port.get("phy_port") phy_driver = port.get("driver") self.connection.execute(bind_cmd.format(dpdk_nic_bind=self.dpdk_nic_bind, @@ -296,8 +305,7 @@ class OvsDpdkContext(Context): except StopIteration: pass else: - raise ValueError("Duplicate nodes!!! Nodes: %s %s", - (node, duplicate)) + raise ValueError("Duplicate nodes!!! Nodes: %s %s" % (node, duplicate)) node["name"] = attr_name return node @@ -328,17 +336,17 @@ class OvsDpdkContext(Context): def configure_nics_for_ovs_dpdk(self): portlist = OrderedDict(self.networks) - for key, ports in portlist.items(): + for key in portlist: mac = StandaloneContextHelper.get_mac_address() portlist[key].update({'mac': mac}) self.networks = portlist - LOG.info("Ports %s" % self.networks) + LOG.info("Ports %s", self.networks) def _enable_interfaces(self, index, vfs, cfg): vpath = self.ovs_properties.get("vpath", "/usr/local") vf = self.networks[vfs[0]] port_num = vf.get('port_num', 0) - vpci = PciAddress.parse_address(vf['vpci'].strip(), multi_line=True) + vpci = PciAddress(vf['vpci'].strip()) # Generate the vpci for the interfaces slot = index + port_num + 10 vf['vpci'] = \ @@ -357,9 +365,10 @@ class OvsDpdkContext(Context): # 1. Check and delete VM if already exists Libvirt.check_if_vm_exists_and_delete(vm_name, self.connection) - vcpu, mac = Libvirt.build_vm_xml(self.connection, self.vm_flavor, cfg, vm_name, index) + _, mac = Libvirt.build_vm_xml(self.connection, self.vm_flavor, + cfg, vm_name, index) # 2: Cleanup already available VMs - for idx, (vkey, vfs) in enumerate(OrderedDict(vnf["network_ports"]).items()): + for vkey, vfs in OrderedDict(vnf["network_ports"]).items(): if vkey == "mgmt": continue self._enable_interfaces(index, vfs, cfg) @@ -367,7 +376,7 @@ class OvsDpdkContext(Context): # copy xml to target... self.connection.put(cfg, cfg) - # FIXME: launch through libvirt + # NOTE: launch through libvirt LOG.info("virsh create ...") Libvirt.virsh_create_vm(self.connection, cfg) diff --git a/yardstick/benchmark/contexts/standalone/sriov.py b/yardstick/benchmark/contexts/standalone/sriov.py index 69825fbbf..9d8423b5f 100644 --- a/yardstick/benchmark/contexts/standalone/sriov.py +++ b/yardstick/benchmark/contexts/standalone/sriov.py @@ -110,7 +110,7 @@ class SriovContext(Context): Libvirt.check_if_vm_exists_and_delete(vm, self.connection) # Bind nics back to kernel - for key, ports in self.networks.items(): + for ports in self.networks.values(): # enable VFs for given... build_vfs = "echo 0 > /sys/bus/pci/devices/{0}/sriov_numvfs" self.connection.execute(build_vfs.format(ports.get('phy_port'))) @@ -170,8 +170,7 @@ class SriovContext(Context): def configure_nics_for_sriov(self): vf_cmd = "ip link set {0} vf 0 mac {1}" - for key, ports in self.networks.items(): - vf_pci = [] + for ports in self.networks.values(): host_driver = ports.get('driver') if host_driver not in self.drivers: self.connection.execute("rmmod %svf" % host_driver) @@ -187,19 +186,19 @@ class SriovContext(Context): if interface is not None: self.connection.execute(vf_cmd.format(interface, mac)) - vf_pci = self.get_vf_data('vf_pci', ports.get('phy_port'), mac, interface) + vf_pci = self._get_vf_data(ports.get('phy_port'), mac, interface) ports.update({ 'vf_pci': vf_pci, 'mac': mac }) - LOG.info("Ports %s" % self.networks) + LOG.info('Ports %s', self.networks) def _enable_interfaces(self, index, idx, vfs, cfg): vf_spoofchk = "ip link set {0} vf 0 spoofchk off" vf = self.networks[vfs[0]] - vpci = PciAddress.parse_address(vf['vpci'].strip(), multi_line=True) + vpci = PciAddress(vf['vpci'].strip()) # Generate the vpci for the interfaces slot = index + idx + 10 vf['vpci'] = \ @@ -222,7 +221,7 @@ class SriovContext(Context): # 1. Check and delete VM if already exists Libvirt.check_if_vm_exists_and_delete(vm_name, self.connection) - vcpu, mac = Libvirt.build_vm_xml(self.connection, self.vm_flavor, cfg, vm_name, index) + _, mac = Libvirt.build_vm_xml(self.connection, self.vm_flavor, cfg, vm_name, index) # 2: Cleanup already available VMs for idx, (vkey, vfs) in enumerate(OrderedDict(vnf["network_ports"]).items()): if vkey == "mgmt": @@ -232,7 +231,7 @@ class SriovContext(Context): # copy xml to target... self.connection.put(cfg, cfg) - # FIXME: launch through libvirt + # NOTE: launch through libvirt LOG.info("virsh create ...") Libvirt.virsh_create_vm(self.connection, cfg) @@ -246,15 +245,15 @@ class SriovContext(Context): return nodes - def get_vf_data(self, key, value, vfmac, pfif): + def _get_vf_data(self, value, vfmac, pfif): vf_data = { "mac": vfmac, "pf_if": pfif } vfs = StandaloneContextHelper.get_virtual_devices(self.connection, value) for k, v in vfs.items(): - m = PciAddress.parse_address(k.strip(), multi_line=True) - m1 = PciAddress.parse_address(value.strip(), multi_line=True) + m = PciAddress(k.strip()) + m1 = PciAddress(value.strip()) if m.bus == m1.bus: vf_data.update({"vf_pci": str(v)}) break diff --git a/yardstick/benchmark/core/__init__.py b/yardstick/benchmark/core/__init__.py index 70036ea1e..3e3aa99a1 100644 --- a/yardstick/benchmark/core/__init__.py +++ b/yardstick/benchmark/core/__init__.py @@ -6,10 +6,15 @@ # which accompanies this distribution, and is available at # http://www.apache.org/licenses/LICENSE-2.0 ############################################################################## +""" +Yardstick benchmark core. +""" + from __future__ import print_function class Param(object): + """This class converts a parameter dictionary to an object.""" def __init__(self, kwargs): # list @@ -31,10 +36,3 @@ class Param(object): # list self.type = kwargs.get('type') - - -def print_hbar(barlen): - """print to stdout a horizontal bar""" - print("+") - print("-" * barlen) - print("+") diff --git a/yardstick/benchmark/core/runner.py b/yardstick/benchmark/core/runner.py index 64acdaa99..b5e457c41 100644 --- a/yardstick/benchmark/core/runner.py +++ b/yardstick/benchmark/core/runner.py @@ -10,9 +10,10 @@ """ Handler for yardstick command 'runner' """ from __future__ import absolute_import -from __future__ import print_function + +import prettytable + from yardstick.benchmark.runners.base import Runner -from yardstick.benchmark.core import print_hbar class Runners(object): # pragma: no cover @@ -21,16 +22,15 @@ class Runners(object): # pragma: no cover Set of commands to discover and display runner types. """ - def list_all(self, args): + def list_all(self, *args): """List existing runner types""" types = Runner.get_types() - print_hbar(78) - print("| %-16s | %-60s" % ("Type", "Description")) - print_hbar(78) + runner_table = prettytable.PrettyTable(['Type', 'Description']) + runner_table.align = 'l' for rtype in types: - print("| %-16s | %-60s" % (rtype.__execution_type__, - rtype.__doc__.split("\n")[0])) - print_hbar(78) + runner_table.add_row([rtype.__execution_type__, + rtype.__doc__.split("\n")[0]]) + print(runner_table) def show(self, args): """Show details of a specific runner type""" diff --git a/yardstick/benchmark/core/scenario.py b/yardstick/benchmark/core/scenario.py index 28eb65230..3366172a5 100644 --- a/yardstick/benchmark/core/scenario.py +++ b/yardstick/benchmark/core/scenario.py @@ -10,8 +10,9 @@ """ Handler for yardstick command 'scenario' """ from __future__ import absolute_import +import prettytable + from yardstick.benchmark.scenarios.base import Scenario -from yardstick.benchmark.core import print_hbar class Scenarios(object): # pragma: no cover @@ -20,16 +21,15 @@ class Scenarios(object): # pragma: no cover Set of commands to discover and display scenario types. """ - def list_all(self, args): + def list_all(self, *args): """List existing scenario types""" types = Scenario.get_types() - print_hbar(78) - print("| %-16s | %-60s" % ("Type", "Description")) - print_hbar(78) + scenario_table = prettytable.PrettyTable(['Type', 'Description']) + scenario_table.align = 'l' for scenario_class in types: - print("| %-16s | %-60s" % (scenario_class.get_scenario_type(), - scenario_class.get_description())) - print_hbar(78) + scenario_table.add_row([scenario_class.get_scenario_type(), + scenario_class.get_description()]) + print(scenario_table) def show(self, args): """Show details of a specific scenario type""" diff --git a/yardstick/benchmark/scenarios/availability/ha_tools/fault_process_kill.bash b/yardstick/benchmark/scenarios/availability/ha_tools/fault_process_kill.bash index eec86e133..d34ce9338 100755 --- a/yardstick/benchmark/scenarios/availability/ha_tools/fault_process_kill.bash +++ b/yardstick/benchmark/scenarios/availability/ha_tools/fault_process_kill.bash @@ -26,7 +26,7 @@ elif [ "$process_name" = "haproxy" ]; then kill -9 "${pid}" done else - for pid in $(pgrep -f "/usr/.*/${process_name}"); + for pid in $(pgrep -fa [^-_a-zA-Z0-9]${process_name} | grep -iv heartbeat | awk '{print $1}'); do kill -9 "${pid}" done diff --git a/yardstick/benchmark/scenarios/compute/spec_cpu.py b/yardstick/benchmark/scenarios/compute/spec_cpu.py index df361cd94..39cd3fb8c 100644 --- a/yardstick/benchmark/scenarios/compute/spec_cpu.py +++ b/yardstick/benchmark/scenarios/compute/spec_cpu.py @@ -10,6 +10,7 @@ from __future__ import absolute_import import logging import pkg_resources +import os import yardstick.ssh as ssh from yardstick.benchmark.scenarios import base @@ -66,6 +67,8 @@ class SpecCPU(base.Scenario): default: na """ __scenario_type__ = "SpecCPU2006" + CPU2006_DIR = "~/cpu2006" + CPU2006_RESULT_FILE = os.path.join(CPU2006_DIR, "result/CINT2006.001.ref.txt") def __init__(self, scenario_cfg, context_cfg): self.scenario_cfg = scenario_cfg @@ -87,8 +90,9 @@ class SpecCPU(base.Scenario): "yardstick.resources", 'files/' + self.runspec_config) # copy SPEC CPU2006 config file to host if given - self.client._put_file_shell(self.runspec_config_file, - '/usr/cpu2006/config/yardstick_spec_cpu2006.cfg') + cfg_path = os.path.join(self.CPU2006_DIR, + 'config/yardstick_spec_cpu2006.cfg') + self.client._put_file_shell(self.runspec_config_file, cfg_path) else: self.runspec_config = "Example-linux64-amd64-gcc43+.cfg" @@ -100,7 +104,8 @@ class SpecCPU(base.Scenario): if not self.setup_done: self.setup() - cmd = "cd /usr/cpu2006/ && . ./shrc && runspec --config %s" % self.runspec_config + cmd = "cd %s && . ./shrc && runspec --config %s" % ( + self.CPU2006_DIR, self.runspec_config) cmd_args = "" if "rate" in self.options: @@ -140,5 +145,12 @@ class SpecCPU(base.Scenario): if status: raise RuntimeError(stderr) + cmd = "cat %s" % self.CPU2006_RESULT_FILE + LOG.debug("Executing command: %s", cmd) + status, stdout, stderr = self.client.execute(cmd, timeout=30) + if status: + raise RuntimeError(stderr) + if stdout: + LOG.info("SPEC CPU2006 result is:\n%s", stdout) LOG.info('SPEC CPU2006 benchmark completed, please find benchmark reports \ at /tmp/result directory') diff --git a/yardstick/cmd/__init__.py b/yardstick/cmd/__init__.py index 3756d9ebb..e69de29bb 100644 --- a/yardstick/cmd/__init__.py +++ b/yardstick/cmd/__init__.py @@ -1,16 +0,0 @@ -############################################################################## -# Copyright (c) 2015 Ericsson AB and others. -# -# 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 -############################################################################## -from __future__ import print_function - - -def print_hbar(barlen): - """print to stdout a horizontal bar""" - print(("+"), end=' ') - print(("-" * barlen), end=' ') - print("+") diff --git a/yardstick/cmd/commands/testcase.py b/yardstick/cmd/commands/testcase.py index a151871b3..7bdcdf003 100644 --- a/yardstick/cmd/commands/testcase.py +++ b/yardstick/cmd/commands/testcase.py @@ -8,11 +8,11 @@ ############################################################################## """ Handler for yardstick command 'testcase' """ -from __future__ import print_function from __future__ import absolute_import +import prettytable + from yardstick.benchmark.core.testcase import Testcase -from yardstick.benchmark.core import print_hbar from yardstick.common.utils import cliargs from yardstick.cmd.commands import change_osloobj_to_paras from yardstick.cmd.commands import Commands @@ -24,7 +24,7 @@ class TestcaseCommands(Commands): Set of commands to discover and display test cases. """ - def do_list(self, args): + def do_list(self, *args): """List existing test cases""" testcase_list = self.client.get('/yardstick/testcases')['result'] self._format_print(testcase_list) @@ -37,11 +37,8 @@ class TestcaseCommands(Commands): def _format_print(self, testcase_list): """format output""" - - print_hbar(88) - print("| %-21s | %-60s" % ("Testcase Name", "Description")) - print_hbar(88) + case_table = prettytable.PrettyTable(['Testcase Name', 'Description']) + case_table.align = 'l' for testcase_record in testcase_list: - print("| %-16s | %-60s" % (testcase_record['Name'], - testcase_record['Description'])) - print_hbar(88) + case_table.add_row([testcase_record['Name'], testcase_record['Description']]) + print(case_table) diff --git a/yardstick/network_services/utils.py b/yardstick/network_services/utils.py index eac3c814f..7a1815eb9 100644 --- a/yardstick/network_services/utils.py +++ b/yardstick/network_services/utils.py @@ -22,6 +22,7 @@ from oslo_config import cfg from oslo_config.cfg import NoSuchOptError from oslo_utils import encodeutils + NSB_ROOT = "/opt/nsb_bin" CONF = cfg.CONF @@ -43,30 +44,37 @@ HEXADECIMAL = "[0-9a-zA-Z]" class PciAddress(object): + """Class to handle PCI addresses. - PCI_PATTERN_STR = HEXADECIMAL.join([ - "(", - "{4}):(", # domain (4 bytes) - "{2}):(", # bus (2 bytes) - "{2}).(", # function (2 bytes) - ")", # slot (1 byte) - ]) + A PCI address could be written in two ways: + - Simple BDF notation: + 00:00.0 # bus:device.function + - With domain extension. + 0000:00:00.0 # domain:bus:device.function - PCI_PATTERN = re.compile(PCI_PATTERN_STR) + Note: in Libvirt, 'device' is called 'slot'. - @classmethod - def parse_address(cls, text, multi_line=False): - if multi_line: - text = text.replace(os.linesep, '') - match = cls.PCI_PATTERN.search(text) - return cls(match.group(0)) + Reference: https://wiki.xenproject.org/wiki/ + Bus:Device.Function_(BDF)_Notation + """ + PCI_PATTERN_STR = ( + r"((?P<domain>[0-9a-zA-Z]{4}):)?(?P<bus>[0-9a-zA-Z]{2}):" + r"(?P<slot>[0-9a-zA-Z]{2})\.(?P<function>[0-9a-zA-Z]{1})") def __init__(self, address): - super(PciAddress, self).__init__() - match = self.PCI_PATTERN.match(address) + pci_pattern = re.compile(self.PCI_PATTERN_STR) + match = pci_pattern.search(address) if not match: raise ValueError('Invalid PCI address: {}'.format(address)) - self.address = address + + self._domain = (match.group('domain') or '0000').lower() + self._bus = match.group('bus').lower() + self._slot = match.group('slot').lower() + self._function = match.group('function').lower() + self.address = '{:0>4}:{:0>2}:{:0>2}.{:1}'.format(self.domain, + self.bus, + self.slot, + self.function) self.match = match def __repr__(self): @@ -74,22 +82,22 @@ class PciAddress(object): @property def domain(self): - return self.match.group(1) + return self._domain @property def bus(self): - return self.match.group(2) + return self._bus @property def slot(self): - return self.match.group(3) + return self._slot @property def function(self): - return self.match.group(4) + return self._function def values(self): - return [self.match.group(n) for n in range(1, 5)] + return [self._domain, self._bus, self._slot, self._function] def get_nsb_option(option, default=None): diff --git a/yardstick/network_services/vnf_generic/vnf/router_vnf.py b/yardstick/network_services/vnf_generic/vnf/router_vnf.py new file mode 100644 index 000000000..aea27ffa6 --- /dev/null +++ b/yardstick/network_services/vnf_generic/vnf/router_vnf.py @@ -0,0 +1,185 @@ +# 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. +""" Add generic L3 forwarder implementation based on sample_vnf.py""" + +from __future__ import absolute_import +import logging +import time +import itertools + +import re +from netaddr import IPRange + +from six.moves import zip + +from yardstick.benchmark.contexts.base import Context +from yardstick.network_services.vnf_generic.vnf.sample_vnf import SampleVNF, \ + DpdkVnfSetupEnvHelper + +LOG = logging.getLogger(__name__) + + +class RouterVNF(SampleVNF): + + WAIT_TIME = 1 + + def __init__(self, name, vnfd, setup_env_helper_type=None, resource_helper_type=None): + if setup_env_helper_type is None: + setup_env_helper_type = DpdkVnfSetupEnvHelper + + # For heat test cases + vnfd['mgmt-interface'].pop("pkey", "") + vnfd['mgmt-interface']['password'] = 'password' + + super(RouterVNF, self).__init__(name, vnfd, setup_env_helper_type, resource_helper_type) + + def instantiate(self, scenario_cfg, context_cfg): + self.scenario_helper.scenario_cfg = scenario_cfg + self.context_cfg = context_cfg + self.nfvi_context = Context.get_context_from_server(self.scenario_helper.nodes[self.name]) + self.configure_routes(self.name, scenario_cfg, context_cfg) + + def wait_for_instantiate(self): + time.sleep(self.WAIT_TIME) + + def _run(self): + # we can't share ssh paramiko objects to force new connection + self.ssh_helper.drop_connection() + + def terminate(self): + self._tear_down() + self.resource_helper.stop_collect() + + def scale(self, flavor=""): + pass + + @staticmethod + def row_with_header(header, data): + """Returns dictionary per row of values for 'ip show stats'. + + Args: + header(str): output header + data(str): output data + + Returns: + dict: dictionary per row of values for 'ip show stats' + + """ + prefix, columns = header.strip().split(':') + column_names = ["{0}:{1}".format(prefix, h) for h in columns.split()] + return dict(list(zip(column_names, data.strip().split()))) + + RX_TX_RE = re.compile(r"\s+[RT]X[^:]*:") + + @classmethod + def get_stats(cls, stdout): + """Returns list of IP statistics. + + Args: + stdout(str): command output + + Returns: + dict: list of IP statistics + + """ + input_lines = stdout.splitlines() + table = {} + for n, row in enumerate(input_lines): + if cls.RX_TX_RE.match(row): + # use pairs of rows, header and data + table.update(cls.row_with_header(*input_lines[n:n + 2])) + return table + + def collect_kpi(self): + # Implement stats collection + ip_link_stats = '/sbin/ip -s link' + stdout = self.ssh_helper.execute(ip_link_stats)[1] + link_stats = self.get_stats(stdout) + # get RX/TX from link_stats and assign to results + + result = { + "packets_in": 0, + "packets_dropped": 0, + "packets_fwd": 0, + "link_stats": link_stats + } + + LOG.debug("%s collect KPIs %s", "RouterVNF", result) + return result + + INTERFACE_WAIT = 2 + + def configure_routes(self, node_name, scenario_cfg, context_cfg): + # Configure IP of dataplane ports and add static ARP entries + # + # This function should be modified to configure a 3rd party/commercial VNF. + # The current implementation works on a Linux based VNF with "ip" command. + # + # Flow contains: + # {'src_ip': ['152.16.100.26-152.16.100.27'], + # 'dst_ip': ['152.16.40.26-152.16.40.27'], 'count': 2} + + ifaces = [] + dst_macs = [] + + ip_cmd_replace = '/sbin/ip addr replace %s/24 dev %s' + ip_cmd_up = '/sbin/ip link set %s up' + ip_cmd_flush = '/sbin/ip address flush dev %s' + + # Get VNF IPs from test case file + for value in context_cfg['nodes'][node_name]['interfaces'].values(): + dst_macs.append(value['dst_mac']) + + # Get the network interface name using local_mac + iname = self.ssh_helper.execute("/sbin/ip a |grep -B 1 %s | head -n 1" + % (value['local_mac'])) + iname = iname[1].split(":")[1].strip() + ifaces.append(iname) + + self.ssh_helper.execute(ip_cmd_flush % iname) + + # Get the local_ip from context_cfg and assign to the data ports + self.ssh_helper.execute(ip_cmd_replace % (str(value['local_ip']), + iname)) + # Enable interface + self.ssh_helper.execute(ip_cmd_up % iname) + time.sleep(self.INTERFACE_WAIT) + + # Configure static ARP entries for each IP + # using SSH or REST API calls + try: + src_ips = scenario_cfg['options']['flow']['src_ip'] + dst_ips = scenario_cfg['options']['flow']['dst_ip'] + except KeyError: + raise KeyError("Missing flow definition in scenario section" + + " of the task definition file") + + # Multiport + ip_ranges = [] + for src, dst in zip(src_ips, dst_ips): + range1 = itertools.cycle(iter(src.split('-'))) + range2 = itertools.cycle(iter(dst.split('-'))) + + range1 = IPRange(next(range1), next(range1)) + range2 = IPRange(next(range2), next(range2)) + ip_ranges.append(range1) + ip_ranges.append(range2) + + ip_cmd = '/sbin/ip neigh add %s lladdr %s dev %s nud perm' + for idx, iface in enumerate(ifaces): + for addr in ip_ranges[idx]: + self.ssh_helper.execute(ip_cmd % (addr, dst_macs[idx], iface)) + + arp_status = self.ssh_helper.execute("arp -a -n") + LOG.debug('arp %s', arp_status) diff --git a/yardstick/network_services/vnf_generic/vnf/tg_ping.py b/yardstick/network_services/vnf_generic/vnf/tg_ping.py index 30a917862..5238a5f02 100644 --- a/yardstick/network_services/vnf_generic/vnf/tg_ping.py +++ b/yardstick/network_services/vnf_generic/vnf/tg_ping.py @@ -126,11 +126,10 @@ class PingTrafficGen(SampleVNFTrafficGen): "packets_received": 0, "rtt": 0, } + self.setup_helper.setup_vnf_environment() intf = self.vnfd_helper.interfaces[0]["virtual-interface"] self.resource_helper.cmd_kwargs = { 'target_ip': IPv4Interface(intf["dst_ip"]).ip.exploded, 'local_ip': IPv4Interface(intf["local_ip"]).ip.exploded, 'local_if_name': intf["local_iface_name"].split('/')[0], } - - self.setup_helper.setup_vnf_environment() |