forked from pool/openvswitch
Accepting request 70540 from home:anubisg1:branches:network
spec file clean up, added the proper dependencies adding python functions and upstream version 1.1.0 (previous was 1.1.0 pre15), python-pyside is optional, re-enabled kmp packages OBS-URL: https://build.opensuse.org/request/show/70540 OBS-URL: https://build.opensuse.org/package/show/network/openvswitch?expand=0&rev=3
This commit is contained in:
parent
1b0709ec1d
commit
dbc1de3515
@ -1,19 +1,7 @@
|
|||||||
brcompat: add stp and forwarding delay call stubs to brcompat layer
|
diff -uNr old-openvswitch-1.1.0//datapath/brcompat.c openvswitch-1.1.0/datapath/brcompat.c
|
||||||
|
--- old-openvswitch-1.1.0//datapath/brcompat.c 2011-04-07 17:41:17.000000000 +0200
|
||||||
From: Patrick Mullaney <pm.mullaney@gmail.com>
|
+++ openvswitch-1.1.0/datapath/brcompat.c 2011-05-17 13:34:26.015407719 +0200
|
||||||
|
@@ -308,6 +308,19 @@
|
||||||
libvirt and various startup scripts like to set these 2 attributes
|
|
||||||
---
|
|
||||||
|
|
||||||
datapath/brcompat.c | 19 +++++++++++++++++++
|
|
||||||
1 files changed, 19 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
|
|
||||||
diff --git a/datapath/brcompat.c b/datapath/brcompat.c
|
|
||||||
index f23db93..eefb7c3 100644
|
|
||||||
--- a/datapath/brcompat.c
|
|
||||||
+++ b/datapath/brcompat.c
|
|
||||||
@@ -310,6 +310,19 @@ nla_put_failure:
|
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -33,7 +21,7 @@ index f23db93..eefb7c3 100644
|
|||||||
/* Legacy ioctl's through SIOCDEVPRIVATE. Called with rtnl_lock. */
|
/* Legacy ioctl's through SIOCDEVPRIVATE. Called with rtnl_lock. */
|
||||||
static int old_dev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
|
static int old_dev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
|
||||||
{
|
{
|
||||||
@@ -333,6 +346,12 @@ static int old_dev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
|
@@ -331,6 +344,12 @@
|
||||||
case BRCTL_GET_FDB_ENTRIES:
|
case BRCTL_GET_FDB_ENTRIES:
|
||||||
return brc_get_fdb_entries(dev, (void __user *)args[1],
|
return brc_get_fdb_entries(dev, (void __user *)args[1],
|
||||||
args[2], args[3]);
|
args[2], args[3]);
|
23
openvswitch-1.1.0-suse.patch
Normal file
23
openvswitch-1.1.0-suse.patch
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
diff -uNr old-openvswitch-1.1.0//xenserver/automake.mk openvswitch-1.1.0/xenserver/automake.mk
|
||||||
|
--- old-openvswitch-1.1.0//xenserver/automake.mk 2011-05-17 13:36:17.041407719 +0200
|
||||||
|
+++ openvswitch-1.1.0/xenserver/automake.mk 2011-05-17 13:37:30.827407720 +0200
|
||||||
|
@@ -27,4 +27,5 @@
|
||||||
|
xenserver/usr_share_openvswitch_scripts_ovs-xapi-sync \
|
||||||
|
xenserver/usr_share_openvswitch_scripts_sysconfig.template \
|
||||||
|
xenserver/usr_share_openvswitch_scripts_xen-bugtool-tc-class-show \
|
||||||
|
+ xenserver/etc_sysconfig_openvswitch \
|
||||||
|
xenserver/uuid.py
|
||||||
|
diff -uNr old-openvswitch-1.1.0//xenserver/etc_sysconfig_openvswitch openvswitch-1.1.0/xenserver/etc_sysconfig_openvswitch
|
||||||
|
--- old-openvswitch-1.1.0//xenserver/etc_sysconfig_openvswitch 1970-01-01 01:00:00.000000000 +0100
|
||||||
|
+++ openvswitch-1.1.0/xenserver/etc_sysconfig_openvswitch 2011-05-17 13:40:26.280407720 +0200
|
||||||
|
@@ -0,0 +1,10 @@
|
||||||
|
+### Configuration options for openvswitch
|
||||||
|
+
|
||||||
|
+# Copyright (C) 2009, 2010 Nicira Networks, Inc.
|
||||||
|
+#
|
||||||
|
+# Copying and distribution of this file, with or without modification,
|
||||||
|
+# are permitted in any medium without royalty provided the copyright
|
||||||
|
+# notice and this notice are preserved. This file is offered as-is,
|
||||||
|
+# without warranty of any kind.
|
||||||
|
+
|
||||||
|
+NETWORK_MODE=openvswitch
|
@ -1,3 +1,3 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
version https://git-lfs.github.com/spec/v1
|
||||||
oid sha256:d1e841d16998eda1b295141b0f1b31df05947149eb62988c71154ab0dfaed6c0
|
oid sha256:f530c58ef24190b20b14972685de0c3d5764bee2d7a7ce1c895f57d2bc8b01f8
|
||||||
size 905812
|
size 1294444
|
||||||
|
@ -1,10 +1,25 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Wed May 18 10:09:45 UTC 2011 - andrea@opensuse.org
|
||||||
|
|
||||||
|
- re-enabled kmp package since openvswitch_mod.ko and
|
||||||
|
brcompat_mod.ko are not available on suse kernel rpms
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue May 17 12:04:05 UTC 2011 - andrea@opensuse.org
|
||||||
|
|
||||||
|
- new upstream version 1.1.0 (stable)
|
||||||
|
- spec file clean up
|
||||||
|
- added as dependency all python modules to enable additional
|
||||||
|
functionalities
|
||||||
|
- rebase patches
|
||||||
|
- build pyside support only if pyside is available
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri Dec 31 15:26:59 UTC 2010 - pmullaney@novell.com
|
Fri Dec 31 15:26:59 UTC 2010 - pmullaney@novell.com
|
||||||
|
|
||||||
- updates for build issues
|
- updates for build issues
|
||||||
- fixes for libvirt integration
|
- fixes for libvirt integration
|
||||||
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Sat Dec 11 19:57:28 UTC 2010 - pmullaney@novell.com
|
Sat Dec 11 19:57:28 UTC 2010 - pmullaney@novell.com
|
||||||
|
|
||||||
|
283
openvswitch.spec
283
openvswitch.spec
@ -1,28 +1,76 @@
|
|||||||
|
#
|
||||||
|
# spec file for package
|
||||||
|
#
|
||||||
|
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
|
#
|
||||||
|
# All modifications and additions to the file contributed by third parties
|
||||||
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
|
# upon. The license for this file, and modifications and additions to the
|
||||||
|
# file, is the same license as for the pristine package itself (unless the
|
||||||
|
# license for the pristine package is not an Open Source License, in which
|
||||||
|
# case the license is the MIT License). An "Open Source License" is a
|
||||||
|
# license that conforms to the Open Source Definition (Version 1.9)
|
||||||
|
# published by the Open Source Initiative.
|
||||||
|
|
||||||
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||||
|
#
|
||||||
|
|
||||||
# norootforbuild
|
# norootforbuild
|
||||||
Name: openvswitch
|
|
||||||
Summary: Utilities for configuring vswitch
|
|
||||||
Version: 1.1.0
|
|
||||||
License: GPL v2 or later
|
|
||||||
Release: 0
|
|
||||||
Group: Productivity/Networking/System
|
|
||||||
URL: http://openvswitch.org/releases/
|
|
||||||
Source: %{name}-%{version}.tar.bz2
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
||||||
Requires: logrotate
|
|
||||||
BuildRequires: openssl libopenssl-devel python-base ncurses-devel pcre-devel pkg-config pcre-devel pyxml
|
|
||||||
Patch0: ovs-suse.patch
|
|
||||||
Patch1: stp-fwd-delay.patch
|
|
||||||
|
|
||||||
# build the kmp for opensuse 11.3 and earlier, openvswitch went upstream after
|
# build the kmp for opensuse 11.3 and earlier, openvswitch went upstream after
|
||||||
%if 0%{?suse_version} <= 1130
|
#%if 0%{?suse_version} <= 1130
|
||||||
%define build_kmp 1
|
%define build_kmp 1
|
||||||
|
#%endif
|
||||||
|
|
||||||
|
%bcond_with pyside
|
||||||
|
|
||||||
|
Name: openvswitch
|
||||||
|
Version: 1.1.0
|
||||||
|
Release: 1
|
||||||
|
License: Apache
|
||||||
|
Summary: An open source, production quality, multilayer virtual switch
|
||||||
|
Url: http://openswitch.org
|
||||||
|
Group: Productivity/Networking/System
|
||||||
|
Source0: %name-%version.tar.bz2
|
||||||
|
Patch0: %name-1.1.0-suse.patch
|
||||||
|
Patch1: %name-1.1.0-stp-fwd-delay.patch
|
||||||
|
BuildRequires: gcc
|
||||||
|
BuildRequires: make
|
||||||
|
BuildRequires: pkg-config
|
||||||
|
BuildRequires: perl
|
||||||
|
BuildRequires: glibc-devel
|
||||||
|
BuildRequires: openssl libopenssl-devel
|
||||||
|
BuildRequires: valgrind-devel
|
||||||
|
BuildRequires: graphviz
|
||||||
|
BuildRequires: python-devel
|
||||||
|
BuildRequires: python-qt4-devel
|
||||||
|
BuildRequires: python-twisted
|
||||||
|
BuildRequires: python-simplejson
|
||||||
|
BuildRequires: python-zopeinterface
|
||||||
|
%if %{with pyside}
|
||||||
|
BuildRequires: python-pyside
|
||||||
|
Requires: python-pyside
|
||||||
%endif
|
%endif
|
||||||
|
Requires: python-qt4
|
||||||
|
Requires: python-twisted
|
||||||
|
Requires: python-simplejson
|
||||||
|
Requires: python-zopeinterface
|
||||||
|
Requires: openssl
|
||||||
|
Requires: graphviz
|
||||||
|
Requires: logrotate
|
||||||
|
%py_requires
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
|
|
||||||
%description
|
%description
|
||||||
virtual switching for the large scale data center virtualization environment
|
Open vSwitch is a production quality, multilayer virtual switch licensed under
|
||||||
|
the open source Apache 2.0 license. It is designed to enable massive network automation
|
||||||
|
through programmatic extension, while still supporting standard management interfaces
|
||||||
|
and protocols (e.g. NetFlow, sFlow, RSPAN, ERSPAN, CLI, LACP, 802.1ag). In addition,
|
||||||
|
it is designed to support distribution across multiple physical servers similar to
|
||||||
|
VMware’s vNetwork distributed vswitch or Cisco’s Nexus 1000V.
|
||||||
|
|
||||||
%if 0%{?build_kmp}
|
%if 0%{?build_kmp}
|
||||||
%package -n openvswitch-KMP
|
%package -n %{name}-KMP
|
||||||
Group: Productivity/Networking/System
|
Group: Productivity/Networking/System
|
||||||
License: GPL v2 or later
|
License: GPL v2 or later
|
||||||
Summary: Kernel module
|
Summary: Kernel module
|
||||||
@ -30,12 +78,12 @@ Requires: kernel-default kernel-desktop
|
|||||||
BuildRequires: perl-base autoconf automake libtool kernel-source kernel-syms module-init-tools
|
BuildRequires: perl-base autoconf automake libtool kernel-source kernel-syms module-init-tools
|
||||||
%suse_kernel_module_package ec2 xen xenpae vmi um
|
%suse_kernel_module_package ec2 xen xenpae vmi um
|
||||||
|
|
||||||
%description -n openvswitch-KMP
|
%description -n %{name}-KMP
|
||||||
Kernel modules supporting the openvswitch datapath
|
Kernel modules supporting the openvswitch datapath
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup
|
%setup -q
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
|
|
||||||
@ -54,7 +102,10 @@ for flavor in %flavors_to_build; do
|
|||||||
rm -rf obj/$flavor
|
rm -rf obj/$flavor
|
||||||
cp -r source obj/$flavor
|
cp -r source obj/$flavor
|
||||||
pushd obj/$flavor
|
pushd obj/$flavor
|
||||||
./configure --enable-ssl=yes --with-logdir=/var/log --with-l26=/usr/src/linux-obj/%_target_cpu/$flavor --with-l26-source=/usr/src/linux
|
%configure \
|
||||||
|
--with-logdir=/var/log \
|
||||||
|
--with-l26=/usr/src/linux-obj/%_target_cpu/$flavor \
|
||||||
|
--with-l26-source=/usr/src/linux
|
||||||
cd datapath/linux-2.6
|
cd datapath/linux-2.6
|
||||||
make
|
make
|
||||||
popd
|
popd
|
||||||
@ -62,13 +113,14 @@ done
|
|||||||
%endif
|
%endif
|
||||||
ls source
|
ls source
|
||||||
pushd source
|
pushd source
|
||||||
%configure --enable-ssl=yes --with-logdir=/var/log
|
%configure \
|
||||||
|
--with-logdir=/var/log
|
||||||
make %{?_smp_mflags}
|
make %{?_smp_mflags}
|
||||||
popd
|
popd
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%if 0%{?build_kmp}
|
%if 0%{?build_kmp}
|
||||||
export INSTALL_MOD_PATH=$RPM_BUILD_ROOT
|
export INSTALL_MOD_PATH=%{buildroot}
|
||||||
export INSTALL_MOD_DIR=updates
|
export INSTALL_MOD_DIR=updates
|
||||||
for flavor in %flavors_to_build; do
|
for flavor in %flavors_to_build; do
|
||||||
pushd obj/$flavor/datapath/linux-2.6
|
pushd obj/$flavor/datapath/linux-2.6
|
||||||
@ -77,139 +129,50 @@ for flavor in %flavors_to_build; do
|
|||||||
done
|
done
|
||||||
%endif
|
%endif
|
||||||
pushd source
|
pushd source
|
||||||
make install DESTDIR=$RPM_BUILD_ROOT INSTALL="%{__install} -p"
|
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/etc/init.d
|
%makeinstall
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/var/adm/fillup-templates
|
install -d -m 755 %{buildroot}/%_sysconfdir/init.d
|
||||||
install -m 644 xenserver/etc_sysconfig_openvswitch \
|
install -d -m 755 %{buildroot}/var/adm/fillup-templates
|
||||||
$RPM_BUILD_ROOT/var/adm/fillup-templates/sysconfig.openvswitch
|
install -m 644 xenserver/etc_sysconfig_%{name} \
|
||||||
install -m 755 xenserver/etc_init.d_openvswitch \
|
%{buildroot}/var/adm/fillup-templates/sysconfig.%{name}
|
||||||
$RPM_BUILD_ROOT/etc/init.d/openvswitch
|
install -m 755 xenserver/etc_init.d_%{name} \
|
||||||
install -m 755 xenserver/etc_init.d_openvswitch-xapi-update \
|
%{buildroot}/%_sysconfdir/init.d/%{name}
|
||||||
$RPM_BUILD_ROOT/etc/init.d/openvswitch-xapi-update
|
install -m 755 xenserver/etc_init.d_%{name}-xapi-update \
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/etc/sysconfig
|
%{buildroot}/%_sysconfdir/init.d/%{name}-xapi-update
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/etc/logrotate.d
|
install -d -m 755 %{buildroot}/%_sysconfdir/sysconfig
|
||||||
install -m 644 xenserver/etc_logrotate.d_openvswitch \
|
install -d -m 755 %{buildroot}/%_sysconfdir/logrotate.d
|
||||||
$RPM_BUILD_ROOT/etc/logrotate.d/openvswitch
|
install -m 644 xenserver/etc_logrotate.d_%{name} \
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/etc/profile.d
|
%{buildroot}/%_sysconfdir/logrotate.d/%{name}
|
||||||
install -m 644 xenserver/etc_profile.d_openvswitch.sh \
|
install -d -m 755 %{buildroot}/%_sysconfdir/profile.d
|
||||||
$RPM_BUILD_ROOT/etc/profile.d/openvswitch.sh
|
install -m 644 xenserver/etc_profile.d_%{name}.sh \
|
||||||
install -d -m 755 $RPM_BUILD_ROOT/etc/xapi.d/plugins
|
%{buildroot}/%_sysconfdir/profile.d/%{name}.sh
|
||||||
install -m 755 xenserver/etc_xapi.d_plugins_openvswitch-cfg-update \
|
install -d -m 755 %{buildroot}/%_sysconfdir/xapi.d/plugins
|
||||||
$RPM_BUILD_ROOT/etc/xapi.d/plugins/openvswitch-cfg-update
|
install -m 755 xenserver/etc_xapi.d_plugins_%{name}-cfg-update \
|
||||||
install -d -m 755 $RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts
|
%{buildroot}/%_sysconfdir/xapi.d/plugins/%{name}-cfg-update
|
||||||
|
install -d -m 755 %{buildroot}/%{_datadir}/%{name}/scripts
|
||||||
install -m 644 vswitchd/vswitch.ovsschema \
|
install -m 644 vswitchd/vswitch.ovsschema \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/vswitch.ovsschema
|
%{buildroot}/%{_datadir}/%{name}/vswitch.ovsschema
|
||||||
install -m 755 xenserver/opt_xensource_libexec_interface-reconfigure \
|
install -m 755 xenserver/opt_xensource_libexec_interface-reconfigure \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/interface-reconfigure
|
%{buildroot}/%{_datadir}/%{name}/scripts/interface-reconfigure
|
||||||
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigure.py \
|
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigure.py \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigure.py
|
%{buildroot}/%{_datadir}/%{name}/scripts/InterfaceReconfigure.py
|
||||||
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureBridge.py \
|
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureBridge.py \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigureBridge.py
|
%{buildroot}/%{_datadir}/%{name}/scripts/InterfaceReconfigureBridge.py
|
||||||
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py \
|
install -m 644 xenserver/opt_xensource_libexec_InterfaceReconfigureVswitch.py \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/InterfaceReconfigureVswitch.py
|
%{buildroot}/%{_datadir}/%{name}/scripts/InterfaceReconfigureVswitch.py
|
||||||
install -m 755 xenserver/etc_xensource_scripts_vif \
|
install -m 755 xenserver/etc_xensource_scripts_vif \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/vif
|
%{buildroot}/%{_datadir}/%{name}/scripts/vif
|
||||||
install -m 755 xenserver/usr_share_openvswitch_scripts_ovs-external-ids \
|
install -m 644 xenserver/usr_share_%{name}_scripts_sysconfig.template \
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/ovs-external-ids
|
%{buildroot}/%{_datadir}/%{name}/scripts/sysconfig.template
|
||||||
install -m 755 xenserver/usr_share_openvswitch_scripts_refresh-xs-network-uuids \
|
install -d -m 755 %{buildroot}/%{_libdir}/xsconsole/plugins-base
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/refresh-xs-network-uuids
|
|
||||||
install -m 755 xenserver/usr_sbin_xen-bugtool \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/xen-bugtool
|
|
||||||
install -m 755 xenserver/usr_sbin_brctl \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/brctl
|
|
||||||
install -m 644 xenserver/usr_share_openvswitch_scripts_sysconfig.template \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/openvswitch/scripts/sysconfig.template
|
|
||||||
install -d -m 755 $RPM_BUILD_ROOT%{_libdir}/xsconsole/plugins-base
|
|
||||||
install -m 644 \
|
install -m 644 \
|
||||||
xenserver/usr_lib_xsconsole_plugins-base_XSFeatureVSwitch.py \
|
xenserver/usr_lib_xsconsole_plugins-base_XSFeatureVSwitch.py \
|
||||||
$RPM_BUILD_ROOT%{_libdir}/xsconsole/plugins-base/XSFeatureVSwitch.py
|
%{buildroot}/%{_libdir}/xsconsole/plugins-base/XSFeatureVSwitch.py
|
||||||
install -m 644 xenserver/uuid.py $RPM_BUILD_ROOT%{_datadir}/openvswitch/python
|
install -m 644 xenserver/uuid.py %{buildroot}/%{_datadir}/%{name}/python
|
||||||
popd
|
popd
|
||||||
|
|
||||||
# Get rid of stuff we don't want to make RPM happy.
|
%clean
|
||||||
rm \
|
%{?buildroot:%__rm -rf "%{buildroot}"}
|
||||||
$RPM_BUILD_ROOT%{_bindir}/ovs-controller \
|
|
||||||
$RPM_BUILD_ROOT%{_bindir}/ovs-discover \
|
|
||||||
$RPM_BUILD_ROOT%{_bindir}/ovs-kill \
|
|
||||||
$RPM_BUILD_ROOT%{_bindir}/ovs-openflowd \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-controller.8 \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-discover.8 \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-kill.8 \
|
|
||||||
$RPM_BUILD_ROOT%{_datadir}/man/man8/ovs-openflowd.8 \
|
|
||||||
|
|
||||||
%files
|
|
||||||
%defattr(-,root,root)
|
|
||||||
%{_sysconfdir}/init.d/openvswitch
|
|
||||||
%{_localstatedir}/adm/fillup-templates/sysconfig.openvswitch
|
|
||||||
%{_sysconfdir}/init.d/openvswitch-xapi-update
|
|
||||||
%{_sysconfdir}/xapi.d/plugins/openvswitch-cfg-update
|
|
||||||
%config %{_sysconfdir}/logrotate.d/openvswitch
|
|
||||||
%config %{_sysconfdir}/profile.d/openvswitch.sh
|
|
||||||
%dir %{_libdir}/xsconsole
|
|
||||||
%dir %{_libdir}/xsconsole/plugins-base
|
|
||||||
%dir %{_datadir}/openvswitch
|
|
||||||
%dir %{_datadir}/openvswitch/python
|
|
||||||
%dir %{_datadir}/openvswitch/python/ovs
|
|
||||||
%dir %{_datadir}/openvswitch/python/ovs/db
|
|
||||||
%dir %{_datadir}/openvswitch/scripts
|
|
||||||
%dir %{_sysconfdir}/xapi.d
|
|
||||||
%dir %{_sysconfdir}/xapi.d/plugins
|
|
||||||
%{_datadir}/openvswitch/python/ovs/__init__.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/daemon.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/__init__.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/data.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/error.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/idl.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/parser.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/schema.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/db/types.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/dirs.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/fatal_signal.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/json.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/jsonrpc.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/ovsuuid.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/poller.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/process.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/reconnect.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/socket_util.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/stream.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/timeval.py
|
|
||||||
%{_datadir}/openvswitch/python/ovs/util.py
|
|
||||||
%{_datadir}/openvswitch/python/uuid.py
|
|
||||||
%{_datadir}/openvswitch/scripts/ovs-external-ids
|
|
||||||
%{_datadir}/openvswitch/scripts/refresh-xs-network-uuids
|
|
||||||
%{_datadir}/openvswitch/scripts/interface-reconfigure
|
|
||||||
%{_datadir}/openvswitch/scripts/InterfaceReconfigure.py
|
|
||||||
%{_datadir}/openvswitch/scripts/InterfaceReconfigureBridge.py
|
|
||||||
%{_datadir}/openvswitch/scripts/InterfaceReconfigureVswitch.py
|
|
||||||
%{_datadir}/openvswitch/scripts/vif
|
|
||||||
%{_datadir}/openvswitch/scripts/xen-bugtool
|
|
||||||
%{_datadir}/openvswitch/scripts/brctl
|
|
||||||
%{_datadir}/openvswitch/scripts/sysconfig.template
|
|
||||||
%{_datadir}/openvswitch/vswitch.ovsschema
|
|
||||||
%{_sbindir}/ovs-brcompatd
|
|
||||||
%{_sbindir}/ovs-vswitchd
|
|
||||||
%{_sbindir}/ovsdb-server
|
|
||||||
%{_bindir}/ovs-pki
|
|
||||||
%{_bindir}/ovs-appctl
|
|
||||||
%{_bindir}/ovs-dpctl
|
|
||||||
%{_bindir}/ovs-ofctl
|
|
||||||
%{_bindir}/ovs-vsctl
|
|
||||||
%{_bindir}/ovsdb-client
|
|
||||||
%{_bindir}/ovsdb-tool
|
|
||||||
%{_libdir}/xsconsole/plugins-base/XSFeatureVSwitch.py
|
|
||||||
%{_datadir}/man/man1/ovsdb-client.1.gz
|
|
||||||
%{_datadir}/man/man1/ovsdb-server.1.gz
|
|
||||||
%{_datadir}/man/man1/ovsdb-tool.1.gz
|
|
||||||
%{_datadir}/man/man5/ovs-vswitchd.conf.db.5.gz
|
|
||||||
%{_datadir}/man/man8/ovs-pki.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-appctl.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-brcompatd.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-dpctl.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-ofctl.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-parse-leaks.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-vsctl.8.gz
|
|
||||||
%{_datadir}/man/man8/ovs-vswitchd.8.gz
|
|
||||||
|
|
||||||
%post
|
%post
|
||||||
%{fillup_and_insserv openvswitch}
|
%{fillup_and_insserv openvswitch}
|
||||||
@ -217,8 +180,32 @@ rm \
|
|||||||
%preun
|
%preun
|
||||||
%stop_on_removal openvswitch
|
%stop_on_removal openvswitch
|
||||||
|
|
||||||
|
%files
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%doc source/AUTHORS source/DESIGN source/INSTALL.* source/NOTICE
|
||||||
|
%doc source/REPORTING-BUGS source/ChangeLog source/PORTING
|
||||||
|
%doc source/SubmittingPatches source/CodingStyle source/README
|
||||||
|
%doc source/WHY-OVS source/COPYING source/README-gcov
|
||||||
|
%_bindir/ovs*
|
||||||
|
%_sbindir/ovs-brcompatd
|
||||||
|
%_sbindir/ovsdb-server
|
||||||
|
%_sbindir/ovs-vlan-bug-workaround
|
||||||
|
%_sbindir/ovs-vswitchd
|
||||||
|
%_datadir/%name
|
||||||
|
%_mandir/man1/*
|
||||||
|
%_mandir/man5/*
|
||||||
|
%_mandir/man8/*
|
||||||
|
%_sysconfdir/init.d/openvswitch
|
||||||
|
%_sysconfdir/init.d/openvswitch-xapi-update
|
||||||
|
%config %_sysconfdir/logrotate.d/openvswitch
|
||||||
|
%_sysconfdir/profile.d/openvswitch.sh
|
||||||
|
%dir %_sysconfdir/xapi.d
|
||||||
|
%dir %dir %_sysconfdir/xapi.d/plugins
|
||||||
|
%dir %_libdir/xsconsole/
|
||||||
|
%dir %_libdir/xsconsole/plugins-base/
|
||||||
|
%_sysconfdir/xapi.d/plugins/openvswitch-cfg-update
|
||||||
|
%_libdir/xsconsole/plugins-base/XSFeatureVSwitch.py
|
||||||
|
/var/adm/fillup-templates/sysconfig.openvswitch
|
||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
# * Tue April 13 2010 pmullaney@novell.com
|
|
||||||
# - Initial Package, Version 0.99.2
|
|
||||||
# * Sun Sept 12 2010 pmullaney@novell.com
|
|
||||||
# - Updated Package, Version 1.0.1
|
|
||||||
|
186
ovs-suse.patch
186
ovs-suse.patch
@ -1,186 +0,0 @@
|
|||||||
openvswitch init script modifications for kvm and lxc hosts
|
|
||||||
|
|
||||||
From: Patrick Mullaney <pm.mullaney@gmail.com>
|
|
||||||
|
|
||||||
Signed-off-by: Patrick Mullaney <pm.mullaney@gmail.com>
|
|
||||||
---
|
|
||||||
|
|
||||||
xenserver/automake.mk | 1
|
|
||||||
xenserver/etc_init.d_openvswitch | 79 +++++++++++++++++++++-----
|
|
||||||
xenserver/etc_init.d_openvswitch-xapi-update | 9 +++
|
|
||||||
xenserver/etc_sysconfig_openvswitch | 11 ++++
|
|
||||||
4 files changed, 86 insertions(+), 14 deletions(-)
|
|
||||||
create mode 100644 xenserver/etc_sysconfig_openvswitch
|
|
||||||
|
|
||||||
|
|
||||||
diff --git a/xenserver/automake.mk b/xenserver/automake.mk
|
|
||||||
index fc23a76..a6c7989 100644
|
|
||||||
--- a/xenserver/automake.mk
|
|
||||||
+++ b/xenserver/automake.mk
|
|
||||||
@@ -27,4 +27,5 @@ EXTRA_DIST += \
|
|
||||||
xenserver/usr_share_openvswitch_scripts_ovs-external-ids \
|
|
||||||
xenserver/usr_share_openvswitch_scripts_refresh-xs-network-uuids \
|
|
||||||
xenserver/usr_share_openvswitch_scripts_sysconfig.template \
|
|
||||||
+ xenserver/etc_sysconfig_openvswitch \
|
|
||||||
xenserver/uuid.py
|
|
||||||
diff --git a/xenserver/etc_init.d_openvswitch b/xenserver/etc_init.d_openvswitch
|
|
||||||
index 5f18196..79de6f0 100755
|
|
||||||
--- a/xenserver/etc_init.d_openvswitch
|
|
||||||
+++ b/xenserver/etc_init.d_openvswitch
|
|
||||||
@@ -18,13 +18,46 @@
|
|
||||||
# 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.
|
|
||||||
+### BEGIN INIT INFO
|
|
||||||
+# Provides: vswitch
|
|
||||||
+# Required-Start: $local_fs
|
|
||||||
+# Required-Stop: $local_fs
|
|
||||||
+# Default-Start: 2 3 5
|
|
||||||
+# Default-Stop:
|
|
||||||
+# Short-Description: vswitch
|
|
||||||
+# Description: virtual switch
|
|
||||||
+### END INIT INFO
|
|
||||||
+
|
|
||||||
+#. /etc/init.d/functions
|
|
||||||
+# source function library
|
|
||||||
+if [ -f /etc/init.d/functions ]; then
|
|
||||||
+ . /etc/init.d/functions
|
|
||||||
+elif [ -f /etc/rc.d/init.d/functions ]; then
|
|
||||||
+ . /etc/rc.d/init.d/functions
|
|
||||||
+elif [ -f /lib/lsb/init-functions ]; then
|
|
||||||
+ . /lib/lsb/init-functions
|
|
||||||
+else
|
|
||||||
+ exit 0
|
|
||||||
+fi
|
|
||||||
|
|
||||||
-. /etc/init.d/functions
|
|
||||||
+# Ugh, SUSE doesn't implement action
|
|
||||||
+action() {
|
|
||||||
+ STRING=$1
|
|
||||||
+ shift
|
|
||||||
+ "$@"
|
|
||||||
+ rc=$?
|
|
||||||
+ if [ $rc -eq 0 ] ; then
|
|
||||||
+ log_success_msg $"$STRING "
|
|
||||||
+ else
|
|
||||||
+ log_failure_msg $"$STRING "
|
|
||||||
+ fi
|
|
||||||
+ return $rc
|
|
||||||
+}
|
|
||||||
|
|
||||||
-. /etc/xensource-inventory
|
|
||||||
test -e /etc/sysconfig/openvswitch && . /etc/sysconfig/openvswitch
|
|
||||||
|
|
||||||
-NETWORK_MODE=$(cat /etc/xensource/network.conf)
|
|
||||||
+test -e /etc/xensource-inventory && . /etc/xensource-inventory
|
|
||||||
+
|
|
||||||
case $NETWORK_MODE in
|
|
||||||
vswitch|openvswitch)
|
|
||||||
;;
|
|
||||||
@@ -38,14 +71,19 @@ case $NETWORK_MODE in
|
|
||||||
esac
|
|
||||||
|
|
||||||
# General config variables in /etc/sysconfig/openvswitch
|
|
||||||
-if test "$PRODUCT_VERSION" = "5.5.0"; then
|
|
||||||
- # XenServer 5.5.0 needs ovs-brcompatd and /proc/net simulation.
|
|
||||||
+if [ -f /etc/xensource-inventory ]; then
|
|
||||||
+ if test "$PRODUCT_VERSION" = "5.5.0"; then
|
|
||||||
+ # XenServer 5.5.0 needs ovs-brcompatd and /proc/net simulation.
|
|
||||||
+ : ${ENABLE_BRCOMPAT:=y}
|
|
||||||
+ : ${ENABLE_FAKE_PROC_NET:=y}
|
|
||||||
+ else
|
|
||||||
+ # Later versions don't need them.
|
|
||||||
+ : ${ENABLE_BRCOMPAT:=n}
|
|
||||||
+ : ${ENABLE_FAKE_PROC_NET:=n}
|
|
||||||
+ fi
|
|
||||||
+else
|
|
||||||
: ${ENABLE_BRCOMPAT:=y}
|
|
||||||
: ${ENABLE_FAKE_PROC_NET:=y}
|
|
||||||
-else
|
|
||||||
- # Later versions don't need them.
|
|
||||||
- : ${ENABLE_BRCOMPAT:=n}
|
|
||||||
- : ${ENABLE_FAKE_PROC_NET:=n}
|
|
||||||
fi
|
|
||||||
: ${ENABLE_MONITOR:=y}
|
|
||||||
: ${FORCE_COREFILES:=y}
|
|
||||||
@@ -297,6 +335,7 @@ EOF
|
|
||||||
}
|
|
||||||
|
|
||||||
function set_system_ids {
|
|
||||||
+
|
|
||||||
if [ -f /etc/xensource-inventory ]; then
|
|
||||||
action "Configuring Open vSwitch system IDs" true
|
|
||||||
$vsctl --no-wait --timeout=5 set Open_vSwitch . \
|
|
||||||
@@ -305,7 +344,17 @@ function set_system_ids {
|
|
||||||
external-ids:system-id="$INSTALLATION_UUID" \
|
|
||||||
external-ids:xs-system-uuid="$INSTALLATION_UUID"
|
|
||||||
else
|
|
||||||
- action "Configuring Open vSwitch system IDs" false
|
|
||||||
+
|
|
||||||
+ if [ -f /etc/openvswitch/install_uuid.conf ]; then
|
|
||||||
+ . /etc/openvswitch/install_uuid.conf
|
|
||||||
+ else
|
|
||||||
+ INSTALLATION_UUID=`uuidgen`
|
|
||||||
+ echo "INSTALLATION_UUID=$INSTALLATION_UUID" > /etc/openvswitch/install_uuid.conf
|
|
||||||
+ fi
|
|
||||||
+ $vsctl --no-wait --timeout=5 set Open_vSwitch . \
|
|
||||||
+ external-ids:system-id="$INSTALLATION_UUID" \
|
|
||||||
+ external-ids:xs-system-uuid="$INSTALLATION_UUID"
|
|
||||||
+ action "Configuring Open vSwitch system IDs" true
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -350,10 +399,12 @@ function start {
|
|
||||||
start_brcompatd
|
|
||||||
fi
|
|
||||||
|
|
||||||
- # Start daemon to monitor external ids
|
|
||||||
- PYTHONPATH=/usr/share/openvswitch/python \
|
|
||||||
- /usr/share/openvswitch/scripts/ovs-external-ids \
|
|
||||||
- --pidfile --detach $monitor_opt "$VSWITCHD_OVSDB_SERVER"
|
|
||||||
+ if [ -f /etc/xensource-inventory ]; then
|
|
||||||
+ # Start daemon to monitor external ids
|
|
||||||
+ PYTHONPATH=/usr/share/openvswitch/python \
|
|
||||||
+ /usr/share/openvswitch/scripts/ovs-external-ids \
|
|
||||||
+ --pidfile --detach $monitor_opt "$VSWITCHD_OVSDB_SERVER"
|
|
||||||
+ fi
|
|
||||||
|
|
||||||
touch /var/lock/subsys/openvswitch
|
|
||||||
}
|
|
||||||
diff --git a/xenserver/etc_init.d_openvswitch-xapi-update b/xenserver/etc_init.d_openvswitch-xapi-update
|
|
||||||
index bc62ba2..e2e8e98 100755
|
|
||||||
--- a/xenserver/etc_init.d_openvswitch-xapi-update
|
|
||||||
+++ b/xenserver/etc_init.d_openvswitch-xapi-update
|
|
||||||
@@ -18,6 +18,15 @@
|
|
||||||
# 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.
|
|
||||||
+### BEGIN INIT INFO
|
|
||||||
+# Provides: openvswitch-api-update
|
|
||||||
+# Required-Start: $network $remote_fs
|
|
||||||
+# Required-Stop: $network
|
|
||||||
+# Default-Start: 3 5
|
|
||||||
+# Default-Stop:
|
|
||||||
+# Short-Description: openvswitch-api-update
|
|
||||||
+# Description: virtual switch-api-update
|
|
||||||
+### END INIT INFO
|
|
||||||
|
|
||||||
. /etc/init.d/functions
|
|
||||||
|
|
||||||
diff --git a/xenserver/etc_sysconfig_openvswitch b/xenserver/etc_sysconfig_openvswitch
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..16f915f
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/xenserver/etc_sysconfig_openvswitch
|
|
||||||
@@ -0,0 +1,11 @@
|
|
||||||
+### Configuration options for openvswitch
|
|
||||||
+
|
|
||||||
+# Copyright (C) 2009, 2010 Nicira Networks, Inc.
|
|
||||||
+#
|
|
||||||
+# Copying and distribution of this file, with or without modification,
|
|
||||||
+# are permitted in any medium without royalty provided the copyright
|
|
||||||
+# notice and this notice are preserved. This file is offered as-is,
|
|
||||||
+# without warranty of any kind.
|
|
||||||
+
|
|
||||||
+NETWORK_MODE=openvswitch
|
|
||||||
+
|
|
Loading…
Reference in New Issue
Block a user