Setting tag sliver-openvswitch-2.2.90-1
[sliver-openvswitch.git] / INSTALL
diff --git a/INSTALL b/INSTALL
index 001d3cb..afefb51 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -10,6 +10,7 @@ on a specific platform, please see one of these files:
     - INSTALL.RHEL
     - INSTALL.XenServer
     - INSTALL.NetBSD
+    - INSTALL.DPDK
 
 Build Requirements
 ------------------
@@ -36,11 +37,15 @@ you will need the following software:
 
     - Python 2.x, for x >= 4.
 
-To compile the kernel module on Linux, you must also install the
-following.  If you cannot build or install the kernel module, you may
-use the userspace-only implementation, at a cost in performance.  The
-userspace implementation may also lack some features.  Refer to
-INSTALL.userspace for more information.
+On Linux, you may choose to compile the kernel module that comes with
+the Open vSwitch distribution or to use the kernel module built into
+the Linux kernel (version 3.3 or later).  See the FAQ question "What
+features are not available in the Open vSwitch kernel datapath that
+ships as part of the upstream Linux kernel?" for more information on
+this trade-off.  You may also use the userspace-only implementation,
+at some cost in features and performance (see INSTALL.userspace for
+details).  To compile the kernel module on Linux, you must also
+install the following:
 
     - A supported Linux kernel version.  Please refer to README for a
       list of supported versions.
@@ -172,6 +177,10 @@ Prerequisites section, follow the procedure below to build.
 
       % ./configure --with-linux=/lib/modules/`uname -r`/build
 
+   If --with-linux requests building for an unsupported version of
+   Linux, then "configure" will fail with an error message.  Please
+   refer to the FAQ for advice in that case.
+
    If you wish to build the kernel module for an architecture other
    than the architecture of the machine used for the build, you may
    specify the kernel architecture string using the KARCH variable
@@ -185,6 +194,11 @@ Prerequisites section, follow the procedure below to build.
    command line, turning warnings into errors.  That makes it
    impossible to miss warnings generated by the build.
 
+   To build with gcov code coverage support, add --enable-coverage,
+   e.g.:
+
+      % ./configure --enable-coverage
+
    The configure script accepts a number of other options and honors
    additional environment variables.  For a full list, invoke
    configure with the --help option.
@@ -274,9 +288,9 @@ Startup
 Before starting ovs-vswitchd itself, you need to start its
 configuration database, ovsdb-server.  Each machine on which Open
 vSwitch is installed should run its own copy of ovsdb-server.
-Configure it to use the database you created during step 7 of
-installation, above, to listen on a Unix domain socket, to connect to
-any managers specified in the database itself, and to use the SSL
+Configure it to use the database you created during installation (as
+explained above), to listen on a Unix domain socket, to connect to any
+managers specified in the database itself, and to use the SSL
 configuration in the database:
 
       % ovsdb-server --remote=punix:/usr/local/var/run/openvswitch/db.sock \
@@ -379,20 +393,27 @@ above, but also replaces the old kernel module with the new one. Open vSwitch
 startup scripts for Debian, XenServer and RHEL use ovs-ctl's functions and it
 is recommended that these functions be used for other software platforms too.
 
-Running the Testsuite
-=====================
+Testsuites
+==========
+
+This section describe Open vSwitch's built-in support for various test
+suites.  You must configure and build Open vSwitch (steps 1 through 3
+in "Building and Installing Open vSwitch for Linux, FreeBSD or NetBSD"
+above) before you run the tests described here.  You do not need to
+install Open vSwitch or to build or load the kernel module to run
+these test suites.  You do not need supervisor privilege to run these
+test suites.
 
-Open vSwitch includes a testsuite.  Before you submit patches
+Self-Tests
+----------
+
+Open vSwitch includes a suite of self-tests.  Before you submit patches
 upstream, we advise that you run the tests and ensure that they pass.
 If you add new features to Open vSwitch, then adding tests for those
 features will ensure your features don't break as developers modify
 other areas of Open vSwitch.
 
-You must configure and build Open vSwitch (steps 1 through 3 in
-"Building and Installing Open vSwitch for Linux, FreeBSD or NetBSD" above)
-before you run the testsuite.  You do not need to install Open vSwitch
-or to build or load the kernel module to run the testsuite.  You do
-not need supervisor privilege to run the testsuite.
+Refer to "Testsuites" above for prerequisites.
 
 To run all the unit tests in Open vSwitch, one at a time:
       make check
@@ -432,7 +453,87 @@ usually a bug in the testsuite, not a bug in Open vSwitch itself.  If
 you find that a test fails intermittently, please report it, since the
 developers may not have noticed.
 
+OFTest
+------
+
+OFTest is an OpenFlow protocol testing suite.  Open vSwitch includes a
+Makefile target to run OFTest with Open vSwitch in "dummy mode".  In
+this mode of testing, no packets travel across physical or virtual
+networks.  Instead, Unix domain sockets stand in as simulated
+networks.  This simulation is imperfect, but it is much easier to set
+up, does not require extra physical or virtual hardware, and does not
+require supervisor privileges.
+
+To run OFTest with Open vSwitch, first read and follow the
+instructions under "Testsuites" above.  Second, obtain a copy of
+OFTest and install its prerequisites.  You need a copy of OFTest that
+includes commit 406614846c5 (make ovs-dummy platform work again).
+This commit was merged into the OFTest repository on Feb 1, 2013, so
+any copy of OFTest more recent than that should work.  Testing OVS in
+dummy mode does not require root privilege, so you may ignore that
+requirement.
+
+Optionally, add the top-level OFTest directory (containing the "oft"
+program) to your $PATH.  This slightly simplifies running OFTest later.
+
+To run OFTest in dummy mode, run the following command from your Open
+vSwitch build directory:
+    make check-oftest OFT=<oft-binary>
+where <oft-binary> is the absolute path to the "oft" program in
+OFTest.
+
+If you added "oft" to your $PATH, you may omit the OFT variable
+assignment:
+    make check-oftest
+By default, "check-oftest" passes "oft" just enough options to enable
+dummy mode.  You can use OFTFLAGS to pass additional options.  For
+example, to run just the basic.Echo test instead of all tests (the
+default) and enable verbose logging:
+    make check-oftest OFT=<oft-binary> OFTFLAGS='--verbose -T basic.Echo'
+
+If you use OFTest that does not include commit 4d1f3eb2c792 (oft:
+change default port to 6653), merged into the OFTest repository in
+October 2013, then you need to add an option to use the IETF-assigned
+controller port:
+    make check-oftest OFT=<oft-binary> OFTFLAGS='--port=6653'
+
+Please interpret OFTest results cautiously.  Open vSwitch can fail a
+given test in OFTest for many reasons, including bugs in Open vSwitch,
+bugs in OFTest, bugs in the "dummy mode" integration, and differing
+interpretations of the OpenFlow standard and other standards.
+
+Open vSwitch has not been validated against OFTest.  Please do report
+test failures that you believe to represent bugs in Open vSwitch.
+Include the precise versions of Open vSwitch and OFTest in your bug
+report, plus any other information needed to reproduce the problem.
+
+Ryu
+---
+
+Ryu is an OpenFlow controller written in Python that includes an
+extensive OpenFlow testsuite.  Open vSwitch includes a Makefile target
+to run Ryu in "dummy mode".  See "OFTest" above for an explanation of
+dummy mode.
+
+To run Ryu tests with Open vSwitch, first read and follow the
+instructions under "Testsuites" above.  Second, obtain a copy of Ryu,
+install its prerequisites, and build it.  You do not need to install
+Ryu (some of the tests do not get installed, so it does not help).
+
+To run Ryu tests, run the following command from your Open vSwitch
+build directory:
+    make check-ryu RYUDIR=<ryu-source-dir>
+where <ryu-source-dir> is the absolute path to the root of the Ryu
+source distribution.  The default <ryu-source-dir> is $srcdir/../ryu
+where $srcdir is your Open vSwitch source directory, so if this
+default is correct then you make simply run "make check-ryu".
+
+Open vSwitch has not been validated against Ryu.  Please do report
+test failures that you believe to represent bugs in Open vSwitch.
+Include the precise versions of Open vSwitch and Ryu in your bug
+report, plus any other information needed to reproduce the problem.
+
 Bug Reporting
--------------
+=============
 
 Please report problems to bugs@openvswitch.org.