Upgrade Rally to 0.9.1

Migrated plugins and cleaned up config files and improved ease of
running some scenarios/plugins.

Change-Id: If76ce233f3067b85aa086be7f615dbb900a1bcb9
This commit is contained in:
akrzos 2017-07-19 08:56:27 -04:00 committed by Alex Krzos
parent 4052a93f50
commit e585fb3df4
53 changed files with 657 additions and 595 deletions

View File

@ -31,7 +31,7 @@ browbeat_venv: "{{browbeat_path}}/.browbeat-venv"
rally_venv: "{{browbeat_path}}/.rally-venv"
# Rally version to install
rally_version: 0.8.1
rally_version: 0.9.1
# The default Shaker venv
shaker_venv: "{{browbeat_path}}/.shaker-venv"

View File

@ -1,5 +1,5 @@
browbeat:
results : results/
results: results/
rerun: 3
cloud_name: {{ browbeat_cloud_name }}
elasticsearch:
@ -38,8 +38,6 @@ rally:
venv: /home/stack/rally-venv
plugins:
- netcreate-boot: rally/rally-plugins/netcreate-boot
- netcreate-boot-ping: rally/rally-plugins/netcreate-boot-ping
- subnet-router-create: rally/rally-plugins/subnet-router-create
benchmarks:
- name: authenticate
enabled: true
@ -119,13 +117,15 @@ rally:
scenarios:
- name: netcreate-1-boot
enabled: true
enable_dhcp: true
image_name: cirros
flavor_name: m1.tiny
file: rally/rally-plugins/netcreate-boot/netcreate_boot.yml
num_networks: 1
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot.yml
- name: netcreate-5-boot
enabled: true
enable_dhcp: true
image_name: cirros
flavor_name: m1.tiny
file: rally/rally-plugins/netcreate-boot/netcreate_boot.yml
num_networks: 5
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot.yml

View File

@ -1,7 +1,7 @@
# Tests to be completed for the install-and-check.sh script minimal and short workloads are performed
# to confirm functionality.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: {{ browbeat_cloud_name }}
elasticsearch:
@ -40,59 +40,47 @@ rally:
venv: /home/stack/rally-venv
plugins:
- netcreate-boot: rally/rally-plugins/netcreate-boot
- netcreate-boot-ping: rally/rally-plugins/netcreate-boot-ping
- subnet-router-create: rally/rally-plugins/subnet-router-create
benchmarks:
- name: authenticate
enabled: true
concurrency:
- 2
- 1
times: 1
scenarios:
- name: authentic-keystone
enabled: true
file: rally/authenticate/keystone-cc.yml
sla_max_avg_duration: 6
sla_max_seconds: 30
sla_max_failure: 0
- name: cinder
enabled: true
concurrency:
- 2
- 1
times: 1
scenarios:
- name: create-attach-volume-centos
enabled: true
file: rally/cinder/cinder-create-and-attach-volume-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: keystonebasic
enabled: false
concurrency:
- 2
- 1
times: 1
scenarios:
- name: create-and-list-tenants
enabled: true
file: rally/keystonebasic/create_and_list_tenants-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
times: 50
- name: neutron
enabled: true
concurrency:
- 2
- 1
times: 1
scenarios:
- name: create-list-network
enabled: true
file: rally/neutron/neutron-create-list-network-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: nova
enabled: true
concurrency:
- 2
- 1
times: 1
scenarios:
- name: boot-snapshot-delete
@ -103,14 +91,13 @@ rally:
- name: plugins
enabled: true
concurrency:
- 2
- 1
times: 1
scenarios:
- name: netcreate-boot
- name: netcreate-1-boot
enabled: true
enable_dhcp: true
image_name: cirros
flavor_name: m1.tiny
file: rally/rally-plugins/netcreate-boot/netcreate_boot.yml
sla_max_avg_duration: 12
sla_max_seconds: 30
sla_max_failure: 0
num_networks: 1
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot.yml

View File

@ -1,7 +1,7 @@
# Tests to be compleated for the install-and-check.sh script minimal and short workloads are performed
# to confirm functionality.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: {{ browbeat_cloud_name }}
elasticsearch:

View File

@ -1,7 +1,7 @@
# Tests to be compleated for the install-and-check.sh script minimal and short workloads are performed
# to confirm functionality.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: {{ browbeat_cloud_name }}
elasticsearch:

View File

@ -1,6 +1,6 @@
# Complete set of Stress Tests, this can take a long time (day(s))
browbeat:
results : results/
results: results/
rerun: 3
cloud_name: openstack
elasticsearch:
@ -55,11 +55,10 @@ rally:
sleep_before: 5
sleep_after: 5
plugins:
- glance: rally/rally-plugins/glance
- neutron: rally/rally-plugins/neutron
- netcreate-boot: rally/rally-plugins/netcreate-boot
- netcreate-boot-ping: rally/rally-plugins/netcreate-boot-ping
- subnet-router-create: rally/rally-plugins/subnet-router-create
- glance-create-boot-delete: rally/rally-plugins/glance-create-boot-delete
- workloads: rally/rally-plugins/workloads
benchmarks:
- name: authenticate
enabled: true
@ -124,15 +123,9 @@ rally:
file: rally/keystonebasic/create_and_list_tenants-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
times: 5000
concurrency:
- 256
- name: create-and-list-users
enabled: true
file: rally/keystonebasic/create_and_list_users-cc.yml
times: 5000
concurrency:
- 256
sla_max_seconds: 30
sla_max_failure: 0
- name: neutron
@ -185,31 +178,26 @@ rally:
file: rally/nova/nova-boot-snapshot-cc.yml
image_name: cirros
flavor_name: m1.xtiny
net_id:
- name: boot-list-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-list-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-show-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-show-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-bounce-delete-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-bounce-delete-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-lock-unlock-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-lock-unlock-cc.yml
flavor_name: m1.xtiny
net_id:
- name: glance
enabled: true
concurrency:
@ -218,18 +206,18 @@ rally:
scenarios:
- name: create-image-boot-instances
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
instances: 2
flavor_name: m1.small
file: rally/glance/create-image-and-boot-instances-cc.yml
- name: create-and-delete-image
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
flavor_name: m1.small
file: rally/glance/create-and-delete-image-cc.yml
- name: create-and-list-image
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
file: rally/glance/create-and-list-image-cc.yml
- name: list-images
enabled: true
@ -245,21 +233,22 @@ rally:
scenarios:
- name: netcreate-boot
enabled: true
enable_dhcp: true
image_name: cirros
flavor_name: m1.tiny
file: rally/rally-plugins/netcreate-boot/netcreate_boot.yml
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot.yml
sla_max_avg_duration: 12
sla_max_seconds: 30
sla_max_failure: 0
- name: subnet-router-create
- name: router-subnet-create-delete
enabled: true
num_networks: 50
file: rally/rally-plugins/subnet-router-create/subnet-router-create.yml
file: rally/rally-plugins/neutron/router_subnet_create_delete.yml
- name: glance-create-boot-delete
enabled: true
flavor_name: m1.tiny
image_location: /home/stack/cirros
file: rally/rally-plugins/glance-create-boot-delete/glance_create_boot_delete.yml
image_location: /home/stack/cirros.qcow2
flavor_name: m1.xtiny
file: rally/rally-plugins/glance/glance_create_boot_delete.yml
#shaker scenarios require atleast 2 compute nodes
shaker:
enabled: true

View File

@ -1,13 +1,13 @@
# Basic set of initial stress tests to test overcloud before running complete set of benchmarks.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: true
regather: true
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json
@ -87,57 +87,43 @@ rally:
sleep_before: 5
sleep_after: 5
plugins:
- glance: rally/rally-plugins/glance
- neutron: rally/rally-plugins/neutron
- netcreate-boot: rally/rally-plugins/netcreate-boot
- netcreate-boot-ping: rally/rally-plugins/netcreate-boot-ping
- subnet-router-create: rally/rally-plugins/subnet-router-create
- glance-create-boot-delete: rally/rally-plugins/glance-create-boot-delete
- nova-create-pbench-uperf: rally/rally-plugins/nova-create-pbench-uperf
- neutron-securitygroup-port: rally/rally-plugins/neutron-securitygroup-port
- workloads: rally/rally-plugins/workloads
benchmarks:
- name: authenticate
enabled: true
concurrency:
- 64
times: 500
- 8
times: 100
scenarios:
- name: authentic-keystone
enabled: true
file: rally/authenticate/keystone-cc.yml
sla_max_avg_duration: 6
sla_max_seconds: 30
sla_max_failure: 0
- name: authentic-neutron
enabled: false
enabled: true
file: rally/authenticate/validate_neutron-cc.yml
sla_max_avg_duration: 18
sla_max_seconds: 30
sla_max_failure: 0
- name: authentic-nova
enabled: false
enabled: true
file: rally/authenticate/validate_nova-cc.yml
sla_max_avg_duration: 12
sla_max_seconds: 30
sla_max_failure: 0
- name: cinder
enabled: true
concurrency:
- 2
times: 6
times: 10
scenarios:
- name: create-attach-volume-centos
enabled: false
file: rally/cinder/cinder-create-and-attach-volume-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-attach-volume-cirros
enabled: true
image_name: cirros
file: rally/cinder/cinder-create-and-attach-volume-cc.yml
flavor_name: m1.tiny
file: rally/cinder/cinder-create-and-attach-volume-cc.yml
- name: keystonebasic
enabled: true
concurrency:
- 10
- 8
times: 100
scenarios:
- name: create-and-list-tenants
@ -146,36 +132,33 @@ rally:
- name: create-and-list-users
enabled: true
file: rally/keystonebasic/create_and_list_users-cc.yml
sla_max_avg_duration: 12
sla_max_seconds: 30
sla_max_failure: 0
- name: neutron
enabled: true
concurrency:
- 8
times: 100
- 2
times: 10
scenarios:
- name: create-list-network
enabled: true
file: rally/neutron/neutron-create-list-network-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-list-port
enabled: true
file: rally/neutron/neutron-create-list-port-cc.yml
- name: create-list-router
enabled: false
enabled: true
file: rally/neutron/neutron-create-list-router-cc.yml
- name: create-list-security-group
enabled: false
enabled: true
file: rally/neutron/neutron-create-list-security-group-cc.yml
- name: create-list-subnet
enabled: false
enabled: true
file: rally/neutron/neutron-create-list-subnet-cc.yml
- name: nova
enabled: true
concurrency:
- 8
- 2
times: 10
scenarios:
- name: boot-snapshot-delete-cirros
@ -183,43 +166,41 @@ rally:
file: rally/nova/nova-boot-snapshot-cc.yml
image_name: cirros
flavor_name: m1.xtiny
net_id:
- name: boot-list-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-list-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-show-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-show-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-bounce-delete-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-boot-bounce-delete-cc.yml
flavor_name: m1.xtiny
net_id:
- name: boot-lock-unlock-cirros
enabled: true
image_name: cirros
file: rally/nova/nova-lock-unlock-cc.yml
flavor_name: m1.xtiny
net_id:
- name: glance
enabled: true
concurrency:
- 8
- 2
times: 10
scenarios:
- name: create-and-delete-image
enabled: true
image_location: /home/stack/cirros
flavor_name: m1.small
image_location: /home/stack/cirros.qcow2
container_format: bare
disk_format: qcow2
file: rally/glance/create-and-delete-image-cc.yml
- name: plugins
- name: simple-plugins
enabled: true
concurrency:
- 8
@ -230,43 +211,58 @@ rally:
enable_dhcp: true
image_name: cirros
flavor_name: m1.tiny
file: rally/rally-plugins/netcreate-boot/netcreate_boot.yml
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot.yml
- name: netcreate-boot-ping
enabled: true
image_name: cirros
flavor_name: m1.xtiny
net_id: 790354c7-f286-4fd1-a4a1-ec9749c61fbf
file: rally/rally-plugins/netcreate-boot-ping/netcreate_nova-boot-fip-ping.yml
- name: subnet-router-create
ext_net_id:
file: rally/rally-plugins/netcreate-boot/netcreate_nova_boot_fip_ping.yml
- name: router-subnet-create-delete
enabled: true
num_networks: 10
file: rally/rally-plugins/subnet-router-create/subnet-router-create.yml
num_networks: 5
file: rally/rally-plugins/neutron/router_subnet_create_delete.yml
- name: glance-create-boot-delete
enabled: true
image_location: /home/stack/cirros
flavor_name: m1.tiny
file: rally/rally-plugins/glance-create-boot-delete/glance_create_boot_delete.yml
image_location: /home/stack/cirros.qcow2
flavor_name: m1.xtiny
file: rally/rally-plugins/glance/glance_create_boot_delete.yml
- name: neutron-securitygroup-port
enabled: false
file: rally/rally-plugins/neutron-securitygroup-port/neutron-securitygroup-port.yml
- name: nova-create-pbench-uperf
enabled: true
hypervisor_server: "nova:overcloud-compute-1.localdomain"
hypervisor_client: "nova:overcloud-compute-0.localdomain"
image_name: pbench-image
file: rally/rally-plugins/neutron/securitygroup_port.yml
- name: plugin-workloads
enabled: true
concurrency:
- 1
times: 1
scenarios:
- name: linpack
enabled: true
image_name: browbeat-linpack
flavor_name: m1.small
cloudname: "my-cloudname"
elastic_host: "my-elastic-host.org"
elastic_port: 9200
user: "root"
password: "password"
external_network: "public"
protocols: "tcp"
external_network:
net_id:
file: rally/rally-plugins/workloads/linpack.yml
- name: browbeat-pbench-uperf
enabled: true
user: root
image_name: browbeat-uperf
flavor_name: m1.small
# hypervisor_server: "nova:overcloud-compute-1.localdomain"
# hypervisor_client: "nova:overcloud-compute-0.localdomain"
external_network:
net_id:
protocols: tcp,udp
instances: 1
num_pairs: 1
message_sizes: "64,1024,16384"
instances: "1,8,16,32,64"
test_types: "stream"
samples: 1
send_results: True
test_name: "browbeat-rally"
file: rally/rally-plugins/nova-create-pbench-uperf/nova-create-pbench-uperf.yml
test_types: stream,rr
message_sizes: 64,1024,16384
test_name: "browbeat-pbench-uperf"
send_results: true
cloudname:
elastic_host:
elastic_port: 9200
file: rally/rally-plugins/workloads/pbench-uperf.yml

View File

@ -1,6 +1,6 @@
# Complete set of Glance Benchmarks
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
@ -47,18 +47,18 @@ rally:
scenarios:
- name: create-image-boot-instances
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
instances: 2
flavor_name: m1.small
file: rally/glance/create-image-and-boot-instances-cc.yml
- name: create-and-delete-image
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
flavor_name: m1.small
file: rally/glance/create-and-delete-image-cc.yml
- name: create-and-list-image
enabled: true
image_location: /home/stack/cirros
image_location: /home/stack/cirros.qcow2
file: rally/glance/create-and-list-image-cc.yml
- name: list-images
enabled: true

View File

@ -1,7 +1,7 @@
# Complete set of Keystone Stress tests run 3 times over multiple concurrencies with high repetitions(times)
# This testing will take days to complete. (You have been warned)
browbeat:
results : results/
results: results/
rerun: 3
cloud_name: openstack
elasticsearch:
@ -9,7 +9,6 @@ elasticsearch:
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json
@ -203,3 +202,13 @@ rally:
file: rally/keystonebasic/create_and_get_role-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-add-list-roles
enabled: true
file: rally/keystonebasic/create_add_list_roles-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-and-update-user
enabled: true
file: rally/keystonebasic/create_and_update_user-cc.yml
sla_max_seconds: 30
sla_max_failure: 0

View File

@ -1,7 +1,7 @@
# Complete set of Keystone Stress tests run minimal number of times.
# Good sanity test to see if OSP will be able to handle the longer stress tests.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
@ -9,7 +9,6 @@ elasticsearch:
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json
@ -127,6 +126,7 @@ rally:
sla_max_failure: 0
- name: create-tenant-with-users
enabled: true
users_per_tenant: 2
file: rally/keystonebasic/create_tenant_with_users-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
@ -195,3 +195,13 @@ rally:
file: rally/keystonebasic/create_and_get_role-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-add-list-roles
enabled: true
file: rally/keystonebasic/create_add_list_roles-cc.yml
sla_max_seconds: 30
sla_max_failure: 0
- name: create-and-update-user
enabled: true
file: rally/keystonebasic/create_and_update_user-cc.yml
sla_max_seconds: 30
sla_max_failure: 0

View File

@ -1,6 +1,6 @@
# Complete set of Workload Benchmarks
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
@ -45,30 +45,32 @@ rally:
- 1
times: 1
scenarios:
- name: linpack
- name: browbeat-linpack
enabled: true
image_name: browbeat-linpack
flavor_name: m1.small
external_network:
net_id:
flavor_name: m1.small
file: rally/rally-plugins/workloads/linpack.yml
- name: uperf
- name: browbeat-pbench-uperf
enabled: true
user: root
password: None
image_name: browbeat-uperf
flavor_name: m1.small
# hypervisor_server: "nova:overcloud-compute-1.localdomain"
# hypervisor_client: "nova:overcloud-compute-0.localdomain"
external_network:
net_id:
flavor_name: m1.small
test_name: test-uperf
protocols: 'tcp'
send_results: true
num_pairs: 1
protocols: tcp,udp
instances: 1
num_pairs: 1
samples: 1
test_types: 'stream'
message_sizes: '64'
cloudname: test-cloud
test_types: stream,rr
message_sizes: 64,1024,16384
test_name: browbeat-pbench-uperf
send_results: true
cloudname:
elastic_host:
elastic_port: 9200
file: rally/rally-plugins/workloads/pbench-uperf.yml

View File

@ -1,6 +1,6 @@
# Ceilometer Stress tests run minimal number of times.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
@ -36,9 +36,7 @@ rally:
enabled: true
sleep_before: 5
sleep_after: 5
plugins:
- validate-ceilometer: rally/rally-plugins/validate-ceilometer
- nova-ceilometer: rally/rally-plugins/nova-ceilometer
plugins: []
benchmarks:
- name: CeilometerAlarms
enabled: true

View File

@ -3,7 +3,7 @@
# each iteration it measures response time of several Ceilometer APIs.
# Currently it maxs at 200 instances
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -1,14 +1,14 @@
# Complete set of Gnocchi Stress tests run minimal number of times.
# Good sanity test to see if OSP will be able to handle the longer stress tests.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: false
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json
@ -28,7 +28,7 @@ ansible:
workers: ansible/browbeat/adjustment-workers.yml
metadata: ansible/gather/site.yml
grafana:
enabled: true
enabled: false
grafana_ip: 1.1.1.1
grafana_port: 3000
dashboards:

View File

@ -7,14 +7,14 @@
# how system resources and api responsiveness degrade over each new set of
# instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: false
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json

View File

@ -7,14 +7,14 @@
# how system resources and api responsiveness degrade over each new set of
# instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: false
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json

View File

@ -7,14 +7,14 @@
# how system resources and api responsiveness degrade over each new set of
# instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: false
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json

View File

@ -7,14 +7,14 @@
# how system resources and api responsiveness degrade over each new set of
# instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:
enabled: false
regather: false
host: 1.1.1.1
port: 9200
regather: true
metadata_files:
- name: hardware-metadata
file: metadata/hardware-metadata.json

View File

@ -4,7 +4,7 @@
# booted. The instances have a nic and a fip.
# You must pre-populate (external_net_name and private_net_id)
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -4,7 +4,7 @@
# booted. The instances have a nic, volume and fip.
# You must pre-populate (external_net_name and private_net_id)
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -3,7 +3,7 @@
# with a concurrency of 20 instances. A total of 1000 instances are
# booted. The instances have a nic and volume.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -5,7 +5,7 @@
# additional telemetry load. View how system resources degrade over each
# new set of instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -4,7 +4,7 @@
# booted. View how system resources degrade over each new set of
# instances booted.
browbeat:
results : results/
results: results/
rerun: 1
cloud_name: openstack
elasticsearch:

View File

@ -342,7 +342,7 @@ setup Browbeat with Rally against your local quickstart cloud.
Also creating executable in /home/akrzos/browbeat/.rally-venv/bin/python
Installing setuptools, pip, wheel...done.
[akrzos@bithead browbeat]$ . .rally-venv/bin/activate
(.rally-venv) [akrzos@bithead browbeat]$ pip install rally ansible==2.3.2.0
(.rally-venv) [akrzos@bithead browbeat]$ pip install rally==0.9.1 ansible==2.3.2.0 elasticsearch
...(Truncated)
(.rally-venv) [akrzos@bithead browbeat]$ rally-manage db recreate
(.rally-venv) [akrzos@bithead browbeat]$ scp -F ~/.quickstart/ssh.config.ansible stack@undercloud:overcloudrc .

View File

@ -1,2 +0,0 @@
Authenticate scenarios
======================

View File

@ -1,2 +0,0 @@
Cinder scenarios
================

View File

@ -12,11 +12,15 @@
name: {{image_name}}
flavor:
name: {{flavor_name}}
auto_assign_nic: true
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
context:
network:
start_cidr: "10.0.0.0/16"
networks_per_tenant: 1
users:
tenants: 2
users_per_tenant: 2

View File

@ -1,4 +1,6 @@
{% set image_location = image_location or "/home/stack/cirros" %}
{% set image_location = image_location or "/home/stack/cirros.qcow2" %}
{% set container_format = container_format or "bare" %}
{% set disk_format = disk_format or "qcow2" %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
@ -7,8 +9,8 @@
-
args:
image_location: "{{image_location}}"
container_format: "bare"
disk_format: "qcow2"
container_format: "{{container_format}}"
disk_format: "{{disk_format}}"
runner:
type: "constant"
times: {{times}}
@ -22,4 +24,3 @@
max_seconds_per_iteration: {{sla_max_seconds}}
failure_rate:
max: {{sla_max_failure}}

View File

@ -1,4 +1,6 @@
{% set image_location = image_location or "/home/stack/cirros" %}
{% set image_location = image_location or "/home/stack/cirros.qcow2" %}
{% set container_format = container_format or "bare" %}
{% set disk_format = disk_format or "qcow2" %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
@ -7,8 +9,8 @@
-
args:
image_location: "{{image_location}}"
container_format: "bare"
disk_format: "qcow2"
container_format: "{{container_format}}"
disk_format: "{{disk_format}}"
runner:
type: "constant"
times: {{times}}
@ -22,4 +24,3 @@
max_seconds_per_iteration: {{sla_max_seconds}}
failure_rate:
max: {{sla_max_failure}}

View File

@ -1,6 +1,8 @@
{% set image_location = image_location or "/home/stack/cirros.qcow2" %}
{% set container_format = container_format or "bare" %}
{% set disk_format = disk_format or "qcow2" %}
{% set flavor_name = flavor_name or "m1.small" %}
{% set instances = instances or 2 %}
{% set image_location = image_location or "/home/stack/cirros" %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
@ -9,16 +11,21 @@
-
args:
image_location: "{{image_location}}"
container_format: "bare"
disk_format: "qcow2"
container_format: "{{container_format}}"
disk_format: "{{disk_format}}"
flavor:
name: "{{flavor_name}}"
name: "{{flavor_name}}"
number_instances: {{instances}}
boot_server_kwargs:
auto_assign_nic: true
runner:
type: "constant"
times: {{times}}
concurrency: {{concurrency}}
context:
network:
start_cidr: "10.0.0.0/16"
networks_per_tenant: 1
users:
tenants: 1
users_per_tenant: 1

View File

@ -1,2 +0,0 @@
KeystoneBasic scenarios
=======================

View File

@ -0,0 +1,25 @@
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
---
KeystoneBasic.create_and_list_roles:
-
args:
create_role_kwargs: {}
list_role_kwargs: {}
context:
users:
project_domain: "default"
resource_management_workers: 30
tenants: 1
user_domain: "default"
users_per_tenant: 8
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
sla:
max_avg_duration: {{sla_max_avg_duration}}
max_seconds_per_iteration: {{sla_max_seconds}}
failure_rate:
max: {{sla_max_failure}}

View File

@ -0,0 +1,26 @@
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
---
KeystoneBasic.create_and_update_user:
-
args:
create_user_kwargs: {}
update_user_kwargs:
enabled: false
context:
users:
project_domain: "default"
resource_management_workers: 30
tenants: 1
user_domain: "default"
users_per_tenant: 8
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
sla:
max_avg_duration: {{sla_max_avg_duration}}
max_seconds_per_iteration: {{sla_max_seconds}}
failure_rate:
max: {{sla_max_failure}}

View File

@ -1,10 +0,0 @@
Rally Plugins Browbeat can use
==============================
Current plugins
---------------
- netcreate-boot-ping ( not complete )
- netcreate-boot
- subnet-router-create
- glance-create-boot-delete

View File

@ -1,5 +1,3 @@
# All Rights Reserved.
#
# 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
@ -12,11 +10,12 @@
# License for the specific language governing permissions and limitations
# under the License.
import time
from rally.common.i18n import _
from rally.common import logging
from rally.task import context
from rally import consts
import time
LOG = logging.getLogger(__name__)

View File

@ -10,30 +10,31 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally.task import scenario
from rally.plugins.openstack.scenarios.nova import utils as nova_utils
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.plugins.openstack.scenarios.glance import utils as glance_utils
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.plugins.openstack.scenarios.nova import utils as nova_utils
from rally.task import scenario
from rally.task import types
from rally.task import validation
from rally import consts
class BrowbeatPlugin(neutron_utils.NeutronScenario,
glance_utils.GlanceScenario,
nova_utils.NovaScenario,
scenario.Scenario):
@types.convert(flavor={"type": "nova_flavor"})
@validation.flavor_exists("flavor")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["nova", "neutron", "glance"]})
def glance_create_boot_delete(self, container_format, image_location, disk_format, flavor,
network_create_args=None, subnet_create_args=None, **kwargs):
@types.convert(flavor={"type": "nova_flavor"},
image_location={"type": "path_or_url"})
@validation.required_services(consts.Service.GLANCE, consts.Service.NEUTRON, consts.Service.NOVA)
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["glance", "neutron", "nova"]},
name="BrowbeatPlugin.glance_create_boot_delete")
class GlanceCreateBootDelete(glance_utils.GlanceScenario,
neutron_utils.NeutronScenario,
nova_utils.NovaScenario):
def run(self, container_format, image_location, disk_format, flavor,
network_create_args=None, subnet_create_args=None, **kwargs):
image = self._create_image(container_format, image_location, disk_format, **kwargs)
image_id = image.id
net = self._create_network(network_create_args or {})
self._create_subnet(net, subnet_create_args or {})
kwargs['nics'] = [{'net-id': net['network']['id']}]
server = self._boot_server(image_id, flavor, **kwargs)
server = self._boot_server(image.id, flavor, **kwargs)
self._delete_server(server)
self._delete_image(image)

View File

@ -1,4 +1,7 @@
{% set image_location = image_location or "/home/stack/cirros" %}
{% set image_location = image_location or '/home/stack/cirros.qcow2' %}
{% set flavor_name = flavor_name or 'm1.small' %}
{% set container_format = container_format or 'bare' %}
{% set disk_format = disk_format or 'qcow2' %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
@ -8,15 +11,15 @@ BrowbeatPlugin.glance_create_boot_delete:
args:
flavor:
name: '{{flavor_name}}'
image_location: "{{image_location}}"
container_format: "bare"
disk_format: "qcow2"
image_location: '{{image_location}}'
container_format: '{{container_format}}'
disk_format: '{{disk_format}}'
network_create_args: {}
subnet_create_args: {}
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
type: 'constant'
context:
users:
tenants: 1

View File

@ -10,162 +10,22 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import uuid
from rally.common.i18n import _
from rally.common import logging
from rally.plugins.openstack import scenario
from rally.common import logging
from rally.task import atomic
from rally.task import context
from rally.task import validation
from rally import consts
from rally import osclients
import uuid
LOG = logging.getLogger(__name__)
class BrowbeatGnocchi(scenario.OpenStackScenario):
@scenario.configure(name='BrowbeatGnocchi.archive_policy_list')
def archive_policy_list(self):
"""List archive policies from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._archive_policy_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.archive_policy_rule_list')
def archive_policy_rule_list(self):
"""List archive policy rules from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._archive_policy_rule_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.capabilities_list')
def capabilities_list(self):
"""List capabilities from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._capabilities_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.create_archive_policy')
def create_archive_policy(self):
"""Create archive policy from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
definition = [{'granularity': '0:00:01', 'timespan': '1:00:00'}]
aggregation_methods = ['std', 'count', '95pct', 'min', 'max', 'sum', 'median', 'mean']
self._create_archive_policy(gnocchi_client, name, definition, aggregation_methods)
@scenario.configure(name='BrowbeatGnocchi.create_delete_archive_policy')
def create_delete_archive_policy(self):
"""Create archive policy from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
definition = [{'granularity': '0:00:01', 'timespan': '1:00:00'}]
aggregation_methods = ['std', 'count', '95pct', 'min', 'max', 'sum', 'median', 'mean']
self._create_archive_policy(gnocchi_client, name, definition, aggregation_methods)
self._delete_archive_policy(gnocchi_client, name)
@scenario.configure(name='BrowbeatGnocchi.create_archive_policy_rule')
def create_archive_policy_rule(self):
"""Create archive policy rule from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
metric_pattern = 'cpu_*'
archive_policy_name = 'low'
self._create_archive_policy_rule(gnocchi_client, name, metric_pattern, archive_policy_name)
@scenario.configure(name='BrowbeatGnocchi.create_delete_archive_policy_rule')
def create_delete_archive_policy_rule(self):
"""Create archive policy rule from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
metric_pattern = 'cpu_*'
archive_policy_name = 'low'
self._create_archive_policy_rule(gnocchi_client, name, metric_pattern, archive_policy_name)
self._delete_archive_policy_rule(gnocchi_client, name)
@scenario.configure(name='BrowbeatGnocchi.create_metric')
def create_metric(self, metric_name=None, archive_policy_name=None, unit=None,
resource_id=None):
"""Create metric from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_metric(gnocchi_client, metric_name, archive_policy_name, unit, resource_id)
@scenario.configure(name='BrowbeatGnocchi.create_delete_metric')
def create_delete_metric(self, metric_name=None, archive_policy_name=None, unit=None,
resource_id=None):
"""Create metric from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
metric = self._create_metric(gnocchi_client, metric_name, archive_policy_name, unit,
resource_id)
self._delete_metric(gnocchi_client, metric['id'])
@scenario.configure(name='BrowbeatGnocchi.create_resource')
def create_resource(self, resource_type):
"""Create resource from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_resource(gnocchi_client, resource_type)
@scenario.configure(name='BrowbeatGnocchi.create_delete_resource')
def create_delete_resource(self, resource_type):
"""Create resource from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
resource = self._create_resource(gnocchi_client, resource_type)
self._delete_resource(gnocchi_client, resource['id'])
@scenario.configure(name='BrowbeatGnocchi.create_resource_type')
def create_resource_type(self):
"""Create resource type from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_resource_type(gnocchi_client, self.generate_random_name())
@scenario.configure(name='BrowbeatGnocchi.create_delete_resource_type')
def create_delete_resource_type(self):
"""Create resource type from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
resource_type = self._create_resource_type(gnocchi_client, self.generate_random_name())
self._delete_resource_type(gnocchi_client, resource_type['name'])
@scenario.configure(name='BrowbeatGnocchi.metric_aggregation')
def metric_aggregation(self, aggregation=None, refresh=False):
"""Get aggregation of metrics from Gnocchi client. The list of metrics to aggregate from
is determined through a context before the scenario starts.
"""
gnocchi_client = self.admin_clients("gnocchi")
metric_index = self.context['iteration'] % len(self.context['metric_ids'])
self._metric_aggregation(gnocchi_client, [self.context['metric_ids'][metric_index]],
aggregation, refresh)
@scenario.configure(name='BrowbeatGnocchi.metric_get_measures')
def metric_get_measures(self, aggregation=None, refresh=False):
"""Get measures from a metric from Gnocchi client. The list of metrics to get measures
from is determined through a context before the scenario starts.
"""
gnocchi_client = self.admin_clients("gnocchi")
metric_index = self.context['iteration'] % len(self.context['metric_ids'])
self._metric_get_measures(gnocchi_client, self.context['metric_ids'][metric_index],
aggregation, refresh)
@scenario.configure(name='BrowbeatGnocchi.metric_list')
def metric_list(self):
"""List metrics from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._metric_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.resource_list')
def resource_list(self):
"""List resources from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._resource_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.resource_type_list')
def resource_type_list(self):
"""List resource types from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._resource_type_list(gnocchi_client)
@scenario.configure(name='BrowbeatGnocchi.status_get')
def status_get(self, detailed):
"""Get status of Gnocchi from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._status_get(gnocchi_client, detailed)
class GnocchiScenario(scenario.OpenStackScenario):
@atomic.action_timer("gnocchi.archive_policy_list")
def _archive_policy_list(self, gnocchi_client):
@ -269,6 +129,243 @@ class BrowbeatGnocchi(scenario.OpenStackScenario):
return gnocchi_client.status.get(detailed)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.archive_policy_list')
class ArchivePolicyList(GnocchiScenario):
def run(self):
"""List archive policies from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._archive_policy_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.archive_policy_rule_list')
class ArchivePolicyRuleList(GnocchiScenario):
def run(self):
"""List archive policy rules from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._archive_policy_rule_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.capabilities_list')
class CapabilitiesList(GnocchiScenario):
def run(self):
"""List capabilities from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._capabilities_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_archive_policy')
class CreateArchivePolicy(GnocchiScenario):
def run(self):
"""Create archive policy from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
definition = [{'granularity': '0:00:01', 'timespan': '1:00:00'}]
aggregation_methods = ['std', 'count', '95pct', 'min', 'max', 'sum', 'median', 'mean']
self._create_archive_policy(gnocchi_client, name, definition, aggregation_methods)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_delete_archive_policy')
class CreateDeleteArchivePolicy(GnocchiScenario):
def run(self):
"""Create archive policy from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
definition = [{'granularity': '0:00:01', 'timespan': '1:00:00'}]
aggregation_methods = ['std', 'count', '95pct', 'min', 'max', 'sum', 'median', 'mean']
self._create_archive_policy(gnocchi_client, name, definition, aggregation_methods)
self._delete_archive_policy(gnocchi_client, name)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_archive_policy_rule')
class CreateArchivePolicyRule(GnocchiScenario):
def run(self):
"""Create archive policy rule from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
metric_pattern = 'cpu_*'
archive_policy_name = 'low'
self._create_archive_policy_rule(gnocchi_client, name, metric_pattern, archive_policy_name)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_delete_archive_policy_rule')
class CreateDeleteArchivePolicyRule(GnocchiScenario):
def run(self):
"""Create archive policy rule from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
name = self.generate_random_name()
metric_pattern = 'cpu_*'
archive_policy_name = 'low'
self._create_archive_policy_rule(gnocchi_client, name, metric_pattern, archive_policy_name)
self._delete_archive_policy_rule(gnocchi_client, name)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_metric')
class CreateMetric(GnocchiScenario):
def run(self, metric_name=None, archive_policy_name=None, unit=None, resource_id=None):
"""Create metric from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_metric(gnocchi_client, metric_name, archive_policy_name, unit, resource_id)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_delete_metric')
class CreateDeleteMetric(GnocchiScenario):
def run(self, metric_name=None, archive_policy_name=None, unit=None, resource_id=None):
"""Create metric from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
metric = self._create_metric(gnocchi_client, metric_name, archive_policy_name, unit,
resource_id)
self._delete_metric(gnocchi_client, metric['id'])
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_resource')
class CreateResource(GnocchiScenario):
def run(self, resource_type):
"""Create resource from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_resource(gnocchi_client, resource_type)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_delete_resource')
class CreateDeleteResource(GnocchiScenario):
def run(self, resource_type):
"""Create resource from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
resource = self._create_resource(gnocchi_client, resource_type)
self._delete_resource(gnocchi_client, resource['id'])
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_resource_type')
class CreateResourceType(GnocchiScenario):
def run(self):
"""Create resource type from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._create_resource_type(gnocchi_client, self.generate_random_name())
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.create_delete_resource_type')
class CreateDeleteResourceType(GnocchiScenario):
def run(self):
"""Create resource type from Gnocchi client and then delete it."""
gnocchi_client = self.admin_clients("gnocchi")
resource_type = self._create_resource_type(gnocchi_client, self.generate_random_name())
self._delete_resource_type(gnocchi_client, resource_type['name'])
@validation.required_contexts("browbeat_gnocchi_metric_list")
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.metric_aggregation')
class MetricAggregation(GnocchiScenario):
def run(self, aggregation=None, refresh=False):
"""Get aggregation of metrics from Gnocchi client. The list of metrics to aggregate from
is determined through a context before the scenario starts.
"""
gnocchi_client = self.admin_clients("gnocchi")
metric_index = self.context['iteration'] % len(self.context['metric_ids'])
self._metric_aggregation(gnocchi_client, [self.context['metric_ids'][metric_index]],
aggregation, refresh)
@validation.required_contexts("browbeat_gnocchi_metric_list")
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.metric_get_measures')
class MetricGetMeasures(GnocchiScenario):
def run(self, aggregation=None, refresh=False):
"""Get measures from a metric from Gnocchi client. The list of metrics to get measures
from is determined through a context before the scenario starts.
"""
gnocchi_client = self.admin_clients("gnocchi")
metric_index = self.context['iteration'] % len(self.context['metric_ids'])
self._metric_get_measures(gnocchi_client, self.context['metric_ids'][metric_index],
aggregation, refresh)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.metric_list')
class MetricList(GnocchiScenario):
def run(self):
"""List metrics from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._metric_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.resource_list')
class ResourceList(GnocchiScenario):
def run(self):
"""List resources from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._resource_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.resource_type_list')
class ResourceTypeList(GnocchiScenario):
def run(self):
"""List resource types from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._resource_type_list(gnocchi_client)
@validation.required_services(consts.Service.GNOCCHI)
@validation.required_openstack(admin=True)
@scenario.configure(name='BrowbeatGnocchi.status_get')
class StatusGet(GnocchiScenario):
def run(self, detailed):
"""Get status of Gnocchi from Gnocchi client."""
gnocchi_client = self.admin_clients("gnocchi")
self._status_get(gnocchi_client, detailed)
@context.configure(name="browbeat_gnocchi_metric_list", order=350)
class BrowbeatGnocchiMetricList(context.Context):
"""Grabs list of metric ids from Gnocchi for use with getting aggregates/measures."""

View File

@ -1,93 +0,0 @@
# 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 rally.task import atomic
from rally.task import scenario
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.plugins.openstack.scenarios.vm import utils as vm_utils
from rally.task import types
from rally.task import validation
class BrowbeatPlugin(neutron_utils.NeutronScenario,
vm_utils.VMScenario,
scenario.Scenario):
#
# Create network
# Create subnet
# Attach to router
# Attach guest to new network
# List
# Ping
# Cleanup
#
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["nova", "neutron"],
"keypair": {}, "allow_ssh": {}})
def create_network_nova_boot_ping(self, image, flavor, ext_net, floating=True,
router_create_args=None, router=None,
network_create_args=None, subnet_create_args=None,
**kwargs):
if router is None:
router = self._create_router(router_create_args, ext_net)
network = self._create_network(network_create_args or {})
subnet = self._create_subnet(network, subnet_create_args or {})
self._add_interface_router(subnet['subnet'], router['router'])
kwargs["nics"] = [{'net-id': network['network']['id']}]
_address = None
if floating:
_guest = self._boot_server_with_fip(
image, flavor, True, ext_net, **kwargs)
_address = _guest[1]['ip']
else:
self._boot_server(image, flavor, **kwargs)
_address = ""
if _address:
self._wait_for_ping(_address)
@atomic.action_timer("neutronPlugin.create_router")
def _create_router(self, router_create_args, external_gw=False):
"""Create neutron router.
:param router_create_args: POST /v2.0/routers request options
:returns: neutron router dict
"""
router_create_args["name"] = self.generate_random_name()
if 'id' in external_gw.keys():
for network in self._list_networks():
if network.get("router:external"):
if network.get("id") == external_gw["id"]:
external_network = network
gw_info = {"network_id": external_network["id"],
"enable_snat": True}
router_create_args.setdefault("external_gateway_info",
gw_info)
else:
if external_gw:
for network in self._list_networks():
if network.get("router:external"):
external_network = network
gw_info = {"network_id": external_network["id"],
"enable_snat": True}
router_create_args.setdefault("external_gateway_info",
gw_info)
return self.clients("neutron").create_router(
{"router": router_create_args})

View File

@ -10,24 +10,25 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally.task import scenario
from rally.plugins.openstack.scenarios.nova import utils as nova_utils
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.task import scenario
from rally.task import types
from rally.task import validation
from rally import consts
class BrowbeatPlugin(neutron_utils.NeutronScenario,
nova_utils.NovaScenario,
scenario.Scenario):
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.required_services(consts.Service.NEUTRON, consts.Service.NOVA)
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron", "nova"]},
name="BrowbeatPlugin.create_network_nova_boot")
class CreateNetworkNovaBoot(neutron_utils.NeutronScenario,
nova_utils.NovaScenario):
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["nova", "neutron"]})
def create_network_nova_boot(self, image, flavor, num_networks=1, network_create_args=None,
subnet_create_args=None, **kwargs):
def run(self, image, flavor, num_networks=1, network_create_args=None,
subnet_create_args=None, **kwargs):
nets = []
for net in range(0, num_networks):
network = self._create_network(network_create_args or {})

View File

@ -1,8 +1,10 @@
{% set image_name = image_name or 'cirros' %}
{% set flavor_name = flavor_name or 'm1.xtiny' %}
{% set enable_dhcp = enable_dhcp or true %}
{% set num_networks = num_networks or 1 %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
{% set num_networks = num_networks or 1 %}
{% set enable_dhcp = enable_dhcp or true %}
---
BrowbeatPlugin.create_network_nova_boot:
-
@ -17,7 +19,7 @@ BrowbeatPlugin.create_network_nova_boot:
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
type: 'constant'
context:
users:
tenants: 1

View File

@ -0,0 +1,53 @@
# 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 rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.plugins.openstack.scenarios.vm import utils as vm_utils
from rally.task import atomic
from rally.task import scenario
from rally.task import types
from rally.task import validation
from rally import consts
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.required_services(consts.Service.NEUTRON, consts.Service.NOVA)
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron", "nova"], "keypair": {}, "allow_ssh": None},
name="BrowbeatPlugin.create_network_nova_boot_ping")
class CreateNetworkNovaBootPing(neutron_utils.NeutronScenario,
vm_utils.VMScenario):
def run(self, image, flavor, ext_net_id, router_create_args=None,
network_create_args=None, subnet_create_args=None, **kwargs):
router_create_args["name"] = self.generate_random_name()
router_create_args.setdefault("external_gateway_info",
{"network_id": ext_net_id, "enable_snat": True})
router = self._create_router(router_create_args)
network = self._create_network(network_create_args or {})
subnet = self._create_subnet(network, subnet_create_args or {})
self._add_interface_router(subnet['subnet'], router['router'])
kwargs["nics"] = [{'net-id': network['network']['id']}]
guest = self._boot_server_with_fip(image, flavor, True, None, **kwargs)
self._wait_for_ping(guest[1]['ip'])
@atomic.action_timer("neutron.create_router")
def _create_router(self, router_create_args):
"""Create neutron router.
:param router_create_args: POST /v2.0/routers request options
:returns: neutron router dict
"""
return self.clients("neutron").create_router({"router": router_create_args})

View File

@ -1,4 +1,5 @@
{% set image_name = image_name or 'cirros' %}
{% set flavor_name = flavor_name or 'm1.xtiny' %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
@ -11,8 +12,7 @@ BrowbeatPlugin.create_network_nova_boot_ping:
name: '{{flavor_name}}'
image:
name: '{{image_name}}'
ext_net:
id: {{ net_id }}
ext_net_id: '{{ext_net_id}}'
network_create_args: {}
router_create_args: {}
subnet_create_args: {}
@ -39,4 +39,3 @@ BrowbeatPlugin.create_network_nova_boot_ping:
max_seconds_per_iteration: {{sla_max_seconds}}
failure_rate:
max: {{sla_max_failure}}

View File

@ -1,5 +1,3 @@
# All Rights Reserved.
#
# 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

View File

@ -10,21 +10,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally.task import scenario
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.task import types
from rally.task import scenario
from rally.task import validation
from rally import consts
class BrowbeatPlugin(neutron_utils.NeutronScenario,
scenario.Scenario):
@validation.required_services(consts.Service.NEUTRON)
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron"]},
name="BrowbeatPlugin.router_subnet_create_delete")
class RouterSubnetCreateDelete(neutron_utils.NeutronScenario):
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron"]})
def create_router_and_net(self, num_networks=1, network_create_args=None,
subnet_create_args=None, **kwargs):
def run(self, num_networks=1, network_create_args=None, subnet_create_args=None, **kwargs):
router = self._create_router({})
subnets = []
for net in range(num_networks):

View File

@ -1,9 +1,9 @@
{% set num_networks = num_networks or 1 %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
{% set num_networks = num_networks or 1 %}
---
BrowbeatPlugin.create_router_and_net:
BrowbeatPlugin.router_subnet_create_delete:
-
args:
network_create_args: {}

View File

@ -10,18 +10,20 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally.task import scenario
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.task import scenario
from rally.task import validation
from rally import consts
class BrowbeatPlugin(neutron_utils.NeutronScenario,
scenario.Scenario):
@validation.required_services(consts.Service.NEUTRON)
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron"]},
name="BrowbeatPlugin.securitygroup_port")
class BrowbeatPlugin(neutron_utils.NeutronScenario):
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["neutron"]})
def neutron_securitygroup_port(self, network_create_args=None,
security_group_create_args={}, port_create_args={}, **kwargs):
def run(self, network_create_args=None, security_group_create_args={}, port_create_args={},
**kwargs):
net = self._create_network(network_create_args or {})
sec_grp = self._create_security_group(**security_group_create_args)
sec_grp_list = []

View File

@ -2,7 +2,7 @@
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
---
BrowbeatPlugin.neutron_securitygroup_port:
BrowbeatPlugin.securitygroup_port:
-
args:
network_create_args: {}

View File

@ -10,53 +10,47 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally import consts
from rally.task import scenario
from rally.plugins.openstack.scenarios.cinder import utils as cinder_utils
from rally.plugins.openstack.scenarios.nova import utils as nova_utils
from rally.plugins.openstack.scenarios.vm import utils as vm_utils
from rally.task import scenario
from rally.task import types
from rally.task import validation
from rally import consts
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_contexts("browbeat_delay")
@validation.required_services(consts.Service.NOVA)
@validation.required_openstack(users=True)
@scenario.configure(context={},
name="BrowbeatNova.nova_boot_persist")
@scenario.configure(context={}, name="BrowbeatNova.nova_boot_persist")
class NovaBootPersist(nova_utils.NovaScenario):
def run(self, image, flavor, **kwargs):
self._boot_server(image, flavor)
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_contexts("browbeat_delay")
@validation.required_contexts("browbeat_persist_network")
@validation.required_services(consts.Service.NOVA)
@validation.required_openstack(users=True)
@scenario.configure(context={},
name="BrowbeatNova.nova_boot_persist_with_network")
@scenario.configure(context={}, name="BrowbeatNova.nova_boot_persist_with_network")
class NovaBootPersistWithNetwork(nova_utils.NovaScenario):
def run(self, image, flavor, **kwargs):
self._boot_server(image, flavor, **kwargs)
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_contexts("browbeat_delay")
@validation.required_contexts("browbeat_persist_network")
@validation.required_services(consts.Service.NOVA, consts.Service.CINDER)
@validation.required_openstack(users=True)
@scenario.configure(context={},
name="BrowbeatNova.nova_boot_persist_with_network_volume")
@scenario.configure(context={}, name="BrowbeatNova.nova_boot_persist_with_network_volume")
class NovaBootPersistWithNetworkVolume(nova_utils.NovaScenario, cinder_utils.CinderScenario):
def run(self, image, flavor, volume_size, **kwargs):
@ -65,28 +59,24 @@ class NovaBootPersistWithNetworkVolume(nova_utils.NovaScenario, cinder_utils.Cin
self._attach_volume(server, volume)
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_contexts("browbeat_delay")
@validation.required_services(consts.Service.NOVA, consts.Service.CINDER)
@validation.required_openstack(users=True)
@scenario.configure(context={},
name="BrowbeatNova.nova_boot_persist_with_network_fip")
@scenario.configure(context={}, name="BrowbeatNova.nova_boot_persist_with_network_fip")
class NovaBootPersistWithNetworkFip(vm_utils.VMScenario):
def run(self, image, flavor, external_net_name, boot_server_kwargs):
server = self._boot_server(image, flavor, **boot_server_kwargs)
self._attach_floating_ip(server, external_net_name)
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_contexts("browbeat_delay")
@validation.required_services(consts.Service.NOVA, consts.Service.CINDER)
@validation.required_openstack(users=True)
@scenario.configure(context={},
name="BrowbeatNova.nova_boot_persist_with_network_volume_fip")
@scenario.configure(context={}, name="BrowbeatNova.nova_boot_persist_with_network_volume_fip")
class NovaBootPersistWithNetworkVolumeFip(vm_utils.VMScenario):
def run(self, image, flavor, volume_size, boot_server_kwargs, external_net_name):

View File

@ -1,9 +0,0 @@
Browbeat Rally Plugin: subnet-router-create
======================================
Functions:
----------
- Create Neutron Router
- Create 'N' Neutron network
- Create 'N' Neutron subnet
- Attach subnets created above to Neutron router

View File

@ -1,10 +1,11 @@
{% set image_name = image_name or 'browbeat-linpack' %}
{% set flavor_name = flavor_name or 'm1.small' %}
{% set username = username or 'centos' %}
{% set times = times or 1 %}
{% set concurrency = concurrency or 1 %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
{% set times = times or 1 %}
{% set concurrency = concurrency or 1 %}
{% set username = username or 'centos' %}
---
VMTasks.boot_runcommand_delete:
-
@ -16,15 +17,15 @@ VMTasks.boot_runcommand_delete:
external:
name: '{{external_network}}'
command:
remote_path: "./linpack.sh"
local_path: "rally/rally-plugins/workloads/linpack.sh"
remote_path: './linpack.sh'
local_path: 'rally/rally-plugins/workloads/linpack.sh'
username: '{{username}}'
nics:
- net-id: '{{net_id}}'
runner:
concurrency: {{concurrency}}
times: {{times}}
type: "constant"
type: 'constant'
context:
users:
tenants: 1

View File

@ -10,35 +10,38 @@
# See the License for the specific language governing permissions and
# limitations under the License.
from rally.task import scenario
import csv
import datetime
import json
import logging
import StringIO
import time
import browbeat.elastic
from rally.plugins.openstack.scenarios.vm import utils as vm_utils
from rally.plugins.openstack.scenarios.neutron import utils as neutron_utils
from rally.common import sshutils
from rally.task import scenario
from rally.task import types
from rally.task import validation
from rally.common import sshutils
import browbeat.elastic
import time
import StringIO
import csv
import json
import datetime
import logging
from rally import consts
LOG = logging.getLogger(__name__)
class BrowbeatPlugin(neutron_utils.NeutronScenario,
vm_utils.VMScenario,
scenario.Scenario):
@types.convert(image={"type": "glance_image"}, flavor={"type": "nova_flavor"})
@validation.required_services(consts.Service.NEUTRON, consts.Service.NOVA)
@validation.image_valid_on_flavor("flavor", "image")
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["cinder", "neutron", "nova"], "keypair": {},
"allow_ssh": None},
name="BrowbeatPlugin.pbench_uperf")
class BrowbeatPbenchUperf(neutron_utils.NeutronScenario,
vm_utils.VMScenario):
def build_jump_host(
self,
external,
image,
flavor,
user,
password=None,
**kwargs):
def build_jump_host(self, external, image, flavor, user, password=None, **kwargs):
keyname = self.context["user"]["keypair"]["name"]
jump_host, jump_host_ip = self._boot_server_with_fip(image,
flavor,
@ -159,32 +162,10 @@ class BrowbeatPlugin(neutron_utils.NeutronScenario,
return _clients, _servers
@types.convert(image={"type": "glance_image"},
flavor={"type": "nova_flavor"})
@validation.required_openstack(users=True)
@scenario.configure(context={"cleanup": ["nova", "neutron", "cinder"],
"keypair": {}, "allow_ssh": {}})
def pbench_uperf(
self,
image,
flavor,
user,
test_types,
protocols,
samples,
test_name,
external=None,
send_results=True,
num_pairs=1,
password="",
network_id=None,
zones=None,
message_sizes=None,
instances=None,
elastic_host=None,
elastic_port=None,
cloudname=None,
**kwargs):
def run(self, image, flavor, user, test_types, protocols, samples, test_name, external=None,
send_results=True, num_pairs=1, password="", network_id=None, zones=None,
message_sizes=None, instances=None, elastic_host=None, elastic_port=None,
cloudname=None, **kwargs):
pbench_path = "/opt/pbench-agent"
pbench_results = "/var/lib/pbench-agent"

View File

@ -1,7 +1,5 @@
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
{% set times = times or 1 %}
{% set image_name = image_name or 'browbeat-uperf' %}
{% set flavor_name = flavor_name or 'm1.small' %}
{% set num_pairs = num_pairs or 1 %}
{% set instances = instances or 1 %}
{% set password = password or 'None' %}
@ -9,7 +7,9 @@
{% set message_sizes = message_sizes or '64,1024,16384' %}
{% set hypervisor_server = hypervisor_server or 'None' %}
{% set hypervisor_client = hypervisor_client or 'None' %}
{% set sla_max_avg_duration = sla_max_avg_duration or 60 %}
{% set sla_max_failure = sla_max_failure or 0 %}
{% set sla_max_seconds = sla_max_seconds or 60 %}
---
BrowbeatPlugin.pbench_uperf:
-