====== Openvswitch (OVS) tips & trips ====== **Before anything - RTFF - [[http://git.openvswitch.org/cgi-bin/gitweb.cgi?p=openvswitch;a=blob_plain;f=FAQ;hb=HEAD|FAQ (Frequently Asked Questions)]]** ===== Installation/compile ===== ==== Debian / from source / GIT ==== export DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -b -us -uc -nc ===== Configuration tips ===== ==== Configuration in Debian/Ubuntu via /etc/network/interfaces ==== Example: allow-ovs br0 iface br0 inet manual ovs_type OVSBridge ovs_ports mgt0 eth1 eth2 ovs_extra set Bridge br0 stp_enable=true allow-br0 mgt0 iface mgt0 inet static address 10.14.131.34 netmask 255.255.255.224 ovs_bridge br0 ovs_type OVSIntPort ovs_options vlan_mode=access ovs_options tag=999 allow-br0 eth1 iface eth1 inet manual ovs_bridge br0 ovs_type OVSPort ovs_options vlan_mode=native-untagged ovs_options trunks=10,20,30,40 ovs_options tag=999 allow-br0 eth2 iface eth2 inet manual ovs_bridge br0 ovs_type OVSPort ovs_options vlan_mode=trunk ovs_options trunks=30,40 ==== Creating GRE tunnel ==== allow-ovs br0 iface br0 inet manual ovs_type OVSBridge ovs_ports mgt0 eth1 ovs_extra set Bridge br0 stp_enable=true post-up ovs-vsctl add-port br0 vgre0 -- set interface vgre0 type=gre \ options:remote_ip=10.0.0.1 .... ===== Frequently use (useful) command ===== # Dump flows ovs-ofctl dump-flows br0 # Show mac table ovs-appctl fdb/show br0 # Show switch ovs-vsctl show # Show datapath ovs-dpctl show # Turn debugging on ovs-appctl vlog/set dbg ===== Troubleshooting ===== ==== GRE problem ==== "You need to unload ''**ip_gre**'' and ''**gre**'' module, openvswitch GRE does not work along with kernel GRE module for now."