Browse Source

Make use of OVS 2.11 in stable/queens

This patch squash two commits:

1) Switch stable/queens jobs to OVS 2.11 branch and remove master jobs

While the master branch should change to build from the
new OVN repo, stable branches should build from a stable
version of it.

We don't want to test stable release against master OVS/OVN, so lets
remove those jobs.

Signed-off-by: Daniel Alvarez <dalvarez@redhat.com>
(cherry picked from commit 6d540e49e6)

2) functional: Use different IP addresses for every fake chassis

As of OVS 2.11, the SB schema changed to not allow having two
Encap rows with the same (ip, type) pairs. Some of our
functional tests need more than one chassis and they all get
created with the same (ip, type) values so they'll fail.

This patch changes it so that a new IP address is used every
time we create a fake chassis. It shouldn't have any impact
as ovn-controller is not running so tunnels won't be created
anyways.

Closes-Bug: #1810292
Signed-off-by: Daniel Alvarez <dalvarez@redhat.com>
(cherry picked from commit 0cdd7ad8fe)

Change-Id: I63d12861e1ff5d444d116188a2a122eca5c45af0
changes/94/681394/6
Daniel Alvarez 2 years ago
committed by Maciej Józefczyk
parent
commit
513647805f
  1. 8
      devstack/devstackgaterc
  2. 2
      devstack/lib/networking-ovn
  3. 2
      devstack/local.conf.sample
  4. 1
      devstack/upgrade/settings
  5. 2
      networking_ovn/tests/contrib/gate_hook.sh
  6. 13
      networking_ovn/tests/functional/base.py
  7. 4
      networking_ovn/tests/functional/test_impl_idl.py
  8. 2
      playbooks/legacy/networking-ovn-dsvm-functional-py35/run.yaml
  9. 3
      playbooks/legacy/networking-ovn-dsvm-functional/run.yaml
  10. 22
      zuul.d/legacy-networking-ovn-jobs.yaml
  11. 1
      zuul.d/networkin-ovn-rally-task.yaml
  12. 4
      zuul.d/project.yaml

8
devstack/devstackgaterc

@ -30,14 +30,6 @@ fi
export DEVSTACK_LOCAL_CONFIG+=$'\n'"Q_USE_PROVIDERNET_FOR_PUBLIC=True"
export DEVSTACK_LOCAL_CONFIG+=$'\n'"PHYSICAL_NETWORK=public"
if [[ "${OVN_OPTS}" == *"latest-release"* ]] ; then
export DEVSTACK_LOCAL_CONFIG+=$'\n'"OVN_BRANCH=branch-2.9"
elif [[ "${OVN_OPTS}" == *"master"* ]] ; then
export DEVSTACK_LOCAL_CONFIG+=$'\n'"OVN_BRANCH=master"
else
echo "No ovs branch specified, using the default from the devstack plugin"
fi
# Enable controller to host gateway routers
export DEVSTACK_LOCAL_CONFIG+=$'\n'"ENABLE_CHASSIS_AS_GW=True"

2
devstack/lib/networking-ovn

@ -52,7 +52,7 @@ OVN_REPO_NAME=$(basename ${OVN_REPO} | cut -f1 -d'.')
NETWORKING_OVN_DIR=$DEST/networking-ovn
# The branch to use from $OVN_REPO
OVN_BRANCH=${OVN_BRANCH:-master}
OVN_BRANCH=${OVN_BRANCH:-branch-2.11}
# How to connect to ovsdb-server hosting the OVN SB database.
OVN_SB_REMOTE=${OVN_SB_REMOTE:-tcp:$SERVICE_HOST:6642}

2
devstack/local.conf.sample

@ -20,7 +20,7 @@ ADMIN_PASSWORD=password
# repo. You can optionally use a different one. For example, you may want to
# use the latest patches in blp's ovn branch:
#OVN_REPO=https://github.com/blp/ovs-reviews.git
OVN_BRANCH=branch-2.9
OVN_BRANCH=branch-2.11
enable_plugin networking-ovn https://git.openstack.org/openstack/networking-ovn stable/queens
enable_service ovn-northd

1
devstack/upgrade/settings

@ -6,3 +6,4 @@ devstack_localrc target enable_plugin networking-ovn http://git.openstack.org/op
devstack_localrc target PUBLIC_BRIDGE=br-ex
devstack_localrc target enable_service s-account s-container s-object s-proxy
devstack_localrc target disable_service q-agt
devstack_localrc target OVN_BRANCH="branch-2.11"

2
networking_ovn/tests/contrib/gate_hook.sh

@ -31,7 +31,7 @@ case $VENV in
remove_ovs_packages
# compile_ovs expects "DEST" to be defined
DEST=$GATE_DEST
OVS_BRANCH=branch-2.9
OVS_BRANCH=branch-2.11
compile_ovs True /usr/local /var
# Make the workspace owned by GATE_STACK_USER

13
networking_ovn/tests/functional/base.py

@ -87,6 +87,7 @@ class TestOVNFunctionalBase(test_plugin.Ml2PluginV2TestCase):
OVS_INSTALL_SHARE_PATH = '/usr/local/share/openvswitch'
_mechanism_drivers = ['logger', 'ovn']
_extension_drivers = ['port_security']
_counter = 0
l3_plugin = 'networking_ovn.l3.l3_ovn.OVNL3RouterPlugin'
def setUp(self, ovn_worker=False):
@ -239,7 +240,15 @@ class TestOVNFunctionalBase(test_plugin.Ml2PluginV2TestCase):
for i, phys_net in enumerate(physical_nets)])
name = uuidutils.generate_uuid()
external_ids['ovn-bridge-mappings'] = bridge_mapping
# We'll be using different IP addresses every time for the Encap of
# the fake chassis as the SB schema doesn't allow to have two entries
# with same (ip,type) pairs as of OVS 2.11. This shouldn't have any
# impact as the tunnels won't get created anyways since ovn-controller
# is not running. Ideally we shouldn't be creating more than 255
# fake chassis but from the SB db point of view, 'ip' column can be
# any string so we could add entries with ip='172.24.4.1000'.
self._counter += 1
self.sb_api.chassis_add(
name, ['geneve'], '172.24.4.10', external_ids=external_ids,
hostname=host).execute(check_error=True)
name, ['geneve'], '172.24.4.%d' % self._counter,
external_ids=external_ids, hostname=host).execute(check_error=True)
return name

4
networking_ovn/tests/functional/test_impl_idl.py

@ -52,11 +52,11 @@ class TestSbApi(base.FunctionalTestCase):
def load_test_data(self):
with self.api.transaction(check_error=True) as txn:
for i, chassis in enumerate(self.data['chassis']):
for chassis in self.data['chassis']:
chassis['name'] = utils.get_rand_device_name('chassis')
chassis['hostname'] = '%s.localdomain.com' % chassis['name']
txn.add(self.api.chassis_add(
chassis['name'], ['geneve'], '192.0.2.%d' % (i + 1,),
chassis['name'], ['geneve'], chassis['hostname'],
hostname=chassis['hostname'],
external_ids=chassis['external_ids']))

2
playbooks/legacy/networking-ovn-dsvm-functional-py35/run.yaml

@ -43,6 +43,8 @@
# our project repository. This makes zuul do the right
# reference magic for testing changes.
export PROJECTS="openstack/networking-ovn $PROJECTS"
export OVN_BRANCH="branch-2.11"
export OVS_BRANCH="branch-2.11"
function gate_hook {
bash -xe $BASE/new/networking-ovn/networking_ovn/tests/contrib/gate_hook.sh dsvm-functional-py35

3
playbooks/legacy/networking-ovn-dsvm-functional/run.yaml

@ -42,7 +42,8 @@
# our project repository. This makes zuul do the right
# reference magic for testing changes.
export PROJECTS="openstack/networking-ovn $PROJECTS"
export OVN_BRANCH="branch-2.11"
export OVS_BRANCH="branch-2.11"
function gate_hook {
bash -xe $BASE/new/networking-ovn/networking_ovn/tests/contrib/gate_hook.sh dsvm-functional
}

22
zuul.d/legacy-networking-ovn-jobs.yaml

@ -90,28 +90,6 @@
- openstack/neutron-tempest-plugin
- openstack/tempest
- job:
name: networking-ovn-tempest-dsvm-ovs-master
parent: legacy-networking-ovn-dsvm-base
run: playbooks/legacy/tempest-dsvm-networking-ovn-ovs-master/run.yaml
post-run: playbooks/legacy/tempest-dsvm-networking-ovn-ovs-master/post.yaml
timeout: 7800
required-projects:
- openstack/devstack-gate
- openstack/networking-ovn
- openstack/tempest
- job:
name: networking-ovn-tempest-dsvm-ovs-master-python3
parent: legacy-networking-ovn-dsvm-base
run: playbooks/legacy/tempest-dsvm-networking-ovn-ovs-master-python3/run.yaml
post-run: playbooks/legacy/tempest-dsvm-networking-ovn-ovs-master-python3/post.yaml
timeout: 7800
required-projects:
- openstack/devstack-gate
- openstack/networking-ovn
- openstack/tempest
- job:
name: networking-ovn-tempest-dsvm-ovs-release
parent: legacy-networking-ovn-dsvm-base

1
zuul.d/networkin-ovn-rally-task.yaml

@ -24,5 +24,6 @@
Q_USE_PROVIDERNET_FOR_PUBLIC: true
ENABLE_CHASSIS_AS_GW: true
OVN_L3_CREATE_PUBLIC_NETWORK: true
OVN_BRANCH: branch-2.11
rally_task: rally-jobs/ovn.yaml
timeout: 7800

4
zuul.d/project.yaml

@ -7,8 +7,6 @@
- openstack-python35-jobs-neutron
check:
jobs:
- networking-ovn-tempest-dsvm-ovs-master:
voting: false
- networking-ovn-tempest-dsvm-ovs-release
- networking-ovn-rally-task
- networking-ovn-dsvm-functional
@ -41,8 +39,6 @@
- tripleo-ci-centos-7-scenario007-multinode-oooq-container
experimental:
jobs:
- networking-ovn-tempest-dsvm-ovs-master-python3:
voting: false
- networking-ovn-grenade-dsvm:
voting: false
branches: ^(?!(driverfixes|stable/(mitaka|newton))).*$

Loading…
Cancel
Save