Deleting a subnet does not remove its id from loadbalancers

Bug #1413817 reported by Rob Cresswell
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
John Schwarz

Bug Description

Attach a subnet to a loadbalancer, then delete the subnet. The subnet is removed successfully, but the loadbalancer keeps the subnet_id field filled with the previous value.

Changed in neutron:
assignee: nobody → venkata anil (anil-venkata)
Revision history for this message
Eugene Nikanorov (enikanorov) wrote :

The delete operation should not be possible in case subnet is in use by lbaas

tags: added: api lbaas
Changed in neutron:
importance: Undecided → Medium
status: New → Confirmed
Revision history for this message
John Schwarz (jschwarz) wrote :

Venaka, is there any progress with this bug fix?

Changed in neutron:
assignee: venkata anil (anil-venkata) → nobody
John Schwarz (jschwarz)
Changed in neutron:
assignee: nobody → John Schwarz (jschwarz)
Revision history for this message
John Schwarz (jschwarz) wrote :

It would seem that deleting a subnet should not be possible if it has a pool associated to it. First the pool must be explicitly deleted, and only then should the subnet be deleted.

By the way, this caused (in Juno) an horizon error page when trying to open the pool's page (since it tries to display the subnet's details). It has been addressed by https://review.openstack.org/#/c/147790/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/174268

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

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

Changed in neutron:
status: Confirmed → In Progress
Kyle Mestery (mestery)
Changed in neutron:
milestone: none → liberty-1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/180147

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron-lbaas (master)

Change abandoned by Kyle Mestery (<email address hidden>) on branch: master
Review: https://review.openstack.org/174384
Reason: This review is > 4 weeks without comment, and failed Jenkins the last time it was checked. We are abandoning this for now. Feel free to reactivate the review by pressing the restore button and leaving a 'recheck' comment to get fresh test results.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (master)

Change abandoned by senthilmageswaran (<email address hidden>) on branch: master
Review: https://review.openstack.org/180147
Reason: This change should be abandoned. The rebase is mistakenly given.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to neutron (master)

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

commit 5f28762ae2a96b8062628d0cac81f5da94c6ed34
Author: John Schwarz <email address hidden>
Date: Thu Apr 16 12:01:26 2015 +0300

    Add callback prior to deleting a subnet

    When using LBaaS and trying to delete a subnet, neutron has no way of
    knowing if the subnet is associated to some pool. As a result, the
    subnet is deleted but the pool remains associated to the (now
    nonexistent) subnet_id. This patch lays the ground-work for adding a
    check in LBaaS' side to prevent such cases.

    Related-Bug: #1413817
    Change-Id: I3d5e231b67c72ffd919c92d65b57da56c63e053c

Thierry Carrez (ttx)
Changed in neutron:
milestone: liberty-1 → liberty-2
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron (feature/pecan)

Related fix proposed to branch: feature/pecan
Review: https://review.openstack.org/196701

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (feature/pecan)

Change abandoned by Kyle Mestery (<email address hidden>) on branch: feature/pecan
Review: https://review.openstack.org/196701
Reason: This is lacking the functional fix [1], so I'll propose a new merge commit which includes that one.

[1] https://review.openstack.org/#/c/196711/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron (feature/pecan)

Related fix proposed to branch: feature/pecan
Review: https://review.openstack.org/196920

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to neutron (feature/pecan)
Download full text (171.5 KiB)

Reviewed: https://review.openstack.org/196920
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=7f759c077f8f860c13db92d2ea6b353ef6b70900
Submitter: Jenkins
Branch: feature/pecan

commit 8123144fadd7c5d5e6e56a76ea860512619a2cf6
Author: Moshe Levi <email address hidden>
Date: Sun Jun 28 14:37:14 2015 +0300

    Fix Consolidate sriov agent and driver code

    This patch add mising __init to mech_sriov/mech_driver/
    and update the setup.cfg to the new agent entrypoint

    Trivial Fix

    Change-Id: I53a527081feb78472f496675bbb3c5121d38a14a

commit 8942fccf02e6e179d47582fdb2792a1ca972da21
Author: Assaf Muller <email address hidden>
Date: Mon Jun 29 11:38:51 2015 -0400

    Remove failing SafeFixture tests

    The fixtures 1.3 release attempted to fix the fixtures resource
    leak issue, but failed to do so completely. Our own SafeFixture
    is still needed: The 1.3 release broke our SafeFixture tests,
    but not the usage of SafeFixture itself. This patch removes
    those failing tests for now to unbreak the gate. Jakub reported
    a bug on fixtures 1.3:
    https://bugs.launchpad.net/python-fixtures/+bug/1469759

    We will continue to use SafeFixture until that bug is fixed
    in fixtures, at which point we will be able to require
    fixtures > 1.3.

    Change-Id: I59457c3bb198ff86d5ad55a1e623d008f0034b8f
    Closes-Bug: #1469734

commit 71dffb0a2c1720cd8233a329d32958a0160dd6f5
Author: Kevin Benton <email address hidden>
Date: Mon Jun 29 08:27:41 2015 +0000

    Revert "Removed test_lib module"

    This reverts commit 9a6536de6e1a7fe9b2552adc142e254426b82b6f.

    We pulled all of the plugins out of the tree, many of which still inherit
    from neutron test classes. This change then stated that we no longer
    support testing other plugins. I think this is a bit premature and should
    have been discussed under the subject
    "Neutron plugins can't use neutron plugin unit tests" or something
    similar.

    Change-Id: I68318589f010b731574ea3bfa8df98492bab31fc

commit b20fd81dbd497e058384a0af065dd0f1fdc4c728
Author: Jakub Libosvar <email address hidden>
Date: Fri Jun 5 14:32:51 2015 +0000

    Refactor NetcatTester class

    Following capabilities were added:
       - used transport protocol is passed as a constant instead of bool
       - src port for testing was added
       - connection can be established explicitly
       - change constructor parameters of NetcatTester

    As a part of removing bool for protocol definition
    get_free_namespace_port() was also modified to match the behavior.

    Change-Id: Id2ec322e7f731c05a3754a65411c9a5d8b258126

commit 83e37980dcd0b2bad6d64dd2cb23bcd2891cafca
Author: jingliuqing <email address hidden>
Date: Sat Jun 27 13:41:54 2015 +0800

    Use REST rather than ReST

    Change-Id: I06c9deaab58c5ec13bfeec39fb8fd4b1fe21f42d

commit 1b60df85ba3ad442c2e4e7e52538e1b9a1bf9378
Author: Kevin Benton <email address hidden>
Date: Thu Jun 25 18:34:38 2015 -0700

    Add a double-mock guard to the base test case

    Use mock to patch mock with a check to prevent multiple active
    patches to the...

tags: added: in-feature-pecan
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (master)

Change abandoned by Kyle Mestery (<email address hidden>) on branch: master
Review: https://review.openstack.org/180147
Reason: This review is > 4 weeks without comment, and failed Jenkins the last time it was checked. We are abandoning this for now. Feel free to reactivate the review by pressing the restore button and leaving a 'recheck' comment to get fresh test results.

Thierry Carrez (ttx)
Changed in neutron:
milestone: liberty-2 → liberty-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron-lbaas (master)

Reviewed: https://review.openstack.org/174384
Committed: https://git.openstack.org/cgit/openstack/neutron-lbaas/commit/?id=a3a35ff36f60b5bfb04f3bb16523b9031e9ded2f
Submitter: Jenkins
Branch: master

commit a3a35ff36f60b5bfb04f3bb16523b9031e9ded2f
Author: John Schwarz <email address hidden>
Date: Thu Apr 16 14:08:07 2015 +0300

    Prevent deletion of a subnet with lbaas v1 pool

    When using LBaaS and trying to delete a subnet, neutron has no way of
    knowing if the subnet is associated to some pool. As a result, the
    subnet is deleted but the pool remains associated to the (now
    nonexistent) subnet_id. This patch adds a check in LBaaS side to
    prevent such a case, using the callbacks system.

    Closes-Bug: #1413817
    Change-Id: I1a8893453b0b623df792fdabcf540163007a3f33
    Depends-on: I3d5e231b67c72ffd919c92d65b57da56c63e053c

Changed in neutron:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in neutron:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in neutron:
milestone: liberty-3 → 7.0.0
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.