Prevents the cloning of rows with outgoing or incoming weak references when those rows aren't being modified. It improves the OVSDB Server performance when many rows with weak references are involved in a transaction. In the original code (dst_refs is created from scratch): old->dst_refs = all the rows that weak referenced old new->dst_refs = all the rows that weak referenced old and are still weak +referencing new + rows in the transaction that weak referenced new In the patch (dst_refs incrementally built): Old->dst_refs = all the rows that weak referenced old Ideally, but expansive to calculate: New->dst_refs = old->dst_refs - "weak references removed within this TXN" + +"weak references created within this TXN" What this patch implements: New->dst_refs = old->dst_refs - "weak references in old rows in TXN" + "weak +references in new rows in TXN" The resulting sets should be equal in both cases. We do some more optimizations: - If we know that the transactions must be successful at some point then, instead of cloning dst_refs we could just move the elements between the lists. - At that point we lost the rollback feature, but we aren't going to need it anyway (note that we didn't really touch the src_refs part). - The references in dst_refs must point to new instead than old. Previously we iterated over all the weak references in dst_refs to change that pointer, but using an UUID is easier, and prevents that iteration completely. For some more commentary, see: http://openvswitch.org/pipermail/dev/2016-July/074840.html Signed-off-by: Esteban Rodriguez Betancourt <estebarb@hpe.com> Signed-off-by: Ben Pfaff <blp@ovn.org>
Open vSwitch
Build Status:
What is Open vSwitch?
Open vSwitch is a multilayer software switch licensed under the open source Apache 2 license. Our goal is to implement a production quality switch platform that supports standard management interfaces and opens the forwarding functions to programmatic extension and control.
Open vSwitch is well suited to function as a virtual switch in VM environments. In addition to exposing standard control and visibility interfaces to the virtual networking layer, it was designed to support distribution across multiple physical servers. Open vSwitch supports multiple Linux-based virtualization technologies including Xen/XenServer, KVM, and VirtualBox.
The bulk of the code is written in platform-independent C and is easily ported to other environments. The current release of Open vSwitch supports the following features:
- Standard 802.1Q VLAN model with trunk and access ports
- NIC bonding with or without LACP on upstream switch
- NetFlow, sFlow(R), and mirroring for increased visibility
- QoS (Quality of Service) configuration, plus policing
- Geneve, GRE, GRE over IPSEC, VXLAN, and LISP tunneling
- 802.1ag connectivity fault management
- OpenFlow 1.0 plus numerous extensions
- Transactional configuration database with C and Python bindings
- High-performance forwarding using a Linux kernel module
The included Linux kernel module supports Linux 3.10 and up.
Open vSwitch can also operate, at a cost in performance, entirely in userspace, without assistance from a kernel module. This userspace implementation should be easier to port than the kernel-based switch. It is considered experimental.
What's here?
The main components of this distribution are:
- ovs-vswitchd, a daemon that implements the switch, along with a companion Linux kernel module for flow-based switching.
- ovsdb-server, a lightweight database server that ovs-vswitchd queries to obtain its configuration.
- ovs-dpctl, a tool for configuring the switch kernel module.
- Scripts and specs for building RPMs for Citrix XenServer and Red Hat Enterprise Linux. The XenServer RPMs allow Open vSwitch to be installed on a Citrix XenServer host as a drop-in replacement for its switch, with additional functionality.
- ovs-vsctl, a utility for querying and updating the configuration of ovs-vswitchd.
- ovs-appctl, a utility that sends commands to running Open vSwitch daemons.
Open vSwitch also provides some tools:
- ovs-ofctl, a utility for querying and controlling OpenFlow switches and controllers.
- ovs-pki, a utility for creating and managing the public-key infrastructure for OpenFlow switches.
- ovs-testcontroller, a simple OpenFlow controller that may be useful for testing (though not for production).
- A patch to tcpdump that enables it to parse OpenFlow messages.
What other documentation is available?
To install Open vSwitch on a regular Linux or FreeBSD host, please read INSTALL.md. For specifics around installation on a specific platform, please see one of these files:
To use Open vSwitch...
-
...with Docker on Linux, read INSTALL.Docker.md
-
...with KVM on Linux, read INSTALL.md, read INSTALL.KVM.md
-
...with Libvirt, read INSTALL.Libvirt.md.
-
...without using a kernel module, read INSTALL.userspace.md.
-
...with SELinux, read [INSTALL.SELinux.md].
For answers to common questions, read FAQ.md.
To learn how to set up SSL support for Open vSwitch, read INSTALL.SSL.md.
To learn about some advanced features of the Open vSwitch software switch, read the tutorial/Tutorial.md.
Each Open vSwitch userspace program is accompanied by a manpage. Many of the manpages are customized to your configuration as part of the build process, so we recommend building Open vSwitch before reading the manpages.