]> git.proxmox.com Git - openvswitch.git/commitdiff
updated for debian jessie, use systemd
authorDietmar Maurer <dietmar@proxmox.com>
Thu, 11 Jun 2015 12:04:35 +0000 (14:04 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Thu, 11 Jun 2015 12:04:35 +0000 (14:04 +0200)
Makefile
changelog.Debian
pvepatches/install-systemd-services.patch [new file with mode: 0644]
pvepatches/series
pvepatches/use-systemctl-inside-ifupdown.patch [new file with mode: 0644]

index 8a5faa096d5c7dfa743e91a62897d19d3768b1be..6ad068fa2be221f3dd75e81ce8efc52b323234d0 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,8 @@
-RELEASE=3.3
+RELEASE=4.0
 
 # also add entry in changelog.Debian
 OVSVER=2.3.1
-PKGRELEASE=1
+PKGRELEASE=2
 
 OVSDIR=openvswitch-${OVSVER}
 OVSSRC=openvswitch-${OVSVER}.tar.gz
index 9800ca530ab017b4012fa9db2fba7469150c1c5c..c386f1e3b632195af968063ffb23b10a2f106aa2 100644 (file)
@@ -1,3 +1,9 @@
+openvswitch (2.3.1-2) unstable; urgency=medium
+
+  * updates for debian jessie, use systemd
+
+ -- Proxmox Support Team <support@proxmox.com>  Thu, 11 Jun 2015 10:16:53 +0200
+
 openvswitch (2.3.1-1) unstable; urgency=low
 
   * update to 2.3.1
diff --git a/pvepatches/install-systemd-services.patch b/pvepatches/install-systemd-services.patch
new file mode 100644 (file)
index 0000000..8f0e6f4
--- /dev/null
@@ -0,0 +1,118 @@
+Index: new/debian/openvswitch-switch.openvswitch-nonetwork.service
+===================================================================
+--- /dev/null
++++ new/debian/openvswitch-switch.openvswitch-nonetwork.service
+@@ -0,0 +1,13 @@
++[Unit]
++Description=Open vSwitch Internal Unit
++After=syslog.target
++PartOf=openvswitch.service
++Wants=openvswitch.service
++
++[Service]
++Type=oneshot
++RemainAfterExit=yes
++EnvironmentFile=-/etc/sysconfig/openvswitch
++ExecStart=/usr/share/openvswitch/scripts/ovs-ctl start \
++          --system-id=random $OPTIONS
++ExecStop=/usr/share/openvswitch/scripts/ovs-ctl stop
+Index: new/debian/openvswitch-switch.openvswitch.service
+===================================================================
+--- /dev/null
++++ new/debian/openvswitch-switch.openvswitch.service
+@@ -0,0 +1,13 @@
++[Unit]
++Description=Open vSwitch
++After=syslog.target network.target openvswitch-nonetwork.service
++Requires=openvswitch-nonetwork.service
++
++[Service]
++Type=oneshot
++ExecStart=/bin/true
++ExecStop=/bin/true
++RemainAfterExit=yes
++
++[Install]
++WantedBy=multi-user.target
+Index: new/debian/rules
+===================================================================
+--- new.orig/debian/rules
++++ new/debian/rules
+@@ -40,6 +40,7 @@ configure-stamp:
+       dh_testdir
+       test -e configure || ./boot.sh
+       test -d _debian || mkdir _debian
++      rm debian/openvswitch-switch.init
+       echo $(DEB_BUILD_OPTIONS)
+       echo $$CC
+       cd _debian && ( \
+@@ -130,8 +131,10 @@ binary-common:
+       dh_installexamples
+       dh_installdebconf
+       dh_installlogrotate
+-      dh_installinit -p "openvswitch-switch" -R -- start 20 S . stop 80 0 6 .
+-      dh_installinit --remaining-packages -R
++      dh_systemd_enable -p "openvswitch-switch" --name openvswitch
++      dh_systemd_enable -p "openvswitch-switch" --name openvswitch-nonetwork
++      dh_installinit
++      dh_systemd_start -p "openvswitch-switch"  --name openvswitch-nonetwork --restart-after-upgrade
+       dh_installcron
+       dh_installman --language=C
+       dh_link
+Index: new/debian/control
+===================================================================
+--- new.orig/debian/control
++++ new/debian/control
+@@ -6,7 +6,8 @@ Uploaders: Ben Pfaff <pfaffben@debian.or
+ Build-Depends:
+  debhelper (>= 8), autoconf (>= 2.64), automake (>= 1.10) | automake1.10, 
+  libssl-dev, bzip2, openssl, graphviz,
+- python-all (>= 2.6.6-3~), procps, libtool
++ python-all (>= 2.6.6-3~), procps, libtool,
++ dh-systemd (>= 1.4)
+ Standards-Version: 3.9.3
+ Homepage: http://openvswitch.org/
+@@ -48,7 +49,7 @@ Description: Open vSwitch common compone
+ Package: openvswitch-switch
+ Architecture: linux-any
+ Suggests: openvswitch-datapath-module
+-Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, openvswitch-common (= ${binary:Version}), kmod | module-init-tools, procps, uuid-runtime, netbase, python-argparse
++Depends: ${shlibs:Depends}, ${misc:Depends}, ${python:Depends}, openvswitch-common (= ${binary:Version}), kmod | module-init-tools, procps, uuid-runtime, netbase, python-argparse, systemd
+ Description: Open vSwitch switch implementations
+  Open vSwitch is a production quality, multilayer, software-based,
+  Ethernet virtual switch. It is designed to enable massive network
+Index: new/Makefile.in
+===================================================================
+--- new.orig/Makefile.in
++++ new/Makefile.in
+@@ -762,7 +762,7 @@ am__noinst_HEADERS_DIST = BUILD.Windows
+       debian/openvswitch-ipsec.install debian/openvswitch-pki.dirs \
+       debian/openvswitch-pki.postinst debian/openvswitch-pki.postrm \
+       debian/openvswitch-switch.README.Debian \
+-      debian/openvswitch-switch.dirs debian/openvswitch-switch.init \
++      debian/openvswitch-switch.dirs \
+       debian/openvswitch-switch.install \
+       debian/openvswitch-switch.logrotate \
+       debian/openvswitch-switch.manpages \
+@@ -1180,7 +1180,7 @@ EXTRA_DIST = BUILD.Windows CONTRIBUTING
+       debian/openvswitch-ipsec.install debian/openvswitch-pki.dirs \
+       debian/openvswitch-pki.postinst debian/openvswitch-pki.postrm \
+       debian/openvswitch-switch.README.Debian \
+-      debian/openvswitch-switch.dirs debian/openvswitch-switch.init \
++      debian/openvswitch-switch.dirs \
+       debian/openvswitch-switch.install \
+       debian/openvswitch-switch.logrotate \
+       debian/openvswitch-switch.manpages \
+Index: new/debian/automake.mk
+===================================================================
+--- new.orig/debian/automake.mk
++++ new/debian/automake.mk
+@@ -26,7 +26,6 @@ EXTRA_DIST += \
+       debian/openvswitch-pki.postrm \
+       debian/openvswitch-switch.README.Debian \
+       debian/openvswitch-switch.dirs \
+-      debian/openvswitch-switch.init \
+       debian/openvswitch-switch.install \
+       debian/openvswitch-switch.logrotate \
+       debian/openvswitch-switch.manpages \
index df23692e828c63fbc6db3da1ebf4c7fe5fb58a56..8fe194712e54d58624a22f51bfc2092fa081bb52 100644 (file)
@@ -1,4 +1,6 @@
 remove-unneeded-from-control.patch
 fix-init-script-patch
 fix-init-depends.patch
-use-log-cons-for-syslog.patch
+#use-log-cons-for-syslog.patch
+install-systemd-services.patch
+use-systemctl-inside-ifupdown.patch
diff --git a/pvepatches/use-systemctl-inside-ifupdown.patch b/pvepatches/use-systemctl-inside-ifupdown.patch
new file mode 100644 (file)
index 0000000..ad52225
--- /dev/null
@@ -0,0 +1,18 @@
+Index: new/debian/ifupdown.sh
+===================================================================
+--- new.orig/debian/ifupdown.sh
++++ new/debian/ifupdown.sh
+@@ -29,8 +29,11 @@ if (ovs_vsctl --version) > /dev/null 2>&
+     exit 0
+ fi
+-if /etc/init.d/openvswitch-switch status > /dev/null 2>&1; then :; else
+-    /etc/init.d/openvswitch-switch start
++SERVICE_UNIT=/lib/systemd/system/openvswitch-nonetwork.service
++if [ -f $SERVICE_UNIT ] && [ -x /bin/systemctl ]; then
++      if ! systemctl --quiet is-active openvswitch-nonetwork.service; then
++              systemctl start openvswitch-nonetwork.service
++      fi
+ fi
+ if [ "${MODE}" = "start" ]; then