From 78a9d70f7f6a5b0b0f941c849a9250da2181c428 Mon Sep 17 00:00:00 2001 From: Feng Pan Date: Wed, 22 Feb 2017 14:44:39 -0500 Subject: Add support for odl_l3-fdio This patch adds support for ODL L3 FDIO scenario. Introduces a new deploy settings parameter, odl_routing_node, to indicate the routing node's hostname. This parameter will only be used for this scenario. Change-Id: I8df3eb701299007761c6cec42c4ca318b124a0b8 opnfv-tht-pr: 108 os-net-config-pr: 4 Signed-off-by: Feng Pan (cherry picked from commit 7d994a3c3e18227c26bf58049e4d5780144ecf98) --- build/nics-template.yaml.jinja2 | 11 ++++++---- build/opnfv-environment.yaml | 4 ++-- build/rpm_specs/opnfv-apex-common.spec | 6 ++++++ build/variables.sh | 12 +++++------ config/deploy/os-odl_l3-fdio-ha.yaml | 37 ++++++++++++++++++++++++++++++++ config/deploy/os-odl_l3-fdio-noha.yaml | 37 ++++++++++++++++++++++++++++++++ config/network/network_settings_vpp.yaml | 6 ++---- lib/overcloud-deploy-functions.sh | 20 ++++++++++------- lib/python/apex/deploy_settings.py | 3 ++- lib/python/apex_python_utils.py | 22 +++++++++++++++++-- lib/undercloud-functions.sh | 10 ++++++--- tests/test_apex_python_utils_py.py | 3 ++- 12 files changed, 140 insertions(+), 31 deletions(-) create mode 100644 config/deploy/os-odl_l3-fdio-ha.yaml create mode 100644 config/deploy/os-odl_l3-fdio-noha.yaml diff --git a/build/nics-template.yaml.jinja2 b/build/nics-template.yaml.jinja2 index 920e9a1b..f2c8000a 100644 --- a/build/nics-template.yaml.jinja2 +++ b/build/nics-template.yaml.jinja2 @@ -176,8 +176,8 @@ resources: - type: {{ nets['tenant']['nic_mapping'][role]['phys_type'] }} name: {{ nets['tenant']['nic_mapping'][role]['members'][0] }} - {%- if 'uio_driver' in nets['tenant']['nic_mapping'][role] %} - uio_driver: {{ nets['tenant']['nic_mapping'][role]['uio_driver'] }} + {%- if 'uio-driver' in nets['tenant']['nic_mapping'][role] %} + uio_driver: {{ nets['tenant']['nic_mapping'][role]['uio-driver'] }} {%- endif %} use_dhcp: false addresses: @@ -185,10 +185,13 @@ resources: ip_netmask: {get_param: TenantIpSubnet} {%- endif %} {%- endif %} - {%- if nets['external'][0]['enabled'] and external_net_type == 'interface' and nets['external'][0]['nic_mapping'][role]['vlan'] == 'native' %} + {%- if nets['external'][0]['enabled'] and external_net_type != 'br-ex' and nets['external'][0]['nic_mapping'][role]['vlan'] == 'native' %} - - type: interface + type: {{ nets['external'][0]['nic_mapping'][role]['phys_type'] }} name: {{ nets['external'][0]['nic_mapping'][role]['members'][0] }} + {%- if 'uio-driver' in nets['external'][0]['nic_mapping'][role] %} + uio_driver: {{ nets['external'][0]['nic_mapping'][role]['uio-driver'] }} + {%- endif %} {%- if role == 'controller' %} dns_servers: {get_param: DnsServers} {%- endif %} diff --git a/build/opnfv-environment.yaml b/build/opnfv-environment.yaml index 30e68997..ff8d501d 100644 --- a/build/opnfv-environment.yaml +++ b/build/opnfv-environment.yaml @@ -25,8 +25,8 @@ parameter_defaults: key: 'os_compute_api:servers:show:host_status' value: 'rule:admin_or_owner' nova::api::default_floating_pool: 'external' - #neutron::agents::dhcp::interface_driver: "neutron.agent.linux.interface.NSDriver" - #neutron::agents::l3::interface_driver: "neutron.agent.linux.interface.NSDriver" + #VPP routing node, used for odl_l3-fdio only. + #opendaylight::vpp_routing_node: overcloud-novacompute-0.opnfvlf.org ControllerServices: - OS::TripleO::Services::CACerts # - OS::TripleO::Services::CephClient diff --git a/build/rpm_specs/opnfv-apex-common.spec b/build/rpm_specs/opnfv-apex-common.spec index a004542b..702e26b4 100644 --- a/build/rpm_specs/opnfv-apex-common.spec +++ b/build/rpm_specs/opnfv-apex-common.spec @@ -51,6 +51,8 @@ install config/deploy/os-odl-bgpvpn-ha.yaml %{buildroot}%{_sysconfdir}/opnfv-ape install config/deploy/os-odl-bgpvpn-noha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl-bgpvpn-noha.yaml install config/deploy/os-odl_l2-fdio-ha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl_l2-fdio-ha.yaml install config/deploy/os-odl_l2-fdio-noha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl_l2-fdio-noha.yaml +install config/deploy/os-odl_l3-fdio-noha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl_l3-fdio-noha.yaml +install config/deploy/os-odl_l3-fdio-ha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl_l3-fdio-ha.yaml install config/deploy/os-odl_l3-nofeature-ha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl_l3-nofeature-ha.yaml install config/deploy/os-odl-gluon-noha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-odl-gluon-noha.yaml #install config/deploy/os-onos-nofeature-ha.yaml %{buildroot}%{_sysconfdir}/opnfv-apex/os-onos-nofeature-ha.yaml @@ -130,6 +132,8 @@ install config/inventory/pod_example_settings.yaml %{buildroot}%{_docdir}/opnfv/ %{_sysconfdir}/opnfv-apex/os-odl-bgpvpn-noha.yaml %{_sysconfdir}/opnfv-apex/os-odl_l2-fdio-noha.yaml %{_sysconfdir}/opnfv-apex/os-odl_l2-fdio-ha.yaml +%{_sysconfdir}/opnfv-apex/os-odl_l3-fdio-noha.yaml +%{_sysconfdir}/opnfv-apex/os-odl_l3-fdio-ha.yaml %{_sysconfdir}/opnfv-apex/os-odl_l3-nofeature-ha.yaml %{_sysconfdir}/opnfv-apex/os-odl-gluon-noha.yaml #%{_sysconfdir}/opnfv-apex/os-onos-nofeature-ha.yaml @@ -149,6 +153,8 @@ install config/inventory/pod_example_settings.yaml %{buildroot}%{_docdir}/opnfv/ %doc %{_docdir}/opnfv/inventory.yaml.example %changelog +* Fri Mar 10 2017 Feng Pan - 4.0-6 +- Add os-odl_l3-fdio-noha.yaml and os-odl_l3-fdio-ha.yaml * Wed Mar 08 2017 Dan Radez - 4.0-5 - Commenting out ONOS, unsupported in Danube - Adding kvm4nfv files diff --git a/build/variables.sh b/build/variables.sh index be610d43..c4eb57bc 100644 --- a/build/variables.sh +++ b/build/variables.sh @@ -24,13 +24,13 @@ onos_ovs_pkg=package_ovs_rpm3.tar.gz if [ -z ${GS_PATHNAME+x} ]; then GS_PATHNAME=/colorado fi -dpdk_uri_base=http://artifacts.opnfv.org/ovsnfv$GS_PATHNAME +dpdk_uri_base=http://artifacts.opnfv.org/ovsnfv dpdk_rpms=( -'ovs4opnfv-e8acab14-dpdk-16.04.0-1.el7.centos.x86_64.rpm' -'ovs4opnfv-e8acab14-dpdk-devel-16.04.0-1.el7.centos.x86_64.rpm' -'ovs4opnfv-e8acab14-dpdk-examples-16.04.0-1.el7.centos.x86_64.rpm' -'ovs4opnfv-e8acab14-dpdk-tools-16.04.0-1.el7.centos.x86_64.rpm' -'ovs4opnfv-e8acab14-openvswitch-2.5.90-0.12032.gitc61e93d6.1.el7.centos.x86_64.rpm' +'ovs4opnfv-e8acab14-dpdk-16.11-5.el7.centos.x86_64.rpm' +'ovs4opnfv-e8acab14-dpdk-devel-16.11-5.el7.centos.x86_64.rpm' +'ovs4opnfv-e8acab14-dpdk-examples-16.11-5.el7.centos.x86_64.rpm' +'ovs4opnfv-e8acab14-dpdk-tools-16.11-5.el7.centos.x86_64.rpm' +'ovs4opnfv-e8acab14-openvswitch-2.6.0-1.el7.centos.x86_64.rpm' ) kvmfornfv_uri_base="http://artifacts.opnfv.org/kvmfornfv" diff --git a/config/deploy/os-odl_l3-fdio-ha.yaml b/config/deploy/os-odl_l3-fdio-ha.yaml new file mode 100644 index 00000000..af81e5a5 --- /dev/null +++ b/config/deploy/os-odl_l3-fdio-ha.yaml @@ -0,0 +1,37 @@ +global_params: + ha_enabled: true + +deploy_options: + sdn_controller: opendaylight + sdn_l3: true + odl_version: carbon + odl_vpp_routing_node: overcloud-novacompute-0 + tacker: true + congress: true + sfc: false + vpn: false + vpp: true + dataplane: fdio + performance: + Controller: + kernel: + hugepages: 1024 + hugepagesz: 2M + intel_iommu: 'on' + iommu: pt + isolcpus: 1,2 + vpp: + main-core: 1 + corelist-workers: 2 + uio-driver: uio_pci_generic + Compute: + kernel: + hugepagesz: 2M + hugepages: 2048 + intel_iommu: 'on' + iommu: pt + isolcpus: 1,2 + vpp: + main-core: 1 + corelist-workers: 2 + uio-driver: uio_pci_generic diff --git a/config/deploy/os-odl_l3-fdio-noha.yaml b/config/deploy/os-odl_l3-fdio-noha.yaml new file mode 100644 index 00000000..adb37f3d --- /dev/null +++ b/config/deploy/os-odl_l3-fdio-noha.yaml @@ -0,0 +1,37 @@ +global_params: + ha_enabled: false + +deploy_options: + sdn_controller: opendaylight + sdn_l3: true + odl_version: carbon + odl_vpp_routing_node: overcloud-novacompute-0 + tacker: true + congress: true + sfc: false + vpn: false + vpp: true + dataplane: fdio + performance: + Controller: + kernel: + hugepages: 1024 + hugepagesz: 2M + intel_iommu: 'on' + iommu: pt + isolcpus: 1,2 + vpp: + main-core: 1 + corelist-workers: 2 + uio-driver: uio_pci_generic + Compute: + kernel: + hugepagesz: 2M + hugepages: 2048 + intel_iommu: 'on' + iommu: pt + isolcpus: 1,2 + vpp: + main-core: 1 + corelist-workers: 2 + uio-driver: uio_pci_generic diff --git a/config/network/network_settings_vpp.yaml b/config/network/network_settings_vpp.yaml index 4b50745f..c6792157 100644 --- a/config/network/network_settings_vpp.yaml +++ b/config/network/network_settings_vpp.yaml @@ -96,14 +96,12 @@ networks: # Network configurations # vlan, vxlan, gre nic_mapping: # Mapping of network configuration for Overcloud Nodes compute: # Mapping for compute profile (nodes that will be used as Compute nodes) - phys_type: vpp_interface # Physical interface type (interface/vpp_interface) - uio_driver: uio_pci_generic # uio driver, for vpp interfaces only + phys_type: interface # Physical interface type (interface/bond) vlan: native # VLAN tag to use with this NIC members: # Physical NIC members of this mapping (Single value allowed for interface phys_type) - eth1 # Note that logic nic name like nic1 cannot be used for fdio deployment yet. controller: # Mapping for controller profile (nodes that will be used as Controller nodes) - phys_type: vpp_interface # Physical interface type (interface/vpp_interface) - uio_driver: uio_pci_generic # uio driver, for vpp interfaces only + phys_type: interface # Physical interface type (interface/bond) vlan: native members: - eth1 # Note that logic nic name like nic1 cannot be used for fdio deployment yet. diff --git a/lib/overcloud-deploy-functions.sh b/lib/overcloud-deploy-functions.sh index a46c6c6b..4d4b7647 100755 --- a/lib/overcloud-deploy-functions.sh +++ b/lib/overcloud-deploy-functions.sh @@ -28,7 +28,11 @@ function overcloud_deploy { DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/services/gluon.yaml" fi elif [ "${deploy_options_array['vpp']}" == 'True' ]; then - DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/neutron-opendaylight-honeycomb.yaml" + if [ "${deploy_options_array['sdn_l3']}" == "True" ]; then + DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/neutron-opendaylight-honeycomb.yaml" + else + DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/neutron-opendaylight-honeycomb-l2.yaml" + fi else DEPLOY_OPTIONS+=" -e /usr/share/openstack-tripleo-heat-templates/environments/neutron-opendaylight-l3.yaml" fi @@ -145,6 +149,13 @@ EOI EOI fi + #Configure routing node for odl_l3-fdio + if [[ "${deploy_options_array['sdn_controller']}" == 'opendaylight' && "${deploy_options_array['dataplane']}" == 'fdio' && "${deploy_options_array['sdn_l3']}" == 'True' ]]; then + ssh -T ${SSH_OPTIONS[@]} "stack@$UNDERCLOUD" <