Routres: attaching a router to a external network without a subnet leads to exceptions

Bug #1543012 reported by Gary Kotton
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
High
Gary Kotton
vmware-nsx
Fix Released
Undecided
Unassigned

Bug Description

2016-01-29 06:45:03.920 18776 ERROR neutron.api.v2.resource [req-c2074082-a6d0-4e5a-8657-41fecb82dacc ] add_router_interface failed
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource Traceback (most recent call last):
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/lib/python2.7/dist-packages/neutron/api/v2/resource.py", line 83, in resource
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource result = method(request=request, **args)
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/lib/python2.7/dist-packages/neutron/api/v2/base.py", line 207, in _handle_action
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource return getattr(self._plugin, name)(*arg_list, **kwargs)
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/vmware_nsx/neutron/plugins/vmware/plugins/nsx_v.py", line 1672, in add_router_interface
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource context, router_id, interface_info)
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/vmware_nsx/neutron/plugins/vmware/plugins/nsx_v_drivers/shared_router_driver.py", line 723, in add_router_interface
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource context, router_id, router_db.admin_state_up)
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/vmware_nsx/neutron/plugins/vmware/plugins/nsx_v_drivers/shared_router_driver.py", line 468, in _bind_router_on_available_edge
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource self._get_available_and_conflicting_ids(context, router_id))
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource File "/usr/local/lib/python2.7/dist-packages/vmware_nsx/neutron/plugins/vmware/plugins/nsx_v_drivers/shared_router_driver.py", line 273, in _get_available_and_conflicting_ids
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource gwp['fixed_ips'][0]['subnet_id'])
2016-01-29 06:45:03.920 18776 TRACE neutron.api.v2.resource IndexError: list index out of range

Tags: l3-ipam-dhcp
Gary Kotton (garyk)
tags: added: l3-ipam-dhcp
Changed in neutron:
assignee: nobody → Gary Kotton (garyk)
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/277307

Changed in neutron:
status: New → In Progress
Changed in neutron:
importance: Undecided → Medium
Gary Kotton (garyk)
Changed in neutron:
importance: Medium → High
Revision history for this message
Armando Migliaccio (armando-migliaccio) wrote :

Is this really a Neutron bug? The stacktrace seems to lead to a plugin-specific trace. Can you repro elsewhere?

Changed in vmware-nsx:
status: New → Confirmed
status: Confirmed → In Progress
Revision history for this message
Armando Migliaccio (armando-migliaccio) wrote :
Changed in neutron:
milestone: none → mitaka-3
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

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

commit 31aed09c1b4540b3f9ab26473a1b39ea1d144698
Author: Gary Kotton <email address hidden>
Date: Mon Feb 8 00:03:51 2016 -0800

    L3: enable plugin to decide if subnet is mandatory

    Commit 07077bebb69da29994257d061d3a8d7ea9598c3d removed
    enforcing that a subnet should be defined on a network. In
    the case of IPv6 this is cool, but for V4 it is problematic.

    The patch adds in a callback that enables the plugin to
    determine validation policy.

    The callback will be invoked prior to creating the gateway
    port.

    Closes-bug: #1543012

    Change-Id: Idb7eeb5e0071aa5a2f302fba083504c4582edc1a

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

Reviewed: https://review.openstack.org/277340
Committed: https://git.openstack.org/cgit/openstack/vmware-nsx/commit/?id=971f420657eb7fe716a2c68842954216bfe5060c
Submitter: Jenkins
Branch: master

commit 971f420657eb7fe716a2c68842954216bfe5060c
Author: Gary Kotton <email address hidden>
Date: Mon Feb 8 02:52:55 2016 -0800

    NSX|V: ensure that gateway network has a subnet

    Leverage neutron callbacks to validate that the network being
    attached to the router has a configured subnet.

    Change-Id: I9ab76ca698a093eab56498b23f533f34420b2dfa
    Closes-bug: #1543012
    Depends-on: 06af05e0a7fd0201e138dbbefce60432e51c0c71

Changed in vmware-nsx:
status: In Progress → Fix Released
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.