From 1fd1ff3720140baa3680d795f6d97597e5113e90 Mon Sep 17 00:00:00 2001 From: Mark Asselstine Date: Wed, 30 May 2018 11:47:10 -0400 Subject: openvswitch: uprev to v2.9.2 This brings us up to date with the latest upstream release. I suspect there will be an upcoming release to add compatibility with DPDK v18.05 (the DPDK release is due out any day now) but getting this fairly large release bump out of the way first will facilitate any upcoming uprev. We are able to drop they python3 patches as they have been merged upstream. Some scripts which needed to be updated to use python3 disappeared, new ones appeared so the 'use python3' patches are updated accordingly. Beyond this the biggest change is related to the systemd unit files, the ovsdb-server has been updated upstream to be generated on the fly via the spec file, we mimic this in the install_prepend. We also add the various configuration files which the unit files source before launching the services. As usual this was tested against out typical usecases including usage in meta-overc. As well the ptests have been run and the results are no better or worse. Previous version: ERROR: 2332 tests were run, 21 failed unexpectedly. 3 tests were skipped. New version: ERROR: 2527 tests were run, 29 failed unexpectedly. 3 tests were skipped. Signed-off-by: Mark Asselstine Signed-off-by: Bruce Ashfield --- .../openvswitch-git/disable_m4_check.patch | 8 +- ...-7e614671cba3c4e338d1c5003b74a10047d7a8eb.patch | 110 +++++++++++++++++++++ .../systemd-update-tool-paths.patch | 45 +++++++++ 3 files changed, 159 insertions(+), 4 deletions(-) create mode 100644 recipes-networking/openvswitch/openvswitch-git/openvswitch-add-ptest-7e614671cba3c4e338d1c5003b74a10047d7a8eb.patch create mode 100644 recipes-networking/openvswitch/openvswitch-git/systemd-update-tool-paths.patch (limited to 'recipes-networking/openvswitch/openvswitch-git') diff --git a/recipes-networking/openvswitch/openvswitch-git/disable_m4_check.patch b/recipes-networking/openvswitch/openvswitch-git/disable_m4_check.patch index 5c86aacc..711a1487 100644 --- a/recipes-networking/openvswitch/openvswitch-git/disable_m4_check.patch +++ b/recipes-networking/openvswitch/openvswitch-git/disable_m4_check.patch @@ -13,10 +13,10 @@ diff --git a/Makefile.am b/Makefile.am index ff7d70a..2fc1f13 100644 --- a/Makefile.am +++ b/Makefile.am -@@ -189,7 +189,7 @@ CLEAN_LOCAL += clean-pycov - # Makefile in datapath/linux, needed to get the list of files to - # distribute, requires GNU make extensions. - if GNU_MAKE +@@ -187,7 +187,7 @@ CLEAN_LOCAL += clean-pycov + + # If we're checked out from a Git repository, make sure that every + # file that is in Git is distributed. -ALL_LOCAL += dist-hook-git +# ALL_LOCAL += dist-hook-git dist-hook-git: distfiles diff --git a/recipes-networking/openvswitch/openvswitch-git/openvswitch-add-ptest-7e614671cba3c4e338d1c5003b74a10047d7a8eb.patch b/recipes-networking/openvswitch/openvswitch-git/openvswitch-add-ptest-7e614671cba3c4e338d1c5003b74a10047d7a8eb.patch new file mode 100644 index 00000000..5b53f969 --- /dev/null +++ b/recipes-networking/openvswitch/openvswitch-git/openvswitch-add-ptest-7e614671cba3c4e338d1c5003b74a10047d7a8eb.patch @@ -0,0 +1,110 @@ +From fb68120ef8aed625b04b2fbd2cb78fc59a7b7432 Mon Sep 17 00:00:00 2001 +From: He Zhe +Date: Wed, 30 Mar 2016 06:23:45 -0400 +Subject: [PATCH] openvswitch: Add test-install rule to support ptest execution + +Signed-off-by: Radu Patriu + +Fix ptest for v2.5 + - Copy certain files from srcdir since it has been different from + build directory. + - Copy more necessary files for new added test cases. + - Modify config files for running on target. + +Signed-off-by: He Zhe + +--- + Makefile.am | 1 + + test.mk | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 73 insertions(+) + create mode 100644 test.mk + +diff --git a/Makefile.am b/Makefile.am +index ea63acb..ff7d70a 100644 +--- a/Makefile.am ++++ b/Makefile.am +@@ -429,3 +429,4 @@ include windows/automake.mk + include ovn/automake.mk + include selinux/automake.mk + include build-aux/automake.mk ++include test.mk +diff --git a/test.mk b/test.mk +new file mode 100644 +index 0000000..b10a581 +--- /dev/null ++++ b/test.mk +@@ -0,0 +1,74 @@ ++TEST_DEST ?= ${prefix}/lib/openvswitch ++TEST_ROOT ?= ${prefix}/lib/openvswitch ++TEST_DEPEND = ++ ++if HAVE_OPENSSL ++TEST_DEPEND += $(TESTPKI_FILES) ++endif ++ ++test-install: $(TEST_DEPEND) ++ @list='$(noinst_PROGRAMS) $(EXTRA_DIST) $(dist_check_SCRIPTS) $(TEST_DEPEND) tests/atlocal tests/atconfig' ;\ ++ install -d $(TEST_DEST)/tests ;\ ++ install $(srcdir)/vtep/ovs-vtep $(TEST_DEST)/tests ;\ ++ install -d $(TEST_DEST)/python ;\ ++ install -d $(TEST_DEST)/python/ovs ;\ ++ install -d $(TEST_DEST)/python/ovs/db ;\ ++ install -d $(TEST_DEST)/python/ovs/compat ;\ ++ install -d $(TEST_DEST)/python/ovs/compat/sortedcontainers ;\ ++ install -d $(TEST_DEST)/python/ovs/unixctl ;\ ++ install -d $(TEST_DEST)/vswitchd ;\ ++ install $(srcdir)/vswitchd/vswitch.ovsschema $(TEST_DEST)/vswitchd ;\ ++ install vswitchd/ovs-vswitchd $(TEST_DEST)/vswitchd ;\ ++ install -d $(TEST_DEST)/debian ;\ ++ install $(srcdir)/debian/ovs-monitor-ipsec $(TEST_DEST)/debian ;\ ++ install -d $(TEST_DEST)/build-aux ;\ ++ install $(srcdir)/build-aux/check-structs $(TEST_DEST)/build-aux ;\ ++ install -d $(TEST_DEST)/xenserver ;\ ++ install $(srcdir)/xenserver/usr_share_openvswitch_scripts_ovs-xapi-sync $(TEST_DEST)/xenserver ;\ ++ install $(srcdir)/xenserver/opt_xensource_libexec_interface-reconfigure $(TEST_DEST)/xenserver ;\ ++ install $(srcdir)/xenserver/opt_xensource_libexec_InterfaceReconfigure.py $(TEST_DEST)/xenserver ;\ ++ install $(srcdir)/xenserver/opt_xensource_libexec_InterfaceReconfigureBridge.py $(TEST_DEST)/xenserver ;\ ++ install $(srcdir)/xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py $(TEST_DEST)/xenserver ;\ ++ install -d $(TEST_DEST)/vtep ;\ ++ install $(srcdir)/vtep/vtep.ovsschema $(TEST_DEST)/vtep ;\ ++ install -d $(TEST_DEST)/ovn ;\ ++ install $(srcdir)/ovn/ovn-nb.ovsschema $(TEST_DEST)/ovn ;\ ++ install $(srcdir)/ovn/ovn-sb.ovsschema $(TEST_DEST)/ovn ;\ ++ install -d $(TEST_DEST)/utilities ;\ ++ install $(srcdir)/utilities/ovs-pcap.in $(TEST_DEST)/utilities ;\ ++ install $(srcdir)/utilities/ovs-pki.in $(TEST_DEST)/utilities ;\ ++ for p in $$list ; do \ ++ echo $$p ;\ ++ p=$${p#../git/} ;\ ++ pre=$${p#tests\/} ;\ ++ if test $$pre != $$p ; then \ ++ echo installing $$p to $(TEST_DEST)/tests/$$pre ;\ ++ if test -f $$p ; then \ ++ install $$p $(TEST_DEST)/tests/$$pre ;\ ++ else \ ++ install $(srcdir)/$$p $(TEST_DEST)/tests/$$pre ;\ ++ fi ;\ ++ continue ;\ ++ fi ;\ ++ pre=$${p#python\/ovs\/} ;\ ++ if test $$pre != $$p ; then \ ++ echo installing $$p to $(TEST_DEST)/python/ovs/$$pre ;\ ++ if test -f $$p ; then \ ++ install $$p $(TEST_DEST)/python/ovs/$$pre ;\ ++ else \ ++ install $(srcdir)/$$p $(TEST_DEST)/python/ovs/$$pre ;\ ++ fi ;\ ++ continue ;\ ++ fi; \ ++ done ;\ ++ sed -i 's|abs_builddir=.*|abs_builddir='"'"'$(TEST_ROOT)/tests'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|abs_srcdir=.*|abs_srcdir='"'"'$(TEST_ROOT)/tests'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|abs_top_srcdir=.*|abs_top_srcdir='"'"'$(TEST_ROOT)'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|abs_top_builddir=.*|abs_top_builddir='"'"'$(TEST_ROOT)'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|at_srcdir=.*|at_srcdir='"'"'.'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|at_top_srcdir=.*|at_top_srcdir='"'"'..'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|at_top_build_prefix=.*|at_top_build_prefix='"'"'../'"'"'|g' $(TEST_DEST)/tests/atconfig ++ sed -i 's|^\(.*config\.log.*\)|#\1|g' $(TEST_DEST)/tests/testsuite ++ sed -i 's|$$srcdir|$$abs_srcdir|g' $(TEST_DEST)/tests/testsuite ++ sed -i 's|ovs-appctl-bashcomp\.bash|/etc/bash_completion.d/ovs-appctl-bashcomp\.bash|g' $(TEST_DEST)/tests/testsuite ++ sed -i 's|ovs-vsctl-bashcomp\.bash|/etc/bash_completion.d/ovs-vsctl-bashcomp\.bash|g' $(TEST_DEST)/tests/testsuite diff --git a/recipes-networking/openvswitch/openvswitch-git/systemd-update-tool-paths.patch b/recipes-networking/openvswitch/openvswitch-git/systemd-update-tool-paths.patch new file mode 100644 index 00000000..9a792e63 --- /dev/null +++ b/recipes-networking/openvswitch/openvswitch-git/systemd-update-tool-paths.patch @@ -0,0 +1,45 @@ +From f45c0a9d712113417e7b56c199f8576b470695ae Mon Sep 17 00:00:00 2001 +From: Mark Asselstine +Date: Tue, 29 May 2018 18:57:46 +0000 +Subject: [PATCH] systemd: update tool paths + +We are using the rhel files but we install our tools in a slightly +different path, update accordingly. + +Signed-off-by: Mark Asselstine +--- + rhel/usr_lib_systemd_system_ovs-vswitchd.service.in | 4 ++-- + rhel/usr_lib_systemd_system_ovsdb-server.service | 2 +- + 2 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/rhel/usr_lib_systemd_system_ovs-vswitchd.service.in b/rhel/usr_lib_systemd_system_ovs-vswitchd.service.in +index 11b34c6..94c48f8 100644 +--- a/rhel/usr_lib_systemd_system_ovs-vswitchd.service.in ++++ b/rhel/usr_lib_systemd_system_ovs-vswitchd.service.in +@@ -15,8 +15,8 @@ EnvironmentFile=/etc/openvswitch/default.conf + EnvironmentFile=-/etc/sysconfig/openvswitch + EnvironmentFile=-/run/openvswitch/useropts + @begin_dpdk@ +-ExecStartPre=-/bin/sh -c '/usr/bin/chown :$${OVS_USER_ID##*:} /dev/hugepages' +-ExecStartPre=-/usr/bin/chmod 0775 /dev/hugepages ++ExecStartPre=-/bin/sh -c '/bin/chown :$${OVS_USER_ID##*:} /dev/hugepages' ++ExecStartPre=-/bin/chmod 0775 /dev/hugepages + @end_dpdk@ + ExecStart=/usr/share/openvswitch/scripts/ovs-ctl \ + --no-ovsdb-server --no-monitor --system-id=random \ +diff --git a/rhel/usr_lib_systemd_system_ovsdb-server.service b/rhel/usr_lib_systemd_system_ovsdb-server.service +index 0fa57a9..75c9e02 100644 +--- a/rhel/usr_lib_systemd_system_ovsdb-server.service ++++ b/rhel/usr_lib_systemd_system_ovsdb-server.service +@@ -10,7 +10,7 @@ Type=forking + Restart=on-failure + EnvironmentFile=/etc/openvswitch/default.conf + EnvironmentFile=-/etc/sysconfig/openvswitch +-ExecStartPre=/usr/bin/chown ${OVS_USER_ID} /var/run/openvswitch ++ExecStartPre=/bin/chown ${OVS_USER_ID} /var/run/openvswitch + ExecStartPre=/bin/sh -c 'rm -f /run/openvswitch/useropts; if [ "$${OVS_USER_ID/:*/}" != "root" ]; then /usr/bin/echo "OVSUSER=--ovs-user=${OVS_USER_ID}" > /run/openvswitch/useropts; fi' + EnvironmentFile=-/run/openvswitch/useropts + ExecStart=/usr/share/openvswitch/scripts/ovs-ctl \ +-- +2.7.4 + -- cgit v1.2.3-54-g00ecf