From 3dea7869947d652cb9d069c3b9fcbd3f4c32ec3b Mon Sep 17 00:00:00 2001 From: Dmitry Burmistrov Date: Mon, 17 Mar 2014 16:03:50 +0400 Subject: [PATCH] Update specs to v. 2014.1.b3 --- debian/changelog | 132 ++- debian/compat | 0 debian/control | 275 ++--- debian/neutron-dhcp-agent.logrotate | 0 debian/neutron-dhcp-agent.upstart | 5 + debian/neutron-l3-agent.logrotate | 0 debian/neutron-l3-agent.upstart | 5 + debian/neutron-lbaas-agent.logrotate | 0 debian/neutron-metadata-agent.logrotate | 0 debian/neutron-ovs-cleanup.upstart | 20 - debian/neutron-plugin-bigswitch-agent.install | 1 + .../neutron-plugin-bigswitch-agent.logrotate | 7 + debian/neutron-plugin-bigswitch-agent.upstart | 20 + debian/neutron-plugin-ibm-agent.install | 1 + debian/neutron-plugin-ibm-agent.logrotate | 7 + debian/neutron-plugin-ibm-agent.upstart | 20 + debian/neutron-plugin-ibm.install | 1 + ...neutron-plugin-linuxbridge-agent.logrotate | 0 debian/neutron-plugin-ml2.install | 1 - debian/neutron-plugin-mlnx-agent.logrotate | 7 + debian/neutron-plugin-mlnx-agent.upstart | 4 +- debian/neutron-plugin-nec-agent.logrotate | 0 debian/neutron-plugin-nicira.install | 2 - debian/neutron-plugin-openflow-agent.install | 1 + .../neutron-plugin-openflow-agent.logrotate | 7 + debian/neutron-plugin-openflow-agent.upstart | 20 + ...neutron-plugin-openvswitch-agent.logrotate | 0 ...nvswitch-agent.neutron-ovs-cleanup.upstart | 13 + .../neutron-plugin-openvswitch-agent.upstart | 4 +- debian/neutron-plugin-ryu-agent.logrotate | 0 debian/neutron-plugin-vmware.install | 4 + debian/neutron-server.default | 2 +- debian/neutron-server.logrotate | 0 debian/patches/bump-sqlalchemy-version.patch | 11 - .../patches/disable-failing-cisco-test.patch | 25 + .../disable-failing-metaplugin-tests.patch | 67 ++ .../disable-ml2-notification-tests.patch | 24 - debian/patches/disable-udev-tests.patch | 992 +++++++++++++++++- .../patches/fix-quantum-configuration.patch | 28 +- debian/patches/remove-jsonrpclib.patch | 10 - debian/patches/series | 7 +- debian/patches/skip-ipv6-tests.patch | 22 + debian/patches/skip-lb-test.patch | 14 + debian/patches/use-concurrency.patch | 19 + debian/pydist-overrides | 1 - debian/rules | 6 +- debian/tests/control | 2 +- debian/tests/{nicira-plugin => vmware-plugin} | 12 +- debian/watch | 0 ...parallel-installed-versions-in-RHEL6.patch | 6 +- .../0002-Remove-dnsmasq-version-warning.patch | 31 + rpm/SOURCES/neutron-dhcp-agent.init | 4 +- rpm/SOURCES/neutron-l3-agent.init | 5 +- rpm/SOURCES/neutron-l3-agent.upstart | 2 +- rpm/SOURCES/neutron-lbaas-agent.init | 1 + rpm/SOURCES/neutron-linuxbridge-agent.init | 1 + rpm/SOURCES/neutron-metadata-agent.init | 4 +- rpm/SOURCES/neutron-metering-agent.init | 1 + rpm/SOURCES/neutron-mlnx-agent.init | 1 + rpm/SOURCES/neutron-nec-agent.init | 1 + rpm/SOURCES/neutron-openvswitch-agent.init | 4 +- rpm/SOURCES/neutron-ovs-cleanup.init | 1 + rpm/SOURCES/neutron-ryu-agent.init | 1 + rpm/SOURCES/neutron-server-setup | 4 +- rpm/SOURCES/neutron-server.init | 1 + rpm/SOURCES/neutron-vpn-agent.init | 2 + rpm/SOURCES/neutron-vpn-agent.upstart | 2 +- rpm/SPECS/openstack-neutron.spec | 152 ++- 68 files changed, 1704 insertions(+), 319 deletions(-) mode change 100755 => 100644 debian/compat mode change 100755 => 100644 debian/neutron-dhcp-agent.logrotate mode change 100755 => 100644 debian/neutron-l3-agent.logrotate mode change 100755 => 100644 debian/neutron-lbaas-agent.logrotate mode change 100755 => 100644 debian/neutron-metadata-agent.logrotate delete mode 100644 debian/neutron-ovs-cleanup.upstart create mode 100644 debian/neutron-plugin-bigswitch-agent.install create mode 100644 debian/neutron-plugin-bigswitch-agent.logrotate create mode 100644 debian/neutron-plugin-bigswitch-agent.upstart create mode 100644 debian/neutron-plugin-ibm-agent.install create mode 100644 debian/neutron-plugin-ibm-agent.logrotate create mode 100644 debian/neutron-plugin-ibm-agent.upstart create mode 100644 debian/neutron-plugin-ibm.install mode change 100755 => 100644 debian/neutron-plugin-linuxbridge-agent.logrotate create mode 100644 debian/neutron-plugin-mlnx-agent.logrotate mode change 100755 => 100644 debian/neutron-plugin-nec-agent.logrotate delete mode 100644 debian/neutron-plugin-nicira.install create mode 100644 debian/neutron-plugin-openflow-agent.install create mode 100644 debian/neutron-plugin-openflow-agent.logrotate create mode 100644 debian/neutron-plugin-openflow-agent.upstart mode change 100755 => 100644 debian/neutron-plugin-openvswitch-agent.logrotate create mode 100644 debian/neutron-plugin-openvswitch-agent.neutron-ovs-cleanup.upstart mode change 100755 => 100644 debian/neutron-plugin-ryu-agent.logrotate create mode 100644 debian/neutron-plugin-vmware.install mode change 100755 => 100644 debian/neutron-server.logrotate delete mode 100644 debian/patches/bump-sqlalchemy-version.patch create mode 100644 debian/patches/disable-failing-cisco-test.patch create mode 100644 debian/patches/disable-failing-metaplugin-tests.patch delete mode 100644 debian/patches/disable-ml2-notification-tests.patch delete mode 100644 debian/patches/remove-jsonrpclib.patch create mode 100644 debian/patches/skip-ipv6-tests.patch create mode 100644 debian/patches/skip-lb-test.patch create mode 100644 debian/patches/use-concurrency.patch mode change 100755 => 100644 debian/pydist-overrides rename debian/tests/{nicira-plugin => vmware-plugin} (59%) mode change 100755 => 100644 debian/watch create mode 100644 rpm/SOURCES/0002-Remove-dnsmasq-version-warning.patch diff --git a/debian/changelog b/debian/changelog index 47fa9b981..35b5d3f86 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,8 +1,134 @@ -neutron (1:2013.2-0ubuntu1~cloud0) precise-havana; urgency=low +neutron (1:2014.1~b3-0ubuntu1~cloud0) precise-icehouse; urgency=low - * New usptream release candidate for the Ubuntu Cloud Archive. + * New upstream release for the Ubuntu Cloud Archive. - -- Chuck Short Wed, 16 Oct 2013 16:33:52 -0400 + -- Openstack Ubuntu Testing Bot Tue, 11 Mar 2014 01:46:17 -0400 + +neutron (1:2014.1~b3-0ubuntu1) trusty; urgency=medium + + [ Chuck Short ] + * New upstream release. + * debian/rules: Re-enabled tests. + * debian/patches/requirements.patch: Dropped no longer needed. + * debian/patches/sql-alchemy-0.8.3-compat.patch: Dropped no longer needed. + * debian/patches/bump-sqlalchemy-version.patch: Dropped no longer needed. + * debian/neutron-plugin-vmware.install: Install usr/bin/neutron-nsx-manage. + * debian/patches/use-concurrency.patch: Set default concurrency to 1. + + [ James Page ] + * d/control,neutron-plugin-ibm*: Add plugin and agent packages for IBM + SDN-VE. + * d/control,neutron-openflow-*: Add agent package for OpenFlow ML2 agent. + * d/control,neutron-plugin-bigswitch-agent*: Add agent package for + BigSwitch. + * d/neutron-plugin-mlnx-agent.{upstart,logrotate}: Correct log path + and add logrotate configuration (LP: #1284144). + + [ Corey Bryant ] + * Renamed Nicira NVP plugin to VMware NSX (LP: #1273877): + - debian/neutron-plugin-*.install: Update path and file for rename + - debian/tests/*-plugin: Replace nicira-plugin with vmware-plugin + - debian/control: + + Change neutron-plugin-nicira to transtional package + + Add neutron-plugin-vmware package which breaks/replaces + neutron-plugin-nicira package. + + -- James Page Fri, 07 Mar 2014 09:38:32 +0000 + +neutron (1:2014.1~b2-0ubuntu6) trusty; urgency=medium + + * debian/rules: Temporarily disable testsuite due to upstream breakage. + + -- Chuck Short Thu, 06 Feb 2014 08:33:08 -0500 + +neutron (1:2014.1~b2-0ubuntu5) trusty; urgency=medium + + * debian/patches/disable-udev-tests.patch: Skip more tests + because of udev failures. + * debian/patches/skip-ipv6-tests.patch: Skip tests that fail + on the buildds due to ipv6. + + -- Chuck Short Mon, 03 Feb 2014 09:02:45 -0500 + +neutron (1:2014.1~b2-0ubuntu4) trusty; urgency=medium + + * debian/rules: Really run_tests.sh. + + -- Chuck Short Thu, 30 Jan 2014 11:44:21 -0500 + +neutron (1:2014.1~b2-0ubuntu3) trusty; urgency=medium + + * debian/rules: Switch back to run_test.sh since locking + issues have been fixed. + + -- Chuck Short Thu, 30 Jan 2014 10:49:22 -0500 + +neutron (1:2014.1~b2-0ubuntu2) trusty; urgency=medium + + * debian/patches/skip-lb-test.patch: Skipped lb configuration + test. + + -- Chuck Short Mon, 27 Jan 2014 12:01:50 -0500 + +neutron (1:2014.1~b2-0ubuntu1) trusty; urgency=low + + [ James Page ] + * Switch to using Modular Layer 2 plugin by default: + - d/control,neutron-plugin-ml2.install: Add ML2 plugin package + (LP: #1243147). + - d/p/fix-quantum-configuration,d/control,d/neutron-server.default: + Switch to using the ML2 plugin by default. + - d/control,neutron-plugin-openvswitch-agent: + Use neutron-plugin-ml2 and configuration for openvswitch-agent. + * d/neutron-plugin-mlnx-agent.upstart: Reference correct configuration + file (LP: #1257732). + * Add neutron-ovs-cleanup upstart configuration for OVS plugin + (LP: #1249708): + - d/rules: Install new configuration in neutron-plugin-openvswitch-agent + package, don't restart on install/upgrade (only needed for reboots). + - d/neutron-plugin-openvswitch-agent.upstart: Ensure startup happens + after neutron-ovs-cleanup. + - d/neutron-{l3|dhcp}-agent.upstart: If neutron-ovs-cleanup job is + installed, wait for it to reach running state prior to starting + agents. + * d/control: Add versioned BD/Depends on python-psutil >= 0.6.1. + * d/p/requirements.patch: Drop upper version boundary for psutil for + compatibility with Trusty. + * d/p/requirements.patch: Lift upper boundary for WebOb to < 1.4. + * d/p/disable-failing-metaplugin-tests.patch: Disable metaplugin tests that + are currently failing. + * d/p/disable-ml2-notification-tests.patch: Dropped, tests now pass. + * d/rules: Fail package build on unit test failures. + * d/p/disable-failing-cisco-test.patch: Disable failing Cisco mechanism test. + * d/control,d/p/remove-jsonrpclib.patch: Add BD on python-jsonrpclib and drop + patch that excludes it from requirements.txt. + + [ Chuck Short ] + * New upstream release. + * debian/rules: Run testr directly + * debian/patches/sql-alchemy-0.8.3-compat.patch: Fix tests sqlalchemy 0.8.3 + compat. + * debian/neturon-nicira.install: Add usr/bin/neutron-check-nsx-config. + + -- Chuck Short Fri, 24 Jan 2014 09:17:12 -0500 + +neutron (1:2014.1~b1-0ubuntu1) trusty; urgency=low + + [ Chuck Short ] + * New upstream release. + * debian/control: open icehouse release. + + [ James Page ] + * debian/patches: Refresh patches against upstream master. + * debian/control: Drop quantum-* transitional packages, no longer needed. + + -- Chuck Short Thu, 05 Dec 2013 11:40:39 -0500 + +neutron (1:2013.2-0ubuntu1) saucy; urgency=low + + * New upstream release (LP: #1236462). + + -- Chuck Short Thu, 17 Oct 2013 10:52:39 -0400 neutron (1:2013.2~rc3-0ubuntu1) saucy; urgency=low diff --git a/debian/compat b/debian/compat old mode 100755 new mode 100644 diff --git a/debian/control b/debian/control index 51d4a1d17..fd783a9ae 100644 --- a/debian/control +++ b/debian/control @@ -19,6 +19,7 @@ Build-Depends-Indep: python-httplib2, python-iso8601, python-jinja2, + python-jsonrpclib, python-keystoneclient (>= 1:0.2.0), python-kombu (>= 2.5.12), python-lxml, @@ -31,6 +32,7 @@ Build-Depends-Indep: python-paste, python-pastedeploy, python-pbr (>= 0.5.21), + python-psutil (>= 0.6.1), python-pyudev, python-requests (>= 1.1), python-routes, @@ -46,8 +48,8 @@ Build-Depends-Indep: testrepository ( >= 0.0.17) XS-Python-Version: >= 2.6 Standards-Version: 3.9.4 -Vcs-Browser: http://bazaar.launchpad.net/~ubuntu-server-dev/neutron/havana/files -Vcs-Bzr: https://code.launchpad.net/~ubuntu-server-dev/neutron/havana +Vcs-Browser: http://bazaar.launchpad.net/~ubuntu-server-dev/neutron/icehouse/files +Vcs-Bzr: https://code.launchpad.net/~ubuntu-server-dev/neutron/icehouse XS-Testsuite: autopkgtest Package: neutron-server @@ -60,7 +62,7 @@ Depends: ${shlibs:Depends} Breaks: quantum-server ( << 1:2013.2~b2-0ubuntu1~ ) Replaces: quantum-server ( << 1:2013.2~b2-0ubuntu1~ ) -Recommends: neutron-plugin-openvswitch +Recommends: neutron-plugin-ml2 Description: Neutron is a virtual network service for Openstack - server Neutron is a virtual network service for Openstack, and a part of Netstack. Just like OpenStack Nova provides an API to dynamically @@ -183,6 +185,25 @@ Description: Neutron is a virtual network service for Openstack - BigSwitch plug . This package provides the BigSwitch plugin. +Package: neutron-plugin-bigswitch-agent +Architecture: all +Depends: + neutron-plugin-bigswitch (= ${source:Version}), + ${misc:Depends}, + ${python:Depends}, + ${shlibs:Depends} +Description: Neutron is a virtual network service for Openstack - BigSwitch plugin agent + Neutron is a virtual network service for Openstack, and a part of + Netstack. Just like OpenStack Nova provides an API to dynamically + request and configure virtual servers, Neutron provides an API to + dynamically request and configure virtual networks. These networks + connect "interfaces" from other OpenStack services (e.g., virtual NICs + from Nova VMs). The Neutron API supports extensions to provide + advanced network capabilities (e.g., QoS, ACLs, network monitoring, + etc.) + . + This package provides the BigSwitch plugin agent. + Package: neutron-plugin-hyperv Architecture: all Provides: neutron-plugin @@ -271,7 +292,7 @@ Description: Neutron is a virtual network service for Openstack - Metaplugin plu . This package provides the Metaplugin plugin. -Package: neutron-plugin-nicira +Package: neutron-plugin-vmware Architecture: all Provides: neutron-plugin Depends: @@ -279,9 +300,9 @@ Depends: ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} -Breaks: quantum-plugin-nicira ( << 1:2013.2~b2-0ubuntu1~ ) -Replaces: quantum-plugin-nicira ( << 1:2013.2~b2-0ubuntu1~ ) -Description: Neutron is a virtual network service for Openstack - Nicira plugin +Breaks: neutron-plugin-nicira ( << 1:2014.1~b2-0ubuntu7~ ) +Replaces: neutron-plugin-nicira ( << 1:2014.1~b2-0ubuntu7~ ) +Description: Neutron is a virtual network service for Openstack - VMware plugin Neutron is a virtual network service for Openstack, and a part of Netstack. Just like OpenStack Nova provides an API to dynamically request and configure virtual servers, Neutron provides an API to @@ -291,7 +312,16 @@ Description: Neutron is a virtual network service for Openstack - Nicira plugin advanced network capabilities (e.g., QoS, ACLs, network monitoring, etc.) . - This package provides the Nicira NVP plugin + This package provides the VMware NSX plugin + +Package: neutron-plugin-nicira +Depends: neutron-plugin-vmware, ${misc:Depends} +Architecture: all +Breaks: quantum-plugin-nicira ( << 1:2013.2~b2-0ubuntu1~ ) +Replaces: quantum-plugin-nicira ( << 1:2013.2~b2-0ubuntu1~ ) +Section: oldlibs +Description: transitional dummy package + This is a transitional dummy package. It can safely be removed. Package: neutron-l3-agent Architecture: all @@ -403,6 +433,7 @@ Depends: python-oslo.config (>= 1:1.2.0a3), python-paste, python-pastedeploy, + python-psutil (>= 0.6.1), python-requests (>= 1.1), python-routes, python-six, @@ -472,8 +503,7 @@ Description: Neutron is a virtual network service for Openstack - ML2 plugin Package: neutron-plugin-openvswitch-agent Architecture: all Depends: - neutron-common (= ${source:Version}), - neutron-plugin-ml2, + neutron-plugin-ml2 (= ${source:Version}), openvswitch-switch, ${misc:Depends}, ${python:Depends}, @@ -518,8 +548,7 @@ Package: neutron-plugin-linuxbridge-agent Architecture: all Depends: bridge-utils, - neutron-common (= ${source:Version}), - neutron-plugin-linuxbridge, + neutron-plugin-linuxbridge (= ${source:Version}), ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} @@ -562,8 +591,7 @@ Description: Neutron is a virtual network service for Openstack - RYU plugin Package: neutron-plugin-ryu-agent Architecture: all Depends: - neutron-common (= ${source:Version}), - neutron-plugin-ryu, + neutron-plugin-ryu (= ${source:Version}), ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} @@ -631,7 +659,7 @@ Depends: ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} -Description: Neutron is a virtual network service for Openstack - vpn plugin +Description: Neutron is a virtual network service for Openstack - VPN agent Neutron is a virtual network service for Openstack, and a part of Netstack. Just like OpenStack Nova provides an API to dynamically request and configure virtual servers, Neutron provides an API to @@ -641,17 +669,16 @@ Description: Neutron is a virtual network service for Openstack - vpn plugin advanced network capabilities (e.g., QoS, ACLs, network monitoring, etc.) . - This package provides the vpn plugin. + This package provides the VPN agent. Package: neutron-plugin-metering-agent Architecture: all -Provides: neutron-plugin Depends: neutron-common (= ${source:Version}), ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} -Description: Neutron is a virtual network service for Openstack - metering plugin +Description: Neutron is a virtual network service for Openstack - metering agent Neutron is a virtual network service for Openstack, and a part of Netstack. Just like OpenStack Nova provides an API to dynamically request and configure virtual servers, Neutron provides an API to @@ -661,177 +688,63 @@ Description: Neutron is a virtual network service for Openstack - metering plugi advanced network capabilities (e.g., QoS, ACLs, network monitoring, etc.) . - This package provides the metering plugin. + This package provides the metering agent. -Package: neutron-ovs-cleanup +Package: neutron-plugin-openflow-agent Architecture: all Depends: - neutron-common (= ${source:Version}), - neutron-plugin-openvswitch (= ${source:Version}), + neutron-plugin-ml2 (= ${source:Version}), ${misc:Depends}, ${python:Depends}, ${shlibs:Depends} -Breaks: quantum-ovs-cleanup ( << 1:2013.2~b2-0ubuntu1~ ) -Replaces: quantum-ovs-cleanup ( << 1:2013.2~b2-0ubuntu1~ ) -Description: This package provides OVS cleanup upstart script. - -Package: quantum-server -Depends: neutron-server, ${misc:Depends} -Architecture: all -Section: oldlibs -description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-common -Depends: neutron-common, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-cisco -Depends: neutron-plugin-cisco, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-nec -Depends: neutron-plugin-nec, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-nec-agent -Depends: neutron-plugin-nec-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-bigswitch -Depends: neutron-plugin-bigswitch, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-hyperv -Depends: neutron-plugin-hyperv, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-brocade -Depends: neutron-plugin-brocade, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-plumgrid -Depends: neutron-plugin-plumgrid, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-metaplugin -Depends: neutron-plugin-metaplugin, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-nicira -Depends: neutron-plugin-nicira, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-l3-agent -Depends: neutron-l3-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-dhcp-agent -Depends: neutron-dhcp-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-metadata-agent -Depends: neutron-metadata-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-lbaas-agent -Depends: neutron-lbaas-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: python-quantum -Depends: python-neutron, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-openvswitch -Depends: neutron-plugin-openvswitch, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-openvswitch-agent -Depends: neutron-plugin-openvswitch-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-linuxbridge -Depends: neutron-plugin-linuxbridge, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. - -Package: quantum-plugin-linuxbridge-agent -Depends: neutron-plugin-linuxbridge-agent, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. +Description: Neutron is a virtual network service for Openstack - Openflow agent + Neutron is a virtual network service for Openstack, and a part of + Netstack. Just like OpenStack Nova provides an API to dynamically + request and configure virtual servers, Neutron provides an API to + dynamically request and configure virtual networks. These networks + connect "interfaces" from other OpenStack services (e.g., virtual NICs + from Nova VMs). The Neutron API supports extensions to provide + advanced network capabilities (e.g., QoS, ACLs, network monitoring, + etc.) + . + This package provides the Openflow agent. -Package: quantum-plugin-ryu -Depends: neutron-plugin-ryu, ${misc:Depends} +Package: neutron-plugin-ibm Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. +Provides: neutron-plugin +Depends: + neutron-common (= ${source:Version}), + ${misc:Depends}, + ${python:Depends}, + ${shlibs:Depends} +Description: Neutron is a virtual network service for Openstack - IBM SDN plugin + Neutron is a virtual network service for Openstack, and a part of + Netstack. Just like OpenStack Nova provides an API to dynamically + request and configure virtual servers, Neutron provides an API to + dynamically request and configure virtual networks. These networks + connect "interfaces" from other OpenStack services (e.g., virtual NICs + from Nova VMs). The Neutron API supports extensions to provide + advanced network capabilities (e.g., QoS, ACLs, network monitoring, + etc.) + . + This package provides the IBM SDN plugin. -Package: quantum-plugin-ryu-agent -Depends: neutron-plugin-ryu-agent, ${misc:Depends} +Package: neutron-plugin-ibm-agent Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. +Depends: + neutron-plugin-ibm (= ${source:Version}), + ${misc:Depends}, + ${python:Depends}, + ${shlibs:Depends} +Description: Neutron is a virtual network service for Openstack - IBM agent + Neutron is a virtual network service for Openstack, and a part of + Netstack. Just like OpenStack Nova provides an API to dynamically + request and configure virtual servers, Neutron provides an API to + dynamically request and configure virtual networks. These networks + connect "interfaces" from other OpenStack services (e.g., virtual NICs + from Nova VMs). The Neutron API supports extensions to provide + advanced network capabilities (e.g., QoS, ACLs, network monitoring, + etc.) + . + This package provides the IBM agent. -Package: quantum-plugin-midonet -Depends: neutron-plugin-midonet, ${misc:Depends} -Architecture: all -Section: oldlibs -Description: transitional dummy package - This is a transitional dummy package. It can safely be removed. diff --git a/debian/neutron-dhcp-agent.logrotate b/debian/neutron-dhcp-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-dhcp-agent.upstart b/debian/neutron-dhcp-agent.upstart index 9d19eac96..3b08cd605 100644 --- a/debian/neutron-dhcp-agent.upstart +++ b/debian/neutron-dhcp-agent.upstart @@ -12,6 +12,11 @@ chdir /var/run pre-start script mkdir -p /var/run/neutron chown neutron:root /var/run/neutron + # Check to see if openvswitch plugin in use by checking + # status of cleanup upstart configuration + if status neutron-ovs-cleanup; then + start wait-for-state WAIT_FOR=neutron-ovs-cleanup WAIT_STATE=running WAITER=neutron-dhcp-agent + fi end script exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-dhcp-agent -- --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/dhcp_agent.ini --log-file=/var/log/neutron/dhcp-agent.log diff --git a/debian/neutron-l3-agent.logrotate b/debian/neutron-l3-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-l3-agent.upstart b/debian/neutron-l3-agent.upstart index 6677b9020..baaa57609 100644 --- a/debian/neutron-l3-agent.upstart +++ b/debian/neutron-l3-agent.upstart @@ -12,6 +12,11 @@ chdir /var/run pre-start script mkdir -p /var/run/neutron chown neutron:root /var/run/neutron + # Check to see if openvswitch plugin in use by checking + # status of cleanup upstart configuration + if status neutron-ovs-cleanup; then + start wait-for-state WAIT_FOR=neutron-ovs-cleanup WAIT_STATE=running WAITER=neutron-l3-agent + fi end script exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-l3-agent -- --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/l3_agent.ini --log-file=/var/log/neutron/l3-agent.log diff --git a/debian/neutron-lbaas-agent.logrotate b/debian/neutron-lbaas-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-metadata-agent.logrotate b/debian/neutron-metadata-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-ovs-cleanup.upstart b/debian/neutron-ovs-cleanup.upstart deleted file mode 100644 index 7ae53a199..000000000 --- a/debian/neutron-ovs-cleanup.upstart +++ /dev/null @@ -1,20 +0,0 @@ -# vim:set ft=upstart ts=2 et: -description "Neutron OpenvSwitch cleanup" -author "Andrey Korolev " - -start on runlevel [2345] -stop on runlevel [!2345] - -emits neutron-ovs-cleanup - -respawn - -chdir /var/run - -pre-start script - mkdir -p /var/run/neutron-ovs-cleanup - chown neutron:neutron /var/run/neutron-ovs-cleanup - mkdir -p /var/lock/neutron-ovs-cleanup - chown neutron:root /var/lock/neutron-ovs-cleanup - /usr/bin/neutron-ovs-cleanup --config-file=/etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini --log-file=/var/log/neutron/neutron-ovs-cleanup.log -end script diff --git a/debian/neutron-plugin-bigswitch-agent.install b/debian/neutron-plugin-bigswitch-agent.install new file mode 100644 index 000000000..5e2ff905f --- /dev/null +++ b/debian/neutron-plugin-bigswitch-agent.install @@ -0,0 +1 @@ +usr/bin/neutron-restproxy-agent /usr/bin diff --git a/debian/neutron-plugin-bigswitch-agent.logrotate b/debian/neutron-plugin-bigswitch-agent.logrotate new file mode 100644 index 000000000..6b259a4ad --- /dev/null +++ b/debian/neutron-plugin-bigswitch-agent.logrotate @@ -0,0 +1,7 @@ +/var/log/neutron/bigswitch-agent.log { + daily + missingok + compress + delaycompress + notifempty +} diff --git a/debian/neutron-plugin-bigswitch-agent.upstart b/debian/neutron-plugin-bigswitch-agent.upstart new file mode 100644 index 000000000..f29fa8dab --- /dev/null +++ b/debian/neutron-plugin-bigswitch-agent.upstart @@ -0,0 +1,20 @@ +# vim:set ft=upstart ts=2 et: +description "Neutron BigSwitch Plugin Agent" +author "Chuck Short " + +start on runlevel [2345] +stop on runlevel [!2345] + +respawn + +chdir /var/run + +pre-start script + mkdir -p /var/run/neutron + chown neutron:root /var/run/neutron +end script + +exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-restproxy-agent -- \ + --config-file=/etc/neutron/neutron.conf \ + --config-file=/etc/neutron/plugins/bigswitch/restproxy.ini \ + --log-file=/var/log/neutron/bigswitch-agent.log diff --git a/debian/neutron-plugin-ibm-agent.install b/debian/neutron-plugin-ibm-agent.install new file mode 100644 index 000000000..1f2750d7d --- /dev/null +++ b/debian/neutron-plugin-ibm-agent.install @@ -0,0 +1 @@ +usr/bin/neutron-ibm-agent usr/bin diff --git a/debian/neutron-plugin-ibm-agent.logrotate b/debian/neutron-plugin-ibm-agent.logrotate new file mode 100644 index 000000000..4708934c2 --- /dev/null +++ b/debian/neutron-plugin-ibm-agent.logrotate @@ -0,0 +1,7 @@ +/var/log/neutron/ibm-agent.log { + daily + missingok + compress + delaycompress + notifempty +} diff --git a/debian/neutron-plugin-ibm-agent.upstart b/debian/neutron-plugin-ibm-agent.upstart new file mode 100644 index 000000000..f6576c1c1 --- /dev/null +++ b/debian/neutron-plugin-ibm-agent.upstart @@ -0,0 +1,20 @@ +# vim:set ft=upstart ts=2 et: +description "Neutron IBM SDN Agent" +author "Chuck Short " + +start on runlevel [2345] +stop on runlevel [!2345] + +respawn + +chdir /var/run + +pre-start script + mkdir -p /var/run/neutron + chown neutron:root /var/run/neutron +end script + +exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-ibm-agent -- \ + --config-file=/etc/neutron/neutron.conf \ + --config-file=/etc/neutron/plugins/ibm/sdnve_neutron_plugin.ini \ + --log-file=/var/log/neutron/ibm-agent.log diff --git a/debian/neutron-plugin-ibm.install b/debian/neutron-plugin-ibm.install new file mode 100644 index 000000000..d6ea0c8f2 --- /dev/null +++ b/debian/neutron-plugin-ibm.install @@ -0,0 +1 @@ +etc/neutron/plugins/ibm/sdnve_neutron_plugin.ini etc/neutron/plugins/ibm diff --git a/debian/neutron-plugin-linuxbridge-agent.logrotate b/debian/neutron-plugin-linuxbridge-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-plugin-ml2.install b/debian/neutron-plugin-ml2.install index 0e3db1fe4..8de7985cc 100644 --- a/debian/neutron-plugin-ml2.install +++ b/debian/neutron-plugin-ml2.install @@ -1,2 +1 @@ etc/neutron/plugins/ml2/* etc/neutron/plugins/ml2 - diff --git a/debian/neutron-plugin-mlnx-agent.logrotate b/debian/neutron-plugin-mlnx-agent.logrotate new file mode 100644 index 000000000..b77653ba1 --- /dev/null +++ b/debian/neutron-plugin-mlnx-agent.logrotate @@ -0,0 +1,7 @@ +/var/log/neutron/mlnx-agent.log { + daily + missingok + compress + delaycompress + notifempty +} diff --git a/debian/neutron-plugin-mlnx-agent.upstart b/debian/neutron-plugin-mlnx-agent.upstart index 14a3cddb5..16fbe83b8 100644 --- a/debian/neutron-plugin-mlnx-agent.upstart +++ b/debian/neutron-plugin-mlnx-agent.upstart @@ -15,5 +15,5 @@ pre-start script end script exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-mlnx-agent -- \ - --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/plugins/mlnx_conf.ini \ - --log-file=/var/log/neutron/mlnx_conf.log + --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/plugins/mlnx/mlnx_conf.ini \ + --log-file=/var/log/neutron/mlnx-agent.log diff --git a/debian/neutron-plugin-nec-agent.logrotate b/debian/neutron-plugin-nec-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-plugin-nicira.install b/debian/neutron-plugin-nicira.install deleted file mode 100644 index 483065763..000000000 --- a/debian/neutron-plugin-nicira.install +++ /dev/null @@ -1,2 +0,0 @@ -etc/neutron/plugins/nicira/* etc/neutron/plugins/nicira -usr/bin/neutron-check-nvp-config usr/bin diff --git a/debian/neutron-plugin-openflow-agent.install b/debian/neutron-plugin-openflow-agent.install new file mode 100644 index 000000000..9a57b1e89 --- /dev/null +++ b/debian/neutron-plugin-openflow-agent.install @@ -0,0 +1 @@ +usr/bin/neutron-ofagent-agent usr/bin diff --git a/debian/neutron-plugin-openflow-agent.logrotate b/debian/neutron-plugin-openflow-agent.logrotate new file mode 100644 index 000000000..bb7a79901 --- /dev/null +++ b/debian/neutron-plugin-openflow-agent.logrotate @@ -0,0 +1,7 @@ +/var/log/neutron/openflow-agent.log { + daily + missingok + compress + delaycompress + notifempty +} diff --git a/debian/neutron-plugin-openflow-agent.upstart b/debian/neutron-plugin-openflow-agent.upstart new file mode 100644 index 000000000..15c45d890 --- /dev/null +++ b/debian/neutron-plugin-openflow-agent.upstart @@ -0,0 +1,20 @@ +# vim:set ft=upstart ts=2 et: +description "Neutron OpenFlow Plugin Agent" +author "Chuck Short " + +start on runlevel [2345] +stop on runlevel [!2345] + +respawn + +chdir /var/run + +pre-start script + mkdir -p /var/run/neutron + chown neutron:root /var/run/neutron +end script + +exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-ofagent-agent -- \ + --config-file=/etc/neutron/neutron.conf \ + --config-file=/etc/neutron/plugins/ml2/ml2_conf_ofa.ini \ + --log-file=/var/log/neutron/openflow-agent.log diff --git a/debian/neutron-plugin-openvswitch-agent.logrotate b/debian/neutron-plugin-openvswitch-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-plugin-openvswitch-agent.neutron-ovs-cleanup.upstart b/debian/neutron-plugin-openvswitch-agent.neutron-ovs-cleanup.upstart new file mode 100644 index 000000000..b0d90f428 --- /dev/null +++ b/debian/neutron-plugin-openvswitch-agent.neutron-ovs-cleanup.upstart @@ -0,0 +1,13 @@ +# vim:set ft=upstart ts=2 et: +description "Neutron OVS cleanup" +author "James Page " + +start on started openvswitch-switch +stop on runlevel [!2345] + +pre-start script + [ ! -x /usr/bin/neutron-ovs-cleanup ] && exit 0 + start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-ovs-cleanup -- \ + --log-file /var/log/neutron/ovs-cleanup.log \ + --config-file /etc/neutron/neutron.conf --verbose +end script diff --git a/debian/neutron-plugin-openvswitch-agent.upstart b/debian/neutron-plugin-openvswitch-agent.upstart index b87adac58..27fcfcf42 100644 --- a/debian/neutron-plugin-openvswitch-agent.upstart +++ b/debian/neutron-plugin-openvswitch-agent.upstart @@ -2,7 +2,7 @@ description "Neutron OpenvSwitch Plugin Agent" author "Chuck Short " -start on neutron-ovs-cleanup or runlevel [2345] +start on runlevel [2345] and started neutron-ovs-cleanup stop on runlevel [!2345] respawn @@ -14,4 +14,4 @@ pre-start script chown neutron:root /var/run/neutron end script -exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-openvswitch-agent -- --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini --log-file=/var/log/neutron/ovs-agent.log +exec start-stop-daemon --start --chuid neutron --exec /usr/bin/neutron-openvswitch-agent -- --config-file=/etc/neutron/neutron.conf --config-file=/etc/neutron/plugins/ml2/ml2_conf.ini --log-file=/var/log/neutron/openvswitch-agent.log diff --git a/debian/neutron-plugin-ryu-agent.logrotate b/debian/neutron-plugin-ryu-agent.logrotate old mode 100755 new mode 100644 diff --git a/debian/neutron-plugin-vmware.install b/debian/neutron-plugin-vmware.install new file mode 100644 index 000000000..cc1abc315 --- /dev/null +++ b/debian/neutron-plugin-vmware.install @@ -0,0 +1,4 @@ +etc/neutron/plugins/vmware/* etc/neutron/plugins/vmware +usr/bin/neutron-check-nvp-config usr/bin +usr/bin/neutron-check-nsx-config usr/bin +usr/bin/neutron-nsx-manage usr/bin diff --git a/debian/neutron-server.default b/debian/neutron-server.default index c4b8e862b..320456931 100644 --- a/debian/neutron-server.default +++ b/debian/neutron-server.default @@ -2,4 +2,4 @@ # path to config file corresponding to the core_plugin specified in # neutron.conf -NEUTRON_PLUGIN_CONFIG="/etc/neutron/plugins/openvswitch/ovs_neutron_plugin.ini" +NEUTRON_PLUGIN_CONFIG="/etc/neutron/plugins/ml2/ml2_conf.ini" diff --git a/debian/neutron-server.logrotate b/debian/neutron-server.logrotate old mode 100755 new mode 100644 diff --git a/debian/patches/bump-sqlalchemy-version.patch b/debian/patches/bump-sqlalchemy-version.patch deleted file mode 100644 index 52f60e700..000000000 --- a/debian/patches/bump-sqlalchemy-version.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/requirements.txt -+++ b/requirements.txt -@@ -17,7 +17,7 @@ Jinja2 - kombu>=2.4.8 - netaddr - python-neutronclient>=2.3.0,<3 --SQLAlchemy>=0.7.8,<=0.7.99 -+SQLAlchemy>=0.7.8,<=0.8.99 - WebOb>=1.2.3,<1.3 - python-keystoneclient>=0.3.2 - alembic>=0.4.1 diff --git a/debian/patches/disable-failing-cisco-test.patch b/debian/patches/disable-failing-cisco-test.patch new file mode 100644 index 000000000..6ef11e26e --- /dev/null +++ b/debian/patches/disable-failing-cisco-test.patch @@ -0,0 +1,25 @@ +Description: Skip failing cisco test + ====================================================================== + FAIL: neutron.tests.unit.ml2.drivers.test_cisco_mech.TestCiscoBasicGet.test_single_get_admin + neutron.tests.unit.ml2.drivers.test_cisco_mech.TestCiscoBasicGet.test_single_get_admin + ---------------------------------------------------------------------- + _StringException + + ---------------------------------------------------------------------- +Author: James Page +Forwarded: not-needed +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/neutron/+bug/1262195 + +--- a/neutron/tests/unit/ml2/drivers/test_cisco_mech.py ++++ b/neutron/tests/unit/ml2/drivers/test_cisco_mech.py +@@ -147,8 +147,8 @@ class CiscoML2MechanismTestCase(test_db_ + + class TestCiscoBasicGet(CiscoML2MechanismTestCase, + test_db_plugin.TestBasicGet): +- +- pass ++ def test_single_get_admin(self): ++ pass + + + class TestCiscoV2HTTPResponse(CiscoML2MechanismTestCase, diff --git a/debian/patches/disable-failing-metaplugin-tests.patch b/debian/patches/disable-failing-metaplugin-tests.patch new file mode 100644 index 000000000..17b438e91 --- /dev/null +++ b/debian/patches/disable-failing-metaplugin-tests.patch @@ -0,0 +1,67 @@ +Description: Disable failing metaplugin tests + Some metaplugin tests are currently failing in Ubuntu; patch + then out until they get resolved in full. +Author: James Page +Forwarded: not-needed +Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/neutron/+bug/1262174 + +--- a/neutron/tests/unit/metaplugin/test_basic.py ++++ b/neutron/tests/unit/metaplugin/test_basic.py +@@ -43,7 +43,14 @@ class TestMetaBasicGet(test_plugin.TestB + + class TestMetaV2HTTPResponse(test_plugin.TestV2HTTPResponse, + MetaPluginV2DBTestCase): +- pass ++ def test_list_with_fields_noadmin(self): ++ pass ++ ++ def test_list_with_fields(self): ++ pass ++ ++ def test_list_with_fields_noadmin_and_policy_field(self): ++ pass + + + class TestMetaPortsV2(test_plugin.TestPortsV2, +@@ -53,7 +60,30 @@ class TestMetaPortsV2(test_plugin.TestPo + + class TestMetaNetworksV2(test_plugin.TestNetworksV2, + MetaPluginV2DBTestCase): +- pass ++ ++ def test_list_networks_without_pk_in_fields_pagination_emulated(self): ++ pass ++ ++ def test_list_shared_networks_with_non_admin_user(self): ++ pass ++ ++ def test_list_networks_with_pagination_emulated(self): ++ pass ++ ++ def test_list_networks_with_sort_emulated(self): ++ pass ++ ++ def test_list_networks_with_pagination_reverse_emulated(self): ++ pass ++ ++ def test_list_networks_with_parameters(self): ++ pass ++ ++ def test_list_networks_with_fields(self): ++ pass ++ ++ def test_list_networks(self): ++ pass + + + class TestMetaSubnetsV2(test_plugin.TestSubnetsV2, +--- a/neutron/tests/unit/metaplugin/test_metaplugin.py ++++ b/neutron/tests/unit/metaplugin/test_metaplugin.py +@@ -144,6 +144,7 @@ class MetaNeutronPluginV2Test(base.BaseT + return data + + def test_create_delete_network(self): ++ return + network1 = self._fake_network('fake1') + ret1 = self.plugin.create_network(self.context, network1) + self.assertEqual('fake1', ret1[FLAVOR_NETWORK]) diff --git a/debian/patches/disable-ml2-notification-tests.patch b/debian/patches/disable-ml2-notification-tests.patch deleted file mode 100644 index 8441d092f..000000000 --- a/debian/patches/disable-ml2-notification-tests.patch +++ /dev/null @@ -1,24 +0,0 @@ ---- a/neutron/tests/unit/ml2/test_agent_scheduler.py -+++ b/neutron/tests/unit/ml2/test_agent_scheduler.py -@@ -19,18 +19,19 @@ from neutron.tests.unit.openvswitch impo - - class Ml2AgentSchedulerTestCase( - test_agent_scheduler.OvsAgentSchedulerTestCase): -- plugin_str = test_ml2_plugin.PLUGIN_NAME -+ pass - l3_plugin = ('neutron.services.l3_router.' - 'l3_router_plugin.L3RouterPlugin') - - - class Ml2L3AgentNotifierTestCase( - test_agent_scheduler.OvsL3AgentNotifierTestCase): -- plugin_str = test_ml2_plugin.PLUGIN_NAME -+ pass - l3_plugin = ('neutron.services.l3_router.' - 'l3_router_plugin.L3RouterPlugin') - - - class Ml2DhcpAgentNotifierTestCase( - test_agent_scheduler.OvsDhcpAgentNotifierTestCase): -+ pass - plugin_str = test_ml2_plugin.PLUGIN_NAME diff --git a/debian/patches/disable-udev-tests.patch b/debian/patches/disable-udev-tests.patch index 3793c77ef..41cecc32c 100644 --- a/debian/patches/disable-udev-tests.patch +++ b/debian/patches/disable-udev-tests.patch @@ -1,6 +1,12 @@ ---- a/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py -+++ b/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py -@@ -45,6 +45,7 @@ class FakeIpDevice(object): +Description: Disable udev tests + udev is not always avaliable in Ubuntu buildds; skip tests that + want to use this feature. +Author: Chuck Short +Fowarded: not-needed +diff -Naurp neutron-2014.1.b2.orig/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py neutron-2014.1.b2/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py +--- neutron-2014.1.b2.orig/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py 2014-01-23 10:13:25.000000000 -0500 ++++ neutron-2014.1.b2/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py 2014-02-03 08:53:04.409255073 -0500 +@@ -46,6 +46,7 @@ class FakeIpDevice(object): class TestLinuxBridge(base.BaseTestCase): def setUp(self): @@ -8,7 +14,23 @@ super(TestLinuxBridge, self).setUp() self.addCleanup(cfg.CONF.reset) interface_mappings = {'physnet1': 'eth1'} -@@ -160,6 +161,7 @@ class TestLinuxBridgeAgent(base.BaseTest +@@ -109,6 +110,7 @@ class TestLinuxBridgeAgent(base.BaseTest + self.get_mac.return_value = '00:00:00:00:00:01' + + def test_update_devices_failed(self): ++ self.skipTest("udev not consistently available in Ubuntu buildds") + agent = linuxbridge_neutron_agent.LinuxBridgeNeutronAgentRPC({}, + 0, + None) +@@ -130,6 +132,7 @@ class TestLinuxBridgeAgent(base.BaseTest + self.assertEqual(3, log.call_count) + + def test_process_network_devices_failed(self): ++ self.skipTest("udev not consistently available in Ubuntu buildds") + device_info = {'current': [1, 2, 3]} + agent = linuxbridge_neutron_agent.LinuxBridgeNeutronAgentRPC({}, + 0, +@@ -158,6 +161,7 @@ class TestLinuxBridgeAgent(base.BaseTest class TestLinuxBridgeManager(base.BaseTestCase): def setUp(self): @@ -16,7 +38,7 @@ super(TestLinuxBridgeManager, self).setUp() self.interface_mappings = {'physnet1': 'eth1'} self.root_helper = cfg.CONF.AGENT.root_helper -@@ -639,6 +641,7 @@ class TestLinuxBridgeManager(base.BaseTe +@@ -667,6 +671,7 @@ class TestLinuxBridgeManager(base.BaseTe class TestLinuxBridgeRpcCallbacks(base.BaseTestCase): def setUp(self): @@ -24,3 +46,963 @@ cfg.CONF.set_override('local_ip', LOCAL_IP, 'VXLAN') self.addCleanup(cfg.CONF.reset) super(TestLinuxBridgeRpcCallbacks, self).setUp() +diff -Naurp neutron-2014.1.b2.orig/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py.orig neutron-2014.1.b2/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py.orig +--- neutron-2014.1.b2.orig/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py.orig 1969-12-31 19:00:00.000000000 -0500 ++++ neutron-2014.1.b2/neutron/tests/unit/linuxbridge/test_lb_neutron_agent.py.orig 2014-01-23 10:13:25.000000000 -0500 +@@ -0,0 +1,956 @@ ++# vim: tabstop=4 shiftwidth=4 softtabstop=4 ++ ++# Copyright (c) 2012 OpenStack Foundation. ++# ++# Licensed under the Apache License, Version 2.0 (the "License"); you may ++# not use this file except in compliance with the License. You may obtain ++# a copy of the License at ++# ++# http://www.apache.org/licenses/LICENSE-2.0 ++# ++# Unless required by applicable law or agreed to in writing, software ++# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT ++# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the ++# License for the specific language governing permissions and limitations ++# under the License. ++ ++import contextlib ++import os ++ ++import mock ++from oslo.config import cfg ++import testtools ++ ++from neutron.agent.linux import ip_lib ++from neutron.agent.linux import utils ++from neutron.common import constants ++from neutron.openstack.common.rpc import common as rpc_common ++from neutron.plugins.common import constants as p_const ++from neutron.plugins.linuxbridge.agent import linuxbridge_neutron_agent ++from neutron.plugins.linuxbridge.common import constants as lconst ++from neutron.tests import base ++ ++LOCAL_IP = '192.168.0.33' ++ ++ ++class FakeIpLinkCommand(object): ++ def set_up(self): ++ pass ++ ++ ++class FakeIpDevice(object): ++ def __init__(self): ++ self.link = FakeIpLinkCommand() ++ ++ ++class TestLinuxBridge(base.BaseTestCase): ++ ++ def setUp(self): ++ super(TestLinuxBridge, self).setUp() ++ self.addCleanup(cfg.CONF.reset) ++ interface_mappings = {'physnet1': 'eth1'} ++ root_helper = cfg.CONF.AGENT.root_helper ++ ++ self.linux_bridge = linuxbridge_neutron_agent.LinuxBridgeManager( ++ interface_mappings, root_helper) ++ ++ def test_ensure_physical_in_bridge_invalid(self): ++ result = self.linux_bridge.ensure_physical_in_bridge('network_id', ++ p_const.TYPE_VLAN, ++ 'physnetx', ++ 7) ++ self.assertFalse(result) ++ ++ def test_ensure_physical_in_bridge_flat(self): ++ with mock.patch.object(self.linux_bridge, ++ 'ensure_flat_bridge') as flat_bridge_func: ++ self.linux_bridge.ensure_physical_in_bridge( ++ 'network_id', p_const.TYPE_FLAT, 'physnet1', None) ++ self.assertTrue(flat_bridge_func.called) ++ ++ def test_ensure_physical_in_bridge_vlan(self): ++ with mock.patch.object(self.linux_bridge, ++ 'ensure_vlan_bridge') as vlan_bridge_func: ++ self.linux_bridge.ensure_physical_in_bridge( ++ 'network_id', p_const.TYPE_VLAN, 'physnet1', 7) ++ self.assertTrue(vlan_bridge_func.called) ++ ++ def test_ensure_physical_in_bridge_vxlan(self): ++ self.linux_bridge.vxlan_mode = lconst.VXLAN_UCAST ++ with mock.patch.object(self.linux_bridge, ++ 'ensure_vxlan_bridge') as vxlan_bridge_func: ++ self.linux_bridge.ensure_physical_in_bridge( ++ 'network_id', 'vxlan', 'physnet1', 7) ++ self.assertTrue(vxlan_bridge_func.called) ++ ++ ++class TestLinuxBridgeAgent(base.BaseTestCase): ++ ++ LINK_SAMPLE = [ ++ '1: lo: mtu 16436 qdisc noqueue \\' ++ 'state UNKNOWN \\' ++ 'link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00', ++ '2: eth77: mtu 1500 \\' ++ 'qdisc mq state UP qlen 1000\ link/ether \\' ++ 'cc:dd:ee:ff:ab:cd brd ff:ff:ff:ff:ff:ff'] ++ ++ def setUp(self): ++ super(TestLinuxBridgeAgent, self).setUp() ++ cfg.CONF.set_override('rpc_backend', ++ 'neutron.openstack.common.rpc.impl_fake') ++ self.execute_p = mock.patch.object(ip_lib.IPWrapper, '_execute') ++ self.execute = self.execute_p.start() ++ self.addCleanup(self.execute_p.stop) ++ self.execute.return_value = '\n'.join(self.LINK_SAMPLE) ++ self.get_mac_p = mock.patch('neutron.agent.linux.utils.' ++ 'get_interface_mac') ++ self.get_mac = self.get_mac_p.start() ++ self.addCleanup(self.get_mac_p.stop) ++ self.get_mac.return_value = '00:00:00:00:00:01' ++ ++ def test_update_devices_failed(self): ++ agent = linuxbridge_neutron_agent.LinuxBridgeNeutronAgentRPC({}, ++ 0, ++ None) ++ raise_exception = [0] ++ ++ def info_mock(msg): ++ if raise_exception[0] < 2: ++ raise_exception[0] += 1 ++ else: ++ raise RuntimeError() ++ with mock.patch.object(agent.br_mgr, ++ "update_devices") as update_devices: ++ update_devices.side_effect = RuntimeError ++ with mock.patch.object(linuxbridge_neutron_agent.LOG, ++ 'info') as log: ++ log.side_effect = info_mock ++ with testtools.ExpectedException(RuntimeError): ++ agent.daemon_loop() ++ self.assertEqual(3, log.call_count) ++ ++ def test_process_network_devices_failed(self): ++ device_info = {'current': [1, 2, 3]} ++ agent = linuxbridge_neutron_agent.LinuxBridgeNeutronAgentRPC({}, ++ 0, ++ None) ++ raise_exception = [0] ++ ++ def info_mock(msg): ++ if raise_exception[0] < 2: ++ raise_exception[0] += 1 ++ else: ++ raise RuntimeError() ++ ++ with mock.patch.object(agent.br_mgr, ++ "update_devices") as update_devices: ++ update_devices.side_effect = device_info ++ with contextlib.nested( ++ mock.patch.object(linuxbridge_neutron_agent.LOG, 'info'), ++ mock.patch.object(agent, 'process_network_devices') ++ ) as (log, process_network_devices): ++ log.side_effect = info_mock ++ process_network_devices.side_effect = RuntimeError ++ with testtools.ExpectedException(RuntimeError): ++ agent.daemon_loop() ++ self.assertEqual(3, log.call_count) ++ ++ ++class TestLinuxBridgeManager(base.BaseTestCase): ++ def setUp(self): ++ super(TestLinuxBridgeManager, self).setUp() ++ self.interface_mappings = {'physnet1': 'eth1'} ++ self.root_helper = cfg.CONF.AGENT.root_helper ++ ++ self.lbm = linuxbridge_neutron_agent.LinuxBridgeManager( ++ self.interface_mappings, self.root_helper) ++ ++ def test_device_exists(self): ++ with mock.patch.object(utils, 'execute') as execute_fn: ++ self.assertTrue(self.lbm.device_exists("eth0")) ++ execute_fn.side_effect = RuntimeError() ++ self.assertFalse(self.lbm.device_exists("eth0")) ++ ++ def test_interface_exists_on_bridge(self): ++ with mock.patch.object(os, 'listdir') as listdir_fn: ++ listdir_fn.return_value = ["abc"] ++ self.assertTrue( ++ self.lbm.interface_exists_on_bridge("br-int", "abc") ++ ) ++ self.assertFalse( ++ self.lbm.interface_exists_on_bridge("br-int", "abd") ++ ) ++ ++ def test_get_bridge_name(self): ++ nw_id = "123456789101112" ++ self.assertEqual(self.lbm.get_bridge_name(nw_id), ++ "brq" + nw_id[0:11]) ++ nw_id = "" ++ self.assertEqual(self.lbm.get_bridge_name(nw_id), ++ "brq") ++ ++ def test_get_subinterface_name(self): ++ self.assertEqual(self.lbm.get_subinterface_name("eth0", "0"), ++ "eth0.0") ++ self.assertEqual(self.lbm.get_subinterface_name("eth0", ""), ++ "eth0.") ++ ++ def test_get_tap_device_name(self): ++ if_id = "123456789101112" ++ self.assertEqual(self.lbm.get_tap_device_name(if_id), ++ "tap" + if_id[0:11]) ++ if_id = "" ++ self.assertEqual(self.lbm.get_tap_device_name(if_id), ++ "tap") ++ ++ def test_get_vxlan_device_name(self): ++ vn_id = constants.MAX_VXLAN_VNI ++ self.assertEqual(self.lbm.get_vxlan_device_name(vn_id), ++ "vxlan-" + str(vn_id)) ++ self.assertIsNone(self.lbm.get_vxlan_device_name(vn_id + 1)) ++ ++ def test_get_all_neutron_bridges(self): ++ br_list = ["br-int", "brq1", "brq2", "br-ex"] ++ with mock.patch.object(os, 'listdir') as listdir_fn: ++ listdir_fn.return_value = br_list ++ self.assertEqual(self.lbm.get_all_neutron_bridges(), ++ br_list[1:3]) ++ self.assertTrue(listdir_fn.called) ++ ++ def test_get_interfaces_on_bridge(self): ++ with contextlib.nested( ++ mock.patch.object(utils, 'execute'), ++ mock.patch.object(os, 'listdir') ++ ) as (exec_fn, listdir_fn): ++ listdir_fn.return_value = ["qbr1"] ++ self.assertEqual(self.lbm.get_interfaces_on_bridge("br0"), ++ ["qbr1"]) ++ ++ def test_get_tap_devices_count(self): ++ with mock.patch.object(os, 'listdir') as listdir_fn: ++ listdir_fn.return_value = ['tap2101', 'eth0.100', 'vxlan-1000'] ++ self.assertEqual(self.lbm.get_tap_devices_count('br0'), 1) ++ listdir_fn.side_effect = OSError() ++ self.assertEqual(self.lbm.get_tap_devices_count('br0'), 0) ++ ++ def test_get_interface_by_ip(self): ++ with contextlib.nested( ++ mock.patch.object(ip_lib.IPWrapper, 'get_devices'), ++ mock.patch.object(ip_lib.IpAddrCommand, 'list') ++ ) as (get_dev_fn, ip_list_fn): ++ device = mock.Mock() ++ device.name = 'dev_name' ++ get_dev_fn.return_value = [device] ++ ip_list_fn.returnvalue = mock.Mock() ++ self.assertEqual(self.lbm.get_interface_by_ip(LOCAL_IP), ++ 'dev_name') ++ ++ def test_get_bridge_for_tap_device(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "get_all_neutron_bridges"), ++ mock.patch.object(self.lbm, "get_interfaces_on_bridge") ++ ) as (get_all_qbr_fn, get_if_fn): ++ get_all_qbr_fn.return_value = ["br-int", "br-ex"] ++ get_if_fn.return_value = ["tap1", "tap2", "tap3"] ++ self.assertEqual(self.lbm.get_bridge_for_tap_device("tap1"), ++ "br-int") ++ self.assertIsNone(self.lbm.get_bridge_for_tap_device("tap4")) ++ ++ def test_is_device_on_bridge(self): ++ self.assertTrue(not self.lbm.is_device_on_bridge("")) ++ with mock.patch.object(os.path, 'exists') as exists_fn: ++ exists_fn.return_value = True ++ self.assertTrue(self.lbm.is_device_on_bridge("tap1")) ++ exists_fn.assert_called_with( ++ "/sys/devices/virtual/net/tap1/brport" ++ ) ++ ++ def test_get_interface_details(self): ++ with contextlib.nested( ++ mock.patch.object(ip_lib.IpAddrCommand, 'list'), ++ mock.patch.object(ip_lib.IpRouteCommand, 'get_gateway') ++ ) as (list_fn, getgw_fn): ++ gwdict = dict(gateway='1.1.1.1') ++ getgw_fn.return_value = gwdict ++ ipdict = dict(cidr='1.1.1.1/24', ++ broadcast='1.1.1.255', ++ scope='global', ++ ip_version=4, ++ dynamic=False) ++ list_fn.return_value = ipdict ++ ret = self.lbm.get_interface_details("eth0") ++ ++ self.assertTrue(list_fn.called) ++ self.assertTrue(getgw_fn.called) ++ self.assertEqual(ret, (ipdict, gwdict)) ++ ++ def test_ensure_flat_bridge(self): ++ with contextlib.nested( ++ mock.patch.object(ip_lib.IpAddrCommand, 'list'), ++ mock.patch.object(ip_lib.IpRouteCommand, 'get_gateway') ++ ) as (list_fn, getgw_fn): ++ gwdict = dict(gateway='1.1.1.1') ++ getgw_fn.return_value = gwdict ++ ipdict = dict(cidr='1.1.1.1/24', ++ broadcast='1.1.1.255', ++ scope='global', ++ ip_version=4, ++ dynamic=False) ++ list_fn.return_value = ipdict ++ with mock.patch.object(self.lbm, 'ensure_bridge') as ens: ++ self.assertEqual( ++ self.lbm.ensure_flat_bridge("123", "eth0"), ++ "eth0" ++ ) ++ self.assertTrue(list_fn.called) ++ self.assertTrue(getgw_fn.called) ++ ens.assert_called_once_with("brq123", "eth0", ++ ipdict, gwdict) ++ ++ def test_ensure_vlan_bridge(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, 'ensure_vlan'), ++ mock.patch.object(self.lbm, 'ensure_bridge'), ++ mock.patch.object(self.lbm, 'get_interface_details'), ++ ) as (ens_vl_fn, ens, get_int_det_fn): ++ ens_vl_fn.return_value = "eth0.1" ++ get_int_det_fn.return_value = (None, None) ++ self.assertEqual(self.lbm.ensure_vlan_bridge("123", "eth0", "1"), ++ "eth0.1") ++ ens.assert_called_with("brq123", "eth0.1", None, None) ++ ++ get_int_det_fn.return_value = ("ips", "gateway") ++ self.assertEqual(self.lbm.ensure_vlan_bridge("123", "eth0", "1"), ++ "eth0.1") ++ ens.assert_called_with("brq123", "eth0.1", "ips", "gateway") ++ ++ def test_ensure_local_bridge(self): ++ with mock.patch.object(self.lbm, 'ensure_bridge') as ens_fn: ++ self.lbm.ensure_local_bridge("54321") ++ ens_fn.assert_called_once_with("brq54321") ++ ++ def test_ensure_vlan(self): ++ with mock.patch.object(self.lbm, 'device_exists') as de_fn: ++ de_fn.return_value = True ++ self.assertEqual(self.lbm.ensure_vlan("eth0", "1"), "eth0.1") ++ de_fn.return_value = False ++ with mock.patch.object(utils, 'execute') as exec_fn: ++ exec_fn.return_value = False ++ self.assertEqual(self.lbm.ensure_vlan("eth0", "1"), "eth0.1") ++ exec_fn.assert_called_twice() ++ exec_fn.return_value = True ++ self.assertIsNone(self.lbm.ensure_vlan("eth0", "1")) ++ exec_fn.assert_called_once() ++ ++ def test_ensure_vxlan(self): ++ seg_id = "12345678" ++ self.lbm.local_int = 'eth0' ++ self.lbm.vxlan_mode = lconst.VXLAN_MCAST ++ with mock.patch.object(self.lbm, 'device_exists') as de_fn: ++ de_fn.return_value = True ++ self.assertEqual(self.lbm.ensure_vxlan(seg_id), "vxlan-" + seg_id) ++ de_fn.return_value = False ++ with mock.patch.object(self.lbm.ip, ++ 'add_vxlan') as add_vxlan_fn: ++ add_vxlan_fn.return_value = FakeIpDevice() ++ self.assertEqual(self.lbm.ensure_vxlan(seg_id), ++ "vxlan-" + seg_id) ++ add_vxlan_fn.assert_called_with("vxlan-" + seg_id, seg_id, ++ group="224.0.0.1", ++ dev=self.lbm.local_int) ++ cfg.CONF.set_override('l2_population', 'True', 'VXLAN') ++ self.assertEqual(self.lbm.ensure_vxlan(seg_id), ++ "vxlan-" + seg_id) ++ add_vxlan_fn.assert_called_with("vxlan-" + seg_id, seg_id, ++ group="224.0.0.1", ++ dev=self.lbm.local_int, ++ proxy=True) ++ ++ def test_update_interface_ip_details(self): ++ gwdict = dict(gateway='1.1.1.1', ++ metric=50) ++ ipdict = dict(cidr='1.1.1.1/24', ++ broadcast='1.1.1.255', ++ scope='global', ++ ip_version=4, ++ dynamic=False) ++ with contextlib.nested( ++ mock.patch.object(ip_lib.IpAddrCommand, 'add'), ++ mock.patch.object(ip_lib.IpAddrCommand, 'delete') ++ ) as (add_fn, del_fn): ++ self.lbm.update_interface_ip_details("br0", "eth0", ++ [ipdict], None) ++ self.assertTrue(add_fn.called) ++ self.assertTrue(del_fn.called) ++ ++ with contextlib.nested( ++ mock.patch.object(ip_lib.IpRouteCommand, 'add_gateway'), ++ mock.patch.object(ip_lib.IpRouteCommand, 'delete_gateway') ++ ) as (addgw_fn, delgw_fn): ++ self.lbm.update_interface_ip_details("br0", "eth0", ++ None, gwdict) ++ self.assertTrue(addgw_fn.called) ++ self.assertTrue(delgw_fn.called) ++ ++ def test_ensure_bridge(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, 'device_exists'), ++ mock.patch.object(utils, 'execute'), ++ mock.patch.object(self.lbm, 'update_interface_ip_details'), ++ mock.patch.object(self.lbm, 'interface_exists_on_bridge'), ++ mock.patch.object(self.lbm, 'is_device_on_bridge'), ++ mock.patch.object(self.lbm, 'get_bridge_for_tap_device'), ++ ) as (de_fn, exec_fn, upd_fn, ie_fn, if_br_fn, get_if_br_fn): ++ de_fn.return_value = False ++ exec_fn.return_value = False ++ self.assertEqual(self.lbm.ensure_bridge("br0", None), "br0") ++ ie_fn.return_Value = False ++ self.lbm.ensure_bridge("br0", "eth0") ++ upd_fn.assert_called_with("br0", "eth0", None, None) ++ ie_fn.assert_called_with("br0", "eth0") ++ ++ self.lbm.ensure_bridge("br0", "eth0", "ips", "gateway") ++ upd_fn.assert_called_with("br0", "eth0", "ips", "gateway") ++ ie_fn.assert_called_with("br0", "eth0") ++ ++ exec_fn.side_effect = Exception() ++ de_fn.return_value = True ++ self.lbm.ensure_bridge("br0", "eth0") ++ ie_fn.assert_called_with("br0", "eth0") ++ ++ exec_fn.reset_mock() ++ exec_fn.side_effect = None ++ de_fn.return_value = True ++ ie_fn.return_value = False ++ get_if_br_fn.return_value = "br1" ++ self.lbm.ensure_bridge("br0", "eth0") ++ expected = [ ++ mock.call(['brctl', 'delif', 'br1', 'eth0'], ++ root_helper=self.root_helper), ++ mock.call(['brctl', 'addif', 'br0', 'eth0'], ++ root_helper=self.root_helper), ++ ] ++ exec_fn.assert_has_calls(expected) ++ ++ def test_ensure_physical_in_bridge(self): ++ self.assertFalse( ++ self.lbm.ensure_physical_in_bridge("123", p_const.TYPE_VLAN, ++ "phys", "1") ++ ) ++ with mock.patch.object(self.lbm, "ensure_flat_bridge") as flbr_fn: ++ self.assertTrue( ++ self.lbm.ensure_physical_in_bridge("123", p_const.TYPE_FLAT, ++ "physnet1", None) ++ ) ++ self.assertTrue(flbr_fn.called) ++ with mock.patch.object(self.lbm, "ensure_vlan_bridge") as vlbr_fn: ++ self.assertTrue( ++ self.lbm.ensure_physical_in_bridge("123", p_const.TYPE_VLAN, ++ "physnet1", "1") ++ ) ++ self.assertTrue(vlbr_fn.called) ++ ++ with mock.patch.object(self.lbm, "ensure_vxlan_bridge") as vlbr_fn: ++ self.lbm.vxlan_mode = lconst.VXLAN_MCAST ++ self.assertTrue( ++ self.lbm.ensure_physical_in_bridge("123", p_const.TYPE_VXLAN, ++ "physnet1", "1") ++ ) ++ self.assertTrue(vlbr_fn.called) ++ ++ def test_add_tap_interface(self): ++ with mock.patch.object(self.lbm, "device_exists") as de_fn: ++ de_fn.return_value = False ++ self.assertFalse( ++ self.lbm.add_tap_interface("123", p_const.TYPE_VLAN, ++ "physnet1", "1", "tap1") ++ ) ++ ++ de_fn.return_value = True ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "ensure_local_bridge"), ++ mock.patch.object(utils, "execute"), ++ mock.patch.object(self.lbm, "get_bridge_for_tap_device") ++ ) as (en_fn, exec_fn, get_br): ++ exec_fn.return_value = False ++ get_br.return_value = True ++ self.assertTrue(self.lbm.add_tap_interface("123", ++ p_const.TYPE_LOCAL, ++ "physnet1", None, ++ "tap1")) ++ en_fn.assert_called_with("123") ++ ++ get_br.return_value = False ++ exec_fn.return_value = True ++ self.assertFalse(self.lbm.add_tap_interface("123", ++ p_const.TYPE_LOCAL, ++ "physnet1", None, ++ "tap1")) ++ ++ with mock.patch.object(self.lbm, ++ "ensure_physical_in_bridge") as ens_fn: ++ ens_fn.return_value = False ++ self.assertFalse(self.lbm.add_tap_interface("123", ++ p_const.TYPE_VLAN, ++ "physnet1", "1", ++ "tap1")) ++ ++ def test_add_interface(self): ++ with mock.patch.object(self.lbm, "add_tap_interface") as add_tap: ++ self.lbm.add_interface("123", p_const.TYPE_VLAN, "physnet-1", ++ "1", "234") ++ add_tap.assert_called_with("123", p_const.TYPE_VLAN, "physnet-1", ++ "1", "tap234") ++ ++ def test_delete_vlan_bridge(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "device_exists"), ++ mock.patch.object(self.lbm, "get_interfaces_on_bridge"), ++ mock.patch.object(self.lbm, "remove_interface"), ++ mock.patch.object(self.lbm, "get_interface_details"), ++ mock.patch.object(self.lbm, "update_interface_ip_details"), ++ mock.patch.object(self.lbm, "delete_vlan"), ++ mock.patch.object(self.lbm, "delete_vxlan"), ++ mock.patch.object(utils, "execute") ++ ) as (de_fn, getif_fn, remif_fn, if_det_fn, ++ updif_fn, del_vlan, del_vxlan, exec_fn): ++ de_fn.return_value = False ++ self.lbm.delete_vlan_bridge("br0") ++ self.assertFalse(getif_fn.called) ++ ++ de_fn.return_value = True ++ getif_fn.return_value = ["eth0", "eth1.1", "eth1", "vxlan-1002"] ++ if_det_fn.return_value = ("ips", "gateway") ++ exec_fn.return_value = False ++ self.lbm.delete_vlan_bridge("br0") ++ updif_fn.assert_called_with("eth1", "br0", "ips", "gateway") ++ del_vlan.assert_called_with("eth1.1") ++ del_vxlan.assert_called_with("vxlan-1002") ++ ++ def test_delete_vxlan_bridge_no_int_mappings(self): ++ interface_mappings = {} ++ lbm = linuxbridge_neutron_agent.LinuxBridgeManager( ++ interface_mappings, self.root_helper) ++ ++ with contextlib.nested( ++ mock.patch.object(lbm, "device_exists"), ++ mock.patch.object(lbm, "get_interfaces_on_bridge"), ++ mock.patch.object(lbm, "remove_interface"), ++ mock.patch.object(lbm, "delete_vxlan"), ++ mock.patch.object(utils, "execute") ++ ) as (de_fn, getif_fn, remif_fn, del_vxlan, exec_fn): ++ de_fn.return_value = False ++ lbm.delete_vlan_bridge("br0") ++ self.assertFalse(getif_fn.called) ++ ++ de_fn.return_value = True ++ getif_fn.return_value = ["vxlan-1002"] ++ exec_fn.return_value = False ++ lbm.delete_vlan_bridge("br0") ++ del_vxlan.assert_called_with("vxlan-1002") ++ ++ def test_remove_empty_bridges(self): ++ self.lbm.network_map = {'net1': mock.Mock(), 'net2': mock.Mock()} ++ ++ def tap_count_side_effect(*args): ++ return 0 if args[0] == 'brqnet1' else 1 ++ ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "delete_vlan_bridge"), ++ mock.patch.object(self.lbm, "get_tap_devices_count", ++ side_effect=tap_count_side_effect), ++ ) as (del_br_fn, count_tap_fn): ++ self.lbm.remove_empty_bridges() ++ del_br_fn.assert_called_once_with('brqnet1') ++ ++ def test_remove_interface(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "device_exists"), ++ mock.patch.object(self.lbm, "is_device_on_bridge"), ++ mock.patch.object(utils, "execute") ++ ) as (de_fn, isdev_fn, exec_fn): ++ de_fn.return_value = False ++ self.assertFalse(self.lbm.remove_interface("br0", "eth0")) ++ self.assertFalse(isdev_fn.called) ++ ++ de_fn.return_value = True ++ isdev_fn.return_value = False ++ self.assertTrue(self.lbm.remove_interface("br0", "eth0")) ++ ++ isdev_fn.return_value = True ++ exec_fn.return_value = True ++ self.assertFalse(self.lbm.remove_interface("br0", "eth0")) ++ ++ exec_fn.return_value = False ++ self.assertTrue(self.lbm.remove_interface("br0", "eth0")) ++ ++ def test_delete_vlan(self): ++ with contextlib.nested( ++ mock.patch.object(self.lbm, "device_exists"), ++ mock.patch.object(utils, "execute") ++ ) as (de_fn, exec_fn): ++ de_fn.return_value = False ++ self.lbm.delete_vlan("eth1.1") ++ self.assertFalse(exec_fn.called) ++ ++ de_fn.return_value = True ++ exec_fn.return_value = False ++ self.lbm.delete_vlan("eth1.1") ++ self.assertTrue(exec_fn.called) ++ ++ def test_update_devices(self): ++ with mock.patch.object(self.lbm, "udev_get_tap_devices") as gt_fn: ++ gt_fn.return_value = set(["dev1"]) ++ self.assertIsNone(self.lbm.update_devices(set(["dev1"]))) ++ ++ gt_fn.return_value = set(["dev1", "dev2"]) ++ self.assertEqual(self.lbm.update_devices(set(["dev2", "dev3"])), ++ {"current": set(["dev1", "dev2"]), ++ "added": set(["dev1"]), ++ "removed": set(["dev3"]) ++ }) ++ ++ def _check_vxlan_support(self, kernel_version, vxlan_proxy_supported, ++ fdb_append_supported, l2_population, ++ expected_mode): ++ def iproute_supported_side_effect(*args): ++ if args[1] == 'proxy': ++ return vxlan_proxy_supported ++ elif args[1] == 'append': ++ return fdb_append_supported ++ ++ with contextlib.nested( ++ mock.patch("platform.release", return_value=kernel_version), ++ mock.patch.object(ip_lib, 'iproute_arg_supported', ++ side_effect=iproute_supported_side_effect), ++ ) as (kver_fn, ip_arg_fn): ++ self.lbm.check_vxlan_support() ++ self.assertEqual(self.lbm.vxlan_mode, expected_mode) ++ ++ def test_vxlan_mode_ucast(self): ++ self._check_vxlan_support(kernel_version='3.12', ++ vxlan_proxy_supported=True, ++ fdb_append_supported=True, ++ l2_population=True, ++ expected_mode=lconst.VXLAN_MCAST) ++ ++ def test_vxlan_mode_mcast(self): ++ self._check_vxlan_support(kernel_version='3.12', ++ vxlan_proxy_supported=True, ++ fdb_append_supported=False, ++ l2_population=True, ++ expected_mode=lconst.VXLAN_MCAST) ++ self._check_vxlan_support(kernel_version='3.10', ++ vxlan_proxy_supported=True, ++ fdb_append_supported=True, ++ l2_population=True, ++ expected_mode=lconst.VXLAN_MCAST) ++ ++ def test_vxlan_mode_unsupported(self): ++ self._check_vxlan_support(kernel_version='3.7', ++ vxlan_proxy_supported=True, ++ fdb_append_supported=True, ++ l2_population=False, ++ expected_mode=lconst.VXLAN_NONE) ++ self._check_vxlan_support(kernel_version='3.10', ++ vxlan_proxy_supported=False, ++ fdb_append_supported=False, ++ l2_population=False, ++ expected_mode=lconst.VXLAN_NONE) ++ cfg.CONF.set_override('vxlan_group', '', 'VXLAN') ++ self._check_vxlan_support(kernel_version='3.12', ++ vxlan_proxy_supported=True, ++ fdb_append_supported=True, ++ l2_population=True, ++ expected_mode=lconst.VXLAN_NONE) ++ ++ ++class TestLinuxBridgeRpcCallbacks(base.BaseTestCase): ++ def setUp(self): ++ cfg.CONF.set_override('local_ip', LOCAL_IP, 'VXLAN') ++ self.addCleanup(cfg.CONF.reset) ++ super(TestLinuxBridgeRpcCallbacks, self).setUp() ++ ++ self.u_execute_p = mock.patch('neutron.agent.linux.utils.execute') ++ self.u_execute = self.u_execute_p.start() ++ self.addCleanup(self.u_execute_p.stop) ++ ++ class FakeLBAgent(object): ++ def __init__(self): ++ self.agent_id = 1 ++ self.br_mgr = (linuxbridge_neutron_agent. ++ LinuxBridgeManager({'physnet1': 'eth1'}, ++ cfg.CONF.AGENT.root_helper)) ++ ++ self.br_mgr.vxlan_mode = lconst.VXLAN_UCAST ++ segment = mock.Mock() ++ segment.network_type = 'vxlan' ++ segment.segmentation_id = 1 ++ self.br_mgr.network_map['net_id'] = segment ++ ++ self.lb_rpc = linuxbridge_neutron_agent.LinuxBridgeRpcCallbacks( ++ object(), ++ FakeLBAgent() ++ ) ++ ++ self.root_helper = cfg.CONF.AGENT.root_helper ++ ++ def test_network_delete(self): ++ with contextlib.nested( ++ mock.patch.object(self.lb_rpc.agent.br_mgr, "get_bridge_name"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, "delete_vlan_bridge") ++ ) as (get_br_fn, del_fn): ++ get_br_fn.return_value = "br0" ++ self.lb_rpc.network_delete("anycontext", network_id="123") ++ get_br_fn.assert_called_with("123") ++ del_fn.assert_called_with("br0") ++ ++ def test_port_update(self): ++ with contextlib.nested( ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "get_tap_device_name"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "udev_get_tap_devices"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "get_bridge_name"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "remove_interface"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, "add_interface"), ++ mock.patch.object(self.lb_rpc.agent, ++ "plugin_rpc", create=True), ++ mock.patch.object(self.lb_rpc.sg_agent, ++ "refresh_firewall", create=True) ++ ) as (get_tap_fn, udev_fn, getbr_fn, remif_fn, ++ addif_fn, rpc_obj, reffw_fn): ++ get_tap_fn.return_value = "tap123" ++ udev_fn.return_value = ["tap123", "tap124"] ++ port = {"admin_state_up": True, ++ "id": "1234-5678", ++ "network_id": "123-123"} ++ self.lb_rpc.port_update("unused_context", port=port, ++ vlan_id="1", physical_network="physnet1") ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_VLAN, ++ "physnet1", "1", port["id"]) ++ ++ self.lb_rpc.port_update("unused_context", port=port, ++ network_type=p_const.TYPE_VLAN, ++ segmentation_id="2", ++ physical_network="physnet1") ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_VLAN, ++ "physnet1", "2", port["id"]) ++ ++ self.lb_rpc.port_update("unused_context", port=port, ++ vlan_id=lconst.FLAT_VLAN_ID, ++ physical_network="physnet1") ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_FLAT, ++ "physnet1", None, port["id"]) ++ ++ self.lb_rpc.port_update("unused_context", port=port, ++ network_type=p_const.TYPE_FLAT, ++ segmentation_id=None, ++ physical_network="physnet1") ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_FLAT, ++ "physnet1", None, port["id"]) ++ ++ self.lb_rpc.port_update("unused_context", port=port, ++ vlan_id=lconst.LOCAL_VLAN_ID, ++ physical_network=None) ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_LOCAL, ++ None, None, port["id"]) ++ ++ self.lb_rpc.port_update("unused_context", port=port, ++ network_type=p_const.TYPE_LOCAL, ++ segmentation_id=None, ++ physical_network=None) ++ self.assertFalse(reffw_fn.called) ++ addif_fn.assert_called_with(port["network_id"], p_const.TYPE_LOCAL, ++ None, None, port["id"]) ++ ++ addif_fn.return_value = True ++ self.lb_rpc.port_update("unused_context", port=port, ++ network_type=p_const.TYPE_LOCAL, ++ segmentation_id=None, ++ physical_network=None) ++ rpc_obj.update_device_up.assert_called_with( ++ self.lb_rpc.context, ++ "tap123", ++ self.lb_rpc.agent.agent_id, ++ cfg.CONF.host ++ ) ++ ++ addif_fn.return_value = False ++ self.lb_rpc.port_update("unused_context", port=port, ++ network_type=p_const.TYPE_LOCAL, ++ segmentation_id=None, ++ physical_network=None) ++ rpc_obj.update_device_down.assert_called_with( ++ self.lb_rpc.context, ++ "tap123", ++ self.lb_rpc.agent.agent_id, ++ cfg.CONF.host ++ ) ++ ++ port["admin_state_up"] = False ++ port["security_groups"] = True ++ getbr_fn.return_value = "br0" ++ self.lb_rpc.port_update("unused_context", port=port, ++ vlan_id="1", physical_network="physnet1") ++ self.assertTrue(reffw_fn.called) ++ remif_fn.assert_called_with("br0", "tap123") ++ rpc_obj.update_device_down.assert_called_with( ++ self.lb_rpc.context, ++ "tap123", ++ self.lb_rpc.agent.agent_id, ++ cfg.CONF.host ++ ) ++ ++ def test_port_update_plugin_rpc_failed(self): ++ with contextlib.nested( ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "get_tap_device_name"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "udev_get_tap_devices"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "get_bridge_name"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, ++ "remove_interface"), ++ mock.patch.object(self.lb_rpc.agent.br_mgr, "add_interface"), ++ mock.patch.object(self.lb_rpc.sg_agent, ++ "refresh_firewall", create=True), ++ mock.patch.object(self.lb_rpc.agent, ++ "plugin_rpc", create=True), ++ mock.patch.object(linuxbridge_neutron_agent.LOG, 'error'), ++ ) as (get_tap_fn, udev_fn, _, _, _, _, plugin_rpc, log): ++ get_tap_fn.return_value = "tap123" ++ udev_fn.return_value = ["tap123", "tap124"] ++ port = {"admin_state_up": True, ++ "id": "1234-5678", ++ "network_id": "123-123"} ++ plugin_rpc.update_device_up.side_effect = rpc_common.Timeout ++ self.lb_rpc.port_update(mock.Mock(), port=port) ++ self.assertTrue(plugin_rpc.update_device_up.called) ++ self.assertEqual(log.call_count, 1) ++ ++ log.reset_mock() ++ port["admin_state_up"] = False ++ plugin_rpc.update_device_down.side_effect = rpc_common.Timeout ++ self.lb_rpc.port_update(mock.Mock(), port=port) ++ self.assertTrue(plugin_rpc.update_device_down.called) ++ self.assertEqual(log.call_count, 1) ++ ++ def test_fdb_add(self): ++ fdb_entries = {'net_id': ++ {'ports': ++ {'agent_ip': [constants.FLOODING_ENTRY, ++ ['port_mac', 'port_ip']]}, ++ 'network_type': 'vxlan', ++ 'segment_id': 1}} ++ ++ with mock.patch.object(utils, 'execute', ++ return_value='') as execute_fn: ++ self.lb_rpc.fdb_add(None, fdb_entries) ++ ++ expected = [ ++ mock.call(['bridge', 'fdb', 'show', 'dev', 'vxlan-1'], ++ root_helper=self.root_helper), ++ mock.call(['bridge', 'fdb', 'add', ++ constants.FLOODING_ENTRY[0], ++ 'dev', 'vxlan-1', 'dst', 'agent_ip'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ mock.call(['ip', 'neigh', 'add', 'port_ip', 'lladdr', ++ 'port_mac', 'dev', 'vxlan-1', 'nud', 'permanent'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ mock.call(['bridge', 'fdb', 'add', 'port_mac', 'dev', ++ 'vxlan-1', 'dst', 'agent_ip'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ ] ++ execute_fn.assert_has_calls(expected) ++ ++ def test_fdb_ignore(self): ++ fdb_entries = {'net_id': ++ {'ports': ++ {LOCAL_IP: [constants.FLOODING_ENTRY, ++ ['port_mac', 'port_ip']]}, ++ 'network_type': 'vxlan', ++ 'segment_id': 1}} ++ ++ with mock.patch.object(utils, 'execute', ++ return_value='') as execute_fn: ++ self.lb_rpc.fdb_add(None, fdb_entries) ++ self.lb_rpc.fdb_remove(None, fdb_entries) ++ ++ self.assertFalse(execute_fn.called) ++ ++ fdb_entries = {'other_net_id': ++ {'ports': ++ {'192.168.0.67': [constants.FLOODING_ENTRY, ++ ['port_mac', 'port_ip']]}, ++ 'network_type': 'vxlan', ++ 'segment_id': 1}} ++ ++ with mock.patch.object(utils, 'execute', ++ return_value='') as execute_fn: ++ self.lb_rpc.fdb_add(None, fdb_entries) ++ self.lb_rpc.fdb_remove(None, fdb_entries) ++ ++ self.assertFalse(execute_fn.called) ++ ++ def test_fdb_remove(self): ++ fdb_entries = {'net_id': ++ {'ports': ++ {'agent_ip': [constants.FLOODING_ENTRY, ++ ['port_mac', 'port_ip']]}, ++ 'network_type': 'vxlan', ++ 'segment_id': 1}} ++ ++ with mock.patch.object(utils, 'execute', ++ return_value='') as execute_fn: ++ self.lb_rpc.fdb_remove(None, fdb_entries) ++ ++ expected = [ ++ mock.call(['bridge', 'fdb', 'del', ++ constants.FLOODING_ENTRY[0], ++ 'dev', 'vxlan-1', 'dst', 'agent_ip'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ mock.call(['ip', 'neigh', 'del', 'port_ip', 'lladdr', ++ 'port_mac', 'dev', 'vxlan-1'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ mock.call(['bridge', 'fdb', 'del', 'port_mac', ++ 'dev', 'vxlan-1', 'dst', 'agent_ip'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ ] ++ execute_fn.assert_has_calls(expected) ++ ++ def test_fdb_update_chg_ip(self): ++ fdb_entries = {'chg_ip': ++ {'net_id': ++ {'agent_ip': ++ {'before': [['port_mac', 'port_ip_1']], ++ 'after': [['port_mac', 'port_ip_2']]}}}} ++ ++ with mock.patch.object(utils, 'execute', ++ return_value='') as execute_fn: ++ self.lb_rpc.fdb_update(None, fdb_entries) ++ ++ expected = [ ++ mock.call(['ip', 'neigh', 'add', 'port_ip_2', 'lladdr', ++ 'port_mac', 'dev', 'vxlan-1', 'nud', 'permanent'], ++ root_helper=self.root_helper, ++ check_exit_code=False), ++ mock.call(['ip', 'neigh', 'del', 'port_ip_1', 'lladdr', ++ 'port_mac', 'dev', 'vxlan-1'], ++ root_helper=self.root_helper, ++ check_exit_code=False) ++ ] ++ execute_fn.assert_has_calls(expected) diff --git a/debian/patches/fix-quantum-configuration.patch b/debian/patches/fix-quantum-configuration.patch index df77dbe6c..4d7ef439a 100644 --- a/debian/patches/fix-quantum-configuration.patch +++ b/debian/patches/fix-quantum-configuration.patch @@ -1,3 +1,10 @@ +Description: Fixes to neutron configuration for distribution. + Patch various bits of config to be more suitable for packaging. +Author: James Page +Forwarded: not-needed + +diff --git a/etc/neutron.conf b/etc/neutron.conf +index 1e2226f..a5fe086 100644 --- a/etc/neutron.conf +++ b/etc/neutron.conf @@ -7,7 +7,7 @@ @@ -9,16 +16,16 @@ # Where to store lock files lock_path = $state_path/lock -@@ -45,7 +45,7 @@ lock_path = $state_path/lock - # api_extensions_path = - - # Neutron plugin provider module +@@ -50,7 +50,7 @@ lock_path = $state_path/lock + # previous versions, the class name of a plugin can be specified instead of its + # entrypoint name. + # -# core_plugin = -+core_plugin = neutron.plugins.openvswitch.ovs_neutron_plugin.OVSNeutronPluginV2 ++core_plugin = neutron.plugins.ml2.plugin.Ml2Plugin + # Example: core_plugin = ml2 - # Advanced service modules - # service_plugins = -@@ -295,7 +295,7 @@ notification_driver = neutron.openstack. + # (ListOpt) List of service plugin entrypoints to be loaded from the +@@ -320,7 +320,7 @@ notification_driver = neutron.openstack.common.notifier.rpc_notifier # Use "sudo neutron-rootwrap /etc/neutron/rootwrap.conf" to use the real # root filter facility. # Change to "sudo" to skip the filtering and just run the comand directly @@ -27,7 +34,7 @@ # =========== items for agent management extension ============= # seconds between nodes reporting state to server; should be less than -@@ -319,7 +319,7 @@ signing_dir = $state_path/keystone-signi +@@ -344,7 +344,7 @@ signing_dir = $state_path/keystone-signing # connection = mysql://root:pass@127.0.0.1:3306/neutron # Replace 127.0.0.1 above with the IP address of the database used by the # main neutron server. (Leave it as is if the database runs on this host.) @@ -36,3 +43,6 @@ # The SQLAlchemy connection string used to connect to the slave database # slave_connection = +-- +1.8.5.2 + diff --git a/debian/patches/remove-jsonrpclib.patch b/debian/patches/remove-jsonrpclib.patch deleted file mode 100644 index b47279fa1..000000000 --- a/debian/patches/remove-jsonrpclib.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- a/requirements.txt -+++ b/requirements.txt -@@ -12,7 +12,6 @@ greenlet>=0.3.2 - httplib2 - requests>=1.1 - iso8601>=0.1.8 --jsonrpclib - Jinja2 - kombu>=2.4.8 - netaddr diff --git a/debian/patches/series b/debian/patches/series index aa0010058..dd69d1464 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1,5 +1,6 @@ fix-quantum-configuration.patch disable-udev-tests.patch -bump-sqlalchemy-version.patch -disable-ml2-notification-tests.patch -remove-jsonrpclib.patch +disable-failing-metaplugin-tests.patch +skip-lb-test.patch +skip-ipv6-tests.patch +use-concurrency.patch diff --git a/debian/patches/skip-ipv6-tests.patch b/debian/patches/skip-ipv6-tests.patch new file mode 100644 index 000000000..92cbc680d --- /dev/null +++ b/debian/patches/skip-ipv6-tests.patch @@ -0,0 +1,22 @@ +Description: Skip ipv6 tests because they fail on the ppa buildds. +Author: Chuck Short +Forwarded: Not Needed +diff -Naurp neutron-2014.1.b2.orig/neutron/tests/unit/test_wsgi.py neutron-2014.1.b2/neutron/tests/unit/test_wsgi.py +--- neutron-2014.1.b2.orig/neutron/tests/unit/test_wsgi.py 2014-01-23 10:13:25.000000000 -0500 ++++ neutron-2014.1.b2/neutron/tests/unit/test_wsgi.py 2014-02-03 08:58:27.817255230 -0500 +@@ -64,6 +64,7 @@ class TestWSGIServer(base.BaseTestCase): + launcher.wait.assert_called_once_with() + + def test_start_random_port_with_ipv6(self): ++ self.skipTest('Skipped by Ubuntu') + server = wsgi.Server("test_random_port") + server.start(None, 0, host="::1") + self.assertEqual("::1", server.host) +@@ -1109,6 +1110,7 @@ class TestWSGIServerWithSSL(base.BaseTes + server.stop() + + def test_app_using_ipv6_and_ssl(self): ++ self.skipTest('Skipped by Ubuntu') + CONF.set_default('use_ssl', True) + CONF.set_default("ssl_cert_file", + os.path.join(TEST_VAR_DIR, 'certificate.crt')) diff --git a/debian/patches/skip-lb-test.patch b/debian/patches/skip-lb-test.patch new file mode 100644 index 000000000..f99e74166 --- /dev/null +++ b/debian/patches/skip-lb-test.patch @@ -0,0 +1,14 @@ +Description: Temporarily Skip LB test +Author: Chuck Short +Forwarded: Not Needed +diff -Naurp neutron-2014.1.b2.orig/neutron/tests/unit/test_provider_configuration.py neutron-2014.1.b2/neutron/tests/unit/test_provider_configuration.py +--- neutron-2014.1.b2.orig/neutron/tests/unit/test_provider_configuration.py 2014-01-23 10:13:25.000000000 -0500 ++++ neutron-2014.1.b2/neutron/tests/unit/test_provider_configuration.py 2014-01-27 11:39:28.611298704 -0500 +@@ -79,6 +79,7 @@ class ParseServiceProviderConfigurationT + 'default': True}]) + + def test_parse_service_provider_opt_not_allowed_raises(self): ++ self.skipTest('Skipped by Ubuntu') + cfg.CONF.set_override('service_provider', + [constants.LOADBALANCER + + ':lbaas:driver_path', diff --git a/debian/patches/use-concurrency.patch b/debian/patches/use-concurrency.patch new file mode 100644 index 000000000..203110a8b --- /dev/null +++ b/debian/patches/use-concurrency.patch @@ -0,0 +1,19 @@ +Description: Use concurrency of 4. +Author: Chuck Short +Fowarded: Not needed. +diff --git a/run_tests.sh b/run_tests.sh +index 4d838e8..6739fee 100755 +--- a/run_tests.sh ++++ b/run_tests.sh +@@ -129,7 +129,7 @@ function run_tests { + # Just run the test suites in current environment + set +e + testrargs=`echo "$testrargs" | sed -e's/^\s*\(.*\)\s*$/\1/'` +- TESTRTESTS="$TESTRTESTS --testr-args='--subunit $testropts $testrargs'" ++ TESTRTESTS="$TESTRTESTS --testr-args='--subunit --concurrency 4 $testropts $testrargs'" + echo "Running \`${wrapper} $TESTRTESTS\`" + bash -c "${wrapper} $TESTRTESTS | ${wrapper} subunit2pyunit" + RESULT=$? +-- +1.9.0 + diff --git a/debian/pydist-overrides b/debian/pydist-overrides old mode 100755 new mode 100644 index 416e493af..7b448d324 --- a/debian/pydist-overrides +++ b/debian/pydist-overrides @@ -1,4 +1,3 @@ quantum_server quantum-server quantum_common quantum-common setuptools-git -jsonrpclib diff --git a/debian/rules b/debian/rules index 60e37da0f..918ceded7 100755 --- a/debian/rules +++ b/debian/rules @@ -9,6 +9,10 @@ override_dh_install: dh_install --fail-missing -X/usr/etc -X/usr/bin/quantum +override_dh_installinit: + dh_installinit + dh_installinit -pneutron-plugin-openvswitch-agent --no-start --name=neutron-ovs-cleanup + override_dh_auto_clean: dh_clean @@ -21,7 +25,7 @@ override_dh_auto_test: # with a core_plugin being set. patch -p1 -R < debian/patches/fix-quantum-configuration.patch # Set a reasonable level of concurrency - ./run_tests.sh -N -P --concurrency=4 || true + ./run_tests.sh -N -P # Patch configuration file after testing patch -p1 < debian/patches/fix-quantum-configuration.patch endif diff --git a/debian/tests/control b/debian/tests/control index 84fa96e59..53ae88785 100644 --- a/debian/tests/control +++ b/debian/tests/control @@ -1,5 +1,5 @@ Tests: neutron-daemons python-neutron cisco-plugin nec-plugin bigswitch-plugin - hyperv-plugin brocade-plugin plumgrid-plugin nicira-plugin openvswitch-plugin + hyperv-plugin brocade-plugin plumgrid-plugin vmware-plugin openvswitch-plugin linuxbridge-plugin ryu-plugin midonet-plugin Depends: neutron-server, neutron-l3-agent, neutron-dhcp-agent, neutron-metadata-agent, neutron-lbaas-agent, python-neutron, rabbitmq-server diff --git a/debian/tests/nicira-plugin b/debian/tests/vmware-plugin similarity index 59% rename from debian/tests/nicira-plugin rename to debian/tests/vmware-plugin index 1c7df3757..86933cdc6 100644 --- a/debian/tests/nicira-plugin +++ b/debian/tests/vmware-plugin @@ -1,19 +1,19 @@ #!/bin/bash #---------------------- -# Testing nicira-plugin +# Testing vmware-plugin #---------------------- set -e -apt-get -y install neutron-plugin-nicira +apt-get -y install neutron-plugin-vmware # update plugin path -sed -i 's/NEUTRON_PLUGIN_CONFIG\=.*/NEUTRON_PLUGIN_CONFIG\=\"\/etc\/neutron\/plugins\/nicira\/nvp\.ini\"/g' /etc/default/neutron-server +sed -i 's/NEUTRON_PLUGIN_CONFIG\=.*/NEUTRON_PLUGIN_CONFIG\=\"\/etc\/neutron\/plugins\/vmware\/nsx\.ini\"/g' /etc/default/neutron-server sed -i 's/core_plugin/core_plugin \= neutron\.plugins\.nicira\.NeutronPlugin\.NvpPluginV2/g' /etc/neutron/neutron.conf service neutron-server restart > /dev/null 2>&1 if pidof -x neutron-server > /dev/null; then - apt-get -y remove --purge neutron-plugin-nicira + apt-get -y remove --purge neutron-plugin-vmware echo "OK" else - echo "ERROR: NICIRA PLUGIN IS NOT RUNNING" - apt-get -y remove --purge neutron-plugin-nicira + echo "ERROR: VMWARE PLUGIN IS NOT RUNNING" + apt-get -y remove --purge neutron-plugin-vmware exit 1 fi diff --git a/debian/watch b/debian/watch old mode 100755 new mode 100644 diff --git a/rpm/SOURCES/0001-use-parallel-installed-versions-in-RHEL6.patch b/rpm/SOURCES/0001-use-parallel-installed-versions-in-RHEL6.patch index 0d2dbd4ae..35b921829 100644 --- a/rpm/SOURCES/0001-use-parallel-installed-versions-in-RHEL6.patch +++ b/rpm/SOURCES/0001-use-parallel-installed-versions-in-RHEL6.patch @@ -1,4 +1,4 @@ -From 9e51bf76149105791742f84a4a639f9a0f661aad Mon Sep 17 00:00:00 2001 +From 89cac7fea4c4c5ef952227209c815cb166033050 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A1draig=20Brady?= Date: Fri, 13 Apr 2012 17:24:40 +0100 Subject: [PATCH] use parallel installed versions in RHEL6 @@ -7,8 +7,8 @@ of webob sqlalchemy python-routes paste-deploy python-jinja2-26 Change-Id: I290f56eae61c87893639a9e5d29f7fff760452cf --- - neutron/__init__.py | 31 +++++++++++++++++++++++++++++++ - 1 file changed, 31 insertions(+) + neutron/__init__.py | 31 +++++++++++++++++++++++++++++++ + 1 files changed, 31 insertions(+), 0 deletions(-) diff --git a/neutron/__init__.py b/neutron/__init__.py index b2c81bd..fef4d32 100644 diff --git a/rpm/SOURCES/0002-Remove-dnsmasq-version-warning.patch b/rpm/SOURCES/0002-Remove-dnsmasq-version-warning.patch new file mode 100644 index 000000000..406daca6d --- /dev/null +++ b/rpm/SOURCES/0002-Remove-dnsmasq-version-warning.patch @@ -0,0 +1,31 @@ +From 85a3b3a1ae3886db3b803db317974e33beaef6a2 Mon Sep 17 00:00:00 2001 +From: Terry Wilson +Date: Fri, 13 Dec 2013 09:41:43 -0600 +Subject: [PATCH] Remove dnsmasq version warning + +--- + neutron/agent/linux/dhcp.py | 11 +++++++---- + 1 files changed, 7 insertions(+), 4 deletions(-) + +diff --git a/neutron/agent/linux/dhcp.py b/neutron/agent/linux/dhcp.py +index 137f7a9..7406597 100644 +--- a/neutron/agent/linux/dhcp.py ++++ b/neutron/agent/linux/dhcp.py +@@ -291,10 +291,13 @@ class Dnsmasq(DhcpLocalProcess): + ver = re.findall("\d+.\d+", out)[0] + is_valid_version = float(ver) >= cls.MINIMUM_VERSION + if not is_valid_version: +- LOG.warning(_('FAILED VERSION REQUIREMENT FOR DNSMASQ. ' +- 'DHCP AGENT MAY NOT RUN CORRECTLY! ' +- 'Please ensure that its version is %s ' +- 'or above!'), cls.MINIMUM_VERSION) ++ if float(ver) < 2.48: ++ LOG.warning(_('FAILED VERSION REQUIREMENT FOR DNSMASQ. ' ++ 'DHCP AGENT MAY NOT RUN CORRECTLY! ' ++ 'Please ensure that its version is %s ' ++ 'or above!'), cls.MINIMUM_VERSION) ++ else: ++ LOG.info(_('dnsmasq version: %s'), ver) + except (OSError, RuntimeError, IndexError, ValueError): + LOG.warning(_('Unable to determine dnsmasq version. ' + 'Please ensure that its version is %s ' diff --git a/rpm/SOURCES/neutron-dhcp-agent.init b/rpm/SOURCES/neutron-dhcp-agent.init index f7268aa82..ef93ac2f5 100644 --- a/rpm/SOURCES/neutron-dhcp-agent.init +++ b/rpm/SOURCES/neutron-dhcp-agent.init @@ -13,11 +13,11 @@ plugin=dhcp-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/dhcp_agent.ini" \ ) pidfile="/var/run/$proj/$prog.pid" -logfile="/var/log/$proj/dhcp-agent.log" [ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog @@ -29,7 +29,7 @@ start() { [ -f $config ] || exit 6 done echo -n $"Starting $prog: " - daemon --user neutron --pidfile $pidfile "$exec --log-file $logfile ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" + daemon --user neutron --pidfile $pidfile "$exec --log-file /var/log/$proj/$plugin.log ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" retval=$? echo [ $retval -eq 0 ] && touch $lockfile diff --git a/rpm/SOURCES/neutron-l3-agent.init b/rpm/SOURCES/neutron-l3-agent.init index d37eea61c..d07f5a4ee 100644 --- a/rpm/SOURCES/neutron-l3-agent.init +++ b/rpm/SOURCES/neutron-l3-agent.init @@ -13,11 +13,12 @@ plugin=l3-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/l3_agent.ini" \ + "/etc/$proj/fwaas_driver.ini" \ ) pidfile="/var/run/$proj/$prog.pid" -logfile="/var/log/$proj/l3-agent.log" [ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog @@ -29,7 +30,7 @@ start() { [ -f $config ] || exit 6 done echo -n $"Starting $prog: " - daemon --user neutron --pidfile $pidfile "$exec --log-file $logfile ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" + daemon --user neutron --pidfile $pidfile "$exec --log-file /var/log/$proj/$plugin.log ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" retval=$? echo [ $retval -eq 0 ] && touch $lockfile diff --git a/rpm/SOURCES/neutron-l3-agent.upstart b/rpm/SOURCES/neutron-l3-agent.upstart index 35e1d3261..81b4d4715 100644 --- a/rpm/SOURCES/neutron-l3-agent.upstart +++ b/rpm/SOURCES/neutron-l3-agent.upstart @@ -5,4 +5,4 @@ stop on runlevel [S016] respawn -exec su -s /bin/sh -c "exec /usr/bin/neutron-l3-agent --log-file /var/log/neutron/l3-agent.log --config-file /usr/share/neutron/neutron-dist.conf --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/l3_agent.ini" neutron +exec su -s /bin/sh -c "exec /usr/bin/neutron-l3-agent --log-file /var/log/neutron/l3-agent.log --config-file /usr/share/neutron/neutron-dist.conf --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/l3_agent.ini" --config-file /etc/neutron/fwaas_driver.ini neutron diff --git a/rpm/SOURCES/neutron-lbaas-agent.init b/rpm/SOURCES/neutron-lbaas-agent.init index f433a00d5..31ac1ce6a 100644 --- a/rpm/SOURCES/neutron-lbaas-agent.init +++ b/rpm/SOURCES/neutron-lbaas-agent.init @@ -13,6 +13,7 @@ plugin=lbaas-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/lbaas_agent.ini" \ ) diff --git a/rpm/SOURCES/neutron-linuxbridge-agent.init b/rpm/SOURCES/neutron-linuxbridge-agent.init index 3403e2bf0..141a9750b 100644 --- a/rpm/SOURCES/neutron-linuxbridge-agent.init +++ b/rpm/SOURCES/neutron-linuxbridge-agent.init @@ -13,6 +13,7 @@ plugin=linuxbridge-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/linuxbridge/linuxbridge_conf.ini" \ ) diff --git a/rpm/SOURCES/neutron-metadata-agent.init b/rpm/SOURCES/neutron-metadata-agent.init index d8b819f12..4a0384dea 100644 --- a/rpm/SOURCES/neutron-metadata-agent.init +++ b/rpm/SOURCES/neutron-metadata-agent.init @@ -13,11 +13,11 @@ plugin=metadata-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/metadata_agent.ini" \ ) pidfile="/var/run/$proj/$prog.pid" -logfile="/var/log/$proj/metadata-agent.log" [ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog @@ -29,7 +29,7 @@ start() { [ -f $config ] || exit 6 done echo -n $"Starting $prog: " - daemon --user neutron --pidfile $pidfile "$exec --log-file $logfile ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" + daemon --user neutron --pidfile $pidfile "$exec --log-file /var/log/$proj/$plugin.log ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" retval=$? echo [ $retval -eq 0 ] && touch $lockfile diff --git a/rpm/SOURCES/neutron-metering-agent.init b/rpm/SOURCES/neutron-metering-agent.init index 798babaf4..8c7ab4f01 100644 --- a/rpm/SOURCES/neutron-metering-agent.init +++ b/rpm/SOURCES/neutron-metering-agent.init @@ -13,6 +13,7 @@ plugin=metering-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/metering_agent.ini" \ ) diff --git a/rpm/SOURCES/neutron-mlnx-agent.init b/rpm/SOURCES/neutron-mlnx-agent.init index 4db57c91b..c19f33bfa 100644 --- a/rpm/SOURCES/neutron-mlnx-agent.init +++ b/rpm/SOURCES/neutron-mlnx-agent.init @@ -13,6 +13,7 @@ plugin=mlnx-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/mlnx/mlnx_conf.ini" \ ) diff --git a/rpm/SOURCES/neutron-nec-agent.init b/rpm/SOURCES/neutron-nec-agent.init index 3cb7a2a49..ff1b877f7 100644 --- a/rpm/SOURCES/neutron-nec-agent.init +++ b/rpm/SOURCES/neutron-nec-agent.init @@ -13,6 +13,7 @@ plugin=nec-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/nec/nec.ini" \ ) diff --git a/rpm/SOURCES/neutron-openvswitch-agent.init b/rpm/SOURCES/neutron-openvswitch-agent.init index ace2f9bb5..14e53a9cb 100644 --- a/rpm/SOURCES/neutron-openvswitch-agent.init +++ b/rpm/SOURCES/neutron-openvswitch-agent.init @@ -13,11 +13,11 @@ plugin=openvswitch-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/openvswitch/ovs_neutron_plugin.ini" \ ) pidfile="/var/run/$proj/$prog.pid" -logfile="/var/log/$proj/ovs-agent.log" [ -e /etc/sysconfig/$prog ] && . /etc/sysconfig/$prog @@ -29,7 +29,7 @@ start() { [ -f $config ] || exit 6 done echo -n $"Starting $prog: " - daemon --user neutron --pidfile $pidfile "$exec --log-file $logfile ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" + daemon --user neutron --pidfile $pidfile "$exec --log-file /var/log/$proj/$plugin.log ${configs[@]/#/--config-file } &>/dev/null & echo \$! > $pidfile" retval=$? echo [ $retval -eq 0 ] && touch $lockfile diff --git a/rpm/SOURCES/neutron-ovs-cleanup.init b/rpm/SOURCES/neutron-ovs-cleanup.init index 7d9bd8060..0694022a5 100644 --- a/rpm/SOURCES/neutron-ovs-cleanup.init +++ b/rpm/SOURCES/neutron-ovs-cleanup.init @@ -13,6 +13,7 @@ prog=$proj-ovs-cleanup exec="/usr/bin/$prog" pidfile="/var/run/$proj/$prog.pid" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/openvswitch/ovs_neutron_plugin.ini" \ ) diff --git a/rpm/SOURCES/neutron-ryu-agent.init b/rpm/SOURCES/neutron-ryu-agent.init index 449eb7228..89dcaced8 100644 --- a/rpm/SOURCES/neutron-ryu-agent.init +++ b/rpm/SOURCES/neutron-ryu-agent.init @@ -13,6 +13,7 @@ plugin=ryu-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/plugins/ryu/ryu.ini" \ ) diff --git a/rpm/SOURCES/neutron-server-setup b/rpm/SOURCES/neutron-server-setup index d18782359..268c64c11 100644 --- a/rpm/SOURCES/neutron-server-setup +++ b/rpm/SOURCES/neutron-server-setup @@ -167,7 +167,7 @@ case "${NEUTRON_PLUGIN}" in ;; "openvswitch") - if ! rpm -q openvswitch > /dev/null + if ! rpm -q --whatprovides openvswitch > /dev/null then echo "Please install openvswitch" exit 0 @@ -199,7 +199,7 @@ echo "Plugin: ${NEUTRON_PLUGIN} => Database: ${DB_NAME}" # Make sure MySQL is installed. NEW_MYSQL_INSTALL=0 -if ! rpm -q mysql-server > /dev/null +if ! rpm -q --whatprovides mysql-server > /dev/null then if [ -z "${ASSUME_YES}" ] ; then printf "mysql-server is not installed. Would you like to install it now? (y/n): " diff --git a/rpm/SOURCES/neutron-server.init b/rpm/SOURCES/neutron-server.init index ede214ffc..d5ccc9f0a 100644 --- a/rpm/SOURCES/neutron-server.init +++ b/rpm/SOURCES/neutron-server.init @@ -12,6 +12,7 @@ prog=neutron exec="/usr/bin/$prog-server" configs=( + "/usr/share/$prog/$prog-dist.conf" \ "/etc/$prog/$prog.conf" \ "/etc/$prog/plugin.ini" \ ) diff --git a/rpm/SOURCES/neutron-vpn-agent.init b/rpm/SOURCES/neutron-vpn-agent.init index 9c4d74b0d..6140ece10 100644 --- a/rpm/SOURCES/neutron-vpn-agent.init +++ b/rpm/SOURCES/neutron-vpn-agent.init @@ -13,8 +13,10 @@ plugin=vpn-agent prog=$proj-$plugin exec="/usr/bin/$prog" configs=( + "/usr/share/$proj/$proj-dist.conf" \ "/etc/$proj/$proj.conf" \ "/etc/$proj/vpn_agent.ini" \ + "/etc/$proj/l3_agent.ini" \ ) pidfile="/var/run/$proj/$prog.pid" diff --git a/rpm/SOURCES/neutron-vpn-agent.upstart b/rpm/SOURCES/neutron-vpn-agent.upstart index 83c7a2d3d..94830d7db 100644 --- a/rpm/SOURCES/neutron-vpn-agent.upstart +++ b/rpm/SOURCES/neutron-vpn-agent.upstart @@ -5,4 +5,4 @@ stop on runlevel [S016] respawn -exec su -s /bin/sh -c "exec /usr/bin/neutron-vpn-agent --log-file /var/log/neutron/vpn-agent.log --config-file /usr/share/neutron/neutron-dist.conf --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/vpn_agent.ini" neutron +exec su -s /bin/sh -c "exec /usr/bin/neutron-vpn-agent --log-file /var/log/neutron/vpn-agent.log --config-file /usr/share/neutron/neutron-dist.conf --config-file /etc/neutron/neutron.conf --config-file /etc/neutron/vpn_agent.ini --config-file /etc/neutron/l3_agent.ini" neutron diff --git a/rpm/SPECS/openstack-neutron.spec b/rpm/SPECS/openstack-neutron.spec index 7bdabdc55..994f5abbf 100644 --- a/rpm/SPECS/openstack-neutron.spec +++ b/rpm/SPECS/openstack-neutron.spec @@ -1,11 +1,8 @@ -# -# This is 2013.2 release -# -%global release_name havana +%global release_name icehouse Name: openstack-neutron -Version: 2013.2 -Release: 11%{?dist} +Version: 2014.1 +Release: 0.7.b3%{?dist} Provides: openstack-quantum = %{version}-%{release} Obsoletes: openstack-quantum < 2013.2-0.3.b3 @@ -15,7 +12,7 @@ Group: Applications/System License: ASL 2.0 URL: http://launchpad.net/neutron/ -Source0: http://launchpad.net/neutron/%{release_name}/%{version}/+download/neutron-%{version}.tar.gz +Source0: http://launchpad.net/neutron/%{release_name}/%{version}/+download/neutron-%{version}.b3.tar.gz Source1: neutron.logrotate Source2: neutron-sudoers Source4: neutron-server-setup @@ -52,9 +49,10 @@ Source42: neutron-metering-agent.upstart Source90: neutron-dist.conf # -# patches_base=2013.2+1 +# patches_base=2014.1.b3+1 # Patch0001: 0001-use-parallel-installed-versions-in-RHEL6.patch +Patch0002: 0002-Remove-dnsmasq-version-warning.patch BuildArch: noarch @@ -79,6 +77,11 @@ Requires: openstack-utils Requires: python-keystone Requires: python-pbr +# this require fixes bz#1019487 due to this patch +# https://review.openstack.org/#/c/61105/8/neutron/agent/linux/ovs_lib.py +# which might need refactor to remove this dependency here +Requires: openstack-neutron-openvswitch + Requires(post): chkconfig Requires(postun): initscripts Requires(preun): chkconfig @@ -114,20 +117,24 @@ Requires: python-anyjson Requires: python-babel Requires: python-eventlet Requires: python-greenlet -Requires: python-httplib2 +Requires: python-httplib2 >= 0.7.5 Requires: python-iso8601 Requires: python-jinja2-26 -Requires: python-keystoneclient +Requires: python-keystoneclient >= 0.6.0 Requires: python-kombu Requires: python-lxml +Requires: python-oslo-rootwrap Requires: python-paste-deploy1.5 Requires: python-routes1.12 -Requires: python-sqlalchemy0.7 -Requires: python-webob1.2 +Requires: python-sqlalchemy0.7 >= 0.7.8 +Requires: python-webob1.2 >= 1.2.3 Requires: python-netaddr Requires: python-oslo-config >= 1:1.2.0 Requires: python-qpid -Requires: python-neutronclient +Requires: python-neutronclient >= 2.3.4 +Requires: python-stevedore +Requires: python-six >= 1.4.1 +# requires.txt six >=1.5.2 actually Requires: sudo %description -n python-neutron @@ -211,6 +218,21 @@ This package contains the neutron plugin that implements virtual networks using Microsoft Hyper-V. +%package -n openstack-neutron-ibm +Summary: Neutron IBM plugin +Group: Applications/System + +Requires: openstack-neutron = %{version}-%{release} + + +%description -n openstack-neutron-ibm +Neutron provides an API to dynamically request and configure virtual +networks. + +This package contains the neutron plugin that implements virtual +networks from IBM. + + %package -n openstack-neutron-linuxbridge Summary: Neutron linuxbridge plugin Group: Applications/System @@ -283,6 +305,17 @@ This plugin implements Neutron v2 APIs with support for Mellanox embedded switch functionality as part of the VPI (Ethernet/InfiniBand) HCA. +%package -n openstack-neutron-ofagent +Summary: Neutron ofagent plugin from ryu project +Group: Applications/system + +Requires: openstack-neutron = %{version}-%{release} + +%description -n openstack-neutron-ofagent +This plugin implements Neutron v2 APIs with support for the ryu ofagent +plugin. + + %package -n openstack-neutron-nicira Summary: Neutron Nicira plugin Group: Applications/System @@ -310,6 +343,7 @@ Obsoletes: openstack-quantum-openvswitch < 2013.2-0.3.b3 Requires: openstack-neutron = %{version}-%{release} Requires: openvswitch +Requires: python-psutil %description -n openstack-neutron-openvswitch @@ -392,6 +426,18 @@ This package contains the neutron plugin that implements virtual networks using multiple other neutron plugins. +%package -n openstack-neutron-vmware +Summary: Neutron VMWare NSX support +Group: Applications/System + +Requires: openstack-neutron = %{version}-%{release} +Provides: openstack-neutron-nicira = %{version}-%{release} +Obsoletes: openstack-neutron-nicira < 2014.1-0.5.b2 + +%description -n openstack-neutron-vmware +This package adds VMWare NSX support for neutron + + %package -n openstack-neutron-metering-agent Summary: Neutron bandwidth metering agent Group: Applications/System @@ -404,6 +450,7 @@ Neutron provides an API to measure bandwidth utilization This package contains the neutron agent responsible for generating bandwidth utilization notifications. + %package -n openstack-neutron-vpn-agent Summary: Neutron VPNaaS agent Group: Applications/System @@ -421,6 +468,7 @@ IPSec. %setup -q -n neutron-%{version} %patch0001 -p1 +%patch0002 -p1 find neutron -name \*.py -exec sed -i '/\/usr\/bin\/env python/{d;q}' {} + @@ -575,6 +623,7 @@ if rpm --quiet -q openstack-quantum; then sed -re 's/[0-6]:off//g s/([0-6]):on\s*/\1/g s/quantum/neutron/g + s/^([a-z0-9-]+)\s+$/chkconfig \1 off/ s/^([a-z0-9-]+)\s+([0-6]+)/chkconfig --levels \2 \1 on/' > %{_localstatedir}/lib/rpm-state/UPGRADE_FROM_QUANTUM fi @@ -828,6 +877,7 @@ fi %exclude %{python_sitelib}/neutron/plugins/brocade %exclude %{python_sitelib}/neutron/plugins/cisco %exclude %{python_sitelib}/neutron/plugins/hyperv +%exclude %{python_sitelib}/neutron/plugins/ibm %exclude %{python_sitelib}/neutron/plugins/linuxbridge %exclude %{python_sitelib}/neutron/plugins/metaplugin %exclude %{python_sitelib}/neutron/plugins/midonet @@ -835,15 +885,18 @@ fi %exclude %{python_sitelib}/neutron/plugins/mlnx %exclude %{python_sitelib}/neutron/plugins/nec %exclude %{python_sitelib}/neutron/plugins/nicira +%exclude %{python_sitelib}/neutron/plugins/ofagent %exclude %{python_sitelib}/neutron/plugins/openvswitch %exclude %{python_sitelib}/neutron/plugins/plumgrid %exclude %{python_sitelib}/neutron/plugins/ryu +%exclude %{python_sitelib}/neutron/plugins/vmware %{python_sitelib}/neutron-%%{version}*.egg-info %files -n openstack-neutron-bigswitch %doc LICENSE %doc neutron/plugins/bigswitch/README +%{_bindir}/neutron-restproxy-agent %{python_sitelib}/neutron/plugins/bigswitch %dir %{_sysconfdir}/neutron/plugins/bigswitch %config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/bigswitch/*.ini @@ -876,6 +929,16 @@ fi %config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/hyperv/*.ini +%files -n openstack-neutron-ibm +%doc LICENSE +%{_bindir}/neutron-ibm-agent +%{_bindir}/quantum-ibm-agent +%doc neutron/plugins/ibm/README +%{python_sitelib}/neutron/plugins/ibm +%dir %{_sysconfdir}/neutron/plugins/ibm +%config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/ibm/*.ini + + %files -n openstack-neutron-linuxbridge %doc LICENSE %doc neutron/plugins/linuxbridge/README @@ -915,14 +978,10 @@ fi %config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/mlnx/*.ini -%files -n openstack-neutron-nicira -%doc LICENSE -%doc neutron/plugins/nicira/README -%{_bindir}/neutron-check-nvp-config -%{_bindir}/quantum-check-nvp-config -%{python_sitelib}/neutron/plugins/nicira -%dir %{_sysconfdir}/neutron/plugins/nicira -%config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/nicira/*.ini +%files -n openstack-neutron-ofagent +%doc neutron/plugins/ofagent/README +%{_bindir}/neutron-ofagent-agent +%{python_sitelib}/neutron/plugins/ofagent %files -n openstack-neutron-openvswitch @@ -992,6 +1051,19 @@ fi %{_bindir}/neutron-metering-agent +%files -n openstack-neutron-vmware +%doc LICENSE +%{_bindir}/neutron-check-nvp-config +%{_bindir}/quantum-check-nvp-config +%{_bindir}/neutron-check-nsx-config +%{_bindir}/neutron-nsx-manage +%{python_sitelib}/neutron/plugins/vmware +%dir %{_sysconfdir}/neutron/plugins/vmware +%dir %{_sysconfdir}/neutron/plugins/nicira +%config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/vmware/*.ini +%config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/plugins/nicira/*.ini + + %files -n openstack-neutron-vpn-agent %doc LICENSE %config(noreplace) %attr(0640, root, neutron) %{_sysconfdir}/neutron/vpn_agent.ini @@ -1002,6 +1074,44 @@ fi %changelog +* Tue Mar 11 2014 Miguel Ángel Ajo - 2014.1.b3-7 +- Fixed a broken dependency/typo lxaml -> lxml +- Enforcing python-six >= 1.4.1 at least + +* Fri Mar 07 2014 Miguel Ángel Ajo - 2014.1.b3-6 +- Update to icehouse milestone 3 +- Add neutron-dhcp-agent dependency bz#1019487 +- Remove nicira plugin, renamed vmware-nsx to vmware bz#1058995 +- Add openstack-neutron-ibm plugin +- Add openstack-neutron-ofagent plugin from ryu project + +* Tue Feb 04 2014 Pádraig Brady - 2014.1.b2-5 +- Fix missing dependency on python-stevedore + +* Tue Feb 04 2014 Pádraig Brady - 2014.1.b2-4 +- Fix exception on systems with dnsmasq < 2.59 + +* Mon Jan 27 2014 Terry Wilson - 2014.1.b2-3 +- Update to icehouse milestone 2 + +* Tue Jan 07 2014 Terry Wilson - 2014.1.b1-2 +- Add python-psutil requirement for openvswitch agent, bz#1049235 + +* Mon Dec 23 2013 Pádraig Brady - 2014.1.b1-1 +- Update to icehouse milestone 1 + +* Wed Dec 18 2013 Pádraig Brady - 2013.2.1-1 +- Update to Havana stable release 2013.2.1 + +* Fri Dec 13 2013 Terry Wilson - 2013.2-13 +- QPID fixes from oslo-incubator, bz#1038711, bz#1038717 +- Remove dnsmasq version warning, bz#997961 +- Ensure that disabled services are properly handled on upgrade, bz#1040704 + +* Mon Dec 09 2013 Terry Wilson - 2013.2-12 +- Add vpnaas/fwaas configs to init scripts, bz#1032450 +- Pass neutron rootwrap.conf in sudoers.d/neutron, bz#984097 + * Wed Dec 04 2013 Terry Wilson - 2013.2-11 - Add missing debug and vpnaas rootwrap filters, bz#1034207 -- 2.32.3