From 203cfd7926583c7b46142581c78f9411c28ccf2b Mon Sep 17 00:00:00 2001 From: akrzos Date: Wed, 19 Jul 2017 08:53:01 -0400 Subject: [PATCH] Adding more nova boot and persist scenarios. * Rally context to insert delay for specific scenarios * Boot a persisting instance with NIC and a volume * Boot a persisting instance with NIC and associate a FIP * Boot a persisting instance with a NIC and a volume and associate a FIP Change-Id: I3735495148ef88e69fc13be23fb53f29c184ed87 --- ...nova-neutron-gnocchi-10k-1000-per-30m.yaml | 1 + ...y-nova-neutron-gnocchi-1k-100-per-30m.yaml | 1 + ...y-nova-neutron-gnocchi-1k-500-per-30m.yaml | 1 + ...y-nova-neutron-gnocchi-5k-500-per-30m.yaml | 1 + ...va-persist-instances-with-network-fip.yaml | 137 ++++++++++++++++ ...ist-instances-with-network-volume-fip.yaml | 147 ++++++++++++++++++ ...persist-instances-with-network-volume.yaml | 136 ++++++++++++++++ ...y-nova-persist-instances-with-network.yaml | 17 +- conf/telemetry-nova-persist-instances.yaml | 16 +- doc/source/plugins.rst | 26 +++- rally/rally-plugins/browbeat/delay.py | 55 +++++++ rally/rally-plugins/neutron/neutron.py | 6 +- rally/rally-plugins/nova/nova.py | 52 +++++++ .../rally-plugins/nova/nova_boot_persist.yml | 11 +- .../nova/nova_boot_persist_with_network.yml | 15 +- .../nova_boot_persist_with_network_fip.yml | 46 ++++++ .../nova_boot_persist_with_network_volume.yml | 48 ++++++ ...a_boot_persist_with_network_volume_fip.yml | 48 ++++++ 18 files changed, 739 insertions(+), 25 deletions(-) create mode 100644 conf/telemetry-nova-persist-instances-with-network-fip.yaml create mode 100644 conf/telemetry-nova-persist-instances-with-network-volume-fip.yaml create mode 100644 conf/telemetry-nova-persist-instances-with-network-volume.yaml create mode 100644 rally/rally-plugins/browbeat/delay.py create mode 100644 rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml create mode 100644 rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml create mode 100644 rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml diff --git a/conf/telemetry-nova-neutron-gnocchi-10k-1000-per-30m.yaml b/conf/telemetry-nova-neutron-gnocchi-10k-1000-per-30m.yaml index 020828dc6..3be3b0fe2 100644 --- a/conf/telemetry-nova-neutron-gnocchi-10k-1000-per-30m.yaml +++ b/conf/telemetry-nova-neutron-gnocchi-10k-1000-per-30m.yaml @@ -47,6 +47,7 @@ rally: sleep_before: 5 sleep_after: 5 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova - neutron: rally/rally-plugins/neutron - gnocchi: rally/rally-plugins/gnocchi diff --git a/conf/telemetry-nova-neutron-gnocchi-1k-100-per-30m.yaml b/conf/telemetry-nova-neutron-gnocchi-1k-100-per-30m.yaml index 21f522287..2453c628a 100644 --- a/conf/telemetry-nova-neutron-gnocchi-1k-100-per-30m.yaml +++ b/conf/telemetry-nova-neutron-gnocchi-1k-100-per-30m.yaml @@ -47,6 +47,7 @@ rally: sleep_before: 5 sleep_after: 5 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova - neutron: rally/rally-plugins/neutron - gnocchi: rally/rally-plugins/gnocchi diff --git a/conf/telemetry-nova-neutron-gnocchi-1k-500-per-30m.yaml b/conf/telemetry-nova-neutron-gnocchi-1k-500-per-30m.yaml index ca51098a2..96ad88fe3 100644 --- a/conf/telemetry-nova-neutron-gnocchi-1k-500-per-30m.yaml +++ b/conf/telemetry-nova-neutron-gnocchi-1k-500-per-30m.yaml @@ -47,6 +47,7 @@ rally: sleep_before: 5 sleep_after: 5 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova - neutron: rally/rally-plugins/neutron - gnocchi: rally/rally-plugins/gnocchi diff --git a/conf/telemetry-nova-neutron-gnocchi-5k-500-per-30m.yaml b/conf/telemetry-nova-neutron-gnocchi-5k-500-per-30m.yaml index 68f65948d..8095cf2b8 100644 --- a/conf/telemetry-nova-neutron-gnocchi-5k-500-per-30m.yaml +++ b/conf/telemetry-nova-neutron-gnocchi-5k-500-per-30m.yaml @@ -47,6 +47,7 @@ rally: sleep_before: 5 sleep_after: 5 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova - neutron: rally/rally-plugins/neutron - gnocchi: rally/rally-plugins/gnocchi diff --git a/conf/telemetry-nova-persist-instances-with-network-fip.yaml b/conf/telemetry-nova-persist-instances-with-network-fip.yaml new file mode 100644 index 000000000..e5b391764 --- /dev/null +++ b/conf/telemetry-nova-persist-instances-with-network-fip.yaml @@ -0,0 +1,137 @@ +# Stress test designed for telemetry services (ceilometer, gnocchi) by +# booting persisting xtiny cirros instances. It boots 100 each iteration +# with a concurrency of 20 instances. A total of 1000 instances are +# booted. The instances have a nic and a fip. +# You must pre-populate (external_net_name and private_net_id) +browbeat: + results : results/ + rerun: 1 + cloud_name: openstack +elasticsearch: + enabled: false + regather: false + host: 1.1.1.1 + port: 9200 + metadata_files: + - name: hardware-metadata + file: metadata/hardware-metadata.json + - name: environment-metadata + file: metadata/environment-metadata.json + - name: software-metadata + file: metadata/software-metadata.json + - name: version + file: metadata/version.json +ansible: + ssh_config: ansible/ssh-config + hosts: ansible/hosts + adjust: + keystone_token: ansible/browbeat/adjustment-keystone-token.yml + neutron_l3: ansible/browbeat/adjustment-l3.yml + nova_db: ansible/browbeat/adjustment-db.yml + workers: ansible/browbeat/adjustment-workers.yml + metadata: ansible/gather/site.yml +connmon: + enabled: false + sudo: true +grafana: + enabled: false + grafana_ip: 1.1.1.1 + grafana_port: 3000 + dashboards: + - openstack-general-system-performance +rally: + enabled: true + sleep_before: 0 + sleep_after: 0 + plugins: + - browbeat: rally/rally-plugins/browbeat + - nova: rally/rally-plugins/nova + - neutron: rally/rally-plugins/neutron + benchmarks: + # Boots a total of 1000 instances, 100 at a time with 30minutes between booting storms + - name: BrowbeatNovaPersistWithNetworkFIP01 + enabled: true + concurrency: + - 20 + times: 100 + scenarios: + - name: nova-boot-persist-with-network-fip-100-01 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-02 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-03 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-04 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-05 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-06 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-07 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-08 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-09 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml + - name: nova-boot-persist-with-network-fip-100-10 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml diff --git a/conf/telemetry-nova-persist-instances-with-network-volume-fip.yaml b/conf/telemetry-nova-persist-instances-with-network-volume-fip.yaml new file mode 100644 index 000000000..2dafb943b --- /dev/null +++ b/conf/telemetry-nova-persist-instances-with-network-volume-fip.yaml @@ -0,0 +1,147 @@ +# Stress test designed for telemetry services (ceilometer, gnocchi) by +# booting persisting xtiny cirros instances. It boots 100 each iteration +# with a concurrency of 20 instances. A total of 1000 instances are +# booted. The instances have a nic, volume and fip. +# You must pre-populate (external_net_name and private_net_id) +browbeat: + results : results/ + rerun: 1 + cloud_name: openstack +elasticsearch: + enabled: false + regather: false + host: 1.1.1.1 + port: 9200 + metadata_files: + - name: hardware-metadata + file: metadata/hardware-metadata.json + - name: environment-metadata + file: metadata/environment-metadata.json + - name: software-metadata + file: metadata/software-metadata.json + - name: version + file: metadata/version.json +ansible: + ssh_config: ansible/ssh-config + hosts: ansible/hosts + adjust: + keystone_token: ansible/browbeat/adjustment-keystone-token.yml + neutron_l3: ansible/browbeat/adjustment-l3.yml + nova_db: ansible/browbeat/adjustment-db.yml + workers: ansible/browbeat/adjustment-workers.yml + metadata: ansible/gather/site.yml +connmon: + enabled: false + sudo: true +grafana: + enabled: false + grafana_ip: 1.1.1.1 + grafana_port: 3000 + dashboards: + - openstack-general-system-performance +rally: + enabled: true + sleep_before: 0 + sleep_after: 0 + plugins: + - browbeat: rally/rally-plugins/browbeat + - nova: rally/rally-plugins/nova + - neutron: rally/rally-plugins/neutron + benchmarks: + # Boots a total of 1000 instances, 100 at a time with 30minutes between booting storms + - name: BrowbeatNovaPersistWithNetworkVolumeFIP01 + enabled: true + concurrency: + - 20 + times: 100 + scenarios: + - name: nova-boot-persist-with-network-volume-fip-100-01 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-02 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-03 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-04 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-05 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-06 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-07 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-08 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-09 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml + - name: nova-boot-persist-with-network-volume-fip-100-10 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + external_net_name: + private_net_id: + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml diff --git a/conf/telemetry-nova-persist-instances-with-network-volume.yaml b/conf/telemetry-nova-persist-instances-with-network-volume.yaml new file mode 100644 index 000000000..804d3299e --- /dev/null +++ b/conf/telemetry-nova-persist-instances-with-network-volume.yaml @@ -0,0 +1,136 @@ +# Stress test designed for telemetry services (ceilometer, gnocchi) by +# booting persisting xtiny cirros instances. It boots 100 each iteration +# with a concurrency of 20 instances. A total of 1000 instances are +# booted. The instances have a nic and volume. +browbeat: + results : results/ + rerun: 1 + cloud_name: openstack +elasticsearch: + enabled: false + regather: false + host: 1.1.1.1 + port: 9200 + metadata_files: + - name: hardware-metadata + file: metadata/hardware-metadata.json + - name: environment-metadata + file: metadata/environment-metadata.json + - name: software-metadata + file: metadata/software-metadata.json + - name: version + file: metadata/version.json +ansible: + ssh_config: ansible/ssh-config + hosts: ansible/hosts + adjust: + keystone_token: ansible/browbeat/adjustment-keystone-token.yml + neutron_l3: ansible/browbeat/adjustment-l3.yml + nova_db: ansible/browbeat/adjustment-db.yml + workers: ansible/browbeat/adjustment-workers.yml + metadata: ansible/gather/site.yml +connmon: + enabled: false + sudo: true +grafana: + enabled: false + grafana_ip: 1.1.1.1 + grafana_port: 3000 + dashboards: + - openstack-general-system-performance +rally: + enabled: true + sleep_before: 0 + sleep_after: 0 + plugins: + - browbeat: rally/rally-plugins/browbeat + - nova: rally/rally-plugins/nova + - neutron: rally/rally-plugins/neutron + benchmarks: + # Boots a total of 1000 instances, 100 at a time with 30minutes between booting storms + - name: BrowbeatNovaPersistWithNetworkVolume01 + enabled: true + concurrency: + - 20 + times: 100 + scenarios: + - name: nova-boot-persist-with-network-volume-100-01 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.0.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-02 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.2.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-03 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.4.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-04 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.6.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-05 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.8.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-06 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.10.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-07 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.12.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-08 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.14.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-09 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.16.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml + - name: nova-boot-persist-with-network-volume-100-10 + enabled: true + image_name: cirros + flavor_name: m1.xtiny + volume_size: 1 + cleanup_delay: 1800 + network_start_cidr: 10.1.18.0/23 + file: rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml diff --git a/conf/telemetry-nova-persist-instances-with-network.yaml b/conf/telemetry-nova-persist-instances-with-network.yaml index e774c45e1..5f1a2fd37 100644 --- a/conf/telemetry-nova-persist-instances-with-network.yaml +++ b/conf/telemetry-nova-persist-instances-with-network.yaml @@ -10,9 +10,9 @@ browbeat: 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 @@ -43,10 +43,9 @@ grafana: rally: enabled: true sleep_before: 0 - # Sleeps 30 minutes after each iteration to allow for system resources to degrade or - # display stepped degrading (If the system is hitting saturation or high utilization) - sleep_after: 1800 + sleep_after: 0 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova - neutron: rally/rally-plugins/neutron benchmarks: @@ -61,59 +60,69 @@ rally: enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.0.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-02 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.2.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-03 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.4.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-04 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.6.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-05 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.8.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-06 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.10.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-07 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.12.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-08 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.14.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-09 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.16.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml - name: nova-boot-persist-with-network-100-10 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 network_start_cidr: 10.1.18.0/23 file: rally/rally-plugins/nova/nova_boot_persist_with_network.yml diff --git a/conf/telemetry-nova-persist-instances.yaml b/conf/telemetry-nova-persist-instances.yaml index 536d944ee..9c599dfa4 100644 --- a/conf/telemetry-nova-persist-instances.yaml +++ b/conf/telemetry-nova-persist-instances.yaml @@ -12,7 +12,6 @@ elasticsearch: regather: false host: 1.1.1.1 port: 9200 - regather: true metadata_files: - name: hardware-metadata file: metadata/hardware-metadata.json @@ -43,10 +42,9 @@ grafana: rally: enabled: true sleep_before: 0 - # Sleeps 30 minutes after each iteration to allow for system resources to degrade or - # display stepped degrading (If the system is hitting saturation or high utilization) - sleep_after: 1800 + sleep_after: 0 plugins: + - browbeat: rally/rally-plugins/browbeat - nova: rally/rally-plugins/nova benchmarks: # Boots a total of 1000 instances, 100 at a time with 30minutes between booting storms @@ -60,49 +58,59 @@ rally: enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-02 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-03 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-04 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-05 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-06 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-07 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-08 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-09 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml - name: nova-boot-100-10 enabled: true image_name: cirros flavor_name: m1.xtiny + cleanup_delay: 1800 file: rally/rally-plugins/nova/nova_boot_persist.yml diff --git a/doc/source/plugins.rst b/doc/source/plugins.rst index a1ab1bed4..78178ffe6 100644 --- a/doc/source/plugins.rst +++ b/doc/source/plugins.rst @@ -5,17 +5,37 @@ Plugins Rally ~~~~~ +Context - browbeat_delay +^^^^^^^^^^^^^^^^^^^^^^^^ + +This context allows a setup and cleanup delay to be introduced into a scenario. + Context - browbeat_persist_network ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -This context creates network resources that persist upon completation of a rally run. It is used in conjunction with the nova_boot_persist_with_network plugin scenario. Beware that removal of the network resources created by this context plugin can be a lengthy process so this is best used on "throw-away-test" clouds. +This context creates network resources that persist upon completion of a rally run. It is used in conjunction with the nova_boot_persist_with_network and nova_boot_persist_with_network_volume plugin scenarios. You can also use `neutron purge` command to purge a project/tenant of neutron network resources. Scenario - nova_boot_persist ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -This scenario creates instances without a network that persist upon completation of a rally run. This scenario is best used for excerising the Telemetry systems within an OpenStack Cloud. Alternatively, it can be used to put idle instances on a cloud for other workloads to compuete for resources. The scenario is referenced in the telemetry Browbeat configurations in order to build a "stepped" workload that can be used to analyze telemetry performance and scalability. +This scenario creates instances without a network that persist upon completion of a rally run. This scenario is best used for excerising the Telemetry systems within an OpenStack Cloud. Alternatively, it can be used to put idle instances on a cloud for other workloads to compete for resources. The scenario is referenced in the Telemetry Browbeat configurations in order to build a "stepped" workload that can be used to analyze Telemetry performance and scalability. Scenario - nova_boot_persist_with_network ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -This scenario creates instances that are attached to a network and persist upon completation of a rally run. This scenario is best used for excerising the Telemetry systems within an OpenStack Cloud. It increases the telemetry workload by creating more resources that the telemetry services must collect and process metrics over. Alternatively, it can be used to put idle instances on a cloud for other workloads to compuete for resources. The scenario is referenced in the telemetry Browbeat configurations in order to build a "stepped" workload that can be used to analyze telemetry scalability. +This scenario creates instances that are attached to a network and persist upon completion of a rally run. This scenario is best used for excerising the Telemetry systems within an OpenStack Cloud. It increases the Telemetry workload by creating more resources that the Telemetry services must collect and process metrics over. Alternatively, it can be used to put idle instances on a cloud for other workloads to compete for resources. The scenario is referenced in the Telemetry Browbeat configurations in order to build a "stepped" workload that can be used to analyze Telemetry scalability. + +Scenario - nova_boot_persist_with_network_fip +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +This scenario creates instances with a nic and associates a floating ip that persist upon completion of a rally run. It is used as a workload with Telemetry by spawning many instances that have many metrics for the Telemetry subsystem to collect upon. + +Scenario - nova_boot_persist_with_network_volume +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +This scenario create instances with a nic and a volume that persist upon completion of a rally run. It is used as a workload with Telemetry by spawning many instances that have many metrics for the Telemetry subsystem to collect upon. + +Scenario - nova_boot_persist_with_network_volume_fip +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +This scenario creates instances with a nic, a volume and associates a floating ip that persist upon completion of a rally run. It is used as a workload with Telemetry by spawning many instances that have many metrics for the Telemetry subsystem to collect upon. diff --git a/rally/rally-plugins/browbeat/delay.py b/rally/rally-plugins/browbeat/delay.py new file mode 100644 index 000000000..9319121b2 --- /dev/null +++ b/rally/rally-plugins/browbeat/delay.py @@ -0,0 +1,55 @@ +# 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 +# +# 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.common.i18n import _ +from rally.common import logging +from rally.task import context +from rally import consts +import time + + +LOG = logging.getLogger(__name__) + + +@context.configure(name="browbeat_delay", order=400) +class BrowbeatDelay(context.Context): + """Add delay to start or end of a rally scenario.""" + + CONFIG_SCHEMA = { + "type": "object", + "$schema": consts.JSON_SCHEMA, + "properties": { + "setup_delay": { + "type": "integer", + "minimum": 0 + }, + "cleanup_delay": { + "type": "integer", + "minimum": 0 + }, + }, + "additionalProperties": False + } + + @logging.log_task_wrapper(LOG.info, _("Enter context: `browbeat_delay`")) + def setup(self): + if self.config.get('setup_delay'): + LOG.info('Setup Delaying: {}'.format(self.config.get('setup_delay'))) + time.sleep(self.config.get('setup_delay')) + + @logging.log_task_wrapper(LOG.info, _("Exit context: `browbeat_delay`")) + def cleanup(self): + if self.config.get('cleanup_delay'): + LOG.info('Cleanup Delaying: {}'.format(self.config.get('cleanup_delay'))) + time.sleep(self.config.get('cleanup_delay')) diff --git a/rally/rally-plugins/neutron/neutron.py b/rally/rally-plugins/neutron/neutron.py index a7286da2f..c0d71cf1c 100644 --- a/rally/rally-plugins/neutron/neutron.py +++ b/rally/rally-plugins/neutron/neutron.py @@ -17,8 +17,6 @@ from rally.common import logging from rally.plugins.openstack.context.network import networks from rally.task import context from rally import consts -import time - LOG = logging.getLogger(__name__) @@ -63,6 +61,4 @@ class BrowbeatPersistNetwork(networks.Network): @logging.log_task_wrapper(LOG.info, _("Exit context: `browbeat_persist_network`")) def cleanup(self): - if self.config.get('cleanup_delay'): - LOG.debug('Cleanup Delaying: {}'.format(self.config.get('cleanup_delay'))) - time.sleep(self.config.get('cleanup_delay')) + pass diff --git a/rally/rally-plugins/nova/nova.py b/rally/rally-plugins/nova/nova.py index ac797df71..24f95199b 100644 --- a/rally/rally-plugins/nova/nova.py +++ b/rally/rally-plugins/nova/nova.py @@ -12,7 +12,9 @@ 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 types from rally.task import validation @@ -20,6 +22,7 @@ from rally.task import validation @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={}, @@ -33,6 +36,7 @@ class NovaBootPersist(nova_utils.NovaScenario): @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) @@ -42,3 +46,51 @@ 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"}) +@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") +class NovaBootPersistWithNetworkVolume(nova_utils.NovaScenario, cinder_utils.CinderScenario): + + def run(self, image, flavor, volume_size, **kwargs): + server = self._boot_server(image, flavor, **kwargs) + volume = self._create_volume(volume_size) + self._attach_volume(server, volume) + + +@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") +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"}) +@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") +class NovaBootPersistWithNetworkVolumeFip(vm_utils.VMScenario): + + def run(self, image, flavor, volume_size, boot_server_kwargs, external_net_name): + server = self._boot_server(image, flavor, **boot_server_kwargs) + volume = self._create_volume(volume_size) + self._attach_volume(server, volume) + self._attach_floating_ip(server, external_net_name) diff --git a/rally/rally-plugins/nova/nova_boot_persist.yml b/rally/rally-plugins/nova/nova_boot_persist.yml index 26e685d87..db7895f24 100644 --- a/rally/rally-plugins/nova/nova_boot_persist.yml +++ b/rally/rally-plugins/nova/nova_boot_persist.yml @@ -1,5 +1,7 @@ -{% set image_name = image_name or "cirros" %} -{% set flavor_name = flavor_name or "m1.xtiny" %} +{% set image_name = image_name or 'cirros' %} +{% set flavor_name = flavor_name or 'm1.xtiny' %} +{% set setup_delay = setup_delay or 0 %} +{% set cleanup_delay = cleanup_delay or 0 %} {% 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 %} @@ -14,8 +16,11 @@ BrowbeatNova.nova_boot_persist: runner: concurrency: {{concurrency}} times: {{times}} - type: "constant" + type: 'constant' context: + browbeat_delay: + setup_delay: {{setup_delay}} + cleanup_delay: {{cleanup_delay}} users: tenants: 1 users_per_tenant: 8 diff --git a/rally/rally-plugins/nova/nova_boot_persist_with_network.yml b/rally/rally-plugins/nova/nova_boot_persist_with_network.yml index 2659f0373..a41ebcedf 100644 --- a/rally/rally-plugins/nova/nova_boot_persist_with_network.yml +++ b/rally/rally-plugins/nova/nova_boot_persist_with_network.yml @@ -1,10 +1,11 @@ -{% set image_name = image_name or "cirros" %} -{% set flavor_name = flavor_name or "m1.xtiny" %} +{% set image_name = image_name or 'cirros' %} +{% set flavor_name = flavor_name or 'm1.xtiny' %} +{% set setup_delay = setup_delay or 0 %} +{% set cleanup_delay = cleanup_delay or 0 %} +{% set network_start_cidr = network_start_cidr or '10.1.0.0/23' %} {% 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 network_start_cidr = network_start_cidr or '10.1.0.0/23' %} -{% set cleanup_delay = cleanup_delay or 0 %} --- BrowbeatNova.nova_boot_persist_with_network: - @@ -16,13 +17,15 @@ BrowbeatNova.nova_boot_persist_with_network: runner: concurrency: {{concurrency}} times: {{times}} - type: "constant" + type: 'constant' context: + browbeat_delay: + setup_delay: {{setup_delay}} + cleanup_delay: {{cleanup_delay}} browbeat_persist_network: networks_per_tenant: 1 subnets_per_network: 1 start_cidr: {{network_start_cidr}} - cleanup_delay: {{cleanup_delay}} users: tenants: 1 users_per_tenant: 8 diff --git a/rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml b/rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml new file mode 100644 index 000000000..edd5193e6 --- /dev/null +++ b/rally/rally-plugins/nova/nova_boot_persist_with_network_fip.yml @@ -0,0 +1,46 @@ +{% set image_name = image_name or 'cirros' %} +{% set flavor_name = flavor_name or 'm1.xtiny' %} +{% set setup_delay = setup_delay or 0 %} +{% set cleanup_delay = cleanup_delay or 0 %} +{% set external_net_name = external_net_name or 'browbeat_public' %} +{% 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 %} +--- +BrowbeatNova.nova_boot_persist_with_network_fip: + - + args: + flavor: + name: '{{flavor_name}}' + image: + name: '{{image_name}}' + external_net_name: '{{external_net_name}}' + boot_server_kwargs: + nics: + - net-id: '{{private_net_id}}' + runner: + concurrency: {{concurrency}} + times: {{times}} + type: 'constant' + context: + browbeat_delay: + setup_delay: {{setup_delay}} + cleanup_delay: {{cleanup_delay}} + users: + tenants: 1 + users_per_tenant: 8 + quotas: + neutron: + network: -1 + port: -1 + router: -1 + subnet: -1 + nova: + instances: -1 + cores: -1 + ram: -1 + sla: + max_avg_duration: {{sla_max_avg_duration}} + max_seconds_per_iteration: {{sla_max_seconds}} + failure_rate: + max: {{sla_max_failure}} diff --git a/rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml b/rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml new file mode 100644 index 000000000..7c9d120f2 --- /dev/null +++ b/rally/rally-plugins/nova/nova_boot_persist_with_network_volume.yml @@ -0,0 +1,48 @@ +{% set image_name = image_name or 'cirros' %} +{% set flavor_name = flavor_name or 'm1.xtiny' %} +{% set setup_delay = setup_delay or 0 %} +{% set cleanup_delay = cleanup_delay or 0 %} +{% set network_start_cidr = network_start_cidr or '10.1.0.0/23' %} +{% set volume_size = volume_size 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 %} +--- +BrowbeatNova.nova_boot_persist_with_network_volume: + - + args: + flavor: + name: '{{flavor_name}}' + image: + name: '{{image_name}}' + volume_size: '{{volume_size}}' + runner: + concurrency: {{concurrency}} + times: {{times}} + type: 'constant' + context: + browbeat_delay: + setup_delay: {{setup_delay}} + cleanup_delay: {{cleanup_delay}} + browbeat_persist_network: + networks_per_tenant: 1 + subnets_per_network: 1 + start_cidr: {{network_start_cidr}} + users: + tenants: 1 + users_per_tenant: 8 + quotas: + neutron: + network: -1 + port: -1 + router: -1 + subnet: -1 + nova: + instances: -1 + cores: -1 + ram: -1 + sla: + max_avg_duration: {{sla_max_avg_duration}} + max_seconds_per_iteration: {{sla_max_seconds}} + failure_rate: + max: {{sla_max_failure}} diff --git a/rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml b/rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml new file mode 100644 index 000000000..dd73c5ff3 --- /dev/null +++ b/rally/rally-plugins/nova/nova_boot_persist_with_network_volume_fip.yml @@ -0,0 +1,48 @@ +{% set image_name = image_name or 'cirros' %} +{% set flavor_name = flavor_name or 'm1.xtiny' %} +{% set setup_delay = setup_delay or 0 %} +{% set cleanup_delay = cleanup_delay or 0 %} +{% set external_net_name = external_net_name or 'browbeat_public' %} +{% set volume_size = volume_size 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 %} +--- +BrowbeatNova.nova_boot_persist_with_network_volume_fip: + - + args: + flavor: + name: '{{flavor_name}}' + image: + name: '{{image_name}}' + volume_size: '{{volume_size}}' + external_net_name: '{{external_net_name}}' + boot_server_kwargs: + nics: + - net-id: '{{private_net_id}}' + runner: + concurrency: {{concurrency}} + times: {{times}} + type: 'constant' + context: + browbeat_delay: + setup_delay: {{setup_delay}} + cleanup_delay: {{cleanup_delay}} + users: + tenants: 1 + users_per_tenant: 8 + quotas: + neutron: + network: -1 + port: -1 + router: -1 + subnet: -1 + nova: + instances: -1 + cores: -1 + ram: -1 + sla: + max_avg_duration: {{sla_max_avg_duration}} + max_seconds_per_iteration: {{sla_max_seconds}} + failure_rate: + max: {{sla_max_failure}}