rally job for monolithic plugin fails because of duplicate security groups

Bug #1671848 reported by Antonio Ojea
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
networking-midonet
Fix Released
Critical
YAMAMOTO Takashi

Bug Description

The rally jobs that are using the midonet monolithic plugin are failing because of duplicate security groups http://logs.openstack.org/58/443058/1/check/gate-networking-midonet-rally-dsvm-v2-ubuntu-xenial-nv/f7bfc01/rally-plot/results.html.gz#/NeutronNetworks.create_and_update_subnets/failures

Traceback (most recent call last):
  File "/opt/stack/new/rally/rally/task/runner.py", line 72, in _run_scenario_once
    getattr(scenario_inst, method_name)(**scenario_kwargs)
  File "/opt/stack/new/rally/rally/plugins/openstack/scenarios/neutron/network.py", line 95, in run
    network = self._create_network(network_create_args or {})
  File "/opt/stack/new/rally/rally/task/atomic.py", line 84, in func_atomic_actions
    f = func(self, *args, **kwargs)
  File "/opt/stack/new/rally/rally/plugins/openstack/scenarios/neutron/utils.py", line 84, in _create_network
    {"network": network_create_args})
  File "/usr/local/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 786, in create_network
    return self.post(self.networks_path, body=body)
  File "/usr/local/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 366, in post
    headers=headers, params=params)
  File "/usr/local/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 301, in do_request
    self._handle_fault_response(status_code, replybody, resp)
  File "/usr/local/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 276, in _handle_fault_response
    exception_handler_v20(status_code, error_body)
  File "/usr/local/lib/python2.7/dist-packages/neutronclient/v2_0/client.py", line 92, in exception_handler_v20
    request_ids=request_ids)
Conflict: {"message":"A(n) SecurityGroup with ID 2ab3dafa-5627-4d49-a40b-ffe995717e03 already exists.","code":409}
Neutron server returns request_ids: ['req-cd341254-4137-4244-a1aa-f50309f412cc']`

However, the rally jobs with ml2 plugin doesn't have this issues

Revision history for this message
YAMAMOTO Takashi (yamamoto) wrote :

i think it was fixed by recent commits

Changed in networking-midonet:
status: New → Incomplete
Revision history for this message
YAMAMOTO Takashi (yamamoto) wrote :
Changed in networking-midonet:
status: Incomplete → Confirmed
Changed in networking-midonet:
importance: Undecided → Critical
assignee: nobody → YAMAMOTO Takashi (yamamoto)
milestone: none → 5.0.0
status: Confirmed → In Progress
Revision history for this message
YAMAMOTO Takashi (yamamoto) wrote :

the recent version of securitygroups_db.py create_security_group just returns the existing default security group. plugin v2 create_security_group should not send it to midonet api.

Iaa83c8664d5bfde31fdcdd694f6f18d9ef9bf14a

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to networking-midonet (master)

Fix proposed to branch: master
Review: https://review.openstack.org/463528

tags: added: ocata-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-midonet (master)

Reviewed: https://review.openstack.org/463528
Committed: https://git.openstack.org/cgit/openstack/networking-midonet/commit/?id=708f97aba8500336488622f30725acbc5b7cde7c
Submitter: Jenkins
Branch: master

commit 708f97aba8500336488622f30725acbc5b7cde7c
Author: YAMAMOTO Takashi <email address hidden>
Date: Tue May 9 20:23:18 2017 +0900

    v2: Replace security group implementation with ML2 version

    The recent Neutron change [1] introduced a race in our
    v2 plugin for the default security group creation.
    Instead of trying to adapt the v2 plugin code,
    just switch the implementation to the one in our ML2 driver.

    Note: This breaks the task-based client because the
    implementation doesn't call the client precommit methods.

    [1] Iaa83c8664d5bfde31fdcdd694f6f18d9ef9bf14a

    Closes-Bug: #1671848
    Change-Id: I17262ecca2b8e2c29fdf2a90e01fc668cf2ca6a4

Changed in networking-midonet:
status: In Progress → Fix Released
tags: added: midokura-jira-tracked
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to networking-midonet (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/467709

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to networking-midonet (stable/ocata)

Reviewed: https://review.openstack.org/467709
Committed: https://git.openstack.org/cgit/openstack/networking-midonet/commit/?id=efedc9ec7322500e9f02ffbe4eb55b0078f90d44
Submitter: Jenkins
Branch: stable/ocata

commit efedc9ec7322500e9f02ffbe4eb55b0078f90d44
Author: YAMAMOTO Takashi <email address hidden>
Date: Tue May 9 20:23:18 2017 +0900

    v2: Replace security group implementation with ML2 version

    The recent Neutron change [1] introduced a race in our
    v2 plugin for the default security group creation.
    Instead of trying to adapt the v2 plugin code,
    just switch the implementation to the one in our ML2 driver.

    Note: This breaks the task-based client because the
    implementation doesn't call the client precommit methods.

    [1] Iaa83c8664d5bfde31fdcdd694f6f18d9ef9bf14a

    Closes-Bug: #1671848
    Change-Id: I17262ecca2b8e2c29fdf2a90e01fc668cf2ca6a4
    (cherry picked from commit 708f97aba8500336488622f30725acbc5b7cde7c)
    Conflicts:
     midonet/neutron/plugin_v2.py

tags: added: in-stable-ocata
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/networking-midonet 5.0.0.0b2

This issue was fixed in the openstack/networking-midonet 5.0.0.0b2 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/networking-midonet 4.1.0

This issue was fixed in the openstack/networking-midonet 4.1.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.