yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #09979
[Bug 1270724] Re: nicira: error occurs when net-gateway-connect with different segmentation-type
** Also affects: openstack-vmwareapi-team
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1270724
Title:
nicira: error occurs when net-gateway-connect with different
segmentation-type
Status in OpenStack Neutron (virtual network service):
Fix Committed
Status in The OpenStack VMwareAPI subTeam:
New
Bug description:
1. create net-gateway and gateway-connection. segmentation-type is vlan and
segmentation_id is 0.
neutron net-gateway-create --device id=c4369a1c-3fb2-4f45-8ac7-17d15b20508e,interface_name=eth0 NetworkgatewayName
neutron net-gateway-connect NetworkgatewayName L2-1 --segmentation-type vlan
openstack@devstack:~/devstack$ neutron net-gateway-show NetworkgatewayName
+-----------+--------------------------------------------------------------------------------------------------------+
| Field | Value |
+-----------+--------------------------------------------------------------------------------------------------------+
| default | False |
| devices | {"interface_name": "eth0", "id": "c4369a1c-3fb2-4f45-8ac7-17d15b20508e"} |
| id | ab76582b-ea57-4184-82ce-68ad013aed5e |
| name | NetworkgatewayName |
| ports | {"port_id": "2e8d5d83-d2a2-4570-815a-fe61d2257568", "segmentation_type": "vlan", "segmentation_id": 0} |
| tenant_id | ec2918c3e7514158987c8f04c64d7521 |
+-----------+--------------------------------------------------------------------------------------------------------+
2. add network to gateway by net-gateway-connect. segmentation-type is
flat.
openstack@devstack:~/devstack$ neutron net-gateway-connect NetworkgatewayName L2-2 --segmentation-type flat
Request Failed: internal server error while processing your request.
I think Neutron should not return 500.
=====
[Neutron server's log]
It seems conflict of segmentation-id because 0 is already used by
vlan.
2014-01-27 11:57:23.805 ERROR NeutronPlugin [-] Unable to create port or set port attachment in NVP.
2014-01-27 11:57:23.819 ERROR neutron.api.v2.resource [req-dbf0b9a0-0ef0-41b1-99e7-88532b07d90e admin 36a8929801cb48d4a02fcad90a93a090] connect_network failed
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource Traceback (most recent call last):
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/resource.py", line 84, in resource
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource result = method(request=request, **args)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/api/v2/base.py", line 191, in _handle_action
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource return getattr(self._plugin, name)(*arg_list, **kwargs)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NeutronPlugin.py", line 1980, in connect_network
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource context, network_gateway_id, network_mapping_info)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/dbexts/nicira_networkgw_db.py", line 316, in connect_network
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource network_mapping_info.get('segmentation_id')}})
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NeutronPlugin.py", line 1189, in create_port
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource self._delete_port(context, neutron_port_id)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource self.gen.next()
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NeutronPlugin.py", line 1173, in create_port
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource port_create_func(context, port_data)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NeutronPlugin.py", line 711, in _nvp_create_l2_gw_port
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource lport['uuid'])
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource self.gen.next()
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NeutronPlugin.py", line 705, in _nvp_create_l2_gw_port
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource int(port_data.get('gw:segmentation_id') or 0))
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/nvplib.py", line 1013, in plug_l2_gw_service
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource return _plug_interface(cluster, lswitch_id, lport_id, att_obj)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/nvplib.py", line 1003, in _plug_interface
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource cluster=cluster)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/nvplib.py", line 1058, in do_request
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource res = cluster.api_client.request(*args)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NvpApiClient.py", line 150, in request
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource self.error_codes[status](self, response)
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource File "/opt/stack/neutron/neutron/plugins/nicira/NvpApiClient.py", line 181, in fourZeroNine
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource raise Conflict()
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource Conflict: Request conflicts with configuration on a different entity.
2014-01-27 11:57:23.819 TRACE neutron.api.v2.resource
2014-01-27 11:57:23.852 INFO neutron.wsgi [req-dbf0b9a0-0ef0-41b1-99e7-88532b07d90e admin 36a8929801cb48d4a02fcad90a93a090] 172.23.51.99 - - [27/Jan/2014 11:57:23] "PUT /v2.0/network-gateways/6ece86bd-b4c9-4bfb-b198-e84c979a84b7/connect_network.json HTTP/1.1" 500 230 0.285504
[net-gatway-connect with vlan which segmentatin-id 0 causes 409]
devstack@devstack:~$ neutron net-gateway-connect --segmentation-type=vlan NetgatewayName L2-2
409-{u'NeutronError': {u'message': u"The specified mapping '{u'network_id': u'ea8d911b-c5ba-4daf-ae27-32415c0689a1', u'segmentation_id': 0, u'segmentation_type': u'vlan'}' is already in use on network gateway '6ece86bd-b4c9-4bfb-b198-e84c979a84b7'.", u'type': u'GatewayConnectionInUse', u'detail': u''}}
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1270724/+subscriptions
References