Merge "hugepage_doc: Add hugepage configuration info to installation doc"
[vswitchperf.git] / conf / 02_vswitch.conf
1 # Copyright 2015-2016 Intel Corporation.
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #   http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 # ############################
16 # Directories
17 # ############################
18 # use DPDK VHOST USER by default
19 RTE_SDK = RTE_SDK_USER
20 OVS_DIR = OVS_DIR_USER
21
22 OVS_VAR_DIR = '/usr/local/var/run/openvswitch/'
23 OVS_ETC_DIR = '/usr/local/etc/openvswitch/'
24
25 VSWITCH_DIR = os.path.join(ROOT_DIR, 'vswitches')
26
27 # ############################
28 # DPDK configuration
29 # ############################
30
31 # DPDK target used when builing DPDK
32 RTE_TARGET = 'x86_64-native-linuxapp-gcc'
33
34 # list of NIC HWIDs to which traffic generator is connected
35 # In case of NIC with SRIOV suport, it is possible to define,
36 # which virtual function should be used
37 # e.g. value '0000:05:00.0|vf1' will configure two VFs and second VF
38 # will be used for testing
39 WHITELIST_NICS = ['0000:05:00.0', '0000:05:00.1']
40
41 # for DPDK_MODULES the path is in reference to the build directory
42 # To use vfio set
43 # DPDK_MODULES = [
44 #     ('vfio-pci'),
45 # ]
46 DPDK_MODULES = [
47     ('kmod', 'igb_uio'),
48 ]
49
50 VHOST_MODULE = [
51     ('eventfd_link', 'eventfd_link')
52 ]
53
54 # list of modules that will be inserted using 'modprobe' on system init
55 # To use vfio set
56 # SYS_MODULES = ['cuse']
57 SYS_MODULES = ['uio', 'cuse']
58
59 # vhost character device file used by dpdkvhostport QemuWrap cases
60 VHOST_DEV_FILE = 'ovs-vhost-net'
61
62 # location of vhost-user sockets
63 VHOST_USER_SOCKS = ['/tmp/dpdkvhostuser0', '/tmp/dpdkvhostuser1',
64                     '/tmp/dpdkvhostuser2', '/tmp/dpdkvhostuser3',
65                     '/tmp/myport0', '/tmp/helloworld123', '/tmp/abcstuff0']
66
67 # ############################
68 # vswitch configuration
69 # ############################
70 # These are DPDK EAL parameters and they may need to be changed depending on
71 # hardware configuration, like cpu numbering and NUMA.
72 VSWITCHD_DPDK_ARGS = ['-c', '0x4', '-n', '4', '--socket-mem 1024,0']
73
74 VSWITCHD_VANILLA_ARGS = []
75
76 # use full module path to load module matching OVS version built from the source
77 VSWITCH_VANILLA_KERNEL_MODULES = ['libcrc32c', 'ip_tunnel', 'vxlan', 'gre', 'nf_conntrack', 'nf_defrag_ipv4', 'nf_defrag_ipv6', os.path.join(OVS_DIR_VANILLA, 'datapath/linux/openvswitch.ko')]
78
79 # Bridge name to be used by VSWTICH
80 VSWITCH_BRIDGE_NAME = 'br0'
81
82 # directory where hugepages will be mounted on system init
83 HUGEPAGE_DIR = '/dev/hugepages'
84
85 # Sets OVS PMDs core mask to 30 for affinitization to 5th and 6th CPU core.
86 # Note that the '0x' notation should not be used.
87 VSWITCH_PMD_CPU_MASK = '30'
88 VSWITCH_AFFINITIZATION_ON = 1
89
90 VSWITCH_FLOW_TIMEOUT = '30000'
91
92 # list of tuples of format (path, module_name), which will be inserted
93 # using 'insmod' on system init
94
95 # for OVS modules the path is in reference to the OVS directory.
96 OVS_MODULES = []
97
98 # log file for ovs-vswitchd
99 LOG_FILE_VSWITCHD = 'vswitchd.log'
100
101 # log file for ovs-dpdk
102 LOG_FILE_OVS = 'ovs.log'
103
104 # default vswitch implementation
105 VSWITCH = "OvsDpdkVhost"