Commit Graph

44 Commits

Author SHA1 Message Date
Sanjay Chari 8e873e678a Start and stop collectd containers while running workloads
This patch introduces the following changes.
1. Playbooks have been created to start collectd on different hosts.
2. A feature has been added that allows a user to start collectd containers
before running workloads, and stop the collectd containers after running
the workloads. This will help us in minimising the space used for storing
collectd data.

Change-Id: I7926884f461e97bc67453f46eef0121c46c7f19e
2021-11-22 13:14:55 +05:30
Zuul 266e709014 Merge "cheange log level from error to info" 2020-04-06 12:58:52 +00:00
Masco Kaliyamoorthy b09f896af8 cheange log level from error to info
Change-Id: I58e2fc64b7bcd83fc1716cfaff320d3b53bfaf4a
2020-04-06 17:59:05 +05:30
Sai Sindhur Malleni fbf309baee Add common logging with filebeat
This commit
1. Provides a playbook to install the filebeat agent on all
   undercloud/overcloud nodes
2. Provides another playbook that adds the browbeat uuid to the
   filebeat config file and starts filebeat during browbeat run
3. Corresponding changes in browbeat.py and browbeat/tools.py
   to run the playbook to insert custom browbeat uuid in the
   filebeat configuration.

Change-Id: Idd2efaf931f4ff581db715a04adef738f81d281c
2020-04-03 19:27:24 +00:00
Charles Short 0fa8454fd1 Remove PerfkitBenchMaker
No longer supported.

Change-Id: Iae8ff4e0a1f55af67b49df16e8ecf276877f2525
Signed-off-by: Charles Short <chucks@redhat.com>
2019-11-20 14:54:43 -05:00
Charles Short 318e0f5c73 Refactor workloads
Move the perkit, rally and shaker workloads to their own submodule
in the browbeat namespace. So we dont pollute the browswer namespace
and make the code a bit more orgranized.

Change-Id: Ib833e86e71e595d336c27b08774f164e8f8c49bd
Signed-off-by: Charles Short <chucks@redhat.com>
2019-03-18 11:08:05 -04:00
Sai Sindhur Malleni 86bfc78e25 BuhBye YODA
YODA is no longer a used or maintainer workload. This will help remove
any confusion.

Change-Id: Ifef26f1419be9429bd9ac72a1d25f90ad8241bfc
2019-03-08 15:21:53 -05:00
Sorin Sbarnea 90d9c1bc41 Include flake8 execution in tox -e linters
This fixes several flake8 failures and integrates flake8 into linters
tox environment.

Rule W504 is disabled because at this moment there is no known way
to avoid flapping between W504 and W503.

This allows us to retire openstack-tox-pep8 job because the more
beneric openstack-tox-linters includes it. Still, developers will
be able to coveniently run only pep8 if they want.

Change-Id: I7da0f6f09a533dd1c4dc303029e8c587bc200f66
2018-10-24 19:52:45 +01:00
Zuul 005ee423ab Merge "Adding elastic methods to query results" 2018-07-19 14:53:49 +00:00
Joe Talerico 55d4aa5a9f Adding elastic methods to query results
Right now we depend on Kibana to do our comparisons. This will give the
user a CLI mechansim to compare two different browbeat runs.

+ Small fix to browbeat metadata comparsion to not query _all

+ Changing how the metadata comparsion is displayed

Change-Id: I3881486100c91dcf3cc4eeeb4ddfa532ff01a7f1
2018-07-19 09:56:50 -04:00
Sai Sindhur Malleni 0966eb930c Add mechanism to gracefully exit on SIGINT
This commit adds functionality for a user to exit out of a long running
browbeat configuration by using SIGINT. On catchinga  SIGINT, browbeat
compeltes the current workload and then exits.

To keep the code lightweight, browbeat termination on SIGINT happens
only at a workload level. The current running workload (in case of
rally, the scenarios and concurrencies associated with the workload) is
finished.

Change-Id: Iaa1f10233dabd053293327f42f8bd1320f1af95d
2018-07-13 07:08:14 -06:00
Sai Sindhur Malleni 665d0ef715 Some fixes to make log info consistent with change
After code was added to mix-match workload, the stats of executed,
passed and failed tests kept by each workload class have become
inconsistent. It makes sense to only maintain a count at the total
number of tests executed/passed/failed vs per  workload.

Change-Id: I4f84f4580ac29206e7ce660222a2a396e419cac8
2018-01-10 20:35:19 -05:00
akrzos 1c3b60a8c8 Mix and Match Workloads
* Mix and Match Workloads
* rerun_type - ['iteration', 'complete'] - allows you to rerun complete
  browbeat workload or iteratively
* browbeat/config.py for loading and validating config schema
* tests/test_config.py to test config.py

Change-Id: I99ea87c01c17d5d06cf7f8d1eec3299aa8d483a5
2017-12-12 11:08:50 -05:00
akrzos aa1b7651d3 Auto venv via path module
* Add path module to handle paths
  * Finds the venv
  * Finds the overcloudrc
* Clean-up/refactor imports

Change-Id: I24c269f2073a28ae0bee230cb9911dc89249f79f
2017-10-06 11:29:11 -04:00
akrzos 2f0096fde5 Initial refactor
Refactor module names
Logger match module names
Add abstract method for run_workloads to WorkloadBase

Change-Id: I20b22787046bab98efb0a099bd32a08df8918628
2017-09-14 13:11:50 -06:00
Joe Talerico 177461357d Add additional output to Metadata Comparison
This change gives the user more output to determine what the
differences between Browbeat-uuids are.

+ browbeat version information
+ newlines to help the cluttered output

Change-Id: I3dfe3f89c07c615addbacd035c512da952faf624
Closes-bug: 1702546
2017-07-06 09:46:33 -04:00
Joe Talerico 21900bffad Query Elastic to compare software-metadata
Method to query ElasticSearch for a specific set of browbeat_uuids and
compare the metadata to determine if there are differences.

This work will also tell the user if a option or value is missing.

Eventually, I would like to see us query Elastic for collectd data to
see if there has been CPU/Memory/DiskIO increases during a specific
Browbeat run -- this is a longer-term goal.

Example of this :
https://gist.github.com/jtaleric/ffc1508eba3cba9515ca24cfcf23583c

Change-Id: Ie65e2c3d505aa2f19ba10109276ba982ee4ab67b
2017-06-22 10:13:15 -04:00
jkilpatr b21cd3cebc Add YODA for undercloud and overcloud workloads
Yoda is a Browbeat workload for Ironic and TripleO

It can perform and monitor the following

 * Introspection bulk or batch
 * Cloud deployment with varying node types and numbers
 * Baremetal node import timing (actually done during introspection tests)

Metrics that are gathered inclue

 * Time to pxe
 * Time till pingable
 * Success/Failure rate ahd times
 * Overcloud Metadata after each deploy

Potential issues

Change-Id: I89809cc35db2cfaa39f8ede49ec853572c0e468e
2017-06-15 15:25:31 +00:00
jkilpatr c443ba7f38 Exit with nonzero return code if Elastic indexing fails
At the end of a Browbeat run loop through all the tests and their results
to check if any failed to index, if so set the return code to 1.

This way tests will complete even if indexing fails but scripts and other
software checking the return code will fail out properly instead of allowing
data to be lost silently.

Change-Id: If1a7b2b41df35abbb8a6cc63d6003c1ae36664dd
2017-03-29 15:51:26 -04:00
jkilpatr c0715bff39 Basic test based return codes for Browbeat
This adds a very simple check for failed tests before Browbeat's exit
if failed tests are found Browbeat will exit with a return code of one.
This will provide Browbeat CI failure when tests fail without interuppting
ongoing tests if a single one fails.

Change-Id: I5382f684fe03d85692a275dc5c03a136004f34d9
2017-02-15 10:08:05 -05:00
Joe Talerico 423da4ff52 Postprocess after a workload has executed
This work is to take an results directory and find all the
rally/Shaker/Perfkit JSONs and create the Elasticsearch JSONs that can be
pushed to Elasticsearch.

This is also a minor refactor of the Rally lib to refactor how we push
results into elasticsearch. This creates a generic function so we can
have file and/or taskid based metrics created

+ (sai) Fix way how we crawl for files
+ (sai) Exclude already postprocessed files
+ (sai) Fix filenaming of dumped postprocessed files
+ {sai) flake8

Co-Authored-By: Sai Sindhur Malleni <smalleni@redhat.com>
Change-Id: I5ca8877f26e889856c9773b51ba38f24562a80af
2017-02-13 14:02:08 +00:00
jkilpatr 33f30eb58a Revert making log and results directory
Reverting Commit: 2ba6da9022

This needed much more testing before merging, my bad.
I strongly suggest we don't add this functionality
in a seperate commit again, it doesn't make sense
to reorg and test all of this and then the pip commit
right after. Just add it's functionality there.

Change-Id: Iee7aa439fbc077c3c71f67b625b67fc55a86f199
2017-01-26 09:48:10 -05:00
jkilpatr adb155c5c3 Fix Python Linting Errors
Some idiot merged a commit with linting errors last night, this should
fix them.

Change-Id: Iab7e4a2a2d5311eba9a7ebbbd4a5f60ab8bf59fd
2017-01-25 08:18:09 -05:00
Chandan Kumar 2ba6da9022 Make results and log directory path using browbeat-config
* if results and log path not found, create it.
* Also resolve $FOO in browbeat config paths -jkilpatr

Change-Id: Ie5ec32386ca0d6db9177d9a3a55387b5b1e88a69
2017-01-24 17:18:18 +00:00
Joe Talerico c9b8d88697 Metadata and restructure
Moving some methods into Tools to cleanup browbeat.py

+ Adding Ansible task to test regather

Change-Id: I4a562ae77a90528df2e7f8779895b1627c9dff11
2017-01-12 13:24:32 -05:00
Sai Sindhur Malleni 2357ad4743 Gather Metadata in main browbeat run
This commit adds logic to run Metadata at the beginning of every browbeat
run through browbeat.py. Also some imports have been fixed.

Co-Authored-By: Joe Talerico <jtaleric@redhat.com>

Change-Id: Ibc13a64710209b25a755f606ea7fddc80232cbc4
2016-09-21 10:41:38 -04:00
Sai Sindhur Malleni 6c1215960d Handle case when metadata files are configured but not present and also
case where metadata file list is empty

This commit specifically fixes the code to handle the case where metadata files
are configured in the browbeat configuration file but are not present in the
metadata directory. Previoulsy since the combine_metadata method return boolean
value false in such cases and the index_result method treated result as a
dcitionary, traceback was seen. With this commit, combine_metadata stops
returning false and instead exits the run if an intended metadata file is
absent.

+ Changing how we return result so that the code doesn't err out even when
  metadata file list is empty in the confing file
+ Checking in browbeat.py too
Change-Id: I52712beaa2dec6209394a2f3ef605d5a9a13f5cb
2016-09-20 13:39:58 -04:00
Sai Sindhur Malleni 17eaf5d3d0 Set Logger to UTC
With directory names, graphs and everything else in UTC, it becomes hard to
correlate things if the logger is not in UTC.

Change-Id: I8d1f88103d6eb413b11046cf997e146ae9820731
2016-08-26 21:45:51 +00:00
Nguyen Hung Phuong 35d648c9cf Clean imports in code
In some part in the code we import objects.
In the Openstack style guidelines they recommend to import only
modules.

http://docs.openstack.org/developer/hacking/#imports

Change-Id: Icae231f06f3c4fd15256f06a464d3ba3e2845e33
2016-08-25 10:30:13 +07:00
Sai Sindhur Malleni 4b1565764f Fixing timezone to UTC
Currently we use UTC in some places and local time in some. Changing everything
to UTC to avoid confusion.

Change-Id: I19bab4e41870bbb2fcb68f1dc6c6b9069271c9f9
2016-08-10 17:46:05 -04:00
Alex Krzos 735138f6af Index each document with a run UUID.
Creates a UUID at the start of browbeat, logs it at (start/end) and
addes it to each document with index.  This should make it easier to
remove large runs if they are invalid or display only a single run
from the ELK/EFK stack.

Change-Id: I8bbc1cda522d609cf27bbe88dce1d74a96afaa93
2016-06-20 09:38:49 -04:00
Sindhur 3980cf5e86 Making browbeat.py executable
Setting browbeat.py permissions to 0775

Change-Id: Iff2966c16d67f73adcf70034b0b47db3ad8ba1b6
2016-06-14 13:14:14 -04:00
Sindhur 06e3e3292b Adding Browbeat Infra files
Adding .gitreview file
Adding tox.ini
Adding setup.py
Adding test-requirments.txt
Fixing syntax

Change-Id: Id6d628708079440207e5f068f5f0827802f2aa14
2016-06-14 09:16:53 -04:00
Sindhur Malleni f174b67e2b Adding a Base Workload Class
Having the workload classes inherit from the abstract base class will
enforce certain methods and help the summarized output
+ Moving logger here
+ Implementing functionality to report max test time
+ Browbeat report in yaml format
+ Renaming workload base method
+ Removing an unnecessary method
+ Formatting methods in WorkloadBase
+ autopep8

Change-Id: I090a863b4b00068a48cf5d914c337e15fd5739f5
2016-04-15 16:07:19 -04:00
Sindhur Malleni d7bde02b0d Adding functionality to check validity of configuration file
Change-Id: Icaf5fecb6e77351c23273e6c888924de1a55d596
2016-04-11 12:12:03 -04:00
Alex Krzos cc5fee596b Remove ansible api due to 1.9.4 confusion and bugs.
+ Adjusted workloads to positional args and is flexiable to take:
  - ./browbeat.py                      ---> Runs all worklaods in order: perfkit rally shaker
  - ./browbeat.py all                  ---> Runs all workloads in order: perfkit rally shaker
  - ./browbeat.py perfkit rally        ---> Runs workloads in order: perfkit rally
  - ./browbeat.py shaker rally perfkit ---> Runs workloads in order: shaker rally perfkit
+ --debug now displays debug messages in stdout in addition to previous locations it logged
+ --setup or -s to take a config, Defaults to browbeat-config.yaml (Same as before), Examples:
  - ./browbeat.py -s browbeat-complete.yaml rally
  - ./browbeat.py -s conf/browbeat-keystone-complete.yaml --debug
+ Use __init__.py to allow cleaner importing of files under lib/
+ Remove ansible version restriction in requirements.txt
+ Separate connmon config from browbeat config for clarity.

Change-Id: Ifb74e5868be128fb378c7b052ba5a1bea46b4dff
2016-03-30 15:00:15 -04:00
Alex Krzos 33f7395c91 Moving Rally to list format for ordered benchmarks/scenarios.
+ Adding plugin to browbeat-config.yaml
+ Address -s config (setting default so error logging is correct)

Change-Id: I5531a5b18a87cfe1a701ba8f467909c862b099e4
2016-03-21 21:38:29 -04:00
Alex Krzos c7a8420bf1 Adding PerfKitBenchmarker to Browbeat.
+ Adding more benchmarks + Grafana snapshots
+ Benchmarks in list for ordering now.
+ Adding connmon

Change-Id: I9fa4f5d31f9575ad7636218ae6091c8e11343410
2016-03-08 15:31:55 -05:00
Sindhur 145dc88317 Improve argument parsing for browbeat.py
Can now specify the workload the user wants to run or simply run all
Added enable option for rally workloads as well

+ (akrzos) Handle empty list as 'all' workloads.
+ (akrzos) Few tweaks to logging

Change-Id: Ie5ae8444408f79d106eabfbf0ad33fdf7819d8f4
Signed-off-by: Sindhur <smalleni@redhat.com>
2016-03-01 20:32:03 -05:00
Alex Krzos 270506a87a Converging browbeat and shaker installers. Adding shaker network for automatic network configuration.
+ Updated Documentation.

Change-Id: Ic119675777d45787266946f08367e761bd55f284
2016-03-01 10:29:01 -05:00
Sindhur aeed9d3105 Integrated Data Plane testing with Shaker
Modified Install Playbook and added playbook for building image
+ flavor and port can now be modified
+ error checking and logging
+ Result Tracking
+ venv is configurable
+ null in config file to deploy all agents at once
+ removing udp in scenarios as known to cause scale problems
+ (akrzos) streamlining shaker install
+ (akrzos) small changes to build_image.yml
+ (akrzos) Small config changes

Change-Id: I2d5c4a1503d5181d5c28597a2b764ce4b775d7b3
Signed-off-by: Sindhur <smalleni@redhat.com>
2016-02-25 22:26:39 -05:00
Joe Talerico 4f662d08f4 Remove pbench from code
We have a solution that works better internally and externally. Pbench
had a set of challanges.

(akrzos) Moved pbench ansible install playbook into pbench folder
(akrzos) cleaned up other garbage
(akrzos) Fix merge conflict

Change-Id: Ie0a59d799846c3c9f5970c1a3b83ae50ebced0b8
2016-02-12 13:31:49 -05:00
Joe Talerico 73957eadc4 Add log files
Store a debug log in ./log/ to help the user determine any possible
issues that might popup. The stdout (info) might not provide enough
information

+Added Logic for Rally

Change-Id: I9ca1f42c061ae912fde9af414ada0d328615f458
2016-02-08 20:01:25 -05:00
Joe Talerico 8a542ef8ec Migrate browbeat.sh to Python
Learning the Ansible API for this migration. Very simple script
that will use the browbeat checks

+ Added Pbench start/stop 01/11/16
+ Moved ansible to config 01/11/16
+ Adding ansible hosts option 01/11/16
+ Connmon added (start/stop) still nothing with results 01/12/16
+ New Rally YAML format... (nova example) 01/12/16
+ Create results directory 01/12/16
+ Created lib with classes 01/13/16
+ Updated Scenarios 01/14/16
+ Updated other workloads to new format 01/15/16
+ Switched to dict get method 01/15/16
+ Removed pyc files and updated 01/15/16
+ updated genhost file 01/15/16
+ Update Ansible for connmon finished pbench work 01/15/16
+ Catch if user tries to run without Ansible or Ansible2 01/26/16
+ Minor changes 01/26/16
+ Bug fix... 01/27/16
+ (akrzos) added keystone yamls and browbeat-complete.yaml
+ Moved BrowbeatRally to Rally and broke connmon out of Tools
+ (akrzos) Implemented per Rally test scenario task args.
+ Updated Docs, removed old browbeat.sh
+ (akrzos) Cleaned up lib/Rally.py and added cinder scenarios to browbeat configs.
+ Fix Connmon install issue
+ (akrzos) Added parameters to neutron task yamls
+ (akrzos) Changed connmon to stop logging immediately after rally task completes.
Change-Id: I338c3463e25f38c2ec7667c7dfc8b5424acba8c2
2016-01-29 21:24:34 +01:00