yardstick.git
6 years agoUse context name instead of key_uuid 47/52347/14
Emma Foley [Fri, 16 Feb 2018 15:22:12 +0000 (15:22 +0000)]
Use context name instead of key_uuid

context.key_uuid is only used as a suffix for the key files.
There is already a unique ID associated with a the context;
the context name includes a task ID, which is a UUID.

This patch sets context.key_uuid to to context.name instead of
generating a separate UUID

As a result, get_short_key_uuid() is not needed.

JIRA: YARDSTICK-1028
Change-Id: Id175061d6cfe23a068bb3d12ce176c1f176e8236
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoAdd _create_new_stack method 79/52779/10
Emma Foley [Wed, 21 Feb 2018 12:36:15 +0000 (12:36 +0000)]
Add _create_new_stack method

The logic for creating a new stack in contexts/heat.py:HeatContext
can added to a method to make the code eassier to read and test.

This is in preparation for an update to deploy() that would allow
an existing stack to be reused, or a new stack created.
By having the create_new_stack logic in a new method, deploy()
becomes easier to read and test.

JIRA: YARDSTICK-886
Change-Id: I7af01e2209a3460658f8db0249b7c620743cced0
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoUpdate TaskParser to deal with qualified name in Context 51/52451/12
Emma Foley [Thu, 22 Feb 2018 19:11:12 +0000 (19:11 +0000)]
Update TaskParser to deal with qualified name in Context

The context name depends on the defined name in the testcase input
file, the task ID and the flags of the context.

If the context is going to be undeployed at the end of the test, the
task ID is suffixed to the name to avoid interferences with previous
deployments. If the context needs to be deployed at the end of the
test, the name assigned is kept.

This patch makes this process transparent to the developer.
This patch modifies how TaskParser determines the correct context name,
taking into account that the name might change based on context flags.

JIRA: YARDSTICK-886

Change-Id: I44da30dac562c1a4166e084645ae91c17798651d
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoAdd qualified name to Context 55/52655/10
Emma Foley [Mon, 26 Feb 2018 11:43:51 +0000 (11:43 +0000)]
Add qualified name to Context

The context name depends on the defined name in the testcase input
file, the task ID and the flags of the context.

If the context is going to be undeployed at the end of the test, the
task ID is suffixed to the name to avoid interferences with previous
deployments. If the context needs to be deployed at the end of the
test, the name assigned is kept.

This patch makes base.Context use Flags when initialising contexts,
this sets the name property based on the no_setup and no_teardown
flags.

Since base.Context is an abstract class, it cannot be instantiated.
However, there are some non-abstract methods that need testing.
Since DummyContext does not override any of these methods, it can be used for
testing.

JIRA: YARDSTICK-886

Change-Id: I1447fb5ed447691eaeb0a97f928c0b3333799d07
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoAdd Flags class to base.Context 53/52653/3
Emma Foley [Mon, 26 Feb 2018 11:25:34 +0000 (11:25 +0000)]
Add Flags class to base.Context

This patch adds a Flags class to represent the flags passed to
the context.

Flags will contain a set of attributes (for example no_setup and no_teardown).
Those attributes will modify the behaviour of the context.

The attributes added initially are:
* 'no_setup' (default: False)
* 'no_teardown' (default: False)

In future patches, they will be used by the context to:
* Change the name of the context.
* Skip the deploy() and undeploy() methods to keep the VNFs active after the
  testcases are run.

JIRA: YARDSTICK-886
Change-Id: I734b082aa101649eea8991304a8b753ae96aa9de
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoMerge "Addition of NSB Prox developer guide."
Abhijit Sinha [Tue, 27 Feb 2018 16:59:54 +0000 (16:59 +0000)]
Merge "Addition of NSB Prox developer guide."

6 years agoAddition of NSB Prox developer guide. 39/52239/3
DanielMartinBuckley [Fri, 16 Feb 2018 14:56:42 +0000 (14:56 +0000)]
Addition of NSB Prox developer guide.

JIRA: YARDSTICK-840

This provides a developer guide to enable the reader to add NSB
PROX tests based on existing PROX functionality.

This allows the user to configure, run and debug NSB Prox tests
for Baremetal and Openstack (both 2 and 4 ports)

Change-Id: I2cb9eb6064e501dd9abe0d2cc4ed8ce4b369f174
Signed-off-by: Daniel Martin Buckley <daniel.m.buckley@intel.com>
6 years agoMerge "Testcase to find storage bottlenecks using Yardstick for Multistack"
Rex Lee [Mon, 26 Feb 2018 04:21:13 +0000 (04:21 +0000)]
Merge "Testcase to find storage bottlenecks using Yardstick for Multistack"

6 years agoTestcase to find storage bottlenecks using Yardstick for Multistack 53/51753/3
Ace Lee [Tue, 6 Feb 2018 17:07:24 +0000 (17:07 +0000)]
Testcase to find storage bottlenecks using Yardstick for Multistack

JIRA: BOTTLENECK-217

This patch is used to find storage bottlenecks while using
yardstick for multistack.

Shubham is busy for his exam,
I can't change his patch, so I need to resubmit a patch.

Change-Id: Ibf8ec3ae7f19b27254eedabb1b95bd89a0993ed7
Signed-off-by: Ace Lee <liyin11@huawei.com>
6 years agoBugfix: ci error due to no heat client 05/52605/1
rexlee8776 [Mon, 26 Feb 2018 02:03:29 +0000 (02:03 +0000)]
Bugfix: ci error due to no heat client

JIRA: YARDSTICK-1030

Change-Id: I5d9e135449b2d35f051ecf5fa63a1ce11030de4a
Signed-off-by: rexlee8776 <limingjiang@huawei.com>
6 years agoMerge "Bug Fix: Move heat_timeout variable higher"
Jing Lu [Sat, 24 Feb 2018 02:31:41 +0000 (02:31 +0000)]
Merge "Bug Fix: Move heat_timeout variable higher"

6 years agoBug Fix: Move heat_timeout variable higher 29/52529/2
Dimitrios Markou [Fri, 23 Feb 2018 14:13:09 +0000 (16:13 +0200)]
Bug Fix: Move heat_timeout variable higher

If a heat_template was used by a testcase the heat_timeout
variable was not getting initialized and that caused errors
in the Shade python module.

JIRA: YARDSTICK-1027

Change-Id: Ic0bf15b13cc00595964a97f8150dc5e6f2b7e1d7
Signed-off-by: Dimitrios Markou <mardim@intracom-telecom.com>
6 years agoAdd 'ANSIBLE_ROLES_PATH' in ansible_env 87/52487/2
JingLu5 [Fri, 23 Feb 2018 01:31:38 +0000 (01:31 +0000)]
Add 'ANSIBLE_ROLES_PATH' in ansible_env

JIRA: YARDSTICK-1024

This work adds the 'ANSIBLE_ROLES_PATH' as one of the Ansible environment variables.
This 'ANSIBLE_ROLES_PATH' is set to the roles directory in Yardstick repo.
By adding this variable, Ansible will first searches the local project for a role, then searches the roles_path.
It will let the users of the plugin projects to able to use a relative role path for any of their own roles in ansible playbook.

Change-Id: I0926ab0c0fa5c6cc37c4fe560db5b2aec3fe6eb1
Signed-off-by: JingLu5 <lvjing5@huawei.com>
6 years agoMerge "Fix error in address input format in "_ip_range_action_partial""
Rodolfo Alonso Hernandez [Thu, 22 Feb 2018 16:29:02 +0000 (16:29 +0000)]
Merge "Fix error in address input format in "_ip_range_action_partial""

6 years agoMerge "Make files pep8 compliant"
Emma Foley [Thu, 22 Feb 2018 12:54:27 +0000 (12:54 +0000)]
Merge "Make files pep8 compliant"

6 years agoMerge "Refactor benchmark.core.test_plugin.PluginTestCase"
Rodolfo Alonso Hernandez [Thu, 22 Feb 2018 11:36:37 +0000 (11:36 +0000)]
Merge "Refactor benchmark.core.test_plugin.PluginTestCase"

6 years agoMerge "Bug fix for Ansible destroy VM script"
Emma Foley [Wed, 21 Feb 2018 09:58:28 +0000 (09:58 +0000)]
Merge "Bug fix for Ansible destroy VM script"

6 years agoMerge "Proposing Abhijit Sinha as a committer in Yardstick"
Ross Brattain [Tue, 20 Feb 2018 18:55:04 +0000 (18:55 +0000)]
Merge "Proposing Abhijit Sinha as a committer in Yardstick"

6 years agoMake files pep8 compliant 45/52345/4
Emma Foley [Wed, 31 Jan 2018 17:41:33 +0000 (17:41 +0000)]
Make files pep8 compliant

This change makes files pep8 compliant before adding the
reuse context feature

JIRA: YARDSTICK-886
Change-Id: Iae7daaa159a9ddbb5809a9a7ac74f8a53683089a
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoMerge "Replace neutron network deletion with shade."
Emma Foley [Mon, 19 Feb 2018 13:34:47 +0000 (13:34 +0000)]
Merge "Replace neutron network deletion with shade."

6 years agoMerge "Make segmentation_id configurable for tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex"
Emma Foley [Mon, 19 Feb 2018 13:29:11 +0000 (13:29 +0000)]
Merge "Make segmentation_id configurable for tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex"

6 years agoMake segmentation_id configurable for tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex 35/52235/2
Mytnyk, Volodymyr [Fri, 16 Feb 2018 10:45:20 +0000 (10:45 +0000)]
Make segmentation_id configurable for tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex

Updated vfw/tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex.yaml TC to be
able to configure segmentation_id from commmand line.

E.g.:
  yardstick -d task start --task-args='{"provider": "sriov", \
    "segmentation_id": 100}' ...

JIRA: YARDSTICK-1004

Change-Id: I53daae3468de2a1f523bd96817143a5f809238a2
Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
6 years agoReplace neutron network deletion with shade. 67/51767/13
Shobhi Jain [Thu, 1 Feb 2018 16:31:55 +0000 (16:31 +0000)]
Replace neutron network deletion with shade.

Function delete_neutron_net now uses shade client instead of neutron
client.

JIRA: YARDSTICK-890

Change-Id: I99b6f3ecd37d6e3b783f7eb3da9f971398fc3bdd
Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
6 years agoFix error in address input format in "_ip_range_action_partial" 91/51691/7
Rodolfo Alonso Hernandez [Mon, 5 Feb 2018 17:52:10 +0000 (17:52 +0000)]
Fix error in address input format in "_ip_range_action_partial"

IP address format introduced in [1] should be unicode instead of string.
"ipaddress.IPv4Address(min_value)" doesn't parse correctly the input
parameter unless the parameter is in unicode format; this is valid both
for Python version 2 and 3.

Execution error if the parameter is a string:
>>> int(ipaddress.IPv4Address('10.0.3.2'))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/ipaddress.py",
  line 1391, in __init__
    self._check_packed_address(address, 4)
  File "/usr/local/lib/python2.7/dist-packages/ipaddress.py",
  line 554, in _check_packed_address
    expected_len, self._version))
ipaddress.AddressValueError: '10.0.3.2' (len 8 != 4) is not permitted
as an IPv4 address. Did you pass in a bytes (str in Python 2) instead
of a unic

[1]https://github.com/opnfv/yardstick/blob/e5775e7efbc55f116b4d4ac11ff87b8d8553247e/yardstick/network_services/traffic_profile/traffic_profile.py#L87-L88

JIRA: YARDSTICK-996

Change-Id: Ic727a79044834b181c99789f0f5efc21c68f0ff2
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoMerge "Workaround to fix Heat stack deletion bug in Shade"
Rodolfo Alonso Hernandez [Sat, 17 Feb 2018 19:01:36 +0000 (19:01 +0000)]
Merge "Workaround to fix Heat stack deletion bug in Shade"

6 years agoMerge "Bump pip packages installed in "nsb_setup.sh" script"
Rodolfo Alonso Hernandez [Fri, 16 Feb 2018 18:08:03 +0000 (18:08 +0000)]
Merge "Bump pip packages installed in "nsb_setup.sh" script"

6 years agoMerge "Fix "./docker/Dockerfile.aarch64.patch""
Rodolfo Alonso Hernandez [Fri, 16 Feb 2018 18:07:57 +0000 (18:07 +0000)]
Merge "Fix "./docker/Dockerfile.aarch64.patch""

6 years agoMerge "Remove tool provisioning from DpdkVnfSetupEnvHelper._setup_dpdk"
Rodolfo Alonso Hernandez [Fri, 16 Feb 2018 18:07:26 +0000 (18:07 +0000)]
Merge "Remove tool provisioning from DpdkVnfSetupEnvHelper._setup_dpdk"

6 years agoRefactor benchmark.core.test_plugin.PluginTestCase 57/47257/8
Rodolfo Alonso Hernandez [Wed, 15 Nov 2017 12:35:04 +0000 (12:35 +0000)]
Refactor benchmark.core.test_plugin.PluginTestCase

Tests in benchmark.core.test_plugin.PluginTestCase are not covering
correctly the functionality of the tested class.

YARDSTICK-851

Change-Id: I0b4cda7dbf109776a202167abfde8c9eb268db12
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoNSB: Ixia remove unused traffic_generator arg 37/52137/4
Ross Brattain [Wed, 14 Feb 2018 05:43:55 +0000 (21:43 -0800)]
NSB: Ixia remove unused traffic_generator arg

also fix pylint unittest warnings

JIRA: YARDSTICK-1014
Change-Id: I4ff9769fdca89c6fc1fb9ca62e9f8ea6b174681e
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoMerge "Update heat RFC2544 based TC to support SRIOV VF ports."
Emma Foley [Thu, 15 Feb 2018 15:03:27 +0000 (15:03 +0000)]
Merge "Update heat RFC2544 based TC to support SRIOV VF ports."

6 years agoWorkaround to fix Heat stack deletion bug in Shade 89/52189/2
Rodolfo Alonso Hernandez [Thu, 15 Feb 2018 11:42:11 +0000 (11:42 +0000)]
Workaround to fix Heat stack deletion bug in Shade

There is a bug in Shade, in the function "event_utils.poll_for_events".
While Shade is waiting for the Heat stack to be deleted, retrieves
periodically the status of this Heat stack. When the stack is deleted,
the function "get_stack" [1] returns None; then L90 tries to access to
a key of this None object.

[1]https://github.com/openstack-infra/shade/blob/e5bcb705c5b32334cdc1dd9807126298c87b0622/shade/_heat/event_utils.py#L89-L90
Shade function

JIRA: YARDSTICK-1015

Change-Id: I56ea853be41bfd7f63e094d7a3696d97ba078ba4
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoBugFix: Fix to pod context filename 51/52151/2
Xavier Simonart [Wed, 14 Feb 2018 14:32:53 +0000 (15:32 +0100)]
BugFix: Fix to pod context filename

The "context:file" of tc_prox_baremetal_lw_aftr
has an incorrect path, compaired to all other
prox test cases.

Change-Id: Id24e74905f36bc84fdf93d1a2966211ecad55c8b
Signed-off-by: Xavier Simonart <xavier.simonart@intel.com>
6 years agoUpdate heat RFC2544 based TC to support SRIOV VF ports. 61/51961/4
Mytnyk, Volodymyr [Fri, 9 Feb 2018 14:55:04 +0000 (14:55 +0000)]
Update heat RFC2544 based TC to support SRIOV VF ports.

Updated vfw/tc_heat_rfc2544_ipv4_1rule_1flow_64B_trex.yaml TC to be
able to run it in heat context with SRIOV VF ports configured in
OpenStack.

E.g.:
  yardstick task start --task-args='{"provider": "sriov"}' ...
  yardstick task start --task-args='{"provider": "sriov"}\
    physical_networks: ["physnet1", "physnet2"]}' ...

Console log: http://paste.openstack.org/show/666931/
Result output: http://paste.openstack.org/show/666930/

JIRA: YARDSTICK-1004

Change-Id: If0dabd0791e4e295782fee0f3de1536474218876
Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
6 years agoMerge "Fixed document for Grafana Port usage"
Rodolfo Alonso Hernandez [Wed, 14 Feb 2018 11:36:03 +0000 (11:36 +0000)]
Merge "Fixed document for Grafana Port usage"

6 years agoNSB: fix test_vpe_vnf.py 35/52135/3
Ross Brattain [Wed, 14 Feb 2018 05:43:10 +0000 (21:43 -0800)]
NSB: fix test_vpe_vnf.py

Change-Id: Ie1da572e2ac00e380b25f8e22f5aa9059dcb5238
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoNSB: fix pylint warnings in test_tg_ixload 33/52133/3
Ross Brattain [Wed, 14 Feb 2018 05:42:45 +0000 (21:42 -0800)]
NSB: fix pylint warnings in test_tg_ixload

Change-Id: Ieb58167d8b20e0de32578b3df105a141507869d5
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoNSB traffic_profile: fix pylint warnings and return partial 31/52131/3
Ross Brattain [Wed, 14 Feb 2018 05:11:11 +0000 (21:11 -0800)]
NSB traffic_profile: fix pylint warnings and return partial

also fix unittests

Change-Id: Ie3026f5a0df8e690271afb71fe36ac531cbae2a0
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoconstants: fix pylint warnings for OSError 39/52139/2
Ross Brattain [Wed, 14 Feb 2018 05:07:36 +0000 (21:07 -0800)]
constants: fix pylint warnings for OSError

IOError and OSError are the same in Python 3?
Anyway we want to ignore ENOENT, not EEXIST

JIRA: YARDSTICK-1012
Change-Id: Ia75e41fecce505685745e0099669e45f3e82a1be
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoMerge "Move tests: unit/benchmark"
Rodolfo Alonso Hernandez [Tue, 13 Feb 2018 11:02:45 +0000 (11:02 +0000)]
Merge "Move tests: unit/benchmark"

6 years agoBug fix for Ansible destroy VM script 89/52089/1
John O Loughlin [Mon, 12 Feb 2018 17:31:59 +0000 (17:31 +0000)]
Bug fix for Ansible destroy VM script

Modified the destroy script to ignore errors as 2 possible
problems can cause a play to fail.
1. A VM can be running but undefined.
2. A VM can be destroyed but still running.

JIRA: YARDSTICK-1006

Change-Id: Ib66f48401bfefb598f553cfef31bfa2682f5a584
Signed-off-by: John O Loughlin <john.oloughlin@intel.com>
6 years agoBump pip packages installed in "nsb_setup.sh" script 53/52053/1
Rodolfo Alonso Hernandez [Mon, 12 Feb 2018 17:30:20 +0000 (17:30 +0000)]
Bump pip packages installed in "nsb_setup.sh" script

Bump pip package versions installed in "nsb_setup.sh" script to match
"./requirements.txt" versions.

JIRA: YARDSTICK-1008

Change-Id: Icb0f7e99c1be38848ee7122735ace7c1c715ef5b
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoFix "./docker/Dockerfile.aarch64.patch" 51/52051/1
Rodolfo Alonso Hernandez [Mon, 12 Feb 2018 17:24:33 +0000 (17:24 +0000)]
Fix "./docker/Dockerfile.aarch64.patch"

Patch "./docker/Dockerfile.aarch64.patch" doesn't apply on
"./docker/Dockerfile" due to the latest modification done in the
original file

The original reference lines must be changed.

JIRA: YARDSTICK-1007

Change-Id: I5cfc349fbaf34e8da59608e5b803818e2cd9d295
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoMove tests: unit/benchmark 45/48245/15
Emma Foley [Wed, 29 Nov 2017 22:56:21 +0000 (22:56 +0000)]
Move tests: unit/benchmark

* Fix pylint errors
* Add TODOs

Some errors are ignored locally, as they were a symptom of other problems.
These issues have been flagged with a TODO, and should be fixed later.

Change-Id: I30eb4b0aafe0575d0cddbc946108291f21a98ed8
Jira: YARDSTICK-837
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoMerge "Create host VMs configuration"
Emma Foley [Mon, 12 Feb 2018 16:57:15 +0000 (16:57 +0000)]
Merge "Create host VMs configuration"

6 years agoMerge "Heatstack create: fix str/bytes error in NamedTemporaryFile.write()"
Emma Foley [Mon, 12 Feb 2018 14:06:58 +0000 (14:06 +0000)]
Merge "Heatstack create: fix str/bytes error in NamedTemporaryFile.write()"

6 years agoMerge "Replace neutron get network id with shade."
Emma Foley [Mon, 12 Feb 2018 13:51:39 +0000 (13:51 +0000)]
Merge "Replace neutron get network id with shade."

6 years agoRemove tool provisioning from DpdkVnfSetupEnvHelper._setup_dpdk 55/51855/3
Rodolfo Alonso Hernandez [Wed, 7 Feb 2018 16:20:56 +0000 (16:20 +0000)]
Remove tool provisioning from DpdkVnfSetupEnvHelper._setup_dpdk

Both "uio" and "igb_uio" drivers are present in the VM image generated
using "./nsb_setup.sh" script. "igb_uio" driver is compiled along with
the DPDK library compilation.

Tool "nsb_setup.sh" provisioning and execution should be removed from
this function because there is not needed anymore.

In case "igb_uio" driver is not loaded, an exception should be raised.

JIRA: YARDSTICK-999

Change-Id: I89174f84ac36d8231587402c96751746cb18e290
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoHeatstack create: fix str/bytes error in NamedTemporaryFile.write() 19/52019/2
Ross Brattain [Mon, 12 Feb 2018 03:24:16 +0000 (19:24 -0800)]
Heatstack create: fix str/bytes error in NamedTemporaryFile.write()

we need to use jsonutils.dump_as_bytes for NamedTemporaryFile.write()

2018-02-11 19:15:01,366 [INFO] yardstick.orchestrator.heat heat.py:563 Creating stack 'yardstick-4359f33e' START
2018-02-11 19:15:01,935 [ERROR] yardstick.benchmark.contexts.heat heat.py:317 stack failed
Traceback (most recent call last):
  File "/home/rbbratta/yardstick-upstream/yardstick/yardstick/benchmark/contexts/heat.py", line 313, in deploy
    timeout=self.heat_timeout)
  File "/home/rbbratta/yardstick-upstream/yardstick/yardstick/orchestrator/heat.py", line 567, in create
    stack.create(self._template, self.heat_parameters, block, timeout)
  File "/home/rbbratta/yardstick-upstream/yardstick/yardstick/orchestrator/heat.py", line 56, in create
    template_file.write(jsonutils.dumps(template))
  File "/home/rbbratta/yardstick_venv3/lib/python3.5/tempfile.py", line 622, in func_wrapper
    return func(*args, **kwargs)
TypeError: a bytes-like object is required, not 'str'

JIRA: YARDSTICK-1005
Change-Id: I504f23b86119b62f3aea5b83a445b97bf810220c
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoCreate host VMs configuration 37/50937/11
John O Loughlin [Mon, 22 Jan 2018 13:57:05 +0000 (13:57 +0000)]
Create host VMs configuration

Using xml files deploy the VM's using the virt plugin.
This code generates the user-data network-config meta-data
and the vm's xml. It also deploys the vm

JIRA: YARDSTICK-963

Change-Id: I97f2d20d0ab75a4444b8b8e6fb65e9e463870af7
Signed-off-by: John O Loughlin <john.oloughlin@intel.com>
6 years agoMerge "Create host networking configuration"
Emma Foley [Mon, 12 Feb 2018 10:12:49 +0000 (10:12 +0000)]
Merge "Create host networking configuration"

6 years agoMerge "vpe: convert DPKD_PORT to LINK ID"
Emma Foley [Mon, 12 Feb 2018 10:06:15 +0000 (10:06 +0000)]
Merge "vpe: convert DPKD_PORT to LINK ID"

6 years agoFixed document for Grafana Port usage 31/52031/1
Abhijit Sinha [Mon, 12 Feb 2018 09:54:41 +0000 (09:54 +0000)]
Fixed document for Grafana Port usage

JIRA: YARDSTICK-992

The Grafana port has been changed to 1948 from 3000, as the
port 3000 may be not free in some environments. The document
still says it uses port 3000, which leads to confusion.

Proposed Solution: The document needs to be updated with
correct Grafana port number "http://host_ip:1948"

Change-Id: I9078783849aec14602585f4d1b3bc293214ae737
Signed-off-by: Abhijit Sinha <abhijit.sinha@intel.com>
6 years agoCreate host networking configuration 27/50927/11
John O Loughlin [Mon, 22 Jan 2018 11:49:43 +0000 (11:49 +0000)]
Create host networking configuration

Create host networking configuration based on the input
configuration file. To define the networks using libvirt,
a temporary XML file is generated for each network.

JIRA: YARDSTICK-962

Change-Id: I24d1c4d2f2e62884675599deb7db255862283ea4
Signed-off-by: John O Loughlin <john.oloughlin@intel.com>
6 years agoProposing Abhijit Sinha as a committer in Yardstick 85/51285/3
Ross Brattain [Tue, 23 Jan 2018 17:31:51 +0000 (09:31 -0800)]
Proposing Abhijit Sinha as a committer in Yardstick

Abhijit Sinha has contributed to the Yardstick project in many ways
Achievements/Contributions include:
- PROX VNF and TG for NFVi characterization tests
- Attending Yardstick meetings
- PROX Grafanfa dashboards

Change-Id: I455ff22b8cb68c6422fc864659668412bed3e9c4
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoMerge "cleanup: rm node_ID from yardstick prepare_env file"
Ross Brattain [Mon, 12 Feb 2018 03:05:09 +0000 (03:05 +0000)]
Merge "cleanup: rm node_ID from yardstick prepare_env file"

6 years agoMerge "Remove references to "dpdk_nic_bind" utility"
Emma Foley [Sun, 11 Feb 2018 22:08:55 +0000 (22:08 +0000)]
Merge "Remove references to "dpdk_nic_bind" utility"

6 years agoMerge "BugFIX: NSB-setup build script fix for BM"
Emma Foley [Sun, 11 Feb 2018 22:02:27 +0000 (22:02 +0000)]
Merge "BugFIX: NSB-setup build script fix for BM"

6 years agoMerge "Replace "python-heatclient" with "shade" client"
Rodolfo Alonso Hernandez [Sun, 11 Feb 2018 20:37:22 +0000 (20:37 +0000)]
Merge "Replace "python-heatclient" with "shade" client"

6 years agoMerge "Prox vnf descriptor cleanup"
Rodolfo Alonso Hernandez [Fri, 9 Feb 2018 18:08:57 +0000 (18:08 +0000)]
Merge "Prox vnf descriptor cleanup"

6 years agoReplace neutron get network id with shade. 65/51765/10
Shobhi Jain [Mon, 29 Jan 2018 11:49:02 +0000 (11:49 +0000)]
Replace neutron get network id with shade.

Function get_network_id now uses shade client instead of shade client.
Removed redundant function: get_port_id.

JIRA: YARDSTICK-890

Change-Id: I6081477fee39fa78131187e65daf3d7d3a9e439f
Signed-off-by: Shobhi Jain <shobhi.jain@intel.com>
6 years agoMerge "Make 'Scenario' classes plugable"
Emma Foley [Fri, 9 Feb 2018 16:35:38 +0000 (16:35 +0000)]
Merge "Make 'Scenario' classes plugable"

6 years agoMerge "Change nsb_setup.sh to use NSB image instead of raw"
Emma Foley [Fri, 9 Feb 2018 16:18:34 +0000 (16:18 +0000)]
Merge "Change nsb_setup.sh to use NSB image instead of raw"

6 years agoMerge "Delete any previous configuration"
Emma Foley [Fri, 9 Feb 2018 15:49:01 +0000 (15:49 +0000)]
Merge "Delete any previous configuration"

6 years agoReplace "python-heatclient" with "shade" client 01/48401/11
Rodolfo Alonso Hernandez [Mon, 4 Dec 2017 16:24:13 +0000 (16:24 +0000)]
Replace "python-heatclient" with "shade" client

Replaced "python-heatclient" with "shade" client. The "python-heatclient"
library is removed from requirements file. "shade" client version 1.22.2
is the required one for OpenStack Pike release.

shade is the recommended client to interact with OpenStack clouds [1]

[1] https://github.com/openstack-infra/shade

JIRA: YARDSTICK-880

Change-Id: Ibbdfc42a543d2d9ed4cf70d78de3de8cbecd0076
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoDelete any previous configuration 19/50919/8
John O Loughlin [Mon, 22 Jan 2018 09:34:45 +0000 (09:34 +0000)]
Delete any previous configuration

Delete any previous configuration using the virsh module in ansible:
Networks, VMs and local IPs.

JIRA: YARDSTICK-950

Change-Id: Ie4963ab8210ce50ba2e9fa22642ec27a3b2031e1
Signed-off-by: John O Loughlin <john.oloughlin@intel.com>
6 years agoProx vnf descriptor cleanup 01/51901/1
Abhijit Sinha [Thu, 8 Feb 2018 16:05:54 +0000 (16:05 +0000)]
Prox vnf descriptor cleanup

JIRA: YARDSTICK-1003

- There are redundant files for Prox vnf descriptors
tg and vnf for 1, 2 and 4 port set-up.
- We can use one vnf descriptor file per prox tg and prox vnf,
reducing the number of redundant files.
- Tested on Prox BM L2fwd 2 and 4 port test case.

Change-Id: I4c61fd11725121f19392443460ac2ad39c934e2d
Signed-off-by: Abhijit Sinha <abhijit.sinha@intel.com>
6 years agoChange nsb_setup.sh to use NSB image instead of raw 95/51895/1
Mytnyk, Volodymyr [Thu, 8 Feb 2018 13:22:46 +0000 (13:22 +0000)]
Change nsb_setup.sh to use NSB image instead of raw

The `ansible/roles/create_samplevnfs_image/tasks/main.yml` ansible role
uses raw NSB image (yardstick-xenial-server.raw) to upload it to
OpenStack instead QCOW2 NSB converted image (yardstick-nsb-image.img
which is converted from the raw). Changed the create_samplevnfs_image
role to to use NSB image.

JIRA: YARDSTICK-1000

Change-Id: Ieda9f14e6882ca854331b4eccc9a4cb390b6a475
Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
6 years agoMerge "Improve ovs_deploy.bash script"
Ross Brattain [Wed, 7 Feb 2018 19:04:23 +0000 (19:04 +0000)]
Merge "Improve ovs_deploy.bash script"

6 years agoMerge "Auto Generated INFO.yaml file"
Ross Brattain [Wed, 7 Feb 2018 19:04:03 +0000 (19:04 +0000)]
Merge "Auto Generated INFO.yaml file"

6 years agoAdd a missing colon in the sample config 57/51857/1
Rodolfo Alonso Hernandez [Wed, 7 Feb 2018 17:27:03 +0000 (17:27 +0000)]
Add a missing colon in the sample config

Just in case anyone uses this file for testing.

Change-Id: Iff0489f839f3985e43ac31d2a89147e5f16c59e9
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agovpe: convert DPKD_PORT to LINK ID 29/43229/8
Ross Brattain [Tue, 26 Sep 2017 23:43:12 +0000 (16:43 -0700)]
vpe: convert DPKD_PORT to LINK ID

http://dpdk.org/doc/guides/sample_app_ug/ip_pipeline.html#application-resources-present-in-the-configuration-file

LINK instances are created implicitly based on the PORT_MASK application startup
argument. LINK0 is the first port enabled in the PORT_MASK, port 1 is the next one,
etc. The LINK ID is different than the DPDK PMD-level NIC port ID, which is the actual
 position in the bitmask mentioned above. For example, if bit 5 is the first bit set
in the bitmask, then LINK0 is having the PMD ID of 5. This mechanism creates a
contiguous LINK ID space and isolates the configuration file against changes in the
board PCIe slots where NICs are plugged in.

Change-Id: I6e449272cfcfb2b2a75c246f7f569e3f923da245
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agoMerge "Adding three missing test case descriptions"
Rodolfo Alonso Hernandez [Tue, 6 Feb 2018 15:11:36 +0000 (15:11 +0000)]
Merge "Adding three missing test case descriptions"

6 years agoAuto Generated INFO.yaml file 17/51717/4
agardner [Mon, 5 Feb 2018 19:39:20 +0000 (14:39 -0500)]
Auto Generated INFO.yaml file

INFO.yaml meant to be machine readable.
This file was auto generated from an ldap lookup
and your projects INFO file.

Meeting times are not currently filled out.
please ammend this patchset to complete

Going forward comitter promotions should be done
against this file.

PTLs:
Must be merged for you to gain delete access on
testresults.opnfv.org

If project_lead: is missing (my script could not parse)
please amend with same from commiters section eg:

project_lead: &opnfv_$project_ptl
    name: 'Lead Name'
    email: 'lead email'
    id: 'lead lfid'
    company: 'lead company'

Change-Id: I241279fba0d9acf69d38242a30541ddb90d22d67
Signed-off-by: agardner <agardner@linuxfoundation.org>
Signed-off-by: Ross Brattain <ross.b.brattain@intel.com>
6 years agocleanup: rm node_ID from yardstick prepare_env file 81/51681/1
ting wu [Mon, 5 Feb 2018 15:17:52 +0000 (16:17 +0100)]
cleanup: rm node_ID from yardstick prepare_env file

There is some redundant code in prepare_env.sh script
for the fuel installer, the changes are to:

1. Remove variabls 'node_ID' and 'node_line_num';
2. Rewrite section that replace ip address of controller/compute;
3  Add $YARDSTICK_REPO_DIR in front of variable 'pod_yaml';

JIRA: YARDSTICK-991

Change-Id: I4fbd2c2ba2e6109cc04dc452202fbed701d79b2b
Signed-off-by: ting wu <ting.wu@enea.com>
6 years agoRemove references to "dpdk_nic_bind" utility 61/51661/2
Rodolfo Alonso Hernandez [Mon, 5 Feb 2018 11:08:28 +0000 (11:08 +0000)]
Remove references to "dpdk_nic_bind" utility

In DPDK 16.07 [1], "dpdk_nic_bind" utility was renamed to "dpdk-devbind".
This patch removes all references to this previous naming to avoid
confusions.

[1] https://dpdk-guide.gitlab.io/dpdk-guide/setup/binding.html

JIRA: YARDSTICK-995

Change-Id: I827c4c11c9e9e519f33f21b80459e7d65e51545e
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoBugFIX: NSB-setup build script fix for BM 57/51657/1
Abhijit Sinha [Mon, 5 Feb 2018 09:45:03 +0000 (09:45 +0000)]
BugFIX: NSB-setup build script fix for BM

JIRA: YARDSTICK-994

The NSB set-up script for baremetal is broken.
In nsb_setp.yml file, "Prepare baremetal machine"
is commented due to which the ubuntu_server_baremetal_deploy_samplevnfs.yml
file is never called.

Change-Id: Icc95018ba746d6efa5baf09322b3255806da8952
Signed-off-by: Abhijit Sinha <abhijit.sinha@intel.com>
6 years agoMerge "Fix i40vf driver download URL"
Emma Foley [Sat, 3 Feb 2018 16:15:17 +0000 (16:15 +0000)]
Merge "Fix i40vf driver download URL"

6 years agoFix i40vf driver download URL 03/51503/1
Rodolfo Alonso Hernandez [Fri, 2 Feb 2018 17:21:46 +0000 (17:21 +0000)]
Fix i40vf driver download URL

Fix the download URL of i40vf driver introduced in
15e122a770d6349c84801dd05891e21661cbad2c.

In order to avoid the redirection, the URL should be:
  https://netix.dl.sourceforge.net/project/e1000/
  i40evf%20stable/{{ i40evf_version }}/{{ i40evf_gzfile }}

JIRA: YARDSTICK-993

Change-Id: Ie19d11d36417914e823b81867046123204111d76
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoRemoved zero from tc number 93/51493/1
Mika Rautakumpu [Fri, 2 Feb 2018 08:00:15 +0000 (10:00 +0200)]
Removed zero from tc number

Originally tc number was TC0042, after fix TC042.

Change-Id: I3c36e39a141ec8eb74f9f00d7218bd511a56fbc9
Signed-off-by: Mika Rautakumpu <mika.rautakumpu@nokia.com>
6 years agoMerge "Adding new vFirewall Test cases based on Concurrency, Connections per second...
Ross Brattain [Thu, 1 Feb 2018 19:25:11 +0000 (19:25 +0000)]
Merge "Adding new vFirewall Test cases based on Concurrency, Connections per second, Throughput and Transactions per second for various http locator image sizes including 1b, 4k, 64k, 256k, 1024k"

6 years agoMerge "Add "img_property" when building Yardstick image"
Ross Brattain [Thu, 1 Feb 2018 19:24:34 +0000 (19:24 +0000)]
Merge "Add "img_property" when building Yardstick image"

6 years agoAdding three missing test case descriptions 51/51451/4
Mika Rautakumpu [Thu, 1 Feb 2018 12:08:17 +0000 (14:08 +0200)]
Adding three missing test case descriptions

HA tests TC056, TC057 and TC058 are missing from Yardstick
test case list. Missing white space added to tc056.rst.

Change-Id: Id56a22ad96af8c3d05d95fb58259e9683ce9fab0
Signed-off-by: Mika Rautakumpu <mika.rautakumpu@nokia.com>
6 years agoMerge "Modify fuel_baremetal pod config file"
Ross Brattain [Wed, 31 Jan 2018 22:00:40 +0000 (22:00 +0000)]
Merge "Modify fuel_baremetal pod config file"

6 years agoAdd sample OpenStack/SRIOV RFC2544 based TC 13/51113/5
Mytnyk, Volodymyr [Thu, 25 Jan 2018 09:41:11 +0000 (09:41 +0000)]
Add sample OpenStack/SRIOV RFC2544 based TC

Add sample OpenStack/SRIOV RFC2544 based test case which can be
run using external Trex.

Console log: http://paste.openstack.org/show/658002/
Result output: http://paste.openstack.org/show/658004/

JIRA: YARDSTICK-967

Change-Id: Id0e2d6d47f459c7e6a3370735bab74f7ce502b24
Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
6 years agoMake 'Scenario' classes plugable 05/51005/4
Rodolfo Alonso Hernandez [Tue, 23 Jan 2018 16:23:57 +0000 (16:23 +0000)]
Make 'Scenario' classes plugable

This patch makes yardstick.benchmark.scenario.base:Scenario classes
plugable.

A new entry point is added to the setup. This entry point could be
extended in other plugin projects to add new Scenario classes.

E.g.: take a look at [1]. This is a Yardstick plugin example project.
Clone the project and execute, from the project directory:

  $ sudo -EH python setup.py install

This will add a new module to python ('yardstick-new-plugin') and a
new Scenario class.

Now list the scenarios in Yardstick:

  $ yardstick scenario list
    ...
    | SpecCPU2006_for_VM    | Spec CPU2006 benchmark for Virtual Machine |
    | SpecCPU2006           | Spec CPU2006 benchmark                     |
    | Dummy2                | Execute Dummy (v2!) echo                   |
    +-----------------------+--------------------------------------------+

[1] https://github.com/ralonsoh/yardstick_new_plugin

JIRA: YARDSTICK-910

Change-Id: Ib70ee9bf4dc7ff91d1dd6377317b313288e36bff
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoMerge "Add Intel Fortville 40G VF driver to sample VNF image"
Rodolfo Alonso Hernandez [Mon, 29 Jan 2018 23:26:52 +0000 (23:26 +0000)]
Merge "Add Intel Fortville 40G VF driver to sample VNF image"

6 years agoMerge "Change CivetWeb download URL"
Ross Brattain [Mon, 29 Jan 2018 19:31:39 +0000 (19:31 +0000)]
Merge "Change CivetWeb download URL"

6 years agoMerge "Fix up tests for Parser scenario"
Ross Brattain [Mon, 29 Jan 2018 19:31:22 +0000 (19:31 +0000)]
Merge "Fix up tests for Parser scenario"

6 years agoMerge "Move tests: unit/cmd/"
Ross Brattain [Mon, 29 Jan 2018 19:30:22 +0000 (19:30 +0000)]
Merge "Move tests: unit/cmd/"

6 years agoAdd Intel Fortville 40G VF driver to sample VNF image 11/51111/6
Mytnyk, Volodymyr [Thu, 25 Jan 2018 09:19:18 +0000 (09:19 +0000)]
Add Intel Fortville 40G VF driver to sample VNF image

1) Add common YAML config file to add kernel drivers to sample VNF image.
2) Add Intel Fortville 40G VF driverto sample VNF image using
   common YAML config file for drivers.
3) Configure i40evf driver to load on boot

JIRA: YARDSTICK-968

Change-Id: I223c8a10d77352baf4f41a481f465970655ba251
Signed-off-by: Mytnyk, Volodymyr <volodymyrx.mytnyk@intel.com>
6 years agoMerge "Adding support to pull docker images behind proxy"
Emma Foley [Mon, 29 Jan 2018 09:48:44 +0000 (09:48 +0000)]
Merge "Adding support to pull docker images behind proxy"

6 years agoImprove ovs_deploy.bash script 77/50377/9
Rodolfo Alonso Hernandez [Wed, 10 Jan 2018 18:59:41 +0000 (18:59 +0000)]
Improve ovs_deploy.bash script

Improved ovs_deploy.bash script [1]:
- Check if there is an error during the execution.
- Removed "prerequisites" function because is not called.
- Modified DPDK package installation: execute "make config" and then "make"
- Added comments.

[1]https://github.com/opnfv/yardstick/blob/master/yardstick/resources/scripts/install/ovs_deploy.bash

JIRA: YARDSTICK-916

Change-Id: I3029f983dde72aa46f6fdd61dd64d086ab3c2af6
Signed-off-by: Rodolfo Alonso Hernandez <rodolfo.alonso.hernandez@intel.com>
6 years agoFix up tests for Parser scenario 59/47759/5
Emma Foley [Fri, 24 Nov 2017 09:46:37 +0000 (09:46 +0000)]
Fix up tests for Parser scenario

* Check the results at the test methods
* Remove print statement from Parser scenario
* Replace assertEquals(x, True) with assertTrue(x)

Change-Id: I5c2612692e625fc888c7ce7637b9e1625440724a
Signed-off-by: Emma Foley <emma.l.foley@intel.com>
6 years agoAdding support to pull docker images behind proxy 71/51171/2
Deepak S [Fri, 26 Jan 2018 07:37:44 +0000 (13:07 +0530)]
Adding support to pull docker images behind proxy

This patch creates a http_proxy.conf in docker service,
to enable docker commands behind the proxy

Change-Id: Iac38a086026c11e89e534728467dc7da0e01ba59
Signed-off-by: Deepak S <deepak.s@linux.intel.com>
6 years agoMerge "Add python-openstackclient in docker image"
Ross Brattain [Fri, 26 Jan 2018 21:13:16 +0000 (21:13 +0000)]
Merge "Add python-openstackclient in docker image"

6 years agoMerge "Replace assertEqual(x, True|False) with assert[True|False](x)"
Ross Brattain [Fri, 26 Jan 2018 21:12:53 +0000 (21:12 +0000)]
Merge "Replace assertEqual(x, True|False) with assert[True|False](x)"

6 years agoMerge changes from topic 'bug/yardstick-864'
Ross Brattain [Fri, 26 Jan 2018 21:12:01 +0000 (21:12 +0000)]
Merge changes from topic 'bug/yardstick-864'

* changes:
  Replace assertEquals with assertEqual
  Make files pep8 compliant before using assertTrue|False

6 years agoMerge "Remove generated file in 'test_build_vm_xml'"
Rodolfo Alonso Hernandez [Fri, 26 Jan 2018 10:54:55 +0000 (10:54 +0000)]
Merge "Remove generated file in 'test_build_vm_xml'"

6 years agoModify fuel_baremetal pod config file 99/50699/3
ting wu [Tue, 16 Jan 2018 12:27:28 +0000 (13:27 +0100)]
Modify fuel_baremetal pod config file

The current HA testcases failed on fuel baremetal installer
with reason "SSHTimeout". This is due to incorrect ssh login
info in the pod config file. The change is to by running
'prepare_env.sh' script to

- read env vars 'USER_NAME' and 'SSH_KEY'
- replace the 'node_username' to env var 'USER_NAME'
- replace the "node_keyfile" to env var 'SSH_KEY'

JIRA: ARMBAND-317

Change-Id: I0239892f447ae99ab4025eedcd133e1b6f04e5a5
Signed-off-by: ting wu <ting.wu@enea.com>