Neutron plugins for NEC networking products

networking-nec library provides Neutron plugins/drivers for NEC SDN networking products.

NEC NWA plugin

In Mitaka release, NWA plugin was added as a new integration layer with NEC NWA (Network Automation) product. NWA plugin consists of layer-2 core plugin and layer-3 service plugin.

Introduction of NEC NWA plugin

Installation of NEC NWA plugin

Requirements

To use the NWA plugin, NWA made by NEC is needed.

After an OpenStack installation, you need to install networking-nec Python package, configure the physical network by NWA and configure the NWA plugin.

Running with DevStack

See DevStack support for NWA plugin

Manual Installation

The released versions of Python module is available at https://pypi.python.org/pypi/networking-nec.

To install:

pip install networking-nec~=2.0

NEC NWA plugin is available from version 2.0.0 or later. The 2.y.z series of networking-nec supports Neutron Mitaka release.

Setting of NEC NWA plugin

This section describes the configurations of the releases of NEC NWA plugin.

neutron.conf
  • core_plugin: Needs to be configured to necnwa to use NEC NWA plugin as core plugin.

    core_plugin = necnwa
    
  • service_plugin: Needs to be configured to necnwa_router to use NEC NWA plugin as service plugin.

    service_plugin = necnwa_router
    
plugin specific configuration

It is usually placed at /etc/neutron/plugins/nec/necnwa.ini.

[ml2] section
  • type_drivers: Needs to be configured to vlan to use NEC NWA plugin as type_drivers.

    type_drivers = vlan
    
  • tenant_network_types: Needs to be configured to vlan to use NEC NWA plugin as tenant_network_types.

    tenant_network_types = vlan
    
  • mechanism_drivers: Needs to be configured to necnwa and openvswitch to use NEC NWA plugin as mechanism_drivers.

    mechanism_drivers = necnwa,openvswitch
    
[ml2_type_vlan] section
  • network_vlan_ranges: Specify the name of an available physical network and a range of VIDs on that network available for allocation to tenant networks. The physical network should be the same name of NWA resource group name.

    network_vlan_ranges = OpenStack/DC/APP:1000:2999,OpenStack/DC/HA1:10:2999,OpenStack/DC/HA2:10:2999
    
[ovs] section
  • bridge_mappings: Specify list of <physical_network>:<bridge> tuples, each specifying an OVS bridge used by the agent for a physical network to which it is connected.

    bridge_mappings = OpenStack/DC/HA1:br-eth1,OpenStack/DC/HA2:br-eth2
    
[NWA] section
  • server_url: The URL of the http/https server listening for NWA RESTful API:

    server_url = http://192.168.122.1:12081
    
  • access_key_id: The access key ID of NWA RESTful API server. The access key consists of an access key ID and secret access key, which are used to sign RESTful API requests that you make to NWA.

    access_key_id = mjivAk6O3G4Ko/0mD8mHUyQwqugEPgTe0FSli8REyN4=
    
  • secret_access_key: The secret access key of NWA Restful API server. The access key consists of an access key ID and secret access key, which are used to sign RESTful API requests that you make to NWA.

    secret_access_key = /3iSORtq1E3F+SQtQg6YN00eM3GUda0EKqWDUV/mvqo=
    
  • resource_group_name: A default rerouce group name when NWA tenant is created.

    resource_group_name = OpenStack/DC/APP
    
  • scenario_polling_timer: Specifies the polling interval of the scenario in seconds.

    scenario_polling_timer = 5
    
  • scenario_polling_count: Specifies the polling counts of the scenario.

    scenario_polling_count = 300
    
  • region_name: A region name (It is the prefix of NWA tenant name).

    region_name = T01DC
    
  • resource_group_file: Load the table of NWA resource group from the file.

    resource_group_file = resource_group.json
    
NWA resource group file

It is usually placed at “/etc/neutron/plugins/nec/resource_group.json.”

This file contains a table of NWA resource group. The format of the file is JSON.

The physical_network is a name of physical network which is used in neutron. It should be set to the same value as ResourceGroupName member.

The device_owner is the owner of the device in OpenStack.

It is specified as compute:AVAILABILITY_ZONE, the VM that has a nova boot option --available-zone is created on the physical network corresponding with the device owner.

If the option --available-zone is not specified in nova boot, regarded as compute:None has been specified.

All available DHCP agent in OpenStack specifies as network:dhcp.

The ResourceGroupName is a name of NWA’s resource group name.

[
   {
       "physical_network": "OpenStack/DC/HA1",
       "device_owner": "compute:DC01_KVM01_ZONE01",
       "ResourceGroupName": "OpenStack/DC/HA1"
   },
   {
       "physical_network": "OpenStack/DC/HA2",
       "device_owner": "compute:DC01_KVM02_ZONE02",
       "ResourceGroupName": "OpenStack/DC/HA2"
   },
   {
       "physical_network": "OpenStack/DC/HA1",
       "device_owner": "compute:None",
       "ResourceGroupName": "OpenStack/DC/HA1"
   },
   {
       "physical_network": "OpenStack/DC/HA2",
       "device_owner": "compute:None",
       "ResourceGroupName": "OpenStack/DC/HA2"
   },
   {
       "physical_network": "OpenStack/DC/HA1",
       "device_owner": "network:dhcp",
       "ResourceGroupName": "OpenStack/DC/HA1"
   },
   {
       "physical_network": "OpenStack/DC/HA2",
       "device_owner": "network:dhcp",
       "ResourceGroupName": "OpenStack/DC/HA2"
   },
   {
       "physical_network": "OpenStack/DC/APP",
       "device_owner": "network:router_gateway",
       "ResourceGroupName": "OpenStack/DC/APP"
   },
   {
       "physical_network": "OpenStack/DC/APP",
       "device_owner": "network:router_interface",
       "ResourceGroupName": "OpenStack/DC/APP"
   },
]

DevStack support for NWA plugin

This DevStack external plugin installs NEC plugin library so that Neutron NEC NWA plugin can be enabled.

To use this DevStack plugin, add the following to your local.conf:

enable_plugin networking-nec https://git.openstack.org/openstack/networking-nec [<branch>]
Examples

Minimum sample local.conf:

[[local|localrc]]
# Enable neutron services
disable_service n-net
enable_service neutron q-svc q-agt
enable_service q-dhcp
enable_service q-meta

# NEC plugin
Q_PLUGIN=nec
enable_plugin networking-nec https://git.openstack.org/openstack/networking-nec

# NWA server configurations
NECNWA_SERVER_URL="http://127.0.0.1:12081"
NECNWA_ACCESS_KEY_ID="mjivAk6O3G4Ko/0mD8mHUyQwqugEPgTe0FSli8REyN4="
NECNWA_SECRET_ACCESS_KEY="/3iSORtq1E3F+SQtQg6YN00eM3GUda0EKqWDUV/mvqo="

# Run neutron-nwa-agent
enable_service nwa-agt

[[post-config|/etc/neutron/dhcp_agent.ini]]
[DEFAULT]
enable_isolated_metadata = True

The NWA plugin consists of plugin driver and agent. Using this plugin, you can operate an SDN controller (MasterScope Network Automation) made by NEC from OpenStack CLI or Dashboard.

NWA can build a large scale layer 2 network which removes the 4K VLAN limit. So you can use the NWA plugin to create, update and delete the network through OpenStack environment.

_images/necnwa-plugin-design.png

NEC OpenFlow plugin

NEC OpenFlow plugin in Liberty or older releases supported NEC ProgrammableFlow controller and Trema Sliceable Switch (as reference implementation).

Warning

NEC OpenFlow plugin was deprecated in OpenStack Liberty release (2015.2) and removed during Mitaka development cycle. Note that the production support will be continued based on the production support policy.

The documentation on NEC OpenFlow plugin is found at http://networking-nec.readthedocs.org/en/stable-liberty/.

Developers Guide

Development Tips

Release package

Create a specific release

The following steps are required to release a package.

  • (Create a stable branch if necessary)

  • Add a signed tag to the repository

    git checkout stable/xxxx (if necessary)
    git tag -s <version number>
    git show <version number>
    git push gerrit <version number>
    

    Warning

    Before pushing a tag to gerrit, you are strongly suggested to test whether a generated package works as expected.

    git checkout <version number>
    python setup.py sdist
    pip install dist/networking-nec-<version number>.tar.gz
    

    To push a tag to gerrit, you must be a member of networking-nec-release gerrit group.

  • Push a release package to PyPI.

    git checkout <version number>
    python setup.py sdist upload
    

    Once the upload succeeded, you can find a new release at https://pypi.python.org/pypi/networking-nec.

    Before uploading a package to PyPI, you need to create your PyPI account and prepare a proper credential file ~/.pypirc like below.

    [distutils]
    index-servers =
      pypi
    
    [pypi]
    repository=https://pypi.python.org/pypi
    username=<your username>
    password=<your password>
    
Create a stable branch

The detail is available at: http://docs.openstack.org/infra/manual/drivers.html#release-management.

To create a (stable) branch, you must be a member of networking-nec-release gerrit group.

More information

Most of the release process is explained in OpenStack Infrastructure User Manual.

Requirements update

In OpenStack projects, requirements.txt and test-requirements.txt should be synced with global-requirements.txt in http://git.openstack.org/cgit/openstack/requirements/tree/.

To sync requirements manually:

  1. Check out requirements repository:

    git clone https://git.openstack.org/openstack/requirements
    
  2. Run update.py:

    cd requirements
    tox -e venv -- python update.py <networking-nec top directory>
    

To sync it automatically, you need to:

  • setup the jenkins job gate-{name}-requirements (it is usually unnecessary as python-jobs contains it),
  • add check-requirements to zuul/layout.yaml in project-config, and
  • add openstack/networking-nec to projects.txt in the requirements project.

Documentation

Build documentation

To build the documentation:

tox -e docs

and the generated documentation will be found under doc/build/html.

Publish documentation

The document is hosted by Read The Docs and the documentation is available at http://networking-nec.readthedocs.org/en/latest/.

To publish the latest documentation, visit the project page, go to Builds and click Build version after selecting latest. After completing the build, the status will be Passed and you can see the new document. If the build fails, investigate reasons of the failure.

Third party CI

Contributing

If you would like to contribute to the development of OpenStack, you must follow the steps in this page:

Once those steps have been completed, changes to OpenStack should be submitted for review via the Gerrit tool, following the workflow documented at:

Pull requests submitted through GitHub will be ignored.

Bugs should be filed on Launchpad, not GitHub: