the right compiler, linker, libraries, Open vSwitch component installation
directories, etc. For example,
- % ./configure CC=./build-aux/cccl LD="`which link`" LIBS="-lws2_32" \
- --prefix="C:/openvswitch/usr" --localstatedir="C:/openvswitch/var" \
- --sysconfdir="C:/openvswitch/etc" --with-pthread="C:/pthread"
+ % ./configure CC=./build-aux/cccl LD="`which link`" \
+ LIBS="-lws2_32 -liphlpapi" --prefix="C:/openvswitch/usr" \
+ --localstatedir="C:/openvswitch/var" --sysconfdir="C:/openvswitch/etc" \
+ --with-pthread="C:/pthread"
By default, the above enables compiler optimization for fast code.
For default compiler optimization, pass the "--with-debug" configure
* While configuring the package, specify the OpenSSL directory path.
For example,
- % ./configure CC=./build-aux/cccl LD="`which link`" LIBS="-lws2_32" \
- --prefix="C:/openvswitch/usr" --localstatedir="C:/openvswitch/var" \
- --sysconfdir="C:/openvswitch/etc" --with-pthread="C:/pthread" \
- --enable-ssl --with-openssl="C:/OpenSSL-Win32"
+ % ./configure CC=./build-aux/cccl LD="`which link`" \
+ LIBS="-lws2_32 -liphlpapi" --prefix="C:/openvswitch/usr" \
+ --localstatedir="C:/openvswitch/var" --sysconfdir="C:/openvswitch/etc" \
+ --with-pthread="C:/pthread" --enable-ssl --with-openssl="C:/OpenSSL-Win32"
* Run make for the ported executables.
* The kernel datapath can be compiled from command line as well. The top
level 'make' will invoke building the kernel datapath, if the
-'--with-vstudioddk' argument is specified while configuring the package.
+'--with-vstudiotarget' argument is specified while configuring the package.
For example,
- % ./configure CC=./build-aux/cccl LD="`which link`" LIBS="-lws2_32" \
- --prefix="C:/openvswitch/usr" --localstatedir="C:/openvswitch/var" \
- --sysconfdir="C:/openvswitch/etc" --with-pthread="C:/pthread" \
- --enable-ssl --with-openssl="C:/OpenSSL-Win32" \
- --with-vstudioddk="<WDK to use>"
+ % ./configure CC=./build-aux/cccl LD="`which link`" \
+ LIBS="-lws2_32 -liphlpapi" --prefix="C:/openvswitch/usr" \
+ --localstatedir="C:/openvswitch/var" --sysconfdir="C:/openvswitch/etc" \
+ --with-pthread="C:/pthread" --enable-ssl \
+ --with-openssl="C:/OpenSSL-Win32" --with-vstudiotarget="<target type>"
- Possible values for "<WDK to use>" are:
- "Win8.1 Debug", "Win8.1 Release", "Win8 Debug" and "Win8 Release".
+ Possible values for "<target type>" are:
+ "Debug" and "Release"
Installing the Kernel module
----------------------------
02> Run ./install.cmd to insert the new one. For this to work you will have to
turn on TESTSIGNING boot option or 'Disable Driver Signature Enforcement'
-during boot.
+during boot. The following commands can be used:
+ % bcdedit /set LOADOPTIONS DISABLE_INTEGRITY_CHECKS
+ % bcdedit /set TESTSIGNING ON
+ % bcdedit /set nointegritychecks ON
+
+Note: you may have to restart the machine for the settings to take effect.
03> In the Virtual Switch Manager configuration you can enable the Open vSwitch
Extension on an existing switch or create a new switch. If you are using an
Port br-pif
Interface br-pif
type: internal
- Bridge br-int
Port "external.1"
Interface "external.1"
+ Bridge br-int
Port br-int
Interface br-int
type: internal
% ovs-vsctl add-port br-int ovs-port-a tag=900
% ovs-vsctl add-port br-int ovs-port-b tag=900
-Steps to add VXLAN tunnels
+Steps to add tunnels
--------------------------
-The Windows Open vSwitch implementation support VXLAN tunnels. To add VXLAN
+The Windows Open vSwitch implementation support VXLAN and STT tunnels. To add
tunnels, the following steps serve as examples.
Note that, any patch ports created between br-int and br-pif MUST be beleted
-prior to adding VXLAN tunnels.
+prior to adding tunnels.
-01> Add the vxlan port between 172.168.201.101 <-> 172.168.201.102
- % ovs-vsctl add-port br-int vxlan-1
- % ovs-vsctl set Interface vxlan-1 type=vxlan
- % ovs-vsctl set Interface vxlan-1 options:local_ip=172.168.201.101
- % ovs-vsctl set Interface vxlan-1 options:remote_ip=172.168.201.102
- % ovs-vsctl set Interface vxlan-1 options:in_key=flow
- % ovs-vsctl set Interface vxlan-1 options:out_key=flow
+01> Add the tunnel port between 172.168.201.101 <-> 172.168.201.102
+ % ovs-vsctl add-port br-int tun-1
+ % ovs-vsctl set Interface tun-1 type=port-type
+ % ovs-vsctl set Interface tun-1 options:local_ip=172.168.201.101
+ % ovs-vsctl set Interface tun-1 options:remote_ip=172.168.201.102
+ % ovs-vsctl set Interface tun-1 options:in_key=flow
+ % ovs-vsctl set Interface tun-1 options:out_key=flow
-02> Add the vxlan port between 172.168.201.101 <-> 172.168.201.105
- % ovs-vsctl add-port br-int vxlan-2
- % ovs-vsctl set Interface vxlan-2 type=vxlan
- % ovs-vsctl set Interface vxlan-2 options:local_ip=172.168.201.102
- % ovs-vsctl set Interface vxlan-2 options:remote_ip=172.168.201.105
- % ovs-vsctl set Interface vxlan-2 options:in_key=flow
- % ovs-vsctl set Interface vxlan-2 options:out_key=flow
+02> Add the tunnel port between 172.168.201.101 <-> 172.168.201.105
+ % ovs-vsctl add-port br-int tun-2
+ % ovs-vsctl set Interface tun-2 type=port-type
+ % ovs-vsctl set Interface tun-2 options:local_ip=172.168.201.102
+ % ovs-vsctl set Interface tun-2 options:remote_ip=172.168.201.105
+ % ovs-vsctl set Interface tun-2 options:in_key=flow
+ % ovs-vsctl set Interface tun-2 options:out_key=flow
+
+ Where port-type is the string stt or vxlan
Requirements
this is still a work in progress. Till the support is complete we recommend
disabling TX/RX offloads for both the VM's as well as the HyperV.
+Windows Services
+----------------
+Open vSwitch daemons come with support to run as a Windows service. The
+instructions here assume that you have installed the Open vSwitch utilities
+and daemons via 'make install'. The commands shown here can be run from
+MSYS bash or Windows command prompt.
+
+* Create the database.
+
+ % ovsdb-tool create C:/openvswitch/etc/openvswitch/conf.db \
+ "C:/openvswitch/usr/share/openvswitch/vswitch.ovsschema"
+
+* Create the ovsdb-server service and start it.
+
+ % sc create ovsdb-server binpath="C:/openvswitch/usr/sbin/ovsdb-server.exe C:/openvswitch/etc/openvswitch/conf.db -vfile:info --log-file --pidfile --remote=punix:db.sock --service --service-monitor"
+
+ One of the common issues with creating a Windows service is with mungled
+ paths. You can make sure that the correct path has been registered with
+ the Windows services manager by running:
+
+ % sc qc ovsdb-server
+
+ Start the service.
+
+ % sc start ovsdb-server
+
+ Check that the service is healthy by running:
+
+ % sc query ovsdb-server
+
+* Initialize the database.
+
+ % ovs-vsctl --no-wait init
+
+* Create the ovs-vswitchd service and start it.
+
+ % sc create ovs-vswitchd binpath="C:/openvswitch/usr/sbin/ovs-vswitchd.exe --pidfile -vfile:info --log-file --service --service-monitor"
+
+ % sc start ovs-vswitchd
+
+ Check that the service is healthy by running:
+
+ % sc query ovs-vswitchd
+
+* To stop and delete the services, run:
+
+ % sc stop ovs-vswitchd
+ % sc stop ovsdb-server
+ % sc delete ovs-vswitchd
+ % sc delete ovsdb-server
+
Windows autobuild service
-------------------------
AppVeyor (appveyor.com) provides a free Windows autobuild service for