[NEUTRON-43] Missing tenantID in NeutronPort for floatingIp port Created: 25/May/15 Updated: 19/Oct/17 Resolved: 22/Jun/15 |
|
| Status: | Resolved |
| Project: | neutron |
| Component/s: | External |
| Affects Version/s: | Multiple |
| Fix Version/s: | None |
| Type: | Bug | ||
| Reporter: | Martin Sunal | Assignee: | Unassigned |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Operating System: All |
||
| External issue ID: | 3368 |
| Description |
|
A neutron port created for floating IP does not contain tenant information. This is NeutronPort.toString() when method neutronPortCreated(NeutronPort port) is invoked on implementation of INeutronPortAware: ], deviceID=2cb9cff7-4ec0-4d8b-86b8-3bf0b8328fce, deviceOwner=network:floatingip, tenantID=, floatingIPMap={}, securityGroups=[], bindinghostID=, bindingvnicType=normal, bindingvnicType=normal] The same issue with NeutronPort passing to the method canCreatePort(NeutronPort port) |
| Comments |
| Comment by Ryan Moats [ 03/Jun/15 ] |
|
https://git.opendaylight.org/gerrit/21794 shows that this isn't a bug with NN but an issue in openstack/devstack (output from Jenkins build: 2015-06-03 16:52:32,054 | INFO | qtp736031520-81 | NeutronNetworkDummyProvider | 258 - org.opendaylight.neutron.dummyprovider - 0.5.0.SNAPSHOT | NeutronNetwork [networkUUID=4e8e5957-649f-477b-9e5b-f1f75b21c03c, networkName=net1, adminStateUp=true, shared=false, tenantID=9bacb3c5d39d41a79512987f338cf177, routerExternal=false, providerNetworkType=flat, providerPhysicalNetwork=null, providerSegmentationID=null, status=ACTIVE, subnets=[], myPorts=[], segments = [NeutronNetwork_Segment [ , providerNetworkType=vlan, providerPhysicalNetwork=8bab8453-1bc9-45af-8c70-f83aa9b50453, providerSegmentationID=2], NeutronNetwork_Segment [ , providerNetworkType=stt, providerPhysicalNetwork=8bab8453-1bc9-45af-8c70-f83aa9b50453, providerSegmentationID=null]]] ], deviceID=, deviceOwner=, tenantID=9bacb3c5d39d41a79512987f338cf177, floatingIPMap={}, securityGroups=[NeutronSecurityGroup{securityGroupUUID='null', securityGroupName='null', securityGroupDescription='null', securityGroupTenantID='null', securityRules=null]], bindinghostID=, bindingvnicType=normal, bindingvnicType=normal] |
| Comment by Ed Warnicke [ 07/Jun/15 ] |
|
I have chased this back... and here's what I've found. OpenDaylight is not getting tenant_id in this case because our ML2 OpenStack Driver is sending "tenant_id":"". Our ML2 Driver is sending "tenant_id":"" because that's what ML2 is sending to it. ML2 is sending "tenant_id":"" because the neutron cli commands are sending "tenant_id":"" to the OpenStack neutron NB. Which is to say, this looks like its either a bug in the neutron cli commands, or a problem with how they are being used (I honestly don't know which yet). |
| Comment by Ryan Moats [ 08/Jun/15 ] |
|
Reopening/Reassigning to external component for tracking |
| Comment by Flavio Fernandes [ 12/Jun/15 ] |
|
I would love to hear from a neutron (openstack) guru on this, but at the time the neutron port created for the floating ip is instantiated, it has no association with any tenants [1], yet. Once floating ip is created [2] is that tenant id info is available within Only when internal<->external ip association happens is that the mapping of See this email thread for more info on obtaining this data: https://lists.opendaylight.org/pipermail/neutron-dev/2015-June/000180.html === [1]: example of a neutron port create just before floating ip is created: POST /controller/nb/v2/neutron/ports/ ], === [2]: floating ip creation POST /controller/nb/v2/neutron/floatingips } === [3]: floating ip association PUT /controller/nb/v2/neutron/floatingips/f013bef4-9468-494d-9417-c9d9e4abb97c } |
| Comment by Ryan Moats [ 12/Jun/15 ] |
|
Wait... The port is scoped by the network - if the network is not shared, then by definition, the port must be in the same tenant as the network. |
| Comment by Flavio Fernandes [ 12/Jun/15 ] |
|
(In reply to Ryan Moats from comment #5) you are correct. In my poor example, this is not a shared network, in cases when net is shared, this is a bit harder. It is good to point All in all, we are in complete agreement that it should be possible to |
| Comment by Isaku Yamahata [ 13/Jun/15 ] |
|
tenant_id=''(empty string) is intentionally passed by neutron l3 code. https://bugs.launchpad.net/neutron/+bug/1464806 As near term work around, tenant_id can deduced from network object. |
| Comment by Isaku Yamahata [ 13/Jun/15 ] |
|
Supplement. Is this acceptable by ODL side? |
| Comment by Ryan Moats [ 15/Jun/15 ] |
|
No, an empty tenant ID is not acceptable, neutron northbound expects a valid tenant UUID in this field |
| Comment by Flavio Fernandes [ 19/Jun/15 ] |
|
With the merged done by Isaku [1], I suspect ODL will no longer get |
| Comment by Martin Sunal [ 22/Jun/15 ] |
|
A floating-ip port contains tenant-id after this commit https://review.openstack.org/#/c/191471/ |