Port does not revert device_owner to previous value in concurrent requests case

Bug #1621750 reported by Anh Tran
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
Anh Tran

Bug Description

From this patch: https://review.openstack.org/#/c/341427/
Sometimes, port doesn't revert device_owner to previous value in concurrent requests case.

$ neutron port-create --name port1 net1 | Overlapped CIDR
$ neutron port-create --name port2 net2 |

mysql> select name, device_id, device_owner from ports;
+-------+-------------------------------------------------------------------------------+--------------------------+
| name--| device_id ------------------------------------------------------------------- | device_owner ----------- |
+-------+-------------------------------------------------------------------------------+--------------------------+
| port1 | ----------------------------------------------------------------------------- | ------------------------ |
| port2 | ----------------------------------------------------------------------------- | ------------------------ |
+-------+-------------------------------------------------------------------------------+--------------------------+

$ neutron router-interface-add router-test port=port1 & neutron router-interface-add router-test port=port2

Added interface 68c26144-4ae5-4316-a631-93d5e3a44fd8 to router router-test.
Bad router request: Cidr 192.166.0.0/16 of subnet 87d56713-e6f0-47ee-918d-759cb69b372d overlaps with cidr 192.166.100.0/24 of subnet 94cdfe4c-0e8e-40af-93fe-e8dcc2cb7484.

WE EXPECTED IN DATABASE:
mysql> select name, device_id, device_owner from ports;
+-------+-------------------------------------------------------------------------------+--------------------------+
| name--| device_id-------------------------------------------------------------------- | device_owner ----------- |
+-------+-------------------------------------------------------------------------------+--------------------------+
| port1 | f872184e-031e-43ae-9bc7-e1f05137e09e ---------------------------------------- | network:router_interface |
| port2 | ----------------------------------------------------------------------------- | ------------------------ |
+-------+-------------------------------------------------------------------------------+--------------------------+

BUT, CURRENT RESULT HERE:
mysql> select name, device_id, device_owner from ports;
+-------+-------------------------------------------------------------------------------+--------------------------+
| name--| device_id ------------------------------------------------------------------- | device_owner ----------- |
+-------+-------------------------------------------------------------------------------+--------------------------+
| port1 | f872184e-031e-43ae-9bc7-e1f05137e09e ---------------------------------------- | network:router_interface |
| port2 | ----------------------------------------------------------------------------- | network:router_interface |
+-------+-------------------------------------------------------------------------------+--------------------------+

Changed in neutron:
assignee: nobody → Anh Tran (trananhkma)
status: New → In Progress
John Schwarz (jschwarz)
Changed in neutron:
importance: Undecided → Medium
Revision history for this message
Anh Tran (trananhkma) wrote :
Changed in neutron:
milestone: none → newton-rc1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/367744
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=5f9d8887076edaf3eef132e914766ba5e7136468
Submitter: Jenkins
Branch: master

commit 5f9d8887076edaf3eef132e914766ba5e7136468
Author: Anh Tran <email address hidden>
Date: Fri Sep 9 11:18:18 2016 +0700

    Fix Rollback port's device_owner

    From this patch: https://review.openstack.org/#/c/341427/
    Sometimes, port doesn't revert device_owner to previous value
    in concurrent requests case.

    This patch fixes this problem and adds unit test.

    Change-Id: I864a559f0316e164caa065abd75c44fae971b571
    Closes-Bug: #1621750

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 9.0.0.0rc1

This issue was fixed in the openstack/neutron 9.0.0.0rc1 release candidate.

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.