For some reason, the MultiStoresImportImages test was causing the
test runner to balloon to ~1.5G, which generates spurious OOMs in
the gate, resulting in worker death and failure.
This test was generating 10M of data with data_utils.random_bytes(),
instead of the default of 1K, for no apparent reason. We are still
not sure why, but this results in the memory ballooning, potentially
because of BytesIO, or request.put() mishandling.
Regardless, this is unnecessary, and causing failures in the gate,
so this patch switches it back to the default, which works fine.
Change-Id: I9f1ea0114531a735bd38ad54da7ce15fb2bf7f7c
HTTPConnection() doesn't take the argument 'context' while
HTTPSConnection() accepts it at creating a connection in an object
client. HTTP connection doesn't require an SSL context.
Change-Id: I51ffc8cd04fe90493e23b0f0ca9b0420c5a24cd5
create_object_continue interface in object_client doesn't use
CONF.identity.disable_ssl_certificate_validation, so even if we set
disable_ssl_certificate_validation=true in tempest.conf, sometimes
we will still get "ssl.SSLCertVerificationError:
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed:
unable to get local issuer certificate (_ssl.c:1108)"
So create_object_continue should judge whether to check ssl
certification according to
CONF.identity.disable_ssl_certificate_validation.
Change-Id: I38f4416641e396caf88d16e3b418f0fc7577179d
Closes-Bug: #1907554
Keystone is moving away from using either project-scope or domain-scope
for the main cloud administrator user, and instead moving toward the
admin user having a role assignment on the "system" scope[1]. This will
mean that no particular project or domain is special, and instead the
cloud administrator scopes to the system in order to make
deployment-wide changes. Keystone has now migrated all of its policies
to understand system scope[2], and if a deployment sets
[oslo_policy]/enforce_scope=true in keystone.conf and uses the new
policies, an admin user scoped to the admin project will not be able to
create dynamic credentials for tempest.
This patch adds a new parameter ``[auth]/admin_system`` to indicate that
neither the ``admin_project`` or ``admin_domain`` parameters apply to
the admin user and that the user should instead authenticate with the
system scope. This also adds ``admin_user_domain_name`` so that the
admin user can be found in its domain (namespace) without setting
``domain_name``, and for completeness also adds
``admin_project_domain_name`` so that ``domain_name`` could be omitted
even if using project scope.
[1] http://specs.openstack.org/openstack/keystone-specs/specs/keystone/queens/system-scope.html
[2] https://bugs.launchpad.net/keystone/+bugs?field.status%3Alist=FIXRELEASED&field.tag=system-scope
Depends-on: https://review.opendev.org/739262
Change-Id: I840b273c37ca7cc4592c43813abfb424337e2836
Allow consumers of create_server to pass custom arguments to
create_port method which is called from create_server one.
Fix namestart var usage in create_port - as the name of the var
suggests, it should be used to generate a name from. Therefore
the patch also adds rand_name call which we accidentaly removed
recently.
Implements: blueprint tempest-scenario-manager-stable
Change-Id: I724e0f37d4381a493217a077492046f7a4b0a2a2
Detaching a volume from an instance in Nova is an asynchronous
operation. While the request can be accepted the underlying act of
detaching the device from the instance, disconnecting the volume from
the host, updating cinder and deleting records in Nova can take some
considerable time.
As such when detaching a volume callers should continue to poll the
os-volume_attachments Nova API to determine when the underlying volume
attachment, also known as a Block Device Mapping or BDM, is removed.
Bug #1908399 outlines an issue where the scenario helper method
nova_volume_detach was being called multiple times during tests and
cleanup while only waiting for the volume status to change to available.
This allowed for a race to occur where additional requests could be made
to detach the volume while the volume attachment still remained in Nova
resulting in a 400 error being returned by n-api.
This change addresses this by switching between the volume resource
status and the volume attachment removal waiters.
Closes-Bug: #1908399
Change-Id: Ib6ae2c30be65eb444976b0330fd23d9457146284
Use proper kwargs arg instead of the named arg in rebuild_server.
The method is not used anywhere with the rebuild_kwargs set so this
change should affect anybody.
Implements: blueprint tempest-scenario-manager-stable
Change-Id: Id445d3f1daee4dec1f771580667a35baffa18e62
The external network be shared by all tenant. When it associated
to a tenant router the cidr of it's subnets cannot overlap with
tenant subnets', otherwise it will lead to bug #1903433. The related
fix patch: https://review.opendev.org/761829
So, in tempest, the external subnets need was considered when check
cidr whether in use.
Related-Bug: #1903433
Change-Id: Ief84251adb0368533570d9e9f6630de92e27c5c3
A global var LOG is set in the tempest/scenario/test_stamp_pattern.py
however it's not used. The patch removes that together with logging
import.
Change-Id: I01e634f7595247cddbf8e391281bfe7e045abeaa
test_qos_min_bw_allocation_basic usually execute in less than 60 secs,
so let's remove slow tag from it.
This patch removes the following config options from tempest-slow job:
* bridge_mappings and resource_provider_bandwidths from
neutron_core_plugin_conf
* qos_placement_physnet from network-feature-enabled in tempest.conf
Change-Id: I03c97edb9d7a177f5face046d1c9f60e4f1eeefa
The test_attach_scsi_disk_with_config_drive test cases is racy at volume
detach. Nova first detach the volume in cinder then later deletes the
BlockDeviceMapping from the nova DB. Test waits for the volume to become
available and then checks the list of volume attachments in the nova API
then it can see that the attachment is still there.
Closes-Bug: #1907084
Change-Id: I814ae3215f39d1e8407c4ca1c7117a314941c80b
New tests for MinBwAllocationPlacementTest: server resize and migration.
Blueprint: support-move-ops-with-qos-ports-ussuri
Change-Id: I8c573c4a11a76932057d8415d76114a03269b9f3
As a part of the scenario/manager.py stabilization tracked by
the below BP the patch adds kwargs argument for create_server_snapshot
method so that the consumers are able to pass additional
parameters if needed.
Implements: blueprint tempest-scenario-manager-stable
Change-Id: I0ae3f86c546be6b3f5b1d427568cfdf2d26e37e0
As a part of the scenario/manager.py stabilization tracked by
the below BP the patch adds kwargs argument to support
username parameter of get_remote_client() method.
Change-Id: I8e0da8b19b2b0b147b36c392fa4e161115325cd7
Implements: blueprint tempest-scenario-manager-stable
Both tests within this class create an instance and volume within the
same availability zone before shelving the instance. By default this
fully offloads the instance removing it from the availability zone.
If [cinder]/cross_az_attach is set to False within nova.conf this then
results in failures to attach volumes to the instance as they no longer
share the same availability zone.
To avoid this we now skip AttachVolumeShelveTestJSON based on the value
of [compute-feature-enabled]/compute_volume_common_az in tempest.conf
introduced by 979e494da2. This should be set if
cinder]/cross_az_attach is False within nova.conf ensuring that the resources
will be created in the same AZ.
Closes-Bug: #1889687
Change-Id: Ic51f6c7671bae2b241ada6d0c75fd9ea410eb73b
test_attach_scsi_disk_with_config_drive test
create the server via self.create_test_server which
delete the server at class level cleanup and created
image cleanup happen at test level so throw error.
We need to delete the server at test level cleanup and before
image.
This is required as when both Glance and Nova use a shared RBD backend
Nova will clone an instance disk directly from the Glance RBD volume.
This results in any attempt to delete the Glance image to fail while the
server is still provisioned as it still references the Glance RBD volume.
Closes-Bug: #1905725
Change-Id: I1aa6a161d3821470fe282914929ebdc93dd5e802
The implementation of method create_port() varies
between plugins and scenario manager.
This patch addresses the same requirement to make
scenario_manager stable
Implements: blueprint tempest-scenario-manager-stable
Signed-off by: Soniya Vyas<svyas@redhat.com>
Change-Id: Ia743c3a93a0b8e9ffe995db8046047b6e87458c1
Tempest plugins do use associate_floating_ip() and
disassociate_floating_ip() api but scenario-
manager doesn't implement it.
The plugins using these apis are manila-tempest-
plugin, tap, vmware-nsx and neutron-tempest-plugin.
Hence, added it to the scenario manager
Implements: blueprint tempest-scenario-manager-stable
Signed-off by: Soniya Vyas<svyas@redhat.com>
Change-Id: I41792bdc3478f5f290a6b3b7172ef3f6b4c62c19