#!/bin/bash # https://bugs.launchpad.net/ubuntu/+source/openvswitch/+bug/1262692 # Depends: openvswitch-switch set -e # Exit with a non-zero exit code if any errors occure ip link add testdummy0 type dummy ovs-vsctl add-br integbr ifconfig testdummy0 192.168.234.21 netmask 255.255.255.0 ovs-vsctl add-port integbr gre0 -- set interface gre0 type=gre options:remote_ip=192.168.234.20 ovs-vsctl add-port integbr tsp0 -- set interface tsp0 type=internal ifconfig tsp0 192.168.15.2 netmask 255.255.255.0 iptables -F iptables -F -t nat # Cleanup sudo ip link del testdummy0 ovs-vsctl del-br integbr