Distributed Router Gateway Clear does not delete the CSNAT Interface Ports for that router.

Bug #1350089 reported by Swaminathan Vasudevan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Undecided
Swaminathan Vasudevan

Bug Description

When Distributed Routers are created with Interface Ports and after a Gateway is set to the router, the plugin will create the "csnat" interface ports with "device_owner" as "router_csnat_interface".

These ports should be deleted when the Gateway is cleared or when the interfaces are removed from the particular router.

In the current plugin code, these "interface" ports are not deleted when a Gateway is cleared. But the ports are deleted when the "router interfaces are removed".

This needs to be fixed.

Since we don't clean up the ports there may be an odd chance of having unused ports in the "Service-node".

Changed in neutron:
assignee: nobody → Swaminathan Vasudevan (swaminathan-vasudevan)
status: New → Confirmed
Revision history for this message
Swaminathan Vasudevan (swaminathan-vasudevan) wrote :

The "csnat" ports are deleted but immediately re-created with a different id.
So it goes through the _delete_gw_port and then immediately goes through the _create_gw_port. That is the reason that it is creating a new port again.

The current check in there is not valid and so need to be fixed.

tags: added: l3-dvr-backlog
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

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

Changed in neutron:
status: Confirmed → In Progress
Revision history for this message
Swaminathan Vasudevan (swaminathan-vasudevan) wrote :

Fixed in the patch shown below.

https://review.openstack.org/#/c/110526/

Changed in neutron:
status: In Progress → Fix Committed
Revision history for this message
Armando Migliaccio (armando-migliaccio) wrote :

This won't be committed until it merges

Changed in neutron:
status: Fix Committed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/110526
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=86a0adefe326116ae42c0e01a8fa2c2849bfa2c2
Submitter: Jenkins
Branch: master

commit 86a0adefe326116ae42c0e01a8fa2c2849bfa2c2
Author: Swaminathan Vasudevan <email address hidden>
Date: Tue Jul 29 16:34:58 2014 -0700

    Fix-DVR Gateway clear doesn't delete csnat port

    When a gateway is set to a distributed router,
    the router checks for the interfaces associated
    with the router and based on the number of
    interfaces the router creates "csnat" interface
    ports that would be used by the SNAT service in
    the Service Node.

    When a gateway is cleared, the plugin should
    delete the "csnat" interface ports. In the
    current code, it is deleting the port and
    re-creating the port with a different id.

    A check need to be made before it creates a new
    port to make sure that the router has a valid
    gateway port.

    This is a bug and this patch fixes this issue.

    Change-Id: I84f1795360b3693a025b5fa3454bf9efc7e503ae
    Closes-Bug: #1350089

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