~ubuntu-branches/ubuntu/wily/openvswitch/wily

« back to all changes in this revision

Viewing changes to README-native-tunneling.md

  • Committer: Package Import Robot
  • Author(s): James Page
  • Date: 2015-08-10 11:35:15 UTC
  • mfrom: (1.1.30)
  • Revision ID: package-import@ubuntu.com-20150810113515-575vj06oq29emxsn
Tags: 2.4.0~git20150810.97bab95-0ubuntu1
* New upstream snapshot from 2.4 branch:
  - d/*: Align any relevant packaging changes with upstream.
* d/*: wrap-and-sort.
* d/openvswitch-{common,vswitch}.install: Correct install location for
  bash completion files.
* d/tests/openflow.py: Explicitly use ovs-testcontroller as provided
  by 2.4.0 release.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Native Tunneling in Open vSwitch userspace
 
2
------------------------------------------
 
3
 
 
4
Open vSwitch supports tunneling in userspace. Tunneling is implemented in
 
5
platform independent way.
 
6
 
 
7
Setup:
 
8
======
 
9
Setup physical bridges for all physical interfaces. Create integration bridge.
 
10
Add VXLAN port to int-bridge. Assign IP address to physical bridge where
 
11
VXLAN traffic is expected.
 
12
 
 
13
Example:
 
14
========
 
15
Connect to VXLAN tunnel endpoint logical ip: 192.168.1.2 and 192.168.1.1.
 
16
 
 
17
Configure OVS bridges as follows.
 
18
 
 
19
1. Lets assume 172.168.1.2/24 network is reachable via eth1 create physical bridge br-eth1
 
20
   assign ip address (172.168.1.1/24) to br-eth1, Add eth1 to br-eth1
 
21
2. Check ovs cached routes using appctl command
 
22
   ovs-appctl ovs/route/show
 
23
   Add tunnel route if not present in OVS route table.
 
24
   ovs-appctl ovs/route/add 172.168.1.1/24 br-eth1
 
25
3. Add integration brdge int-br and add tunnel port using standard syntax.
 
26
   ovs-vsctl add-port int-br vxlan0 -- set interface vxlan0 type=vxlan  options:remote_ip=172.168.1.2
 
27
4. Assign IP address to int-br, So final topology looks like:
 
28
 
 
29
                 192.168.1.1/24
 
30
                +--------------+
 
31
                |    int-br    |                                    192.168.1.2/24
 
32
                +--------------+                                   +--------------+
 
33
                |    vxlan0    |                                   |    vxlan0    |
 
34
                +--------------+                                   +--------------+
 
35
                       |                                                  |
 
36
                       |                                                  |
 
37
                       |                                                  |
 
38
                 172.168.1.1/24                                           |
 
39
                +--------------+                                          |
 
40
                |    br-eth1   |                                   172.168.1.2/24
 
41
                +--------------+                                  +---------------+
 
42
                |    eth1      |----------------------------------|      eth1     |
 
43
                +--------------+                                  +---------------+
 
44
 
 
45
                Host A with OVS.                                      Remote host.
 
46
 
 
47
With this setup, ping to VXLAN target device (192.168.1.2) should work
 
48
There are following commands that shows internal tables:
 
49
 
 
50
Tunneling related commands:
 
51
===========================
 
52
Tunnel routing table:
 
53
    To Add route:
 
54
       ovs-appctl ovs/route/add <IP address>/<prefix length> <output-bridge-name> <gw>
 
55
    To see all routes configured:
 
56
       ovs-appctl ovs/route/show
 
57
    To del route:
 
58
       ovs-appctl ovs/route/del <IP address>/<prefix length>
 
59
    To look up and display the route for a destination:
 
60
       ovs-appctl ovs/route/lookup <IP address>
 
61
 
 
62
ARP:
 
63
    To see arp cache content:
 
64
       ovs-appctl tnl/arp/show
 
65
    To flush arp cache:
 
66
       ovs-appctl tnl/arp/flush
 
67
 
 
68
To check tunnel ports listening in vswitchd:
 
69
     ovs-appctl tnl/ports/show
 
70
 
 
71
To set range for VxLan udp source port:
 
72
     To set:
 
73
         ovs-appctl tnl/egress_port_range <num1> <num2>
 
74
     Shows Current range:
 
75
         ovs-appctl tnl/egress_port_range
 
76
 
 
77
To check datapath ports:
 
78
     ovs-appctl dpif/show
 
79
 
 
80
To check datapath flows:
 
81
     ovs-appctl dpif/dump-flows
 
82
 
 
83
Contact
 
84
=======
 
85
bugs@openvswitch.org