[openstack-dev] [neutron] [nova] [os-vif] OVS plugin assumes an incorrect datapath_type in os-vif

Alonso Hernandez, Rodolfo rodolfo.alonso.hernandez at intel.com
Tue Jun 20 16:16:51 UTC 2017


Hello fellows:

Currently there is a bug in os-vif [1<https://bugs.launchpad.net/os-vif/+bug/1632372>]. When os-vif tries to plug an OVS interface, the datapath type is hardcoded:

-          https://github.com/openstack/os-vif/blob/9fb7fe512902a37432e38d884b8be59ce91582db/vif_plug_ovs/ovs.py#L100-L101

-          https://github.com/openstack/os-vif/blob/9fb7fe512902a37432e38d884b8be59ce91582db/vif_plug_ovs/ovs.py#L127-L128

-          https://github.com/openstack/os-vif/blob/9fb7fe512902a37432e38d884b8be59ce91582db/vif_plug_ovs/ovs.py#L135-L136

-          https://github.com/openstack/os-vif/blob/9fb7fe512902a37432e38d884b8be59ce91582db/vif_plug_ovs/ovs.py#L149-L150

The problem is os-vif doesn’t have this information now. I’m proposing the following solution:

-          Nova: https://review.openstack.org/#/c/474892/

-          Neutron: https://review.openstack.org/#/c/474588/

-          Neutron-lib: https://review.openstack.org/#/c/474248/

-          os-vif: https://review.openstack.org/#/c/474914/

Neutron will add to VIF details the datapath type to the vif details dict. If this information is not given in the config file, the default parameter written will be OVS_DATAPATH_SYSTEM, which is the default value. The change in neutron-lib is needed for Neutron to keep the same dict key name (matching the name set in nova.network.model)

1)

2)      Nova will receive this information (if given in the dict), getting the value stored in vif['details']. If the key is not set, the default datapath will be None. Because currently no information is passed and Nova doesn’t know about the different datapath types (this information is in Neutron), it makes sense not to assign any value. Nova is protected in case the dict doesn't have this information.

Finally, os-vif will receive the VIF information given by Nova. If the datapath_type is not given in the variable (dict) or the value is None, the default value (OVS_DATAPATH_SYSTEM) will be set.

As you can see, it's indeed an API change, but the projects affected are protected in case the information expected in the variable passed is not present.

What do you think?

Thank you in advance.

[1] https://bugs.launchpad.net/os-vif/+bug/1632372




-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20170620/3635c501/attachment.html>


More information about the OpenStack-dev mailing list