Rally test NeutronNetworks.create_and_update_subnets fails
Bug #1920923 reported by
Slawek Kaplonski
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
neutron |
Fix Released
|
High
|
Rodolfo Alonso |
Bug Description
It happens pretty often recently that test NeutronNetworks
Examples:
Changed in neutron: | |
assignee: | nobody → Rodolfo Alonso (rodolfo-alonso-hernandez) |
Changed in neutron: | |
status: | Confirmed → In Progress |
tags: | added: neutron-proactive-backport-potential |
Changed in neutron: | |
status: | In Progress → Fix Released |
To post a comment you must log in.
Hello:
As we can see in [1][2] (this is the best place where I found this error), the problem happens during the segment allocation ("allocate_ partially_ specified_ segment" ).
This method, if "network_ segment_ range" is not enabled (this is not the case in Rally tests), will retrieve a subset of non allocated segments and will try to allocate the first one returned.
This code has two problems:
- If we use only one segment, why do we retrieve so many? This is a possible optimization.
- A race condition between several requests. This is the main problem and that explains the issues seen in the Rally CI. If several queries are executed at the same time, all of them will return the same segment list and will compete to allocate the first one.
When a network is created without defining the segmentation ID (this is why we call "allocate_ partially_ specified_ segment" ), the segmentation ID assigned to this network could be any of the free ones. Nothing guarantees that the network will be allocated in the next free segmentation ID. If a specific segmentation ID is required, the user should provide it in the request.
My proposal will be to randomize this query and return on single non allocated segment.
Regards.
[1]https:/ /89a28d92de3b4c 8c3017- 1438e56e418f3d4 087dd94ee6330f7 d7.ssl. cf5.rackcdn. com/780916/ 3/check/ neutron- rally-task/ c316a5c/ results/ report. html#/NeutronNe tworks. create_ and_update_ subnets/ failures paste.openstack .org/show/ 803835/
[2]http://