Hi,
I have taken a closer look and the fact that the attachment ID exists on the agent is great. The gateway ID is not there. I spent some time investigating this and if the following changes were made top the nova code then the gateway ID would also exist (and it will certainly be a lot healthier for future developments).

1. /opt/stack/nova/nova/network/quantum/manager.py
    def enable_dhcp(self, context, quantum_net_id, network_ref, vif_rec,
            project_id):
    ...
       self.q_conn.create_and_attach_port(q_tenant_id,
                       quantum_net_id, network_ref['uuid'])

The problem here is that this does not work for the linux bridge plugin (not sure about UCS and RYU). Is there anyway of identifying which Quantum plugin is running at runtime on Nova? If so then I can add the fix and it will work for OVS. Please advise.

2. /opt/stack/nova/nova/network/linux_net.py
class LinuxOVSInterfaceDriver(LinuxNetInterfaceDriver):

    def plug(self, network, mac_address, gateway=True):
...
            _execute('ovs-vsctl',
                     '--', '--may-exist', 'add-port', bridge, dev,
                     '--', 'set', 'Interface', dev, 'type=internal',
                     '--', 'set', 'Interface', dev,
                     'external-ids:iface-id=%s' % network['uuid'],
                     '--', 'set', 'Interface', dev,
                     'external-ids:iface-status=active',
                     '--', 'set', 'Interface', dev,
                     'external-ids:attached-mac=%s' % mac_address,
                     run_as_root=True)

Thanks
Gary

On 05/22/2012 09:23 AM, Gary Kotton wrote:
Thanks

On 05/21/2012 11:30 PM, Dan Wendlandt wrote:
Just looking at it now. I'd really caution against having generic calls like "device_added", since the set of things that may need to be fetched when a device appears will likely increase significantly in the future, even if Folsom-2 (things like security groups, QoS settings, etc.). I'd rather have specific calls that have a well-defined schema that we think will be reasonably stable over time. In Nova we've had very bad experiences with RPCs that just pass large dictionaries of data around, where the "schema" of that dictionary grows organically over time is and is not really documented anywhere.
Good point. I'll address this

Also, at least for the OVS plugin, I'd like to avoid using the device name as the key that is sent back. The OVS agent already knows the attachment-id, so there's no need to pollute the code with the device name.
Great - if the information is there then it will be used :)

Thanks,

Dan


    Thanks
    Gary




--
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Dan Wendlandt
Nicira, Inc: www.nicira.com <http://www.nicira.com>
twitter: danwendlandt
~~~~~~~~~~~~~~~~~~~~~~~~~~~



-- 
Mailing list: https://launchpad.net/~netstack
Post to     : netstack@lists.launchpad.net
Unsubscribe : https://launchpad.net/~netstack
More help   : https://help.launchpad.net/ListHelp

Reply via email to