A component-based software defined networking framework for OpenStack.
Go to file
Yuichi Ito 70542380d3 test tool: add OpenFlowSwitch test tool
What this patch implements:

    This patch implements a tool which performs OpenFlow conformance testing.
    The tool can:
      - install various flow entries of OpenFlow 1.3 as follows:
        * all 'action' except SET_QUEUE and GROUP
        * all 'match' except IN_PHY_PORT
      - confirm whether the datapath works correctly according to the installed flow entries.

Required test environment:

    The tool requires the test environment that includes 2 switches and 2 links as follows:

                      +-----------+
           +----------| target sw | The OpenFlow switch to be tested
           |          +-----------+
    +------------+      (1)   (2)
    | controller |       |     |
    +------------+      (1)   (2)
           |          +-----------+
           +----------| tester sw | OpenFlow Switch
                      +-----------+

      (X) : port number

How does the tool work:

    The tool will:
      - install the flow entries into the target switch.
      - transmit a packet from the tester switch to the target switch.
        * According to the installed flow entries, the target switch outputs a packet towards the tester switch.
        * The tester switch sends a PacketIn message to the tool.
      - examine the packet that is included in the PacketIn message and output the result.
        * The tool supports also the table-miss examinations.

    The tool processes test files in the specified directory sequentially.

    By forming the result, you can create the list as:
    http://osrg.github.io/ryu-certification/switch/ovs.html
    http://osrg.github.io/ryu-certification/switch/LINC.html
    http://osrg.github.io/ryu-certification/switch/ofsoftswitch13.html

Required test file format:

    [
        "test name",
        {
            test pattern #01
        },
        {
            test pattern #02
        }, ...
    ]

    Each test pattern has the following internal format:

    {
        "description": description of this test pattern,
        "prerequisite": [
            FlowMod messages used by this test pattern
        ],
        "tests": [
            "ingress": inbound packet data,
            "egress": outbound packet data,
            "PACKET-IN": packet data sent by PacketIn message,
            "table-miss": table id in which table-miss occurs
        ]
    }

    The extensions of the test files have to be '.json'.

How to run:

    Do the following command:
    ryu-manager ryu/tests/switch/tester.py

    The following options can be used:
      - --test-switch-target   (target sw dp-id)
      - --test-switch-tester   (tester sw dp-id)
      - --test-switch-dir      (test files directory)

    ex)
    ryu-manager --test-switch-target 0000000000000005 --test-switch-dir /home/ryu/tests ryu/tests/switch/tester.py

Signed-off-by: WATANABE Fumitaka <watanabe.fumitaka@nttcom.co.jp>
Signed-off-by: Yuichi Ito <ito.yuichi0@gmail.com>
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
2013-12-13 17:27:49 +09:00
bin a simple command line msgpack-rpc client 2013-11-29 09:23:41 +09:00
doc rpc-cli man page 2013-11-29 09:23:41 +09:00
etc/ryu revert s/_/-/ changes for ryu.conf 2013-03-04 21:14:29 +09:00
ryu test tool: add OpenFlowSwitch test tool 2013-12-13 17:27:49 +09:00
tools msgpack-rpc fixes and improvements 2013-11-29 09:23:37 +09:00
.gitignore add .tox/ to .gitignore 2013-09-02 14:44:29 +09:00
.pylintrc test: improve the framework 2012-06-27 20:57:07 +09:00
.travis.yml use run_tests.sh -N for Travis CI 2013-09-08 17:47:52 +09:00
LICENSE LICENCE: change end-of-line code CRLF to LF 2013-02-13 06:10:15 +09:00
MANIFEST.in MANIFEST.in: exclude packet_data_generator 2013-08-24 09:41:44 +09:00
README.rst sync README with the web site 2013-08-01 10:09:36 +09:00
run_tests.sh a simple command line msgpack-rpc client 2013-11-29 09:23:41 +09:00
setup.cfg a simple command line msgpack-rpc client 2013-11-29 09:23:41 +09:00
setup.py avoid pbr's non multi-version aware script 2013-10-07 18:08:36 +09:00
SubmittingPatches.rst SubmittingPatches: mention tools/normalize_json.py 2013-11-03 14:31:23 +09:00
tox.ini Add a configuration file for tox (http://testrun.org/tox/) 2013-09-02 12:35:05 +09:00

What's Ryu

Ryu is a component-based software defined networking framework.

Ryu provides software components with well defined API that make it easy for developers to create new network management and control applications. Ryu supports various protocols for managing network devices, such as OpenFlow, Netconf, OF-config, etc. About OpenFlow, Ryu supports fully 1.0, 1.2, 1.3 and Nicira Extensions.

All of the code is freely available under the Apache 2.0 license. Ryu is fully written in Python.

Quick Start

Installing Ryu is quite easy:

% pip install ryu

If you prefer to install Ryu from the source code:

% git clone git://github.com/osrg/ryu.git
% cd ryu; python ./setup.py install

If you want to use Ryu with OpenStack, please refer detailed documents. You can create tens of thousands of isolated virtual networks without using VLAN. The Ryu application is included in OpenStack mainline as of Essex release.

If you want to write your Ryu application, have a look at Writing ryu application document. After writing your application, just type:

% ryu-manager yourapp.py

Support

Ryu Official site is http://osrg.github.io/ryu/.

If you have any questions, suggestions, and patches, the mailing list is available at ryu-devel ML. The ML archive at Gmane is also available.