2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-19 14:37:21 +00:00
Commit Graph

20 Commits

Author SHA1 Message Date
Ben Pfaff
acfb4e9597 xenserver: Synchronize scripts with XenServer 6.0.0.
This commit updates the "vif" and "interface-reconfigure" scripts installed
by Open vSwitch on Citrix XenServer with those in XenServer 6.0.0.

Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-01-24 09:52:48 -08:00
Ben Pfaff
431488e663 Support vlan_group workaround implemented in XenServer kernels.
Some Linux network drivers support a feature called "VLAN acceleration",
associated with a data structure called a "vlan_group".  A vlan_group is,
abstractly, a dictionary that maps from a VLAN ID (in the range 0...4095)
to a VLAN device, that is, a Linux network device associated with a
particular VLAN, e.g. "eth0.9" for VLAN 9 on eth0.

Some drivers that support VLAN acceleration have bugs that fall roughly
into the following categories:

    * Some NICs strip VLAN tags on receive if no vlan_group is registered,
      so that the tag is completely lost.

    * Some drivers size their receive buffers based on whether a vlan_group
      is enabled, meaning that a maximum size packet with a VLAN tag will
      not fit if a vlan_group is not configured.

    * On transmit some drivers expect that VLAN acceleration will be used
      if it is available (which can only be done if a vlan_group is
      configured).  In these cases, the driver may fail to parse the packet
      and correctly setup checksum offloading and/or TSO.

The correct long term solution is to fix these driver bugs.  To cope until
then, we have prepared a patch to the Linux kernel network stack that works
around these problems.  This commit adds support for the workaround
implemented by that patch.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jesse Gross <jesse@nicira.com>
2011-03-16 14:39:17 -07:00
Andrew Evans
da54975c9d xenserver: Add support for disabling in-band management via XAPI.
Allow users or applications to enable or disable in-band management of
individual bridges by setting the 'vswitch-disable-in-band' key in the
'other_config' attribute of the corresponding network to 'true' or
'false'.

Bug #4749.
2011-02-28 18:26:48 -08:00
Andrew Evans
404c169247 xenserver: Merge upstream changes and drop pre-5.6.100 support.
Citrix have made modifications to the various interface configuration scripts
that OVS replaces, so at present those modifications are lost when OVS is
installed on e.g. XenServer 5.6.100. This commit applies those changes while
preserving OVS-specific modifications that have been made in the interim.

One major change introduced by these updates is the removal of support for
XenServer releases prior to 5.6.100.

This commit also updates the OVS-supplied xen-bugtool in similar fashion. We
will soon remove xen-bugtool from OVS altogether and move the added OVS
functionality to an XML extension as described in the Supplemental Pack DDK
guide.
2011-02-11 13:03:06 -08:00
Ethan Jackson
2776e40860 xenserver: Allow LACP configuration from xapi.
Makes required changes to interface reconfigure to allow LACP
configuration from xapi.  Conforms to XenServer style bonding
configuration which is slightly different from OVS.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
Bug #4213.
2011-02-03 12:26:58 -08:00
Ethan Jackson
2dd2683703 xenserver: Support fail_mode override at network level.
This patch allows the Pool object's vswitch-controller-fail-mode
setting to be overridden on by Network object.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
2011-01-26 18:17:37 -08:00
Ethan Jackson
0671665d93 xenserver: Allow NULL pool in configuration cache.
InterfaceReconfigure assumes the pool is in the configuration
cache.  This is always true except when upgrading from an older
version of openvswitch which does record the pool.  This can cause
upgrades to lock up.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
2011-01-19 17:08:59 -08:00
Ethan Jackson
939e5a1bbf xenserver: Allow fail_mode to be set from xapi.
This commit allows xapi to set the fail mode through the
vswitch-controller-fail-mode other-config setting in the Pool
object.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
2011-01-18 14:57:08 -08:00
Ethan Jackson
3dfa61ca3d xenserver: Allow unknown other-config attributes.
When saving the database cache, InterfaceReconfigure can crash if
unexpected attributes are in an object's other-config column.  This
commit causes it to skip that attribute and log a warning.

Signed-off-by: Ethan Jackson <ethan@nicira.com>
CC: Ian Campbell <Ian.Campbell@citrix.com>
CC: Dominic Curran <Dominic.Curran@citrix.com>
2011-01-18 14:57:08 -08:00
Ian Campbell
a361c3a86a xenserver: Largely untested patch for 5.5 and 5.6 CHIN compatibility 2010-06-23 12:34:05 -07:00
Ian Campbell
92e906e484 interface-reconfigure: Handle CHIN Tunnel objects
Only the vswitch backend is able to implement CHIN.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
2010-06-23 12:32:08 -07:00
Ian Campbell
823c5699d4 interface-reconfigure: callout to datapath backend class method on rewrite
Use this mechanism to allow the vswitch backend to update the vswitch
configuration's mapping from datapath to XenAPI datamodel Network
UUIDs. The vswitch needs a mechanism to update these when they change
(i.e. on pool join and eject).

Refactor the DatapathFactory method to return the class which the
caller can instantiate or not as the require.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
2010-06-04 10:20:36 -07:00
Ian Campbell
aeb2b7a166 interface-reconfigure+vif: accept openvswitch in /etc/xensource/network.conf
Signed-off-by: Ian Campbell <ian.campbell@citrix.com>
2010-04-08 09:39:36 -07:00
Ben Pfaff
3a32d4ca77 xenserver: Avoid error due to missing MTU fields on XenServer 5.5.
The network records in XenServer 5.5 do not have an MTU field, so allow
these to be missing.

Diagnosed-by: Reid Price <reid@nicira.com>
CC: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2010-02-24 15:45:11 -08:00
Ian Campbell
9a2b117527 CP-1592: interface-reconfigure: Configure network device MTU from Network.MTU field
With override via other-config:mtu field on specific objects in the datamodel.

Signed-off-by: Ian Campbell <ian.campbell@citrix.com>

# HG changeset patch
# User Ian Campbell <ian.campbell@citrix.com>
# Date 1267008538 0
# Node ID a91df72fd4bf6329831d3efcae45a5ff55e3ba2e
# Parent  219104a041786d7274b15800de5c3efccf0c4f42
2010-02-24 10:54:41 -08:00
Ben Pfaff
b63fadcfdc xenserver: Add --no-syslog feature to interface-reconfigure.
This makes it easier to do unit tests (some of which will be added in an
upcoming commit) by allowing messages to be read from stderr instead of
having to somehow intercept syslog calls.

Signed-off-by: Ben Pfaff <blp@nicira.com>
2010-02-23 09:55:44 -08:00
Ben Pfaff
64ddb6fecf xenserver: Add --root-prefix feature to interface-reconfigure.
This makes it easier to do unit tests (some of which will be added in an
upcoming commit) by allowing fake configuration files and scripts to be
added in a directory other than the real root.

Signed-off-by: Ben Pfaff <blp@nicira.com>
2010-02-23 09:55:42 -08:00
Ben Pfaff
96c7918c40 xenserver: Hoist identical bridge and vswitch functions into common code.
The previous commit made pif_bridge_name() in the bridge and vswitch
versions of interface-reconfigure functionally identical, so this commit
hoists them into a single common implementation in InterfaceReconfigure.py.

pif_is_bridged() also comes along for the ride because it is also generic
and because it is logically related.  Only the bridge code uses it at the
moment.

Suggested-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
2010-02-23 09:52:13 -08:00
Justin Pettit
13ffee26f1 xenserver: Various cleanups to get OVS to work with XenServer 5.5 2010-02-06 20:48:48 -08:00
Ian Campbell
b3080599f6 xenserver: Update interface-reconfigure and vif integration scripts.
This patch updates the versions of the host integration scripts to
what is present in the recent XCP update and the next release of
XenServer (5.6). I think it probably works on 5.5 as well but I
haven't verified that.

These new versions support runtime selection of the Linux bridging vs
vswitch through the toolstack. The patch includes the necessary
reconfiguration (rewriting /etc/xensource/network.conf) to enable
vswitch in the RPM %post stage.

The RPM spec file integration is only lightly tested, seems to work
for me.

This commit is as provided by Ian Campbell, with a few minor tweaks:

    - Updated xenserver/automake.mk to distribute the added files.

    - Updated RPM spec file not to complain if the added files do
      not already exist (since they do not exist on XenServer 5.5.0).

    - Change location of dbcache back to /var/lib/openvswitch/dbcache
      so that this can coexist with our other internal builds.
      (Undoubtedly we will have to adopt the new location chosen by Ian
      eventually, however.)
2010-01-25 10:36:08 -08:00