Create router with external network attached doesn't notify l3 agent

Bug #1535707 reported by Masco
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
OpenStack Dashboard (Horizon)
Fix Released
High
Masco
neutron
Fix Released
High
Andreas Scheuring

Bug Description

Description of problem:
======================
When creating a router with an external network attached, the q-l3 agent does not get triggered.

Steps to Reproduce via GUI:
==========================
1. Go to Project-> Network -> Routers
2. Click Create Router
3. Input name, Admin state UP and select an External Network from the list

Steps to Reproduce via CLI:
# neutron router-create router4 --external_gateway_info type=dict network_id=<ext-network-id>

Actual results:
==============
Router gets created but no router namespace gets created on the controller. The q-l3 is not getting triggered.

There's no entry in the "routerl3agentbindings" table
mysql: select * from routerl3agentbindings

Deleting the port from the router using neutron port-delete results in a DB error
"DBError: (IntegrityError) (1451, 'Cannot delete or update a pare
nt row: a foreign key constraint fails (`neutron`.`routers`, CONSTRAINT `routers_ibfk_1` FOREIGN KEY (`gw_port_id`) REFERENC
ES `ports` (`id`))') 'DELETE FROM ports WHERE ports.id = %s' ('76573418-f9ff-4f2d-8ffb-d0a200f7f1ea',)"

--> More details see duplicate bug!

Expected results:
=================
Router namespace gets created on the controller with an IP assigned from the selected external network.

The l3 agent get's triggered

Deletion of the port should fail with
"Port cd885903-ca26-445e-848b-a65dc4a0811c cannot be deleted directly via the port API: has device owner network:router_gateway."

Additional info:
===============
If I don't select the external network in the Create Router form when I create it and attach it to the external network afterwards by using the set gateway button then everything is ok.

Masco (masco)
Changed in horizon:
assignee: nobody → Masco (masco)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to horizon (master)

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

Changed in horizon:
status: New → In Progress
Revision history for this message
Akihiro Motoki (amotoki) wrote : Re: Create router with external network attached doesn't create router namespace

It is found in Horizon, but it is actually a neutron bug.

I created a router with external_gateway_info, but the router created did not appear on a network node.
The detail step on a single node with devstack is found at: http://paste.openstack.org/show/484507/

Changed in horizon:
importance: Undecided → High
Changed in neutron:
importance: Undecided → Medium
status: New → Confirmed
tags: added: l3-ipam-dhcp neutron
Changed in neutron:
assignee: nobody → venkata anil (anil-venkata)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to horizon (master)

Reviewed: https://review.openstack.org/269605
Committed: https://git.openstack.org/cgit/openstack/horizon/commit/?id=7334c3cfee12a81657296fa0e90c7d25457de9f6
Submitter: Jenkins
Branch: master

commit 7334c3cfee12a81657296fa0e90c7d25457de9f6
Author: Masco Kaliyamoorthy <email address hidden>
Date: Tue Jan 19 18:21:33 2016 +0530

    Router namespace not created in controller

    When creating a router with an external network attached
    from the Create Router form a router namespace doesn't
    get created on the controller.

    By calling the correct APIs, the namespace get
    created.

    To check the namespace list run the below command
    on controller node.
    'sudo ip netns list'

    Change-Id: I829c707353830ff808b6f6a0b29ccedeca588616
    Closes-Bug: #1535707

Changed in horizon:
status: In Progress → Fix Released
Matthias Runge (mrunge)
Changed in horizon:
milestone: none → mitaka-3
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/horizon 9.0.0.0b3

This issue was fixed in the openstack/horizon 9.0.0.0b3 development milestone.

summary: - Create router with external network attached doesn't create router
- namespace
+ Create router with external network attached doesn't notify l3 agent
description: updated
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/290470

Changed in neutron:
assignee: venkata anil (anil-venkata) → Andreas Scheuring (andreas-scheuring)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

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

commit da00d1a186c55c91887c9546e893f6d075a2c2ad
Author: Andreas Scheuring <email address hidden>
Date: Wed Mar 9 13:56:22 2016 +0100

    l3: Send notify on router_create when ext gw is specified

    A router that got created with an external gateway specified now
    triggers a notfiy_router_updated event. This triggers scheduling
    of the router and creation of the network namespace on the target
    node.

    Change-Id: I7f6ff5edf6a9c5ffa6d8978c1f3de0e106b6a8bb
    Closes-Bug: #1535707

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/298813

Changed in neutron:
importance: Medium → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/mitaka)

Reviewed: https://review.openstack.org/298813
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=ef6ea62d5d1fc767a23e3caf2716e76f90d63f03
Submitter: Jenkins
Branch: stable/mitaka

commit ef6ea62d5d1fc767a23e3caf2716e76f90d63f03
Author: Andreas Scheuring <email address hidden>
Date: Wed Mar 9 13:56:22 2016 +0100

    l3: Send notify on router_create when ext gw is specified

    A router that got created with an external gateway specified now
    triggers a notfiy_router_updated event. This triggers scheduling
    of the router and creation of the network namespace on the target
    node.

    Change-Id: I7f6ff5edf6a9c5ffa6d8978c1f3de0e106b6a8bb
    Closes-Bug: #1535707
    (cherry picked from commit da00d1a186c55c91887c9546e893f6d075a2c2ad)

tags: added: in-stable-mitaka
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/neutron 8.1.0

This issue was fixed in the openstack/neutron 8.1.0 release.

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/314250

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)
Download full text (36.9 KiB)

Reviewed: https://review.openstack.org/314250
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=3bf73801df169de40d365e6240e045266392ca63
Submitter: Jenkins
Branch: master

commit a323769143001d67fd1b3b4ba294e59accd09e0e
Author: Ryan Moats <email address hidden>
Date: Tue Oct 20 15:51:37 2015 +0000

    Revert "Improve performance of ensure_namespace"

    This reverts commit 81823e86328e62850a89aef9f0b609bfc0a6dacd.

    Unneeded optimization: this commit only improves execution
    time on the order of milliseconds, which is less than 1% of
    the total router update execution time at the network node.

    This also

    Closes-bug: #1574881

    Change-Id: Icbcdf4725ba7d2e743bb6761c9799ae436bd953b

commit 7fcf0253246832300f13b0aa4cea397215700572
Author: OpenStack Proposal Bot <email address hidden>
Date: Thu Apr 21 07:05:16 2016 +0000

    Imported Translations from Zanata

    For more information about this automatic import see:
    https://wiki.openstack.org/wiki/Translations/Infrastructure

    Change-Id: I9e930750dde85a9beb0b6f85eeea8a0962d3e020

commit 643b4431606421b09d05eb0ccde130adbf88df64
Author: OpenStack Proposal Bot <email address hidden>
Date: Tue Apr 19 06:52:48 2016 +0000

    Imported Translations from Zanata

    For more information about this automatic import see:
    https://wiki.openstack.org/wiki/Translations/Infrastructure

    Change-Id: I52d7460b3265b5460b9089e1cc58624640dc7230

commit 1ffea42ccdc14b7a6162c1895bd8f2aae48d5dae
Author: OpenStack Proposal Bot <email address hidden>
Date: Mon Apr 18 15:03:30 2016 +0000

    Updated from global requirements

    Change-Id: Icb27945b3f222af1d9ab2b62bf2169d82b6ae26c

commit b970ed5bdac60c0fa227f2fddaa9b842ba4f51a7
Author: Kevin Benton <email address hidden>
Date: Fri Apr 8 17:52:14 2016 -0700

    Clear DVR MAC on last agent deletion from host

    Once all agents are deleted from a host, the DVR MAC generated
    for that host should be deleted as well to prevent a buildup of
    pointless flows generated in the OVS agent for hosts that don't
    exist.

    Closes-Bug: #1568206
    Change-Id: I51e736aa0431980a595ecf810f148ca62d990d20
    (cherry picked from commit 92527c2de2afaf4862fddc101143e4d02858924d)

commit eee9e58ed258a48c69effef121f55fdaa5b68bd6
Author: Mike Bayer <email address hidden>
Date: Tue Feb 9 13:10:57 2016 -0500

    Add an option for WSGI pool size

    Neutron currently hardcodes the number of
    greenlets used to process requests in a process to 1000.
    As detailed in
    http://lists.openstack.org/pipermail/openstack-dev/2015-December/082717.html

    this can cause requests to wait within one process
    for available database connection while other processes
    remain available.

    By adding a wsgi_default_pool_size option functionally
    identical to that of Nova, we can lower the number of
    greenlets per process to be more in line with a typical
    max database connection pool size.

    DocImpact: a previously unused configuration value
               wsgi_default_pool_size is now used to a...

tags: added: neutron-proactive-backport-potential
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/neutron 9.0.0.0b1

This issue was fixed in the openstack/neutron 9.0.0.0b1 development milestone.

tags: removed: neutron-proactive-backport-potential
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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