]> git.proxmox.com Git - ovs.git/blob - vswitchd/vswitch.xml
netns: Add documentation and update NEWS.
[ovs.git] / vswitchd / vswitch.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <database name="ovs-vswitchd.conf.db" title="Open vSwitch Configuration Database">
3 <p>
4 A database with this schema holds the configuration for one Open
5 vSwitch daemon. The top-level configuration for the daemon is the
6 <ref table="Open_vSwitch"/> table, which must have exactly one
7 record. Records in other tables are significant only when they
8 can be reached directly or indirectly from the <ref
9 table="Open_vSwitch"/> table. Records that are not reachable from
10 the <ref table="Open_vSwitch"/> table are automatically deleted
11 from the database, except for records in a few distinguished
12 ``root set'' tables.
13 </p>
14
15 <h2>Common Columns</h2>
16
17 <p>
18 Most tables contain two special columns, named <code>other_config</code>
19 and <code>external_ids</code>. These columns have the same form and
20 purpose each place that they appear, so we describe them here to save space
21 later.
22 </p>
23
24 <dl>
25 <dt><code>other_config</code>: map of string-string pairs</dt>
26 <dd>
27 <p>
28 Key-value pairs for configuring rarely used features. Supported keys,
29 along with the forms taken by their values, are documented individually
30 for each table.
31 </p>
32 <p>
33 A few tables do not have <code>other_config</code> columns because no
34 key-value pairs have yet been defined for them.
35 </p>
36 </dd>
37
38 <dt><code>external_ids</code>: map of string-string pairs</dt>
39 <dd>
40 Key-value pairs for use by external frameworks that integrate with Open
41 vSwitch, rather than by Open vSwitch itself. System integrators should
42 either use the Open vSwitch development mailing list to coordinate on
43 common key-value definitions, or choose key names that are likely to be
44 unique. In some cases, where key-value pairs have been defined that are
45 likely to be widely useful, they are documented individually for each
46 table.
47 </dd>
48 </dl>
49
50 <table name="Open_vSwitch" title="Open vSwitch configuration.">
51 Configuration for an Open vSwitch daemon. There must be exactly
52 one record in the <ref table="Open_vSwitch"/> table.
53
54 <group title="Configuration">
55 <column name="bridges">
56 Set of bridges managed by the daemon.
57 </column>
58
59 <column name="ssl">
60 SSL used globally by the daemon.
61 </column>
62
63 <column name="external_ids" key="system-id">
64 A unique identifier for the Open vSwitch's physical host.
65 The form of the identifier depends on the type of the host.
66 On a Citrix XenServer, this will likely be the same as
67 <ref column="external_ids" key="xs-system-uuid"/>.
68 </column>
69
70 <column name="external_ids" key="xs-system-uuid">
71 The Citrix XenServer universally unique identifier for the physical
72 host as displayed by <code>xe host-list</code>.
73 </column>
74
75 <column name="external_ids" key="hostname">
76 The hostname for the host running Open vSwitch. This is a fully
77 qualified domain name since version 2.6.2.
78 </column>
79
80 <column name="external_ids" key="rundir">
81 In Open vSwitch 2.8 and later, the run directory of the running Open
82 vSwitch daemon. This directory is used for runtime state such as
83 control and management sockets. The value of <ref
84 column="other_config" key="vhost-sock-dir"/> is relative to this
85 directory.
86 </column>
87
88 <column name="other_config" key="stats-update-interval"
89 type='{"type": "integer", "minInteger": 5000}'>
90 <p>
91 Interval for updating statistics to the database, in milliseconds.
92 This option will affect the update of the <code>statistics</code>
93 column in the following tables: <code>Port</code>, <code>Interface
94 </code>, <code>Mirror</code>.
95 </p>
96 <p>
97 Default value is 5000 ms.
98 </p>
99 <p>
100 Getting statistics more frequently can be achieved via OpenFlow.
101 </p>
102 </column>
103
104 <column name="other_config" key="flow-restore-wait"
105 type='{"type": "boolean"}'>
106 <p>
107 When <code>ovs-vswitchd</code> starts up, it has an empty flow table
108 and therefore it handles all arriving packets in its default fashion
109 according to its configuration, by dropping them or sending them to
110 an OpenFlow controller or switching them as a standalone switch.
111 This behavior is ordinarily desirable. However, if
112 <code>ovs-vswitchd</code> is restarting as part of a ``hot-upgrade,''
113 then this leads to a relatively long period during which packets are
114 mishandled.
115 </p>
116 <p>
117 This option allows for improvement. When <code>ovs-vswitchd</code>
118 starts with this value set as <code>true</code>, it will neither
119 flush or expire previously set datapath flows nor will it send and
120 receive any packets to or from the datapath. When this value is
121 later set to <code>false</code>, <code>ovs-vswitchd</code> will
122 start receiving packets from the datapath and re-setup the flows.
123 </p>
124 <p>
125 Thus, with this option, the procedure for a hot-upgrade of
126 <code>ovs-vswitchd</code> becomes roughly the following:
127 </p>
128 <ol>
129 <li>
130 Stop <code>ovs-vswitchd</code>.
131 </li>
132 <li>
133 Set <ref column="other_config" key="flow-restore-wait"/>
134 to <code>true</code>.
135 </li>
136 <li>
137 Start <code>ovs-vswitchd</code>.
138 </li>
139 <li>
140 Use <code>ovs-ofctl</code> (or some other program, such as an
141 OpenFlow controller) to restore the OpenFlow flow table
142 to the desired state.
143 </li>
144 <li>
145 Set <ref column="other_config" key="flow-restore-wait"/>
146 to <code>false</code> (or remove it entirely from the database).
147 </li>
148 </ol>
149 <p>
150 The <code>ovs-ctl</code>'s ``restart'' and ``force-reload-kmod''
151 functions use the above config option during hot upgrades.
152 </p>
153 </column>
154
155 <column name="other_config" key="flow-limit"
156 type='{"type": "integer", "minInteger": 0}'>
157 <p>
158 The maximum
159 number of flows allowed in the datapath flow table. Internally OVS
160 will choose a flow limit which will likely be lower than this number,
161 based on real time network conditions. Tweaking this value is
162 discouraged unless you know exactly what you're doing.
163 </p>
164 <p>
165 The default is 200000.
166 </p>
167 </column>
168
169 <column name="other_config" key="max-idle"
170 type='{"type": "integer", "minInteger": 500}'>
171 <p>
172 The maximum time (in ms) that idle flows will remain cached in the
173 datapath. Internally OVS will check the validity and activity for
174 datapath flows regularly and may expire flows quicker than this
175 number, based on real time network conditions. Tweaking this
176 value is discouraged unless you know exactly what you're doing.
177 </p>
178 <p>
179 The default is 10000.
180 </p>
181 </column>
182
183 <column name="other_config" key="hw-offload"
184 type='{"type": "boolean"}'>
185 <p>
186 Set this value to <code>true</code> to enable netdev flow offload.
187 </p>
188 <p>
189 The default value is <code>false</code>. Changing this value requires
190 restarting the daemon
191 </p>
192 <p>
193 Currently Open vSwitch supports hardware offloading on
194 Linux systems. On other systems, this value is ignored.
195 This functionality is considered 'experimental'. Depending
196 on which OpenFlow matches and actions are configured,
197 which kernel version is used, and what hardware is
198 available, Open vSwitch may not be able to offload
199 functionality to hardware.
200 </p>
201 </column>
202
203 <column name="other_config" key="tc-policy"
204 type='{"type": "string"}'>
205 <p>
206 Specified the policy used with HW offloading.
207 Options:
208 <code>none</code> - Add software rule and offload rule to HW.
209 <code>skip_sw</code> - Offload rule to HW only.
210 <code>skip_hw</code> - Add software rule without offloading rule to HW.
211 </p>
212 <p>
213 This is only relevant if HW offloading is enabled (hw-offload).
214 </p>
215 <p>
216 The default value is <code>none</code>.
217 </p>
218 </column>
219
220 <column name="other_config" key="dpdk-init"
221 type='{"type": "boolean"}'>
222 <p>
223 Set this value to <code>true</code> to enable runtime support for
224 DPDK ports. The vswitch must have compile-time support for DPDK as
225 well.
226 </p>
227 <p>
228 The default value is <code>false</code>. Changing this value requires
229 restarting the daemon
230 </p>
231 <p>
232 If this value is <code>false</code> at startup, any dpdk ports which
233 are configured in the bridge will fail due to memory errors.
234 </p>
235 </column>
236
237 <column name="other_config" key="dpdk-lcore-mask"
238 type='{"type": "integer", "minInteger": 1}'>
239 <p>
240 Specifies the CPU cores where dpdk lcore threads should be spawned.
241 The DPDK lcore threads are used for DPDK library tasks, such as
242 library internal message processing, logging, etc. Value should be in
243 the form of a hex string (so '0x123') similar to the 'taskset' mask
244 input.
245 </p>
246 <p>
247 The lowest order bit corresponds to the first CPU core. A set bit
248 means the corresponding core is available and an lcore thread will be
249 created and pinned to it. If the input does not cover all cores,
250 those uncovered cores are considered not set.
251 </p>
252 <p>
253 For performance reasons, it is best to set this to a single core on
254 the system, rather than allow lcore threads to float.
255 </p>
256 <p>
257 If not specified, the value will be determined by choosing the lowest
258 CPU core from initial cpu affinity list. Otherwise, the value will be
259 passed directly to the DPDK library.
260 </p>
261 </column>
262
263 <column name="other_config" key="pmd-cpu-mask">
264 <p>
265 Specifies CPU mask for setting the cpu affinity of PMD (Poll
266 Mode Driver) threads. Value should be in the form of hex string,
267 similar to the dpdk EAL '-c COREMASK' option input or the 'taskset'
268 mask input.
269 </p>
270 <p>
271 The lowest order bit corresponds to the first CPU core. A set bit
272 means the corresponding core is available and a pmd thread will be
273 created and pinned to it. If the input does not cover all cores,
274 those uncovered cores are considered not set.
275 </p>
276 <p>
277 If not specified, one pmd thread will be created for each numa node
278 and pinned to any available core on the numa node by default.
279 </p>
280 </column>
281
282 <column name="other_config" key="dpdk-alloc-mem"
283 type='{"type": "integer", "minInteger": 0}'>
284 <p>
285 Specifies the amount of memory to preallocate from the hugepage pool,
286 regardless of socket. It is recommended that dpdk-socket-mem is used
287 instead.
288 </p>
289 </column>
290
291 <column name="other_config" key="dpdk-socket-mem"
292 type='{"type": "string"}'>
293 <p>
294 Specifies the amount of memory to preallocate from the hugepage pool,
295 on a per-socket basis.
296 </p>
297 <p>
298 The specifier is a comma-separated string, in ascending order of CPU
299 socket. E.g. On a four socket system 1024,0,2048 would set socket 0
300 to preallocate 1024MB, socket 1 to preallocate 0MB, socket 2 to
301 preallocate 2048MB and socket 3 (no value given) to preallocate 0MB.
302 </p>
303 <p>
304 If dpdk-socket-mem and dpdk-alloc-mem are not specified, dpdk-socket-mem
305 will be used and the default value is 1024,0. If dpdk-socket-mem and
306 dpdk-alloc-mem are specified at same time, dpdk-socket-mem will be
307 used as default. Changing this value requires restarting the daemon.
308 </p>
309 </column>
310
311 <column name="other_config" key="dpdk-hugepage-dir"
312 type='{"type": "string"}'>
313 <p>
314 Specifies the path to the hugetlbfs mount point.
315 </p>
316 <p>
317 If not specified, this will be guessed by the DPDK library (default
318 is /dev/hugepages). Changing this value requires restarting the
319 daemon.
320 </p>
321 </column>
322
323 <column name="other_config" key="dpdk-extra"
324 type='{"type": "string"}'>
325 <p>
326 Specifies additional eal command line arguments for DPDK.
327 </p>
328 <p>
329 The default is empty. Changing this value requires restarting the
330 daemon
331 </p>
332 </column>
333
334 <column name="other_config" key="vhost-sock-dir"
335 type='{"type": "string"}'>
336 <p>
337 Specifies a relative path from <ref column="external_ids"
338 key="rundir"/> to the vhost-user unix domain socket files. If this
339 value is unset, the sockets are put directly in <ref
340 column="external_ids" key="rundir"/>.
341 </p>
342 <p>
343 Changing this value requires restarting the daemon.
344 </p>
345 </column>
346
347 <column name="other_config" key="vhost-iommu-support"
348 type='{"type": "boolean"}'>
349 <p>
350 vHost IOMMU is a security feature, which restricts the vhost memory
351 that a virtio device may access. vHost IOMMU support is disabled by
352 default, due to a bug in QEMU implementations of the vhost REPLY_ACK
353 protocol, (on which vHost IOMMU relies) prior to v2.9.1. Setting this
354 value to <code>true</code> enables vHost IOMMU support for vHost User
355 Client ports in OvS-DPDK, starting from DPDK v17.11.
356 </p>
357 <p>
358 Changing this value requires restarting the daemon.
359 </p>
360 </column>
361
362 <column name="other_config" key="tx-flush-interval"
363 type='{"type": "integer",
364 "minInteger": 0, "maxInteger": 1000000}'>
365 <p>
366 Specifies the time in microseconds that a packet can wait in output
367 batch for sending i.e. amount of time that packet can spend in an
368 intermediate output queue before sending to netdev.
369 This option can be used to configure balance between throughput
370 and latency. Lower values decreases latency while higher values
371 may be useful to achieve higher performance.
372 </p>
373 <p>
374 Defaults to 0 i.e. instant packet sending (latency optimized).
375 </p>
376 </column>
377
378 <column name="other_config" key="n-handler-threads"
379 type='{"type": "integer", "minInteger": 1}'>
380 <p>
381 Specifies the number of threads for software datapaths to use for
382 handling new flows. The default the number of online CPU cores minus
383 the number of revalidators.
384 </p>
385 <p>
386 This configuration is per datapath. If you have more than one
387 software datapath (e.g. some <code>system</code> bridges and some
388 <code>netdev</code> bridges), then the total number of threads is
389 <code>n-handler-threads</code> times the number of software
390 datapaths.
391 </p>
392 </column>
393
394 <column name="other_config" key="n-revalidator-threads"
395 type='{"type": "integer", "minInteger": 1}'>
396 <p>
397 Specifies the number of threads for software datapaths to use for
398 revalidating flows in the datapath. Typically, there is a direct
399 correlation between the number of revalidator threads, and the number
400 of flows allowed in the datapath. The default is the number of cpu
401 cores divided by four plus one. If <code>n-handler-threads</code> is
402 set, the default changes to the number of cpu cores minus the number
403 of handler threads.
404 </p>
405 <p>
406 This configuration is per datapath. If you have more than one
407 software datapath (e.g. some <code>system</code> bridges and some
408 <code>netdev</code> bridges), then the total number of threads is
409 <code>n-handler-threads</code> times the number of software
410 datapaths.
411 </p>
412 </column>
413
414 <column name="other_config" key="emc-insert-inv-prob"
415 type='{"type": "integer", "minInteger": 0, "maxInteger": 4294967295}'>
416 <p>
417 Specifies the inverse probability (1/emc-insert-inv-prob) of a flow
418 being inserted into the Exact Match Cache (EMC). On average one in
419 every <code>emc-insert-inv-prob</code> packets that generate a unique
420 flow will cause an insertion into the EMC.
421
422 A value of 1 will result in an insertion for every flow (1/1 = 100%)
423 whereas a value of zero will result in no insertions and essentially
424 disable the EMC.
425 </p>
426 <p>
427 Defaults to 100 ie. there is (1/100 =) 1% chance of EMC insertion.
428 </p>
429 </column>
430
431 <column name="other_config" key="vlan-limit"
432 type='{"type": "integer", "minInteger": 0}'>
433 <p>
434 Limits the number of VLAN headers that can be matched to the
435 specified number. Further VLAN headers will be treated as payload,
436 e.g. a packet with more 802.1q headers will match Ethernet type
437 0x8100.
438 </p>
439 <p>
440 Value <code>0</code> means unlimited. The actual number of supported
441 VLAN headers is the smallest of <code>vlan-limit</code>, the number
442 of VLANs supported by Open vSwitch userspace (currently 2), and the
443 number supported by the datapath.
444 </p>
445
446 <p>
447 If this value is absent, the default is currently 1. This maintains
448 backward compatibility with controllers that were designed for use
449 with Open vSwitch versions earlier than 2.8, which only supported one
450 VLAN.
451 </p>
452 </column>
453 </group>
454
455 <group title="Status">
456 <column name="next_cfg">
457 Sequence number for client to increment. When a client modifies
458 any part of the database configuration and wishes to wait for
459 Open vSwitch to finish applying the changes, it may increment
460 this sequence number.
461 </column>
462
463 <column name="cur_cfg">
464 Sequence number that Open vSwitch sets to the current value of
465 <ref column="next_cfg"/> after it finishes applying a set of
466 configuration changes.
467 </column>
468
469 <group title="Statistics">
470 <p>
471 The <code>statistics</code> column contains key-value pairs that
472 report statistics about a system running an Open vSwitch. These are
473 updated periodically (currently, every 5 seconds). Key-value pairs
474 that cannot be determined or that do not apply to a platform are
475 omitted.
476 </p>
477
478 <column name="other_config" key="enable-statistics"
479 type='{"type": "boolean"}'>
480 Statistics are disabled by default to avoid overhead in the common
481 case when statistics gathering is not useful. Set this value to
482 <code>true</code> to enable populating the <ref column="statistics"/>
483 column or to <code>false</code> to explicitly disable it.
484 </column>
485
486 <column name="statistics" key="cpu"
487 type='{"type": "integer", "minInteger": 1}'>
488 <p>
489 Number of CPU processors, threads, or cores currently online and
490 available to the operating system on which Open vSwitch is running,
491 as an integer. This may be less than the number installed, if some
492 are not online or if they are not available to the operating
493 system.
494 </p>
495 <p>
496 Open vSwitch userspace processes are not multithreaded, but the
497 Linux kernel-based datapath is.
498 </p>
499 </column>
500
501 <column name="statistics" key="load_average">
502 A comma-separated list of three floating-point numbers,
503 representing the system load average over the last 1, 5, and 15
504 minutes, respectively.
505 </column>
506
507 <column name="statistics" key="memory">
508 <p>
509 A comma-separated list of integers, each of which represents a
510 quantity of memory in kilobytes that describes the operating
511 system on which Open vSwitch is running. In respective order,
512 these values are:
513 </p>
514
515 <ol>
516 <li>Total amount of RAM allocated to the OS.</li>
517 <li>RAM allocated to the OS that is in use.</li>
518 <li>RAM that can be flushed out to disk or otherwise discarded
519 if that space is needed for another purpose. This number is
520 necessarily less than or equal to the previous value.</li>
521 <li>Total disk space allocated for swap.</li>
522 <li>Swap space currently in use.</li>
523 </ol>
524
525 <p>
526 On Linux, all five values can be determined and are included. On
527 other operating systems, only the first two values can be
528 determined, so the list will only have two values.
529 </p>
530 </column>
531
532 <column name="statistics" key="process_NAME">
533 <p>
534 One such key-value pair, with <code>NAME</code> replaced by
535 a process name, will exist for each running Open vSwitch
536 daemon process, with <var>name</var> replaced by the
537 daemon's name (e.g. <code>process_ovs-vswitchd</code>). The
538 value is a comma-separated list of integers. The integers
539 represent the following, with memory measured in kilobytes
540 and durations in milliseconds:
541 </p>
542
543 <ol>
544 <li>The process's virtual memory size.</li>
545 <li>The process's resident set size.</li>
546 <li>The amount of user and system CPU time consumed by the
547 process.</li>
548 <li>The number of times that the process has crashed and been
549 automatically restarted by the monitor.</li>
550 <li>The duration since the process was started.</li>
551 <li>The duration for which the process has been running.</li>
552 </ol>
553
554 <p>
555 The interpretation of some of these values depends on whether the
556 process was started with the <option>--monitor</option>. If it
557 was not, then the crash count will always be 0 and the two
558 durations will always be the same. If <option>--monitor</option>
559 was given, then the crash count may be positive; if it is, the
560 latter duration is the amount of time since the most recent crash
561 and restart.
562 </p>
563
564 <p>
565 There will be one key-value pair for each file in Open vSwitch's
566 ``run directory'' (usually <code>/var/run/openvswitch</code>)
567 whose name ends in <code>.pid</code>, whose contents are a
568 process ID, and which is locked by a running process. The
569 <var>name</var> is taken from the pidfile's name.
570 </p>
571
572 <p>
573 Currently Open vSwitch is only able to obtain all of the above
574 detail on Linux systems. On other systems, the same key-value
575 pairs will be present but the values will always be the empty
576 string.
577 </p>
578 </column>
579
580 <column name="statistics" key="file_systems">
581 <p>
582 A space-separated list of information on local, writable file
583 systems. Each item in the list describes one file system and
584 consists in turn of a comma-separated list of the following:
585 </p>
586
587 <ol>
588 <li>Mount point, e.g. <code>/</code> or <code>/var/log</code>.
589 Any spaces or commas in the mount point are replaced by
590 underscores.</li>
591 <li>Total size, in kilobytes, as an integer.</li>
592 <li>Amount of storage in use, in kilobytes, as an integer.</li>
593 </ol>
594
595 <p>
596 This key-value pair is omitted if there are no local, writable
597 file systems or if Open vSwitch cannot obtain the needed
598 information.
599 </p>
600 </column>
601 </group>
602 </group>
603
604 <group title="Version Reporting">
605 <p>
606 These columns report the types and versions of the hardware and
607 software running Open vSwitch. We recommend in general that software
608 should test whether specific features are supported instead of relying
609 on version number checks. These values are primarily intended for
610 reporting to human administrators.
611 </p>
612
613 <column name="ovs_version">
614 The Open vSwitch version number, e.g. <code>1.1.0</code>.
615 </column>
616
617 <column name="db_version">
618 <p>
619 The database schema version number, e.g. <code>1.2.3</code>. See
620 ovsdb-tool(1) for an explanation of the numbering scheme.
621 </p>
622
623 <p>
624 The schema version is part of the database schema, so it can also be
625 retrieved by fetching the schema using the Open vSwitch database
626 protocol.
627 </p>
628 </column>
629
630 <column name="system_type">
631 <p>
632 An identifier for the type of system on top of which Open vSwitch
633 runs, e.g. <code>XenServer</code> or <code>KVM</code>.
634 </p>
635 <p>
636 System integrators are responsible for choosing and setting an
637 appropriate value for this column.
638 </p>
639 </column>
640
641 <column name="system_version">
642 <p>
643 The version of the system identified by <ref column="system_type"/>,
644 e.g. <code>5.6.100-39265p</code> on XenServer 5.6.100 build 39265.
645 </p>
646 <p>
647 System integrators are responsible for choosing and setting an
648 appropriate value for this column.
649 </p>
650 </column>
651
652 </group>
653
654 <group title="Capabilities">
655 <p>
656 These columns report capabilities of the Open vSwitch instance.
657 </p>
658 <column name="datapath_types">
659 <p>
660 This column reports the different dpifs registered with the system.
661 These are the values that this instance supports in the <ref
662 column="datapath_type" table="Bridge"/> column of the <ref
663 table="Bridge"/> table.
664 </p>
665 </column>
666 <column name="iface_types">
667 <p>
668 This column reports the different netdevs registered with the system.
669 These are the values that this instance supports in the <ref
670 column="type" table="Interface"/> column of the <ref
671 table="Interface"/> table.
672 </p>
673 </column>
674 </group>
675
676 <group title="Database Configuration">
677 <p>
678 These columns primarily configure the Open vSwitch database
679 (<code>ovsdb-server</code>), not the Open vSwitch switch
680 (<code>ovs-vswitchd</code>). The OVSDB database also uses the <ref
681 column="ssl"/> settings.
682 </p>
683
684 <p>
685 The Open vSwitch switch does read the database configuration to
686 determine remote IP addresses to which in-band control should apply.
687 </p>
688
689 <column name="manager_options">
690 Database clients to which the Open vSwitch database server should
691 connect or to which it should listen, along with options for how these
692 connection should be configured. See the <ref table="Manager"/> table
693 for more information.
694 </column>
695 </group>
696
697 <group title="Common Columns">
698 The overall purpose of these columns is described under <code>Common
699 Columns</code> at the beginning of this document.
700
701 <column name="other_config"/>
702 <column name="external_ids"/>
703 </group>
704 </table>
705
706 <table name="Bridge">
707 <p>
708 Configuration for a bridge within an
709 <ref table="Open_vSwitch"/>.
710 </p>
711 <p>
712 A <ref table="Bridge"/> record represents an Ethernet switch with one or
713 more ``ports,'' which are the <ref table="Port"/> records pointed to by
714 the <ref table="Bridge"/>'s <ref column="ports"/> column.
715 </p>
716
717 <group title="Core Features">
718 <column name="name">
719 <p>
720 Bridge identifier. Must be unique among the names of ports,
721 interfaces, and bridges on a host.
722 </p>
723
724 <p>
725 The name must be alphanumeric and must not contain forward or
726 backward slashes. The name of a bridge is also the name of an <ref
727 table="Interface"/> (and a <ref table="Port"/>) within the bridge, so
728 the restrictions on the <ref table="Interface" column="name"/> column
729 in the <ref table="Interface"/> table, particularly on length, also
730 apply to bridge names. Refer to the documentation for <ref
731 table="Interface"/> names for details.
732 </p>
733 </column>
734
735 <column name="ports">
736 Ports included in the bridge.
737 </column>
738
739 <column name="mirrors">
740 Port mirroring configuration.
741 </column>
742
743 <column name="netflow">
744 NetFlow configuration.
745 </column>
746
747 <column name="sflow">
748 sFlow(R) configuration.
749 </column>
750
751 <column name="ipfix">
752 IPFIX configuration.
753 </column>
754
755 <column name="flood_vlans">
756 <p>
757 VLAN IDs of VLANs on which MAC address learning should be disabled,
758 so that packets are flooded instead of being sent to specific ports
759 that are believed to contain packets' destination MACs. This should
760 ordinarily be used to disable MAC learning on VLANs used for
761 mirroring (RSPAN VLANs). It may also be useful for debugging.
762 </p>
763 <p>
764 SLB bonding (see the <ref table="Port" column="bond_mode"/> column in
765 the <ref table="Port"/> table) is incompatible with
766 <code>flood_vlans</code>. Consider using another bonding mode or
767 a different type of mirror instead.
768 </p>
769 </column>
770
771 <column name="auto_attach">
772 Auto Attach configuration.
773 </column>
774 </group>
775
776 <group title="OpenFlow Configuration">
777 <column name="controller">
778 <p>
779 OpenFlow controller set. If unset, then no OpenFlow controllers
780 will be used.
781 </p>
782
783 <p>
784 If there are primary controllers, removing all of them clears the
785 OpenFlow flow tables, group table, and meter table. If there are no
786 primary controllers, adding one also clears these tables. Other
787 changes to the set of controllers, such as adding or removing a
788 service controller, adding another primary controller to supplement
789 an existing primary controller, or removing only one of two primary
790 controllers, have no effect on these tables.
791 </p>
792 </column>
793
794 <column name="flow_tables">
795 Configuration for OpenFlow tables. Each pair maps from an OpenFlow
796 table ID to configuration for that table.
797 </column>
798
799 <column name="fail_mode">
800 <p>When a controller is configured, it is, ordinarily, responsible
801 for setting up all flows on the switch. Thus, if the connection to
802 the controller fails, no new network connections can be set up.
803 If the connection to the controller stays down long enough,
804 no packets can pass through the switch at all. This setting
805 determines the switch's response to such a situation. It may be set
806 to one of the following:
807 <dl>
808 <dt><code>standalone</code></dt>
809 <dd>If no message is received from the controller for three
810 times the inactivity probe interval
811 (see <ref column="inactivity_probe"/>), then Open vSwitch
812 will take over responsibility for setting up flows. In
813 this mode, Open vSwitch causes the bridge to act like an
814 ordinary MAC-learning switch. Open vSwitch will continue
815 to retry connecting to the controller in the background
816 and, when the connection succeeds, it will discontinue its
817 standalone behavior.</dd>
818 <dt><code>secure</code></dt>
819 <dd>Open vSwitch will not set up flows on its own when the
820 controller connection fails or when no controllers are
821 defined. The bridge will continue to retry connecting to
822 any defined controllers forever.</dd>
823 </dl>
824 </p>
825 <p>
826 The default is <code>standalone</code> if the value is unset, but
827 future versions of Open vSwitch may change the default.
828 </p>
829 <p>
830 The <code>standalone</code> mode can create forwarding loops on a
831 bridge that has more than one uplink port unless STP is enabled. To
832 avoid loops on such a bridge, configure <code>secure</code> mode or
833 enable STP (see <ref column="stp_enable"/>).
834 </p>
835 <p>When more than one controller is configured,
836 <ref column="fail_mode"/> is considered only when none of the
837 configured controllers can be contacted.</p>
838 <p>
839 Changing <ref column="fail_mode"/> when no primary controllers are
840 configured clears the OpenFlow flow tables, group table, and meter
841 table.
842 </p>
843 </column>
844
845 <column name="datapath_id">
846 Reports the OpenFlow datapath ID in use. Exactly 16 hex digits.
847 (Setting this column has no useful effect. Set <ref
848 column="other-config" key="datapath-id"/> instead.)
849 </column>
850
851 <column name="datapath_version">
852 <p>
853 Reports the version number of the Open vSwitch datapath in use.
854 This allows management software to detect and report discrepancies
855 between Open vSwitch userspace and datapath versions. (The <ref
856 column="ovs_version" table="Open_vSwitch"/> column in the <ref
857 table="Open_vSwitch"/> reports the Open vSwitch userspace version.)
858 The version reported depends on the datapath in use:
859 </p>
860
861 <ul>
862 <li>
863 When the kernel module included in the Open vSwitch source tree is
864 used, this column reports the Open vSwitch version from which the
865 module was taken.
866 </li>
867
868 <li>
869 When the kernel module that is part of the upstream Linux kernel is
870 used, this column reports <code>&lt;unknown&gt;</code>.
871 </li>
872
873 <li>
874 When the datapath is built into the <code>ovs-vswitchd</code>
875 binary, this column reports <code>&lt;built-in&gt;</code>. A
876 built-in datapath is by definition the same version as the rest of
877 the Open VSwitch userspace.
878 </li>
879
880 <li>
881 Other datapaths (such as the Hyper-V kernel datapath) currently
882 report <code>&lt;unknown&gt;</code>.
883 </li>
884 </ul>
885
886 <p>
887 A version discrepancy between <code>ovs-vswitchd</code> and the
888 datapath in use is not normally cause for alarm. The Open vSwitch
889 kernel datapaths for Linux and Hyper-V, in particular, are designed
890 for maximum inter-version compatibility: any userspace version works
891 with with any kernel version. Some reasons do exist to insist on
892 particular user/kernel pairings. First, newer kernel versions add
893 new features, that can only be used by new-enough userspace, e.g.
894 VXLAN tunneling requires certain minimal userspace and kernel
895 versions. Second, as an extension to the first reason, some newer
896 kernel versions add new features for enhancing performance that only
897 new-enough userspace versions can take advantage of.
898 </p>
899 </column>
900
901 <column name="other_config" key="datapath-id">
902 Overrides the default OpenFlow datapath ID, setting it to the specified
903 value specified in hex. The value must either have a <code>0x</code>
904 prefix or be exactly 16 hex digits long. May not be all-zero.
905 </column>
906
907 <column name="other_config" key="dp-desc">
908 Human readable description of datapath. It is a maximum 256
909 byte-long free-form string to describe the datapath for
910 debugging purposes, e.g. <code>switch3 in room 3120</code>.
911 </column>
912
913 <column name="other_config" key="disable-in-band"
914 type='{"type": "boolean"}'>
915 If set to <code>true</code>, disable in-band control on the bridge
916 regardless of controller and manager settings.
917 </column>
918
919 <column name="other_config" key="in-band-queue"
920 type='{"type": "integer", "minInteger": 0, "maxInteger": 4294967295}'>
921 A queue ID as a nonnegative integer. This sets the OpenFlow queue ID
922 that will be used by flows set up by in-band control on this bridge.
923 If unset, or if the port used by an in-band control flow does not have
924 QoS configured, or if the port does not have a queue with the specified
925 ID, the default queue is used instead.
926 </column>
927
928 <column name="protocols">
929 <p>
930 List of OpenFlow protocols that may be used when negotiating
931 a connection with a controller. OpenFlow 1.0, 1.1, 1.2, 1.3, and
932 1.4 are enabled by default if this column is empty.
933 </p>
934
935 <p>
936 OpenFlow 1.5 and 1.6 are not enabled by default because their
937 implementations are missing features. In addition, the OpenFlow 1.6
938 specification is still under development and thus subject to change.
939 </p>
940 </column>
941 </group>
942
943 <group title="Spanning Tree Configuration">
944 <p>
945 The IEEE 802.1D Spanning Tree Protocol (STP) is a network protocol
946 that ensures loop-free topologies. It allows redundant links to
947 be included in the network to provide automatic backup paths if
948 the active links fails.
949 </p>
950
951 <p>
952 These settings configure the slower-to-converge but still widely
953 supported version of Spanning Tree Protocol, sometimes known as
954 802.1D-1998. Open vSwitch also supports the newer Rapid Spanning Tree
955 Protocol (RSTP), documented later in the section titled <code>Rapid
956 Spanning Tree Configuration</code>.
957 </p>
958
959 <group title="STP Configuration">
960 <column name="stp_enable" type='{"type": "boolean"}'>
961 <p>
962 Enable spanning tree on the bridge. By default, STP is disabled
963 on bridges. Bond, internal, and mirror ports are not supported
964 and will not participate in the spanning tree.
965 </p>
966
967 <p>
968 STP and RSTP are mutually exclusive. If both are enabled, RSTP
969 will be used.
970 </p>
971 </column>
972
973 <column name="other_config" key="stp-system-id">
974 The bridge's STP identifier (the lower 48 bits of the bridge-id)
975 in the form
976 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>.
977 By default, the identifier is the MAC address of the bridge.
978 </column>
979
980 <column name="other_config" key="stp-priority"
981 type='{"type": "integer", "minInteger": 0, "maxInteger": 65535}'>
982 The bridge's relative priority value for determining the root
983 bridge (the upper 16 bits of the bridge-id). A bridge with the
984 lowest bridge-id is elected the root. By default, the priority
985 is 0x8000.
986 </column>
987
988 <column name="other_config" key="stp-hello-time"
989 type='{"type": "integer", "minInteger": 1, "maxInteger": 10}'>
990 The interval between transmissions of hello messages by
991 designated ports, in seconds. By default the hello interval is
992 2 seconds.
993 </column>
994
995 <column name="other_config" key="stp-max-age"
996 type='{"type": "integer", "minInteger": 6, "maxInteger": 40}'>
997 The maximum age of the information transmitted by the bridge
998 when it is the root bridge, in seconds. By default, the maximum
999 age is 20 seconds.
1000 </column>
1001
1002 <column name="other_config" key="stp-forward-delay"
1003 type='{"type": "integer", "minInteger": 4, "maxInteger": 30}'>
1004 The delay to wait between transitioning root and designated
1005 ports to <code>forwarding</code>, in seconds. By default, the
1006 forwarding delay is 15 seconds.
1007 </column>
1008
1009 <column name="other_config" key="mcast-snooping-aging-time"
1010 type='{"type": "integer", "minInteger": 1}'>
1011 <p>
1012 The maximum number of seconds to retain a multicast snooping entry for
1013 which no packets have been seen. The default is currently 300
1014 seconds (5 minutes). The value, if specified, is forced into a
1015 reasonable range, currently 15 to 3600 seconds.
1016 </p>
1017 </column>
1018
1019 <column name="other_config" key="mcast-snooping-table-size"
1020 type='{"type": "integer", "minInteger": 1}'>
1021 <p>
1022 The maximum number of multicast snooping addresses to learn. The
1023 default is currently 2048. The value, if specified, is forced into
1024 a reasonable range, currently 10 to 1,000,000.
1025 </p>
1026 </column>
1027 <column name="other_config" key="mcast-snooping-disable-flood-unregistered"
1028 type='{"type": "boolean"}'>
1029 <p>
1030 If set to <code>false</code>, unregistered multicast packets are forwarded
1031 to all ports.
1032 If set to <code>true</code>, unregistered multicast packets are forwarded
1033 to ports connected to multicast routers.
1034 </p>
1035 </column>
1036 </group>
1037
1038 <group title="STP Status">
1039 <p>
1040 These key-value pairs report the status of 802.1D-1998. They are
1041 present only if STP is enabled (via the <ref column="stp_enable"/>
1042 column).
1043 </p>
1044 <column name="status" key="stp_bridge_id">
1045 The bridge ID used in spanning tree advertisements, in the form
1046 <var>xxxx</var>.<var>yyyyyyyyyyyy</var> where the <var>x</var>s are
1047 the STP priority, the <var>y</var>s are the STP system ID, and each
1048 <var>x</var> and <var>y</var> is a hex digit.
1049 </column>
1050 <column name="status" key="stp_designated_root">
1051 The designated root for this spanning tree, in the same form as <ref
1052 column="status" key="stp_bridge_id"/>. If this bridge is the root,
1053 this will have the same value as <ref column="status"
1054 key="stp_bridge_id"/>, otherwise it will differ.
1055 </column>
1056 <column name="status" key="stp_root_path_cost">
1057 The path cost of reaching the designated bridge. A lower number is
1058 better. The value is 0 if this bridge is the root, otherwise it is
1059 higher.
1060 </column>
1061 </group>
1062 </group>
1063
1064 <group title="Rapid Spanning Tree">
1065 <p>
1066 Rapid Spanning Tree Protocol (RSTP), like STP, is a network protocol
1067 that ensures loop-free topologies. RSTP superseded STP with the
1068 publication of 802.1D-2004. Compared to STP, RSTP converges more
1069 quickly and recovers more quickly from failures.
1070 </p>
1071
1072 <group title="RSTP Configuration">
1073 <column name="rstp_enable" type='{"type": "boolean"}'>
1074 <p>
1075 Enable Rapid Spanning Tree on the bridge. By default, RSTP is disabled
1076 on bridges. Bond, internal, and mirror ports are not supported
1077 and will not participate in the spanning tree.
1078 </p>
1079
1080 <p>
1081 STP and RSTP are mutually exclusive. If both are enabled, RSTP
1082 will be used.
1083 </p>
1084 </column>
1085
1086 <column name="other_config" key="rstp-address">
1087 The bridge's RSTP address (the lower 48 bits of the bridge-id)
1088 in the form
1089 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>.
1090 By default, the address is the MAC address of the bridge.
1091 </column>
1092
1093 <column name="other_config" key="rstp-priority"
1094 type='{"type": "integer", "minInteger": 0, "maxInteger": 61440}'>
1095 The bridge's relative priority value for determining the root
1096 bridge (the upper 16 bits of the bridge-id). A bridge with the
1097 lowest bridge-id is elected the root. By default, the priority
1098 is 0x8000 (32768). This value needs to be a multiple of 4096,
1099 otherwise it's rounded to the nearest inferior one.
1100 </column>
1101
1102 <column name="other_config" key="rstp-ageing-time"
1103 type='{"type": "integer", "minInteger": 10, "maxInteger": 1000000}'>
1104 The Ageing Time parameter for the Bridge. The default value
1105 is 300 seconds.
1106 </column>
1107
1108 <column name="other_config" key="rstp-force-protocol-version"
1109 type='{"type": "integer"}'>
1110 The Force Protocol Version parameter for the Bridge. This
1111 can take the value 0 (STP Compatibility mode) or 2
1112 (the default, normal operation).
1113 </column>
1114
1115 <column name="other_config" key="rstp-max-age"
1116 type='{"type": "integer", "minInteger": 6, "maxInteger": 40}'>
1117 The maximum age of the information transmitted by the Bridge
1118 when it is the Root Bridge. The default value is 20.
1119 </column>
1120
1121 <column name="other_config" key="rstp-forward-delay"
1122 type='{"type": "integer", "minInteger": 4, "maxInteger": 30}'>
1123 The delay used by STP Bridges to transition Root and Designated
1124 Ports to Forwarding. The default value is 15.
1125 </column>
1126
1127 <column name="other_config" key="rstp-transmit-hold-count"
1128 type='{"type": "integer", "minInteger": 1, "maxInteger": 10}'>
1129 The Transmit Hold Count used by the Port Transmit state machine
1130 to limit transmission rate. The default value is 6.
1131 </column>
1132 </group>
1133
1134 <group title="RSTP Status">
1135 <p>
1136 These key-value pairs report the status of 802.1D-2004. They are
1137 present only if RSTP is enabled (via the <ref column="rstp_enable"/>
1138 column).
1139 </p>
1140 <column name="rstp_status" key="rstp_bridge_id">
1141 The bridge ID used in rapid spanning tree advertisements, in the form
1142 <var>x</var>.<var>yyy</var>.<var>zzzzzzzzzzzz</var> where
1143 <var>x</var> is the RSTP priority, the <var>y</var>s are a locally
1144 assigned system ID extension, the <var>z</var>s are the STP system
1145 ID, and each <var>x</var>, <var>y</var>, or <var>z</var> is a hex
1146 digit.
1147 </column>
1148 <column name="rstp_status" key="rstp_root_id">
1149 The root of this spanning tree, in the same form as <ref
1150 column="rstp_status" key="rstp_bridge_id"/>. If this bridge is the
1151 root, this will have the same value as <ref column="rstp_status"
1152 key="rstp_bridge_id"/>, otherwise it will differ.
1153 </column>
1154 <column name="rstp_status" key="rstp_root_path_cost"
1155 type='{"type": "integer", "minInteger": 0}'>
1156 The path cost of reaching the root. A lower number is better. The
1157 value is 0 if this bridge is the root, otherwise it is higher.
1158 </column>
1159 <column name="rstp_status" key="rstp_designated_id">
1160 The RSTP designated ID, in the same form as <ref column="rstp_status"
1161 key="rstp_bridge_id"/>.
1162 </column>
1163 <column name="rstp_status" key="rstp_designated_port_id">
1164 The RSTP designated port ID, as a 4-digit hex number.
1165 </column>
1166 <column name="rstp_status" key="rstp_bridge_port_id">
1167 The RSTP bridge port ID, as a 4-digit hex number.
1168 </column>
1169 </group>
1170 </group>
1171
1172 <group title="Multicast Snooping Configuration">
1173 Multicast snooping (RFC 4541) monitors the Internet Group Management
1174 Protocol (IGMP) and Multicast Listener Discovery traffic between hosts
1175 and multicast routers. The switch uses what IGMP and MLD snooping
1176 learns to forward multicast traffic only to interfaces that are connected
1177 to interested receivers. Currently it supports IGMPv1, IGMPv2, IGMPv3,
1178 MLDv1 and MLDv2 protocols.
1179
1180 <column name="mcast_snooping_enable">
1181 Enable multicast snooping on the bridge. For now, the default
1182 is disabled.
1183 </column>
1184 </group>
1185
1186 <group title="Other Features">
1187 <column name="datapath_type">
1188 Name of datapath provider. The kernel datapath has type
1189 <code>system</code>. The userspace datapath has type
1190 <code>netdev</code>. A manager may refer to the <ref
1191 table="Open_vSwitch" column="datapath_types"/> column of the <ref
1192 table="Open_vSwitch"/> table for a list of the types accepted by this
1193 Open vSwitch instance.
1194 </column>
1195
1196 <column name="external_ids" key="bridge-id">
1197 A unique identifier of the bridge. On Citrix XenServer this will
1198 commonly be the same as
1199 <ref column="external_ids" key="xs-network-uuids"/>.
1200 </column>
1201
1202 <column name="external_ids" key="xs-network-uuids">
1203 Semicolon-delimited set of universally unique identifier(s) for the
1204 network with which this bridge is associated on a Citrix XenServer
1205 host. The network identifiers are RFC 4122 UUIDs as displayed by,
1206 e.g., <code>xe network-list</code>.
1207 </column>
1208
1209 <column name="other_config" key="hwaddr">
1210 An Ethernet address in the form
1211 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>
1212 to set the hardware address of the local port and influence the
1213 datapath ID.
1214 </column>
1215
1216 <column name="other_config" key="forward-bpdu"
1217 type='{"type": "boolean"}'>
1218
1219 <p>
1220 Controls forwarding of BPDUs and other network control frames when
1221 NORMAL action is invoked. When this option is <code>false</code> or
1222 unset, frames with reserved Ethernet addresses (see table below) will
1223 not be forwarded. When this option is <code>true</code>, such frames
1224 will not be treated specially.
1225 </p>
1226
1227 <p>
1228 The above general rule has the following exceptions:
1229 </p>
1230
1231 <ul>
1232 <li>
1233 If STP is enabled on the bridge (see the <ref column="stp_enable"
1234 table="Bridge"/> column in the <ref table="Bridge"/> table), the
1235 bridge processes all received STP packets and never passes them to
1236 OpenFlow or forwards them. This is true even if STP is disabled on
1237 an individual port.
1238 </li>
1239
1240 <li>
1241 If LLDP is enabled on an interface (see the <ref column="lldp"
1242 table="Interface"/> column in the <ref table="Interface"/> table),
1243 the interface processes received LLDP packets and never passes them
1244 to OpenFlow or forwards them.
1245 </li>
1246 </ul>
1247
1248 <p>
1249 Set this option to <code>true</code> if the Open vSwitch bridge
1250 connects different Ethernet networks and is not configured to
1251 participate in STP.
1252 </p>
1253
1254 <p>
1255 This option affects packets with the following destination MAC
1256 addresses:
1257 </p>
1258
1259 <dl>
1260 <dt><code>01:80:c2:00:00:00</code></dt>
1261 <dd>IEEE 802.1D Spanning Tree Protocol (STP).</dd>
1262
1263 <dt><code>01:80:c2:00:00:01</code></dt>
1264 <dd>IEEE Pause frame.</dd>
1265
1266 <dt><code>01:80:c2:00:00:0<var>x</var></code></dt>
1267 <dd>Other reserved protocols.</dd>
1268
1269 <dt><code>00:e0:2b:00:00:00</code></dt>
1270 <dd>Extreme Discovery Protocol (EDP).</dd>
1271
1272 <dt>
1273 <code>00:e0:2b:00:00:04</code> and <code>00:e0:2b:00:00:06</code>
1274 </dt>
1275 <dd>Ethernet Automatic Protection Switching (EAPS).</dd>
1276
1277 <dt><code>01:00:0c:cc:cc:cc</code></dt>
1278 <dd>
1279 Cisco Discovery Protocol (CDP), VLAN Trunking Protocol (VTP),
1280 Dynamic Trunking Protocol (DTP), Port Aggregation Protocol (PAgP),
1281 and others.
1282 </dd>
1283
1284 <dt><code>01:00:0c:cc:cc:cd</code></dt>
1285 <dd>Cisco Shared Spanning Tree Protocol PVSTP+.</dd>
1286
1287 <dt><code>01:00:0c:cd:cd:cd</code></dt>
1288 <dd>Cisco STP Uplink Fast.</dd>
1289
1290 <dt><code>01:00:0c:00:00:00</code></dt>
1291 <dd>Cisco Inter Switch Link.</dd>
1292
1293 <dt><code>01:00:0c:cc:cc:c<var>x</var></code></dt>
1294 <dd>Cisco CFM.</dd>
1295 </dl>
1296 </column>
1297
1298 <column name="other_config" key="mac-aging-time"
1299 type='{"type": "integer", "minInteger": 1}'>
1300 <p>
1301 The maximum number of seconds to retain a MAC learning entry for
1302 which no packets have been seen. The default is currently 300
1303 seconds (5 minutes). The value, if specified, is forced into a
1304 reasonable range, currently 15 to 3600 seconds.
1305 </p>
1306
1307 <p>
1308 A short MAC aging time allows a network to more quickly detect that a
1309 host is no longer connected to a switch port. However, it also makes
1310 it more likely that packets will be flooded unnecessarily, when they
1311 are addressed to a connected host that rarely transmits packets. To
1312 reduce the incidence of unnecessary flooding, use a MAC aging time
1313 longer than the maximum interval at which a host will ordinarily
1314 transmit packets.
1315 </p>
1316 </column>
1317
1318 <column name="other_config" key="mac-table-size"
1319 type='{"type": "integer", "minInteger": 1}'>
1320 <p>
1321 The maximum number of MAC addresses to learn. The default is
1322 currently 2048. The value, if specified, is forced into a reasonable
1323 range, currently 10 to 1,000,000.
1324 </p>
1325 </column>
1326 </group>
1327
1328 <group title="Common Columns">
1329 The overall purpose of these columns is described under <code>Common
1330 Columns</code> at the beginning of this document.
1331
1332 <column name="other_config"/>
1333 <column name="external_ids"/>
1334 </group>
1335 </table>
1336
1337 <table name="Port" table="Port or bond configuration.">
1338 <p>A port within a <ref table="Bridge"/>.</p>
1339 <p>Most commonly, a port has exactly one ``interface,'' pointed to by its
1340 <ref column="interfaces"/> column. Such a port logically
1341 corresponds to a port on a physical Ethernet switch. A port
1342 with more than one interface is a ``bonded port'' (see
1343 <ref group="Bonding Configuration"/>).</p>
1344 <p>Some properties that one might think as belonging to a port are actually
1345 part of the port's <ref table="Interface"/> members.</p>
1346
1347 <column name="name">
1348 Port name. For a non-bonded port, this should be the same as its
1349 interface's name. Port names must otherwise be unique among the names of
1350 ports, interfaces, and bridges on a host. Because port and interfaces
1351 names are usually the same, the restrictions on the <ref
1352 table="Interface" column="name"/> column in the <ref table="Interface"/>
1353 table, particularly on length, also apply to port names. Refer to the
1354 documentation for <ref table="Interface"/> names for details.
1355 </column>
1356
1357 <column name="interfaces">
1358 The port's interfaces. If there is more than one, this is a
1359 bonded Port.
1360 </column>
1361
1362 <group title="VLAN Configuration">
1363 <p>
1364 In short, a VLAN (short for ``virtual LAN'') is a way to partition a
1365 single switch into multiple switches. VLANs can be confusing, so for
1366 an introduction, please refer to the question ``What's a VLAN?'' in the
1367 Open vSwitch FAQ.
1368 </p>
1369
1370 <p>
1371 A VLAN is sometimes encoded into a packet using a 802.1Q or 802.1ad
1372 VLAN header, but every packet is part of some VLAN whether or not it is
1373 encoded in the packet. (A packet that appears to have no VLAN is part
1374 of VLAN 0, by default.) As a result, it's useful to think of a VLAN as
1375 a metadata property of a packet, separate from how the VLAN is encoded.
1376 For a given port, this column determines how the encoding of a packet
1377 that ingresses or egresses the port maps to the packet's VLAN. When a
1378 packet enters the switch, its VLAN is determined based on its setting
1379 in this column and its VLAN headers, if any, and then, conceptually,
1380 the VLAN headers are then stripped off. Conversely, when a packet
1381 exits the switch, its VLAN and the settings in this column determine
1382 what VLAN headers, if any, are pushed onto the packet before it
1383 egresses the port.
1384 </p>
1385
1386 <p>
1387 The VLAN configuration in this column affects Open vSwitch only when it
1388 is doing ``normal switching.'' It does not affect flows set up by an
1389 OpenFlow controller, outside of the OpenFlow ``normal action.''
1390 </p>
1391
1392 <p>
1393 Bridge ports support the following types of VLAN configuration:
1394 </p>
1395
1396 <dl>
1397 <dt>trunk</dt>
1398 <dd>
1399 <p>
1400 A trunk port carries packets on one or more specified VLANs
1401 specified in the <ref column="trunks"/> column (often, on every
1402 VLAN). A packet that ingresses on a trunk port is in the VLAN
1403 specified in its 802.1Q header, or VLAN 0 if the packet has no
1404 802.1Q header. A packet that egresses through a trunk port will
1405 have an 802.1Q header if it has a nonzero VLAN ID.
1406 </p>
1407
1408 <p>
1409 Any packet that ingresses on a trunk port tagged with a VLAN that
1410 the port does not trunk is dropped.
1411 </p>
1412 </dd>
1413
1414 <dt>access</dt>
1415 <dd>
1416 <p>
1417 An access port carries packets on exactly one VLAN specified in the
1418 <ref column="tag"/> column. Packets egressing on an access port
1419 have no 802.1Q header.
1420 </p>
1421
1422 <p>
1423 Any packet with an 802.1Q header with a nonzero VLAN ID that
1424 ingresses on an access port is dropped, regardless of whether the
1425 VLAN ID in the header is the access port's VLAN ID.
1426 </p>
1427 </dd>
1428
1429 <dt>native-tagged</dt>
1430 <dd>
1431 A native-tagged port resembles a trunk port, with the exception that
1432 a packet without an 802.1Q header that ingresses on a native-tagged
1433 port is in the ``native VLAN'' (specified in the <ref column="tag"/>
1434 column).
1435 </dd>
1436
1437 <dt>native-untagged</dt>
1438 <dd>
1439 A native-untagged port resembles a native-tagged port, with the
1440 exception that a packet that egresses on a native-untagged port in
1441 the native VLAN will not have an 802.1Q header.
1442 </dd>
1443
1444 <dt>dot1q-tunnel</dt>
1445 <dd>
1446 <p>
1447 A dot1q-tunnel port is somewhat like an access port. Like an
1448 access port, it carries packets on the single VLAN specified in the
1449 <ref column="tag"/> column and this VLAN, called the service VLAN,
1450 does not appear in an 802.1Q header for packets that ingress or
1451 egress on the port. The main difference lies in the behavior when
1452 packets that include a 802.1Q header ingress on the port. Whereas
1453 an access port drops such packets, a dot1q-tunnel port treats these
1454 as double-tagged with the outer service VLAN <ref column="tag"/>
1455 and the inner customer VLAN taken from the 802.1Q header.
1456 Correspondingly, to egress on the port, a packet outer VLAN (or
1457 only VLAN) must be <ref column="tag"/>, which is removed before
1458 egress, which exposes the inner (customer) VLAN if one is present.
1459 </p>
1460
1461 <p>
1462 If <ref column="cvlans"/> is set, only allows packets in the
1463 specified customer VLANs.
1464 </p>
1465 </dd>
1466 </dl>
1467 <p>
1468 A packet will only egress through bridge ports that carry the VLAN of
1469 the packet, as described by the rules above.
1470 </p>
1471
1472 <column name="vlan_mode">
1473 <p>
1474 The VLAN mode of the port, as described above. When this column is
1475 empty, a default mode is selected as follows:
1476 </p>
1477 <ul>
1478 <li>
1479 If <ref column="tag"/> contains a value, the port is an access
1480 port. The <ref column="trunks"/> column should be empty.
1481 </li>
1482 <li>
1483 Otherwise, the port is a trunk port. The <ref column="trunks"/>
1484 column value is honored if it is present.
1485 </li>
1486 </ul>
1487 </column>
1488
1489 <column name="tag">
1490 <p>
1491 For an access port, the port's implicitly tagged VLAN. For a
1492 native-tagged or native-untagged port, the port's native VLAN. Must
1493 be empty if this is a trunk port.
1494 </p>
1495 </column>
1496
1497 <column name="trunks">
1498 <p>
1499 For a trunk, native-tagged, or native-untagged port, the 802.1Q VLAN
1500 or VLANs that this port trunks; if it is empty, then the port trunks
1501 all VLANs. Must be empty if this is an access port.
1502 </p>
1503 <p>
1504 A native-tagged or native-untagged port always trunks its native
1505 VLAN, regardless of whether <ref column="trunks"/> includes that
1506 VLAN.
1507 </p>
1508 </column>
1509
1510 <column name="cvlans">
1511 <p>
1512 For a dot1q-tunnel port, the customer VLANs that this port includes.
1513 If this is empty, the port includes all customer VLANs.
1514 </p>
1515 <p>
1516 For other kinds of ports, this setting is ignored.
1517 </p>
1518 </column>
1519
1520 <column name="other_config" key="qinq-ethtype"
1521 type='{"type": "string", "enum": ["set", ["802.1ad", "802.1q"]]}'>
1522 <p>
1523 For a dot1q-tunnel port, this is the TPID for the service tag, that
1524 is, for the 802.1Q header that contains the service VLAN ID. Because
1525 packets that actually ingress and egress a dot1q-tunnel port do not
1526 include an 802.1Q header for the service VLAN, this does not affect
1527 packets on the dot1q-tunnel port itself. Rather, it determines the
1528 service VLAN for a packet that ingresses on a dot1q-tunnel port and
1529 egresses on a trunk port.
1530 </p>
1531 <p>
1532 The value <code>802.1ad</code> specifies TPID 0x88a8, which is also
1533 the default if the setting is omitted. The value <code>802.1q</code>
1534 specifies TPID 0x8100.
1535 </p>
1536 <p>
1537 For other kinds of ports, this setting is ignored.
1538 </p>
1539 </column>
1540
1541 <column name="other_config" key="priority-tags"
1542 type='{"type": "boolean"}'>
1543 <p>
1544 An 802.1Q header contains two important pieces of information: a VLAN
1545 ID and a priority. A frame with a zero VLAN ID, called a
1546 ``priority-tagged'' frame, is supposed to be treated the same way as
1547 a frame without an 802.1Q header at all (except for the priority).
1548 </p>
1549
1550 <p>
1551 However, some network elements ignore any frame that has 802.1Q
1552 header at all, even when the VLAN ID is zero. Therefore, by default
1553 Open vSwitch does not output priority-tagged frames, instead omitting
1554 the 802.1Q header entirely if the VLAN ID is zero. Set this key to
1555 <code>true</code> to enable priority-tagged frames on a port.
1556 </p>
1557
1558 <p>
1559 Regardless of this setting, Open vSwitch omits the 802.1Q header on
1560 output if both the VLAN ID and priority would be zero.
1561 </p>
1562
1563 <p>
1564 All frames output to native-tagged ports have a nonzero VLAN ID, so
1565 this setting is not meaningful on native-tagged ports.
1566 </p>
1567 </column>
1568 </group>
1569
1570 <group title="Bonding Configuration">
1571 <p>A port that has more than one interface is a ``bonded port.'' Bonding
1572 allows for load balancing and fail-over.</p>
1573
1574 <p>
1575 The following types of bonding will work with any kind of upstream
1576 switch. On the upstream switch, do not configure the interfaces as a
1577 bond:
1578 </p>
1579
1580 <dl>
1581 <dt><code>balance-slb</code></dt>
1582 <dd>
1583 Balances flows among slaves based on source MAC address and output
1584 VLAN, with periodic rebalancing as traffic patterns change.
1585 </dd>
1586
1587 <dt><code>active-backup</code></dt>
1588 <dd>
1589 Assigns all flows to one slave, failing over to a backup slave when
1590 the active slave is disabled. This is the only bonding mode in which
1591 interfaces may be plugged into different upstream switches.
1592 </dd>
1593 </dl>
1594
1595 <p>
1596 The following modes require the upstream switch to support 802.3ad with
1597 successful LACP negotiation. If LACP negotiation fails and
1598 other-config:lacp-fallback-ab is true, then <code>active-backup</code>
1599 mode is used:
1600 </p>
1601
1602 <dl>
1603 <dt><code>balance-tcp</code></dt>
1604 <dd>
1605 Balances flows among slaves based on L3 and L4 protocol information
1606 such as IP addresses and TCP/UDP ports.
1607 </dd>
1608 </dl>
1609
1610 <p>These columns apply only to bonded ports. Their values are
1611 otherwise ignored.</p>
1612
1613 <column name="bond_mode">
1614 <p>The type of bonding used for a bonded port. Defaults to
1615 <code>active-backup</code> if unset.
1616 </p>
1617 </column>
1618
1619 <column name="other_config" key="bond-hash-basis"
1620 type='{"type": "integer"}'>
1621 An integer hashed along with flows when choosing output slaves in load
1622 balanced bonds. When changed, all flows will be assigned different
1623 hash values possibly causing slave selection decisions to change. Does
1624 not affect bonding modes which do not employ load balancing such as
1625 <code>active-backup</code>.
1626 </column>
1627
1628 <group title="Link Failure Detection">
1629 <p>
1630 An important part of link bonding is detecting that links are down so
1631 that they may be disabled. These settings determine how Open vSwitch
1632 detects link failure.
1633 </p>
1634
1635 <column name="other_config" key="bond-detect-mode"
1636 type='{"type": "string", "enum": ["set", ["carrier", "miimon"]]}'>
1637 The means used to detect link failures. Defaults to
1638 <code>carrier</code> which uses each interface's carrier to detect
1639 failures. When set to <code>miimon</code>, will check for failures
1640 by polling each interface's MII.
1641 </column>
1642
1643 <column name="other_config" key="bond-miimon-interval"
1644 type='{"type": "integer"}'>
1645 The interval, in milliseconds, between successive attempts to poll
1646 each interface's MII. Relevant only when <ref column="other_config"
1647 key="bond-detect-mode"/> is <code>miimon</code>.
1648 </column>
1649
1650 <column name="bond_updelay">
1651 <p>
1652 The number of milliseconds for which the link must stay up on an
1653 interface before the interface is considered to be up. Specify
1654 <code>0</code> to enable the interface immediately.
1655 </p>
1656
1657 <p>
1658 This setting is honored only when at least one bonded interface is
1659 already enabled. When no interfaces are enabled, then the first
1660 bond interface to come up is enabled immediately.
1661 </p>
1662 </column>
1663
1664 <column name="bond_downdelay">
1665 The number of milliseconds for which the link must stay down on an
1666 interface before the interface is considered to be down. Specify
1667 <code>0</code> to disable the interface immediately.
1668 </column>
1669 </group>
1670
1671 <group title="LACP Configuration">
1672 <p>
1673 LACP, the Link Aggregation Control Protocol, is an IEEE standard that
1674 allows switches to automatically detect that they are connected by
1675 multiple links and aggregate across those links. These settings
1676 control LACP behavior.
1677 </p>
1678
1679 <column name="lacp">
1680 Configures LACP on this port. LACP allows directly connected
1681 switches to negotiate which links may be bonded. LACP may be enabled
1682 on non-bonded ports for the benefit of any switches they may be
1683 connected to. <code>active</code> ports are allowed to initiate LACP
1684 negotiations. <code>passive</code> ports are allowed to participate
1685 in LACP negotiations initiated by a remote switch, but not allowed to
1686 initiate such negotiations themselves. If LACP is enabled on a port
1687 whose partner switch does not support LACP, the bond will be
1688 disabled, unless other-config:lacp-fallback-ab is set to true.
1689 Defaults to <code>off</code> if unset.
1690 </column>
1691
1692 <column name="other_config" key="lacp-system-id">
1693 The LACP system ID of this <ref table="Port"/>. The system ID of a
1694 LACP bond is used to identify itself to its partners. Must be a
1695 nonzero MAC address. Defaults to the bridge Ethernet address if
1696 unset.
1697 </column>
1698
1699 <column name="other_config" key="lacp-system-priority"
1700 type='{"type": "integer", "minInteger": 1, "maxInteger": 65535}'>
1701 The LACP system priority of this <ref table="Port"/>. In LACP
1702 negotiations, link status decisions are made by the system with the
1703 numerically lower priority.
1704 </column>
1705
1706 <column name="other_config" key="lacp-time"
1707 type='{"type": "string", "enum": ["set", ["fast", "slow"]]}'>
1708 <p>
1709 The LACP timing which should be used on this <ref table="Port"/>.
1710 By default <code>slow</code> is used. When configured to be
1711 <code>fast</code> LACP heartbeats are requested at a rate of once
1712 per second causing connectivity problems to be detected more
1713 quickly. In <code>slow</code> mode, heartbeats are requested at a
1714 rate of once every 30 seconds.
1715 </p>
1716 </column>
1717
1718 <column name="other_config" key="lacp-fallback-ab"
1719 type='{"type": "boolean"}'>
1720 <p>
1721 Determines the behavior of openvswitch bond in LACP mode. If
1722 the partner switch does not support LACP, setting this option
1723 to <code>true</code> allows openvswitch to fallback to
1724 active-backup. If the option is set to <code>false</code>, the
1725 bond will be disabled. In both the cases, once the partner switch
1726 is configured to LACP mode, the bond will use LACP.
1727 </p>
1728 </column>
1729 </group>
1730
1731 <group title="Rebalancing Configuration">
1732 <p>
1733 These settings control behavior when a bond is in
1734 <code>balance-slb</code> or <code>balance-tcp</code> mode.
1735 </p>
1736
1737 <column name="other_config" key="bond-rebalance-interval"
1738 type='{"type": "integer", "minInteger": 0, "maxInteger": 10000}'>
1739 For a load balanced bonded port, the number of milliseconds between
1740 successive attempts to rebalance the bond, that is, to move flows
1741 from one interface on the bond to another in an attempt to keep usage
1742 of each interface roughly equal. If zero, load balancing is disabled
1743 on the bond (link failure still cause flows to move). If
1744 less than 1000ms, the rebalance interval will be 1000ms.
1745 </column>
1746 </group>
1747
1748 <column name="bond_fake_iface">
1749 For a bonded port, whether to create a fake internal interface with the
1750 name of the port. Use only for compatibility with legacy software that
1751 requires this.
1752 </column>
1753 </group>
1754
1755 <group title="Spanning Tree Protocol">
1756 <p>
1757 The configuration here is only meaningful, and the status is only
1758 populated, when 802.1D-1998 Spanning Tree Protocol is enabled on the
1759 port's <ref column="Bridge"/> with its <ref column="stp_enable"/>
1760 column.
1761 </p>
1762
1763 <group title="STP Configuration">
1764 <column name="other_config" key="stp-enable"
1765 type='{"type": "boolean"}'>
1766 When STP is enabled on a bridge, it is enabled by default on all of
1767 the bridge's ports except bond, internal, and mirror ports (which do
1768 not work with STP). If this column's value is <code>false</code>,
1769 STP is disabled on the port.
1770 </column>
1771
1772 <column name="other_config" key="stp-port-num"
1773 type='{"type": "integer", "minInteger": 1, "maxInteger": 255}'>
1774 The port number used for the lower 8 bits of the port-id. By
1775 default, the numbers will be assigned automatically. If any
1776 port's number is manually configured on a bridge, then they
1777 must all be.
1778 </column>
1779
1780 <column name="other_config" key="stp-port-priority"
1781 type='{"type": "integer", "minInteger": 0, "maxInteger": 255}'>
1782 The port's relative priority value for determining the root
1783 port (the upper 8 bits of the port-id). A port with a lower
1784 port-id will be chosen as the root port. By default, the
1785 priority is 0x80.
1786 </column>
1787
1788 <column name="other_config" key="stp-path-cost"
1789 type='{"type": "integer", "minInteger": 0, "maxInteger": 65535}'>
1790 Spanning tree path cost for the port. A lower number indicates
1791 a faster link. By default, the cost is based on the maximum
1792 speed of the link.
1793 </column>
1794 </group>
1795
1796 <group title="STP Status">
1797 <column name="status" key="stp_port_id">
1798 The port ID used in spanning tree advertisements for this port, as 4
1799 hex digits. Configuring the port ID is described in the
1800 <code>stp-port-num</code> and <code>stp-port-priority</code> keys of
1801 the <code>other_config</code> section earlier.
1802 </column>
1803 <column name="status" key="stp_state"
1804 type='{"type": "string", "enum": ["set",
1805 ["disabled", "listening", "learning",
1806 "forwarding", "blocking"]]}'>
1807 STP state of the port.
1808 </column>
1809 <column name="status" key="stp_sec_in_state"
1810 type='{"type": "integer", "minInteger": 0}'>
1811 The amount of time this port has been in the current STP state, in
1812 seconds.
1813 </column>
1814 <column name="status" key="stp_role"
1815 type='{"type": "string", "enum": ["set",
1816 ["root", "designated", "alternate"]]}'>
1817 STP role of the port.
1818 </column>
1819 </group>
1820 </group>
1821
1822 <group title="Rapid Spanning Tree Protocol">
1823 <p>
1824 The configuration here is only meaningful, and the status and
1825 statistics are only populated, when 802.1D-1998 Spanning Tree Protocol
1826 is enabled on the port's <ref column="Bridge"/> with its <ref
1827 column="stp_enable"/> column.
1828 </p>
1829
1830 <group title="RSTP Configuration">
1831 <column name="other_config" key="rstp-enable"
1832 type='{"type": "boolean"}'>
1833 When RSTP is enabled on a bridge, it is enabled by default on all of
1834 the bridge's ports except bond, internal, and mirror ports (which do
1835 not work with RSTP). If this column's value is <code>false</code>,
1836 RSTP is disabled on the port.
1837 </column>
1838
1839 <column name="other_config" key="rstp-port-priority"
1840 type='{"type": "integer", "minInteger": 0, "maxInteger": 240}'>
1841 The port's relative priority value for determining the root port, in
1842 multiples of 16. By default, the port priority is 0x80 (128). Any
1843 value in the lower 4 bits is rounded off. The significant upper 4
1844 bits become the upper 4 bits of the port-id. A port with the lowest
1845 port-id is elected as the root.
1846 </column>
1847
1848 <column name="other_config" key="rstp-port-num"
1849 type='{"type": "integer", "minInteger": 1, "maxInteger": 4095}'>
1850 The local RSTP port number, used as the lower 12 bits of the port-id.
1851 By default the port numbers are assigned automatically, and typically
1852 may not correspond to the OpenFlow port numbers. A port with the
1853 lowest port-id is elected as the root.
1854 </column>
1855
1856 <column name="other_config" key="rstp-port-path-cost"
1857 type='{"type": "integer"}'>
1858 The port path cost. The Port's contribution, when it is
1859 the Root Port, to the Root Path Cost for the Bridge. By default the
1860 cost is automatically calculated from the port's speed.
1861 </column>
1862
1863 <column name="other_config" key="rstp-port-admin-edge"
1864 type='{"type": "boolean"}'>
1865 The admin edge port parameter for the Port. Default is
1866 <code>false</code>.
1867 </column>
1868
1869 <column name="other_config" key="rstp-port-auto-edge"
1870 type='{"type": "boolean"}'>
1871 The auto edge port parameter for the Port. Default is
1872 <code>true</code>.
1873 </column>
1874
1875 <column name="other_config" key="rstp-port-mcheck"
1876 type='{"type": "boolean"}'>
1877 <p>
1878 The mcheck port parameter for the Port. Default is
1879 <code>false</code>. May be set to force the Port Protocol
1880 Migration state machine to transmit RST BPDUs for a
1881 MigrateTime period, to test whether all STP Bridges on the
1882 attached LAN have been removed and the Port can continue to
1883 transmit RSTP BPDUs. Setting mcheck has no effect if the
1884 Bridge is operating in STP Compatibility mode.
1885 </p>
1886 <p>
1887 Changing the value from <code>true</code> to
1888 <code>false</code> has no effect, but needs to be done if
1889 this behavior is to be triggered again by subsequently
1890 changing the value from <code>false</code> to
1891 <code>true</code>.
1892 </p>
1893 </column>
1894 </group>
1895
1896 <group title="RSTP Status">
1897 <column name="rstp_status" key="rstp_port_id">
1898 The port ID used in spanning tree advertisements for this port, as 4
1899 hex digits. Configuring the port ID is described in the
1900 <code>rstp-port-num</code> and <code>rstp-port-priority</code> keys
1901 of the <code>other_config</code> section earlier.
1902 </column>
1903 <column name="rstp_status" key="rstp_port_role"
1904 type='{"type": "string", "enum": ["set",
1905 ["Root", "Designated", "Alternate", "Backup", "Disabled"]]}'>
1906 RSTP role of the port.
1907 </column>
1908 <column name="rstp_status" key="rstp_port_state"
1909 type='{"type": "string", "enum": ["set",
1910 ["Disabled", "Learning", "Forwarding", "Discarding"]]}'>
1911 RSTP state of the port.
1912 </column>
1913 <column name="rstp_status" key="rstp_designated_bridge_id">
1914 The port's RSTP designated bridge ID, in the same form as <ref
1915 column="rstp_status" key="rstp_bridge_id"/> in the <ref
1916 table="Bridge"/> table.
1917 </column>
1918 <column name="rstp_status" key="rstp_designated_port_id">
1919 The port's RSTP designated port ID, as 4 hex digits.
1920 </column>
1921 <column name="rstp_status" key="rstp_designated_path_cost"
1922 type='{"type": "integer"}'>
1923 The port's RSTP designated path cost. Lower is better.
1924 </column>
1925 </group>
1926
1927 <group title="RSTP Statistics">
1928 <column name="rstp_statistics" key="rstp_tx_count">
1929 Number of RSTP BPDUs transmitted through this port.
1930 </column>
1931 <column name="rstp_statistics" key="rstp_rx_count">
1932 Number of valid RSTP BPDUs received by this port.
1933 </column>
1934 <column name="rstp_statistics" key="rstp_error_count">
1935 Number of invalid RSTP BPDUs received by this port.
1936 </column>
1937 <column name="rstp_statistics" key="rstp_uptime">
1938 The duration covered by the other RSTP statistics, in seconds.
1939 </column>
1940 </group>
1941 </group>
1942
1943 <group title="Multicast Snooping">
1944 <column name="other_config" key="mcast-snooping-flood"
1945 type='{"type": "boolean"}'>
1946 <p>
1947 If set to <code>true</code>, multicast packets (except Reports) are
1948 unconditionally forwarded to the specific port.
1949 </p>
1950 </column>
1951 <column name="other_config" key="mcast-snooping-flood-reports"
1952 type='{"type": "boolean"}'>
1953 <p>
1954 If set to <code>true</code>, multicast Reports are unconditionally
1955 forwarded to the specific port.
1956 </p>
1957 </column>
1958 </group>
1959
1960 <group title="Other Features">
1961 <column name="qos">
1962 Quality of Service configuration for this port.
1963 </column>
1964
1965 <column name="mac">
1966 The MAC address to use for this port for the purpose of choosing the
1967 bridge's MAC address. This column does not necessarily reflect the
1968 port's actual MAC address, nor will setting it change the port's actual
1969 MAC address.
1970 </column>
1971
1972 <column name="fake_bridge">
1973 Does this port represent a sub-bridge for its tagged VLAN within the
1974 Bridge? See ovs-vsctl(8) for more information.
1975 </column>
1976
1977 <column name="protected" type='{"type": "boolean"}'>
1978 The protected ports feature allows certain ports to be designated as
1979 protected. Traffic between protected ports is blocked. Protected
1980 ports can send traffic to unprotected ports. Unprotected ports can
1981 send traffic to any port.
1982 Default is false.
1983 </column>
1984
1985 <column name="external_ids" key="fake-bridge-id-*">
1986 External IDs for a fake bridge (see the <ref column="fake_bridge"/>
1987 column) are defined by prefixing a <ref table="Bridge"/> <ref
1988 table="Bridge" column="external_ids"/> key with
1989 <code>fake-bridge-</code>,
1990 e.g. <code>fake-bridge-xs-network-uuids</code>.
1991 </column>
1992
1993 <column name="other_config" key="transient"
1994 type='{"type": "boolean"}'>
1995 <p>
1996 If set to <code>true</code>, the port will be removed when
1997 <code>ovs-ctl start --delete-transient-ports</code> is used.
1998 </p>
1999 </column>
2000 </group>
2001
2002 <column name="bond_active_slave">
2003 For a bonded port, record the mac address of the current active slave.
2004 </column>
2005
2006 <group title="Port Statistics">
2007 <p>
2008 Key-value pairs that report port statistics. The update period
2009 is controlled by <ref column="other_config"
2010 key="stats-update-interval"/> in the <code>Open_vSwitch</code> table.
2011 </p>
2012 <group title="Statistics: STP transmit and receive counters">
2013 <column name="statistics" key="stp_tx_count">
2014 Number of STP BPDUs sent on this port by the spanning
2015 tree library.
2016 </column>
2017 <column name="statistics" key="stp_rx_count">
2018 Number of STP BPDUs received on this port and accepted by the
2019 spanning tree library.
2020 </column>
2021 <column name="statistics" key="stp_error_count">
2022 Number of bad STP BPDUs received on this port. Bad BPDUs
2023 include runt packets and those with an unexpected protocol ID.
2024 </column>
2025 </group>
2026 </group>
2027
2028 <group title="Common Columns">
2029 The overall purpose of these columns is described under <code>Common
2030 Columns</code> at the beginning of this document.
2031
2032 <column name="other_config"/>
2033 <column name="external_ids"/>
2034 </group>
2035 </table>
2036
2037 <table name="Interface" title="One physical network device in a Port.">
2038 An interface within a <ref table="Port"/>.
2039
2040 <group title="Core Features">
2041 <column name="name">
2042 <p>
2043 Interface name. Should be alphanumeric. For non-bonded port, this
2044 should be the same as the port name. It must otherwise be unique
2045 among the names of ports, interfaces, and bridges on a host.
2046 </p>
2047
2048 <p>
2049 The maximum length of an interface name depends on the underlying
2050 datapath:
2051 </p>
2052
2053 <ul>
2054 <li>
2055 The names of interfaces implemented as Linux and BSD network
2056 devices, including interfaces with type <code>internal</code>,
2057 <code>tap</code>, or <code>system</code> plus the different types
2058 of tunnel ports, are limited to 15 bytes. Windows limits these
2059 names to 255 bytes.
2060 </li>
2061
2062 <li>
2063 The names of patch ports are not used in the underlying datapath,
2064 so operating system restrictions do not apply. Thus, they may have
2065 arbitrary length.
2066 </li>
2067 </ul>
2068
2069 <p>
2070 Regardless of other restrictions, OpenFlow only supports 15-byte
2071 names, which means that <code>ovs-ofctl</code> and OpenFlow
2072 controllers will show names truncated to 15 bytes.
2073 </p>
2074 </column>
2075
2076 <column name="ifindex">
2077 A positive interface index as defined for SNMP MIB-II in RFCs 1213 and
2078 2863, if the interface has one, otherwise 0. The ifindex is useful for
2079 seamless integration with protocols such as SNMP and sFlow.
2080 </column>
2081
2082 <column name="mac_in_use">
2083 The MAC address in use by this interface.
2084 </column>
2085
2086 <column name="mac">
2087 <p>Ethernet address to set for this interface. If unset then the
2088 default MAC address is used:</p>
2089 <ul>
2090 <li>For the local interface, the default is the lowest-numbered MAC
2091 address among the other bridge ports, either the value of the
2092 <ref table="Port" column="mac"/> in its <ref table="Port"/> record,
2093 if set, or its actual MAC (for bonded ports, the MAC of its slave
2094 whose name is first in alphabetical order). Internal ports and
2095 bridge ports that are used as port mirroring destinations (see the
2096 <ref table="Mirror"/> table) are ignored.</li>
2097 <li>For other internal interfaces, the default MAC is randomly
2098 generated.</li>
2099 <li>External interfaces typically have a MAC address associated with
2100 their hardware.</li>
2101 </ul>
2102 <p>Some interfaces may not have a software-controllable MAC
2103 address.</p>
2104 </column>
2105
2106 <column name="error">
2107 If the configuration of the port failed, as indicated by -1 in <ref
2108 column="ofport"/>, Open vSwitch sets this column to an error
2109 description in human readable form. Otherwise, Open vSwitch clears
2110 this column.
2111 </column>
2112
2113 <group title="OpenFlow Port Number">
2114 <p>
2115 When a client adds a new interface, Open vSwitch chooses an OpenFlow
2116 port number for the new port. If the client that adds the port fills
2117 in <ref column="ofport_request"/>, then Open vSwitch tries to use its
2118 value as the OpenFlow port number. Otherwise, or if the requested
2119 port number is already in use or cannot be used for another reason,
2120 Open vSwitch automatically assigns a free port number. Regardless of
2121 how the port number was obtained, Open vSwitch then reports in <ref
2122 column="ofport"/> the port number actually assigned.
2123 </p>
2124
2125 <p>
2126 Open vSwitch limits the port numbers that it automatically assigns to
2127 the range 1 through 32,767, inclusive. Controllers therefore have
2128 free use of ports 32,768 and up.
2129 </p>
2130
2131 <column name="ofport">
2132 <p>
2133 OpenFlow port number for this interface. Open vSwitch sets this
2134 column's value, so other clients should treat it as read-only.
2135 </p>
2136 <p>
2137 The OpenFlow ``local'' port (<code>OFPP_LOCAL</code>) is 65,534.
2138 The other valid port numbers are in the range 1 to 65,279,
2139 inclusive. Value -1 indicates an error adding the interface.
2140 </p>
2141 </column>
2142
2143 <column name="ofport_request"
2144 type='{"type": "integer", "minInteger": 1, "maxInteger": 65279}'>
2145 <p>
2146 Requested OpenFlow port number for this interface.
2147 </p>
2148
2149 <p>
2150 A client should ideally set this column's value in the same
2151 database transaction that it uses to create the interface. Open
2152 vSwitch version 2.1 and later will honor a later request for a
2153 specific port number, althuogh it might confuse some controllers:
2154 OpenFlow does not have a way to announce a port number change, so
2155 Open vSwitch represents it over OpenFlow as a port deletion
2156 followed immediately by a port addition.
2157 </p>
2158
2159 <p>
2160 If <ref column="ofport_request"/> is set or changed to some other
2161 port's automatically assigned port number, Open vSwitch chooses a
2162 new port number for the latter port.
2163 </p>
2164 </column>
2165 </group>
2166 </group>
2167
2168 <group title="System-Specific Details">
2169 <column name="type">
2170 <p>
2171 The interface type. The types supported by a particular instance of
2172 Open vSwitch are listed in the <ref table="Open_vSwitch"
2173 column="iface_types"/> column in the <ref table="Open_vSwitch"/>
2174 table. The following types are defined:
2175 </p>
2176
2177 <dl>
2178 <dt><code>system</code></dt>
2179 <dd>An ordinary network device, e.g. <code>eth0</code> on Linux.
2180 Sometimes referred to as ``external interfaces'' since they are
2181 generally connected to hardware external to that on which the Open
2182 vSwitch is running. The empty string is a synonym for
2183 <code>system</code>.</dd>
2184
2185 <dt><code>internal</code></dt>
2186 <dd>A simulated network device that sends and receives traffic. An
2187 internal interface whose <ref column="name"/> is the same as its
2188 bridge's <ref table="Open_vSwitch" column="name"/> is called the
2189 ``local interface.'' It does not make sense to bond an internal
2190 interface, so the terms ``port'' and ``interface'' are often used
2191 imprecisely for internal interfaces.</dd>
2192
2193 <dt><code>tap</code></dt>
2194 <dd>
2195 <p>
2196 A TUN/TAP device managed by Open vSwitch.
2197 </p>
2198 <p>
2199 Open vSwitch checks the interface state before send packets
2200 to the device. When it is <code>down</code>, the packets are
2201 dropped and the tx_dropped statistic is updated accordingly.
2202 Older versions of Open vSwitch did not check the interface state
2203 and then the tx_packets was incremented along with tx_dropped.
2204 </p>
2205 </dd>
2206
2207 <dt><code>geneve</code></dt>
2208 <dd>
2209 An Ethernet over Geneve (<code>http://tools.ietf.org/html/draft-ietf-nvo3-geneve</code>)
2210 IPv4/IPv6 tunnel.
2211
2212 A description of how to match and set Geneve options can be found
2213 in the <code>ovs-ofctl</code> manual page.
2214 </dd>
2215
2216 <dt><code>gre</code></dt>
2217 <dd>
2218 Generic Routing Encapsulation (GRE) over IPv4/IPv6 tunnel,
2219 configurable to encapsulate layer 2 or layer 3 traffic.
2220 </dd>
2221
2222 <dt><code>vxlan</code></dt>
2223 <dd>
2224 <p>
2225 An Ethernet tunnel over the UDP-based VXLAN protocol described in
2226 RFC 7348.
2227 </p>
2228 <p>
2229 Open vSwitch uses IANA-assigned UDP destination port 4789. The
2230 source port used for VXLAN traffic varies on a per-flow basis
2231 and is in the ephemeral port range.
2232 </p>
2233 </dd>
2234
2235 <dt><code>lisp</code></dt>
2236 <dd>
2237 <p>
2238 A layer 3 tunnel over the experimental, UDP-based Locator/ID
2239 Separation Protocol (RFC 6830).
2240 </p>
2241 <p>
2242 Only IPv4 and IPv6 packets are supported by the protocol, and
2243 they are sent and received without an Ethernet header. Traffic
2244 to/from LISP ports is expected to be configured explicitly, and
2245 the ports are not intended to participate in learning based
2246 switching. As such, they are always excluded from packet
2247 flooding.
2248 </p>
2249 </dd>
2250
2251 <dt><code>stt</code></dt>
2252 <dd>
2253 The Stateless TCP Tunnel (STT) is particularly useful when tunnel
2254 endpoints are in end-systems, as it utilizes the capabilities of
2255 standard network interface cards to improve performance. STT utilizes
2256 a TCP-like header inside the IP header. It is stateless, i.e., there is
2257 no TCP connection state of any kind associated with the tunnel. The
2258 TCP-like header is used to leverage the capabilities of existing
2259 network interface cards, but should not be interpreted as implying
2260 any sort of connection state between endpoints.
2261 Since the STT protocol does not engage in the usual TCP 3-way handshake,
2262 so it will have difficulty traversing stateful firewalls.
2263 The protocol is documented at
2264 https://tools.ietf.org/html/draft-davie-stt
2265
2266 All traffic uses a default destination port of 7471.
2267 </dd>
2268
2269 <dt><code>patch</code></dt>
2270 <dd>
2271 A pair of virtual devices that act as a patch cable.
2272 </dd>
2273 </dl>
2274 </column>
2275 </group>
2276
2277 <group title="Tunnel Options">
2278 <p>
2279 These options apply to interfaces with <ref column="type"/> of
2280 <code>geneve</code>, <code>gre</code>, <code>vxlan</code>,
2281 <code>lisp</code> and <code>stt</code>.
2282 </p>
2283
2284 <p>
2285 Each tunnel must be uniquely identified by the combination of <ref
2286 column="type"/>, <ref column="options" key="remote_ip"/>, <ref
2287 column="options" key="local_ip"/>, and <ref column="options"
2288 key="in_key"/>. If two ports are defined that are the same except one
2289 has an optional identifier and the other does not, the more specific
2290 one is matched first. <ref column="options" key="in_key"/> is
2291 considered more specific than <ref column="options" key="local_ip"/> if
2292 a port defines one and another port defines the other.
2293 </p>
2294
2295 <column name="options" key="remote_ip">
2296 <p>Required. The remote tunnel endpoint, one of:</p>
2297
2298 <ul>
2299 <li>
2300 An IPv4 or IPv6 address (not a DNS name), e.g. <code>192.168.0.123</code>.
2301 Only unicast endpoints are supported.
2302 </li>
2303 <li>
2304 The word <code>flow</code>. The tunnel accepts packets from any
2305 remote tunnel endpoint. To process only packets from a specific
2306 remote tunnel endpoint, the flow entries may match on the
2307 <code>tun_src</code> or <code>tun_ipv6_src</code>field. When
2308 sending packets to a <code>remote_ip=flow</code> tunnel, the flow
2309 actions must explicitly set the <code>tun_dst</code> or
2310 <code>tun_ipv6_dst</code> field to the IP address of the desired
2311 remote tunnel endpoint, e.g. with a <code>set_field</code> action.
2312 </li>
2313 </ul>
2314
2315 <p>
2316 The remote tunnel endpoint for any packet received from a tunnel
2317 is available in the <code>tun_src</code> field for matching in the
2318 flow table.
2319 </p>
2320 </column>
2321
2322 <column name="options" key="local_ip">
2323 <p>
2324 Optional. The tunnel destination IP that received packets must
2325 match. Default is to match all addresses. If specified, may be one
2326 of:
2327 </p>
2328
2329 <ul>
2330 <li>
2331 An IPv4/IPv6 address (not a DNS name), e.g. <code>192.168.12.3</code>.
2332 </li>
2333 <li>
2334 The word <code>flow</code>. The tunnel accepts packets sent to any
2335 of the local IP addresses of the system running OVS. To process
2336 only packets sent to a specific IP address, the flow entries may
2337 match on the <code>tun_dst</code> or <code>tun_ipv6_dst</code> field.
2338 When sending packets to a <code>local_ip=flow</code> tunnel, the flow
2339 actions may explicitly set the <code>tun_src</code> or <code>tun_ipv6_src</code>
2340 field to the desired IP address, e.g. with a <code>set_field</code> action.
2341 However, while routing the tunneled packet out, the local system may
2342 override the specified address with the local IP address configured for the
2343 outgoing system interface.
2344
2345 <p>
2346 This option is valid only for tunnels also configured with the
2347 <code>remote_ip=flow</code> option.
2348 </p>
2349 </li>
2350 </ul>
2351
2352 <p>
2353 The tunnel destination IP address for any packet received from a
2354 tunnel is available in the <code>tun_dst</code> or <code>tun_ipv6_dst</code>
2355 field for matching in the flow table.
2356 </p>
2357 </column>
2358
2359 <column name="options" key="in_key">
2360 <p>Optional. The key that received packets must contain, one of:</p>
2361
2362 <ul>
2363 <li>
2364 <code>0</code>. The tunnel receives packets with no key or with a
2365 key of 0. This is equivalent to specifying no <ref column="options"
2366 key="in_key"/> at all.
2367 </li>
2368 <li>
2369 A positive 24-bit (for Geneve, VXLAN, and LISP), 32-bit (for GRE)
2370 or 64-bit (for STT) number. The tunnel receives only
2371 packets with the specified key.
2372 </li>
2373 <li>
2374 The word <code>flow</code>. The tunnel accepts packets with any
2375 key. The key will be placed in the <code>tun_id</code> field for
2376 matching in the flow table. The <code>ovs-ofctl</code> manual page
2377 contains additional information about matching fields in OpenFlow
2378 flows.
2379 </li>
2380 </ul>
2381
2382 <p>
2383 </p>
2384 </column>
2385
2386 <column name="options" key="out_key">
2387 <p>Optional. The key to be set on outgoing packets, one of:</p>
2388
2389 <ul>
2390 <li>
2391 <code>0</code>. Packets sent through the tunnel will have no key.
2392 This is equivalent to specifying no <ref column="options"
2393 key="out_key"/> at all.
2394 </li>
2395 <li>
2396 A positive 24-bit (for Geneve, VXLAN and LISP), 32-bit (for GRE) or
2397 64-bit (for STT) number. Packets sent through the tunnel
2398 will have the specified key.
2399 </li>
2400 <li>
2401 The word <code>flow</code>. Packets sent through the tunnel will
2402 have the key set using the <code>set_tunnel</code> Nicira OpenFlow
2403 vendor extension (0 is used in the absence of an action). The
2404 <code>ovs-ofctl</code> manual page contains additional information
2405 about the Nicira OpenFlow vendor extensions.
2406 </li>
2407 </ul>
2408 </column>
2409
2410 <column name="options" key="dst_port">
2411 Optional. The tunnel transport layer destination port, for UDP and TCP
2412 based tunnel protocols (Geneve, VXLAN, LISP, and STT).
2413 </column>
2414
2415 <column name="options" key="key">
2416 Optional. Shorthand to set <code>in_key</code> and
2417 <code>out_key</code> at the same time.
2418 </column>
2419
2420 <column name="options" key="tos">
2421 Optional. The value of the ToS bits to be set on the encapsulating
2422 packet. ToS is interpreted as DSCP and ECN bits, ECN part must be
2423 zero. It may also be the word <code>inherit</code>, in which case
2424 the ToS will be copied from the inner packet if it is IPv4 or IPv6
2425 (otherwise it will be 0). The ECN fields are always inherited.
2426 Default is 0.
2427 </column>
2428
2429 <column name="options" key="ttl">
2430 Optional. The TTL to be set on the encapsulating packet. It may also
2431 be the word <code>inherit</code>, in which case the TTL will be copied
2432 from the inner packet if it is IPv4 or IPv6 (otherwise it will be the
2433 system default, typically 64). Default is the system default TTL.
2434 </column>
2435
2436 <column name="options" key="df_default"
2437 type='{"type": "boolean"}'>
2438 Optional. If enabled, the Don't Fragment bit will be set on tunnel
2439 outer headers to allow path MTU discovery. Default is enabled; set
2440 to <code>false</code> to disable.
2441 </column>
2442
2443 <column name="options" key="egress_pkt_mark">
2444 Optional. The pkt_mark to be set on the encapsulating packet. This
2445 option sets packet mark for the tunnel endpoint for all tunnel packets
2446 including tunnel monitoring.
2447 </column>
2448
2449 <group title="Tunnel Options: lisp only">
2450 <column name="options" key="packet_type"
2451 type='{"type": "string", "enum": ["set",
2452 ["legacy_l3", "ptap"]]}'>
2453 <p>
2454 A LISP tunnel sends and receives only IPv4 and IPv6 packets. This
2455 option controls what how the tunnel represents the packets that it
2456 sends and receives:
2457 </p>
2458
2459 <ul>
2460 <li>
2461 By default, or if this option is <code>legacy_l3</code>, the
2462 tunnel represents packets as Ethernet frames for compatibility
2463 with legacy OpenFlow controllers that expect this behavior.
2464 </li>
2465 <li>
2466 If this option is <code>ptap</code>, the tunnel represents
2467 packets using the <code>packet_type</code> mechanism introduced
2468 in OpenFlow 1.5.
2469 </li>
2470 </ul>
2471 </column>
2472 </group>
2473
2474 <group title="Tunnel Options: vxlan only">
2475
2476 <column name="options" key="exts">
2477 <p>Optional. Comma separated list of optional VXLAN extensions to
2478 enable. The following extensions are supported:</p>
2479
2480 <ul>
2481 <li>
2482 <code>gbp</code>: VXLAN-GBP allows to transport the group policy
2483 context of a packet across the VXLAN tunnel to other network
2484 peers. See the description of <code>tun_gbp_id</code> and
2485 <code>tun_gbp_flags</code> in <code>ovs-fields</code>(7) for
2486 additional information.
2487 (<code>https://tools.ietf.org/html/draft-smith-vxlan-group-policy</code>)
2488 </li>
2489 <li>
2490 <code>gpe</code>: Support for Generic Protocol Encapsulation in
2491 accordance with IETF draft
2492 <code>https://tools.ietf.org/html/draft-ietf-nvo3-vxlan-gpe</code>.
2493 Without this option, a VXLAN packet always encapsulates an
2494 Ethernet frame. With this option, an VXLAN packet may also
2495 encapsulate an IPv4, IPv6, NSH, or MPLS packet.
2496 </li>
2497 </ul>
2498 </column>
2499
2500 <column name="options" key="packet_type"
2501 type='{"type": "string", "enum": ["set",
2502 ["legacy_l2", "legacy_l3", "ptap"]]}'>
2503 <p>
2504 This option controls what types of packets the tunnel sends and
2505 receives and how it represents them:
2506 </p>
2507
2508 <ul>
2509 <li>
2510 By default, or if this option is <code>legacy_l2</code>, the
2511 tunnel sends and receives only Ethernet frames.
2512 </li>
2513 <li>
2514 If this option is <code>legacy_l3</code>, the tunnel sends and
2515 receives only non-Ethernet (L3) packet, but the packets are
2516 represented as Ethernet frames for compatibility with legacy
2517 OpenFlow controllers that expect this behavior. This requires
2518 enabling <code>gpe</code> in <ref column="options" key="exts"/>.
2519 </li>
2520 <li>
2521 If this option is <code>ptap</code>, Open vSwitch represents
2522 packets in the tunnel using the <code>packet_type</code>
2523 mechanism introduced in OpenFlow 1.5. This mechanism supports
2524 any kind of packet, but actually sending and receiving
2525 non-Ethernet packets requires additionally enabling
2526 <code>gpe</code> in <ref column="options" key="exts"/>.
2527 </li>
2528 </ul>
2529 </column>
2530 </group>
2531
2532 <group title="Tunnel Options: gre only">
2533 <p>
2534 <code>gre</code> interfaces support these options.
2535 </p>
2536
2537 <column name="options" key="packet_type"
2538 type='{"type": "string", "enum": ["set",
2539 ["legacy_l2", "legacy_l3", "ptap"]]}'>
2540 <p>
2541 This option controls what types of packets the tunnel sends and
2542 receives and how it represents them:
2543 </p>
2544
2545 <ul>
2546 <li>
2547 By default, or if this option is <code>legacy_l2</code>, the
2548 tunnel sends and receives only Ethernet frames.
2549 </li>
2550 <li>
2551 If this option is <code>legacy_l3</code>, the tunnel sends and
2552 receives only non-Ethernet (L3) packet, but the packets are
2553 represented as Ethernet frames for compatibility with legacy
2554 OpenFlow controllers that expect this behavior.
2555 </li>
2556 <li>
2557 If this option is <code>ptap</code>, the tunnel sends and
2558 receives any kind of packet. Open vSwitch represents packets in
2559 the tunnel using the <code>packet_type</code> mechanism
2560 introduced in OpenFlow 1.5.
2561 </li>
2562 </ul>
2563 </column>
2564 </group>
2565
2566 <group title="Tunnel Options: gre, geneve, and vxlan">
2567 <p>
2568 <code>gre</code>, <code>geneve</code>, and
2569 <code>vxlan</code> interfaces support these options.
2570 </p>
2571
2572 <column name="options" key="csum" type='{"type": "boolean"}'>
2573 <p>
2574 Optional. Compute encapsulation header (either GRE or UDP)
2575 checksums on outgoing packets. Default is disabled, set to
2576 <code>true</code> to enable. Checksums present on incoming
2577 packets will be validated regardless of this setting.
2578 </p>
2579
2580 <p>
2581 When using the upstream Linux kernel module, computation of
2582 checksums for <code>geneve</code> and <code>vxlan</code> requires
2583 Linux kernel version 4.0 or higher. <code>gre</code> supports
2584 checksums for all versions of Open vSwitch that support GRE.
2585 The out of tree kernel module distributed as part of OVS
2586 can compute all tunnel checksums on any kernel version that it
2587 is compatible with.
2588 </p>
2589
2590 </column>
2591 </group>
2592 </group>
2593
2594 <group title="Patch Options">
2595 <p>
2596 These options apply only to <dfn>patch ports</dfn>, that is, interfaces
2597 whose <ref column="type"/> column is <code>patch</code>. Patch ports
2598 are mainly a way to connect otherwise independent bridges to one
2599 another, similar to how one might plug an Ethernet cable (a ``patch
2600 cable'') into two physical switches to connect those switches. The
2601 effect of plugging a patch port into two switches is conceptually
2602 similar to that of plugging the two ends of a Linux <code>veth</code>
2603 device into those switches, but the implementation of patch ports makes
2604 them much more efficient.
2605 </p>
2606
2607 <p>
2608 Patch ports may connect two different bridges (the usual case) or the
2609 same bridge. In the latter case, take special care to avoid loops,
2610 e.g. by programming appropriate flows with OpenFlow. Patch ports do
2611 not work if its ends are attached to bridges on different datapaths,
2612 e.g. to connect bridges in <code>system</code> and <code>netdev</code>
2613 datapaths.
2614 </p>
2615
2616 <p>
2617 The following command creates and connects patch ports <code>p0</code>
2618 and <code>p1</code> and adds them to bridges <code>br0</code> and
2619 <code>br1</code>, respectively:
2620 </p>
2621
2622 <pre>
2623 ovs-vsctl add-port br0 p0 -- set Interface p0 type=patch options:peer=p1 \
2624 -- add-port br1 p1 -- set Interface p1 type=patch options:peer=p0
2625 </pre>
2626
2627 <column name="options" key="peer">
2628 The <ref column="name"/> of the <ref table="Interface"/> for the other
2629 side of the patch. The named <ref table="Interface"/>'s own
2630 <code>peer</code> option must specify this <ref table="Interface"/>'s
2631 name. That is, the two patch interfaces must have reversed <ref
2632 column="name"/> and <code>peer</code> values.
2633 </column>
2634 </group>
2635
2636 <group title="PMD (Poll Mode Driver) Options">
2637 <p>
2638 Only PMD netdevs support these options.
2639 </p>
2640
2641 <column name="options" key="n_rxq"
2642 type='{"type": "integer", "minInteger": 1}'>
2643 <p>
2644 Specifies the maximum number of rx queues to be created for PMD
2645 netdev. If not specified or specified to 0, one rx queue will
2646 be created by default.
2647 Not supported by DPDK vHost interfaces.
2648 </p>
2649 </column>
2650
2651 <column name="options" key="dpdk-devargs"
2652 type='{"type": "string"}'>
2653 <p>
2654 Specifies the PCI address associated with the port for physical
2655 devices, or the virtual driver to be used for the port when a virtual
2656 PMD is intended to be used. For the latter, the argument string
2657 typically takes the form of
2658 <code>eth_<var>driver_name</var><var>x</var></code>, where
2659 <var>driver_name</var> is a valid virtual DPDK PMD driver name and
2660 <var>x</var> is a unique identifier of your choice for the given
2661 port. Only supported by the dpdk port type.
2662 </p>
2663 </column>
2664
2665 <column name="other_config" key="pmd-rxq-affinity">
2666 <p>Specifies mapping of RX queues of this interface to CPU cores.</p>
2667 <p>Value should be set in the following form:</p>
2668 <p>
2669 <code>other_config:pmd-rxq-affinity=&lt;rxq-affinity-list&gt;</code>
2670 </p>
2671 <p>where</p>
2672 <p>
2673 <ul>
2674 <li>
2675 &lt;rxq-affinity-list&gt; ::= NULL | &lt;non-empty-list&gt;
2676 </li>
2677 <li>
2678 &lt;non-empty-list&gt; ::= &lt;affinity-pair&gt; |
2679 &lt;affinity-pair&gt; , &lt;non-empty-list&gt;
2680 </li>
2681 <li>
2682 &lt;affinity-pair&gt; ::= &lt;queue-id&gt; : &lt;core-id&gt;
2683 </li>
2684 </ul>
2685 </p>
2686 </column>
2687
2688 <column name="options" key="vhost-server-path"
2689 type='{"type": "string"}'>
2690 <p>
2691 The value specifies the path to the socket associated with a vHost
2692 User client mode device that has been or will be created by QEMU.
2693 Only supported by dpdkvhostuserclient interfaces.
2694 </p>
2695 </column>
2696
2697 <column name="options" key="dq-zero-copy"
2698 type='{"type": "boolean"}'>
2699 <p>
2700 The value specifies whether or not to enable dequeue zero copy on
2701 the given interface.
2702 Must be set before vhost-server-path is specified.
2703 Only supported by dpdkvhostuserclient interfaces.
2704 The feature is considered experimental.
2705 </p>
2706 </column>
2707
2708 <column name="options" key="n_rxq_desc"
2709 type='{"type": "integer", "minInteger": 1, "maxInteger": 4096}'>
2710 <p>
2711 Specifies the rx queue size (number rx descriptors) for dpdk ports.
2712 The value must be a power of 2, less than 4096 and supported
2713 by the hardware of the device being configured.
2714 If not specified or an incorrect value is specified, 2048 rx
2715 descriptors will be used by default.
2716 </p>
2717 </column>
2718
2719 <column name="options" key="n_txq_desc"
2720 type='{"type": "integer", "minInteger": 1, "maxInteger": 4096}'>
2721 <p>
2722 Specifies the tx queue size (number tx descriptors) for dpdk ports.
2723 The value must be a power of 2, less than 4096 and supported
2724 by the hardware of the device being configured.
2725 If not specified or an incorrect value is specified, 2048 tx
2726 descriptors will be used by default.
2727 </p>
2728 </column>
2729 </group>
2730
2731 <group title="MTU">
2732 <p>
2733 The MTU (maximum transmission unit) is the largest amount of data
2734 that can fit into a single Ethernet frame. The standard Ethernet
2735 MTU is 1500 bytes. Some physical media and many kinds of virtual
2736 interfaces can be configured with higher MTUs.
2737 </p>
2738
2739 <p>
2740 A client may change an interface MTU by filling in
2741 <ref column="mtu_request"/>. Open vSwitch then reports in
2742 <ref column="mtu"/> the currently configured value.
2743 </p>
2744
2745 <column name="mtu">
2746 <p>
2747 The currently configured MTU for the interface.
2748 </p>
2749
2750 <p>
2751 This column will be empty for an interface that does not
2752 have an MTU as, for example, some kinds of tunnels do not.
2753 </p>
2754
2755 <p>
2756 Open vSwitch sets this column's value, so other clients should treat
2757 it as read-only.
2758 </p>
2759 </column>
2760
2761 <column name="mtu_request"
2762 type='{"type": "integer", "minInteger": 1}'>
2763 <p>
2764 Requested MTU (Maximum Transmission Unit) for the interface. A client
2765 can fill this column to change the MTU of an interface.
2766 </p>
2767
2768 <p>
2769 RFC 791 requires every internet module to be able to forward a
2770 datagram of 68 octets without further fragmentation. The maximum
2771 size of an IP packet is 65535 bytes.
2772 </p>
2773
2774 <p>
2775 If this is not set and if the interface has <code>internal</code>
2776 type, Open vSwitch will change the MTU to match the minimum of the
2777 other interfaces in the bridge.
2778 </p>
2779 </column>
2780
2781 </group>
2782
2783 <group title="Interface Status">
2784 <p>
2785 Status information about interfaces attached to bridges, updated every
2786 5 seconds. Not all interfaces have all of these properties; virtual
2787 interfaces don't have a link speed, for example. Non-applicable
2788 columns will have empty values.
2789 </p>
2790 <column name="admin_state">
2791 <p>
2792 The administrative state of the physical network link.
2793 </p>
2794 </column>
2795
2796 <column name="link_state">
2797 <p>
2798 The observed state of the physical network link. This is ordinarily
2799 the link's carrier status. If the interface's <ref table="Port"/> is
2800 a bond configured for miimon monitoring, it is instead the network
2801 link's miimon status.
2802 </p>
2803 </column>
2804
2805 <column name="link_resets">
2806 <p>
2807 The number of times Open vSwitch has observed the
2808 <ref column="link_state"/> of this <ref table="Interface"/> change.
2809 </p>
2810 </column>
2811
2812 <column name="link_speed">
2813 <p>
2814 The negotiated speed of the physical network link.
2815 Valid values are positive integers greater than 0.
2816 </p>
2817 </column>
2818
2819 <column name="duplex">
2820 <p>
2821 The duplex mode of the physical network link.
2822 </p>
2823 </column>
2824
2825 <column name="lacp_current">
2826 Boolean value indicating LACP status for this interface. If true, this
2827 interface has current LACP information about its LACP partner. This
2828 information may be used to monitor the health of interfaces in a LACP
2829 enabled port. This column will be empty if LACP is not enabled.
2830 </column>
2831
2832 <column name="status">
2833 Key-value pairs that report port status. Supported status values are
2834 <ref column="type"/>-dependent; some interfaces may not have a valid
2835 <ref column="status" key="driver_name"/>, for example.
2836 </column>
2837
2838 <column name="status" key="driver_name">
2839 The name of the device driver controlling the network adapter.
2840 </column>
2841
2842 <column name="status" key="driver_version">
2843 The version string of the device driver controlling the network
2844 adapter.
2845 </column>
2846
2847 <column name="status" key="firmware_version">
2848 The version string of the network adapter's firmware, if available.
2849 </column>
2850
2851 <column name="status" key="source_ip">
2852 The source IP address used for an IPv4/IPv6 tunnel end-point, such as
2853 <code>gre</code>.
2854 </column>
2855
2856 <column name="status" key="tunnel_egress_iface">
2857 Egress interface for tunnels. Currently only relevant for tunnels
2858 on Linux systems, this column will show the name of the interface
2859 which is responsible for routing traffic destined for the configured
2860 <ref column="options" key="remote_ip"/>. This could be an internal
2861 interface such as a bridge port.
2862 </column>
2863
2864 <column name="status" key="tunnel_egress_iface_carrier"
2865 type='{"type": "string", "enum": ["set", ["down", "up"]]}'>
2866 Whether carrier is detected on <ref column="status"
2867 key="tunnel_egress_iface"/>.
2868 </column>
2869
2870 <group title="dpdk">
2871 <p>
2872 DPDK specific interface status options.
2873 </p>
2874
2875 <column name="status" key="port_no">
2876 DPDK port ID.
2877 </column>
2878
2879 <column name="status" key="numa_id">
2880 NUMA socket ID to which an Ethernet device is connected.
2881 </column>
2882
2883 <column name="status" key="min_rx_bufsize">
2884 Minimum size of RX buffer.
2885 </column>
2886
2887 <column name="status" key="max_rx_pktlen">
2888 Maximum configurable length of RX pkt.
2889 </column>
2890
2891 <column name="status" key="max_rx_queues">
2892 Maximum number of RX queues.
2893 </column>
2894
2895 <column name="status" key="max_tx_queues">
2896 Maximum number of TX queues.
2897 </column>
2898
2899 <column name="status" key="max_mac_addrs">
2900 Maximum number of MAC addresses.
2901 </column>
2902
2903 <column name="status" key="max_hash_mac_addrs">
2904 Maximum number of hash MAC addresses for MTA and UTA.
2905 </column>
2906
2907 <column name="status" key="max_vfs">
2908 Maximum number of hash MAC addresses for MTA and UTA.
2909 Maximum number of VFs.
2910 </column>
2911
2912 <column name="status" key="max_vmdq_pools">
2913 Maximum number of VMDq pools.
2914 </column>
2915
2916 <column name="status" key="if_type">
2917 Interface type ID according to IANA ifTYPE MIB definitions.
2918 </column>
2919
2920 <column name="status" key="if_descr">
2921 Interface description string.
2922 </column>
2923
2924 <column name="status" key="pci-vendor_id">
2925 Vendor ID of PCI device.
2926 </column>
2927
2928 <column name="status" key="pci-device_id">
2929 Device ID of PCI device.
2930 </column>
2931
2932 </group>
2933 </group>
2934
2935 <group title="Statistics">
2936 <p>
2937 Key-value pairs that report interface statistics. The current
2938 implementation updates these counters periodically. The update period
2939 is controlled by <ref column="other_config"
2940 key="stats-update-interval"/> in the <code>Open_vSwitch</code> table.
2941 Future implementations may update them when an interface is created,
2942 when they are queried (e.g. using an OVSDB <code>select</code>
2943 operation), and just before an interface is deleted due to virtual
2944 interface hot-unplug or VM shutdown, and perhaps at other times, but
2945 not on any regular periodic basis.
2946 </p>
2947 <p>
2948 These are the same statistics reported by OpenFlow in its <code>struct
2949 ofp_port_stats</code> structure. If an interface does not support a
2950 given statistic, then that pair is omitted.
2951 </p>
2952 <group title="Statistics: Successful transmit and receive counters">
2953 <column name="statistics" key="rx_packets">
2954 Number of received packets.
2955 </column>
2956 <column name="statistics" key="rx_bytes">
2957 Number of received bytes.
2958 </column>
2959 <column name="statistics" key="tx_packets">
2960 Number of transmitted packets.
2961 </column>
2962 <column name="statistics" key="tx_bytes">
2963 Number of transmitted bytes.
2964 </column>
2965 </group>
2966 <group title="Statistics: Receive errors">
2967 <column name="statistics" key="rx_dropped">
2968 Number of packets dropped by RX.
2969 </column>
2970 <column name="statistics" key="rx_frame_err">
2971 Number of frame alignment errors.
2972 </column>
2973 <column name="statistics" key="rx_over_err">
2974 Number of packets with RX overrun.
2975 </column>
2976 <column name="statistics" key="rx_crc_err">
2977 Number of CRC errors.
2978 </column>
2979 <column name="statistics" key="rx_errors">
2980 Total number of receive errors, greater than or equal to the sum of
2981 the above.
2982 </column>
2983 </group>
2984 <group title="Statistics: Transmit errors">
2985 <column name="statistics" key="tx_dropped">
2986 Number of packets dropped by TX.
2987 </column>
2988 <column name="statistics" key="collisions">
2989 Number of collisions.
2990 </column>
2991 <column name="statistics" key="tx_errors">
2992 Total number of transmit errors, greater than or equal to the sum of
2993 the above.
2994 </column>
2995 </group>
2996 </group>
2997
2998 <group title="Ingress Policing">
2999 <p>
3000 These settings control ingress policing for packets received on this
3001 interface. On a physical interface, this limits the rate at which
3002 traffic is allowed into the system from the outside; on a virtual
3003 interface (one connected to a virtual machine), this limits the rate at
3004 which the VM is able to transmit.
3005 </p>
3006 <p>
3007 Policing is a simple form of quality-of-service that simply drops
3008 packets received in excess of the configured rate. Due to its
3009 simplicity, policing is usually less accurate and less effective than
3010 egress QoS (which is configured using the <ref table="QoS"/> and <ref
3011 table="Queue"/> tables).
3012 </p>
3013 <p>
3014 Policing is currently implemented on Linux and OVS with DPDK. Both
3015 implementations use a simple ``token bucket'' approach:
3016 </p>
3017 <ul>
3018 <li>
3019 The size of the bucket corresponds to <ref
3020 column="ingress_policing_burst"/>. Initially the bucket is full.
3021 </li>
3022 <li>
3023 Whenever a packet is received, its size (converted to tokens) is
3024 compared to the number of tokens currently in the bucket. If the
3025 required number of tokens are available, they are removed and the
3026 packet is forwarded. Otherwise, the packet is dropped.
3027 </li>
3028 <li>
3029 Whenever it is not full, the bucket is refilled with tokens at the
3030 rate specified by <ref column="ingress_policing_rate"/>.
3031 </li>
3032 </ul>
3033 <p>
3034 Policing interacts badly with some network protocols, and especially
3035 with fragmented IP packets. Suppose that there is enough network
3036 activity to keep the bucket nearly empty all the time. Then this token
3037 bucket algorithm will forward a single packet every so often, with the
3038 period depending on packet size and on the configured rate. All of the
3039 fragments of an IP packets are normally transmitted back-to-back, as a
3040 group. In such a situation, therefore, only one of these fragments
3041 will be forwarded and the rest will be dropped. IP does not provide
3042 any way for the intended recipient to ask for only the remaining
3043 fragments. In such a case there are two likely possibilities for what
3044 will happen next: either all of the fragments will eventually be
3045 retransmitted (as TCP will do), in which case the same problem will
3046 recur, or the sender will not realize that its packet has been dropped
3047 and data will simply be lost (as some UDP-based protocols will do).
3048 Either way, it is possible that no forward progress will ever occur.
3049 </p>
3050 <column name="ingress_policing_rate">
3051 <p>
3052 Maximum rate for data received on this interface, in kbps. Data
3053 received faster than this rate is dropped. Set to <code>0</code>
3054 (the default) to disable policing.
3055 </p>
3056 </column>
3057
3058 <column name="ingress_policing_burst">
3059 <p>Maximum burst size for data received on this interface, in kb. The
3060 default burst size if set to <code>0</code> is 8000 kbit. This value
3061 has no effect if <ref column="ingress_policing_rate"/>
3062 is <code>0</code>.</p>
3063 <p>
3064 Specifying a larger burst size lets the algorithm be more forgiving,
3065 which is important for protocols like TCP that react severely to
3066 dropped packets. The burst size should be at least the size of the
3067 interface's MTU. Specifying a value that is numerically at least as
3068 large as 80% of <ref column="ingress_policing_rate"/> helps TCP come
3069 closer to achieving the full rate.
3070 </p>
3071 </column>
3072 </group>
3073
3074 <group title="Bidirectional Forwarding Detection (BFD)">
3075 <p>
3076 BFD, defined in RFC 5880 and RFC 5881, allows point-to-point
3077 detection of connectivity failures by occasional transmission of
3078 BFD control messages. Open vSwitch implements BFD to serve
3079 as a more popular and standards compliant alternative to CFM.
3080 </p>
3081
3082 <p>
3083 BFD operates by regularly transmitting BFD control messages at a rate
3084 negotiated independently in each direction. Each endpoint specifies
3085 the rate at which it expects to receive control messages, and the rate
3086 at which it is willing to transmit them. By default, Open vSwitch uses
3087 a detection multiplier of three, meaning that an endpoint signals a
3088 connectivity fault if three consecutive BFD control messages fail to
3089 arrive. In the case of a unidirectional connectivity issue, the system
3090 not receiving BFD control messages signals the problem to its peer in
3091 the messages it transmits.
3092 </p>
3093
3094 <p>
3095 The Open vSwitch implementation of BFD aims to comply faithfully
3096 with RFC 5880 requirements. Open vSwitch does not implement the
3097 optional Authentication or ``Echo Mode'' features.
3098 </p>
3099
3100 <group title="BFD Configuration">
3101 <p>
3102 A controller sets up key-value pairs in the <ref column="bfd"/>
3103 column to enable and configure BFD.
3104 </p>
3105
3106 <column name="bfd" key="enable" type='{"type": "boolean"}'>
3107 True to enable BFD on this <ref table="Interface"/>. If not
3108 specified, BFD will not be enabled by default.
3109 </column>
3110
3111 <column name="bfd" key="min_rx"
3112 type='{"type": "integer", "minInteger": 1}'>
3113 The shortest interval, in milliseconds, at which this BFD session
3114 offers to receive BFD control messages. The remote endpoint may
3115 choose to send messages at a slower rate. Defaults to
3116 <code>1000</code>.
3117 </column>
3118
3119 <column name="bfd" key="min_tx"
3120 type='{"type": "integer", "minInteger": 1}'>
3121 The shortest interval, in milliseconds, at which this BFD session is
3122 willing to transmit BFD control messages. Messages will actually be
3123 transmitted at a slower rate if the remote endpoint is not willing to
3124 receive as quickly as specified. Defaults to <code>100</code>.
3125 </column>
3126
3127 <column name="bfd" key="decay_min_rx" type='{"type": "integer"}'>
3128 An alternate receive interval, in milliseconds, that must be greater
3129 than or equal to <ref column="bfd" key="min_rx"/>. The
3130 implementation switches from <ref column="bfd" key="min_rx"/> to <ref
3131 column="bfd" key="decay_min_rx"/> when there is no obvious incoming
3132 data traffic at the interface, to reduce the CPU and bandwidth cost
3133 of monitoring an idle interface. This feature may be disabled by
3134 setting a value of 0. This feature is reset whenever <ref
3135 column="bfd" key="decay_min_rx"/> or <ref column="bfd" key="min_rx"/>
3136 changes.
3137 </column>
3138
3139 <column name="bfd" key="forwarding_if_rx" type='{"type": "boolean"}'>
3140 When <code>true</code>, traffic received on the
3141 <ref table="Interface"/> is used to indicate the capability of packet
3142 I/O. BFD control packets are still transmitted and received. At
3143 least one BFD control packet must be received every 100 * <ref
3144 column="bfd" key="min_rx"/> amount of time. Otherwise, even if
3145 traffic are received, the <ref column="bfd" key="forwarding"/>
3146 will be <code>false</code>.
3147 </column>
3148
3149 <column name="bfd" key="cpath_down" type='{"type": "boolean"}'>
3150 Set to true to notify the remote endpoint that traffic should not be
3151 forwarded to this system for some reason other than a connectivty
3152 failure on the interface being monitored. The typical underlying
3153 reason is ``concatenated path down,'' that is, that connectivity
3154 beyond the local system is down. Defaults to false.
3155 </column>
3156
3157 <column name="bfd" key="check_tnl_key" type='{"type": "boolean"}'>
3158 Set to true to make BFD accept only control messages with a tunnel
3159 key of zero. By default, BFD accepts control messages with any
3160 tunnel key.
3161 </column>
3162
3163 <column name="bfd" key="bfd_local_src_mac">
3164 Set to an Ethernet address in the form
3165 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>
3166 to set the MAC used as source for transmitted BFD packets. The
3167 default is the mac address of the BFD enabled interface.
3168 </column>
3169
3170 <column name="bfd" key="bfd_local_dst_mac">
3171 Set to an Ethernet address in the form
3172 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>
3173 to set the MAC used as destination for transmitted BFD packets. The
3174 default is <code>00:23:20:00:00:01</code>.
3175 </column>
3176
3177 <column name="bfd" key="bfd_remote_dst_mac">
3178 Set to an Ethernet address in the form
3179 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>
3180 to set the MAC used for checking the destination of received BFD packets.
3181 Packets with different destination MAC will not be considered as BFD packets.
3182 If not specified the destination MAC address of received BFD packets
3183 are not checked.
3184 </column>
3185
3186 <column name="bfd" key="bfd_src_ip">
3187 Set to an IPv4 address to set the IP address used as source for
3188 transmitted BFD packets. The default is <code>169.254.1.1</code>.
3189 </column>
3190
3191 <column name="bfd" key="bfd_dst_ip">
3192 Set to an IPv4 address to set the IP address used as destination
3193 for transmitted BFD packets. The default is <code>169.254.1.0</code>.
3194 </column>
3195
3196 <column name="bfd" key="oam">
3197 Some tunnel protocols (such as Geneve) include a bit in the header
3198 to indicate that the encapsulated packet is an OAM frame. By setting
3199 this to true, BFD packets will be marked as OAM if encapsulated in
3200 one of these tunnels.
3201 </column>
3202
3203 <column name="bfd" key="mult"
3204 type='{"type": "integer", "minInteger": 1, "maxInteger": 255}'>
3205 The BFD detection multiplier, which defaults to 3. An endpoint
3206 signals a connectivity fault if the given number of consecutive BFD
3207 control messages fail to arrive.
3208 </column>
3209 </group>
3210
3211 <group title="BFD Status">
3212 <p>
3213 The switch sets key-value pairs in the <ref column="bfd_status"/>
3214 column to report the status of BFD on this interface. When BFD is
3215 not enabled, with <ref column="bfd" key="enable"/>, the switch clears
3216 all key-value pairs from <ref column="bfd_status"/>.
3217 </p>
3218
3219 <column name="bfd_status" key="state"
3220 type='{"type": "string",
3221 "enum": ["set", ["admin_down", "down", "init", "up"]]}'>
3222 Reports the state of the BFD session. The BFD session is fully
3223 healthy and negotiated if <code>UP</code>.
3224 </column>
3225
3226 <column name="bfd_status" key="forwarding" type='{"type": "boolean"}'>
3227 Reports whether the BFD session believes this <ref
3228 table="Interface"/> may be used to forward traffic. Typically this
3229 means the local session is signaling <code>UP</code>, and the remote
3230 system isn't signaling a problem such as concatenated path down.
3231 </column>
3232
3233 <column name="bfd_status" key="diagnostic">
3234 A diagnostic code specifying the local system's reason for the
3235 last change in session state. The error messages are defined in
3236 section 4.1 of [RFC 5880].
3237 </column>
3238
3239 <column name="bfd_status" key="remote_state"
3240 type='{"type": "string",
3241 "enum": ["set", ["admin_down", "down", "init", "up"]]}'>
3242 Reports the state of the remote endpoint's BFD session.
3243 </column>
3244
3245 <column name="bfd_status" key="remote_diagnostic">
3246 A diagnostic code specifying the remote system's reason for the
3247 last change in session state. The error messages are defined in
3248 section 4.1 of [RFC 5880].
3249 </column>
3250
3251 <column name="bfd_status" key="flap_count"
3252 type='{"type": "integer", "minInteger": 0}'>
3253 Counts the number of <ref column="bfd_status" key="forwarding" />
3254 flaps since start. A flap is considered as a change of the
3255 <ref column="bfd_status" key="forwarding" /> value.
3256 </column>
3257 </group>
3258 </group>
3259
3260 <group title="Connectivity Fault Management">
3261 <p>
3262 802.1ag Connectivity Fault Management (CFM) allows a group of
3263 Maintenance Points (MPs) called a Maintenance Association (MA) to
3264 detect connectivity problems with each other. MPs within a MA should
3265 have complete and exclusive interconnectivity. This is verified by
3266 occasionally broadcasting Continuity Check Messages (CCMs) at a
3267 configurable transmission interval.
3268 </p>
3269
3270 <p>
3271 According to the 802.1ag specification, each Maintenance Point should
3272 be configured out-of-band with a list of Remote Maintenance Points it
3273 should have connectivity to. Open vSwitch differs from the
3274 specification in this area. It simply assumes the link is faulted if
3275 no Remote Maintenance Points are reachable, and considers it not
3276 faulted otherwise.
3277 </p>
3278
3279 <p>
3280 When operating over tunnels which have no <code>in_key</code>, or an
3281 <code>in_key</code> of <code>flow</code>. CFM will only accept CCMs
3282 with a tunnel key of zero.
3283 </p>
3284
3285 <column name="cfm_mpid">
3286 <p>
3287 A Maintenance Point ID (MPID) uniquely identifies each endpoint
3288 within a Maintenance Association. The MPID is used to identify this
3289 endpoint to other Maintenance Points in the MA. Each end of a link
3290 being monitored should have a different MPID. Must be configured to
3291 enable CFM on this <ref table="Interface"/>.
3292 </p>
3293 <p>
3294 According to the 802.1ag specification, MPIDs can only range between
3295 [1, 8191]. However, extended mode (see <ref column="other_config"
3296 key="cfm_extended"/>) supports eight byte MPIDs.
3297 </p>
3298 </column>
3299
3300 <column name="cfm_flap_count">
3301 Counts the number of cfm fault flapps since boot. A flap is
3302 considered to be a change of the <ref column="cfm_fault"/> value.
3303 </column>
3304
3305 <column name="cfm_fault">
3306 <p>
3307 Indicates a connectivity fault triggered by an inability to receive
3308 heartbeats from any remote endpoint. When a fault is triggered on
3309 <ref table="Interface"/>s participating in bonds, they will be
3310 disabled.
3311 </p>
3312 <p>
3313 Faults can be triggered for several reasons. Most importantly they
3314 are triggered when no CCMs are received for a period of 3.5 times the
3315 transmission interval. Faults are also triggered when any CCMs
3316 indicate that a Remote Maintenance Point is not receiving CCMs but
3317 able to send them. Finally, a fault is triggered if a CCM is
3318 received which indicates unexpected configuration. Notably, this
3319 case arises when a CCM is received which advertises the local MPID.
3320 </p>
3321 </column>
3322
3323 <column name="cfm_fault_status" key="recv">
3324 Indicates a CFM fault was triggered due to a lack of CCMs received on
3325 the <ref table="Interface"/>.
3326 </column>
3327
3328 <column name="cfm_fault_status" key="rdi">
3329 Indicates a CFM fault was triggered due to the reception of a CCM with
3330 the RDI bit flagged. Endpoints set the RDI bit in their CCMs when they
3331 are not receiving CCMs themselves. This typically indicates a
3332 unidirectional connectivity failure.
3333 </column>
3334
3335 <column name="cfm_fault_status" key="maid">
3336 Indicates a CFM fault was triggered due to the reception of a CCM with
3337 a MAID other than the one Open vSwitch uses. CFM broadcasts are tagged
3338 with an identification number in addition to the MPID called the MAID.
3339 Open vSwitch only supports receiving CCM broadcasts tagged with the
3340 MAID it uses internally.
3341 </column>
3342
3343 <column name="cfm_fault_status" key="loopback">
3344 Indicates a CFM fault was triggered due to the reception of a CCM
3345 advertising the same MPID configured in the <ref column="cfm_mpid"/>
3346 column of this <ref table="Interface"/>. This may indicate a loop in
3347 the network.
3348 </column>
3349
3350 <column name="cfm_fault_status" key="overflow">
3351 Indicates a CFM fault was triggered because the CFM module received
3352 CCMs from more remote endpoints than it can keep track of.
3353 </column>
3354
3355 <column name="cfm_fault_status" key="override">
3356 Indicates a CFM fault was manually triggered by an administrator using
3357 an <code>ovs-appctl</code> command.
3358 </column>
3359
3360 <column name="cfm_fault_status" key="interval">
3361 Indicates a CFM fault was triggered due to the reception of a CCM
3362 frame having an invalid interval.
3363 </column>
3364
3365 <column name="cfm_remote_opstate">
3366 <p>When in extended mode, indicates the operational state of the
3367 remote endpoint as either <code>up</code> or <code>down</code>. See
3368 <ref column="other_config" key="cfm_opstate"/>.
3369 </p>
3370 </column>
3371
3372 <column name="cfm_health">
3373 <p>
3374 Indicates the health of the interface as a percentage of CCM frames
3375 received over 21 <ref column="other_config" key="cfm_interval"/>s.
3376 The health of an interface is undefined if it is communicating with
3377 more than one <ref column="cfm_remote_mpids"/>. It reduces if
3378 healthy heartbeats are not received at the expected rate, and
3379 gradually improves as healthy heartbeats are received at the desired
3380 rate. Every 21 <ref column="other_config" key="cfm_interval"/>s, the
3381 health of the interface is refreshed.
3382 </p>
3383 <p>
3384 As mentioned above, the faults can be triggered for several reasons.
3385 The link health will deteriorate even if heartbeats are received but
3386 they are reported to be unhealthy. An unhealthy heartbeat in this
3387 context is a heartbeat for which either some fault is set or is out
3388 of sequence. The interface health can be 100 only on receiving
3389 healthy heartbeats at the desired rate.
3390 </p>
3391 </column>
3392
3393 <column name="cfm_remote_mpids">
3394 When CFM is properly configured, Open vSwitch will occasionally
3395 receive CCM broadcasts. These broadcasts contain the MPID of the
3396 sending Maintenance Point. The list of MPIDs from which this
3397 <ref table="Interface"/> is receiving broadcasts from is regularly
3398 collected and written to this column.
3399 </column>
3400
3401 <column name="other_config" key="cfm_interval"
3402 type='{"type": "integer"}'>
3403 <p>
3404 The interval, in milliseconds, between transmissions of CFM
3405 heartbeats. Three missed heartbeat receptions indicate a
3406 connectivity fault.
3407 </p>
3408
3409 <p>
3410 In standard operation only intervals of 3, 10, 100, 1,000, 10,000,
3411 60,000, or 600,000 ms are supported. Other values will be rounded
3412 down to the nearest value on the list. Extended mode (see <ref
3413 column="other_config" key="cfm_extended"/>) supports any interval up
3414 to 65,535 ms. In either mode, the default is 1000 ms.
3415 </p>
3416
3417 <p>We do not recommend using intervals less than 100 ms.</p>
3418 </column>
3419
3420 <column name="other_config" key="cfm_extended"
3421 type='{"type": "boolean"}'>
3422 When <code>true</code>, the CFM module operates in extended mode. This
3423 causes it to use a nonstandard destination address to avoid conflicting
3424 with compliant implementations which may be running concurrently on the
3425 network. Furthermore, extended mode increases the accuracy of the
3426 <code>cfm_interval</code> configuration parameter by breaking wire
3427 compatibility with 802.1ag compliant implementations. And extended
3428 mode allows eight byte MPIDs. Defaults to <code>false</code>.
3429 </column>
3430
3431 <column name="other_config" key="cfm_demand" type='{"type": "boolean"}'>
3432 <p>
3433 When <code>true</code>, and
3434 <ref column="other_config" key="cfm_extended"/> is true, the CFM
3435 module operates in demand mode. When in demand mode, traffic
3436 received on the <ref table="Interface"/> is used to indicate
3437 liveness. CCMs are still transmitted and received. At least one
3438 CCM must be received every 100 * <ref column="other_config"
3439 key="cfm_interval"/> amount of time. Otherwise, even if traffic
3440 are received, the CFM module will raise the connectivity fault.
3441 </p>
3442
3443 <p>
3444 Demand mode has a couple of caveats:
3445 <ul>
3446 <li>
3447 To ensure that ovs-vswitchd has enough time to pull statistics
3448 from the datapath, the fault detection interval is set to
3449 3.5 * MAX(<ref column="other_config" key="cfm_interval"/>, 500)
3450 ms.
3451 </li>
3452
3453 <li>
3454 To avoid ambiguity, demand mode disables itself when there are
3455 multiple remote maintenance points.
3456 </li>
3457
3458 <li>
3459 If the <ref table="Interface"/> is heavily congested, CCMs
3460 containing the <ref column="other_config" key="cfm_opstate"/>
3461 status may be dropped causing changes in the operational state to
3462 be delayed. Similarly, if CCMs containing the RDI bit are not
3463 received, unidirectional link failures may not be detected.
3464 </li>
3465 </ul>
3466 </p>
3467 </column>
3468
3469 <column name="other_config" key="cfm_opstate"
3470 type='{"type": "string", "enum": ["set", ["down", "up"]]}'>
3471 When <code>down</code>, the CFM module marks all CCMs it generates as
3472 operationally down without triggering a fault. This allows remote
3473 maintenance points to choose not to forward traffic to the
3474 <ref table="Interface"/> on which this CFM module is running.
3475 Currently, in Open vSwitch, the opdown bit of CCMs affects
3476 <ref table="Interface"/>s participating in bonds, and the bundle
3477 OpenFlow action. This setting is ignored when CFM is not in extended
3478 mode. Defaults to <code>up</code>.
3479 </column>
3480
3481 <column name="other_config" key="cfm_ccm_vlan"
3482 type='{"type": "integer", "minInteger": 1, "maxInteger": 4095}'>
3483 When set, the CFM module will apply a VLAN tag to all CCMs it generates
3484 with the given value. May be the string <code>random</code> in which
3485 case each CCM will be tagged with a different randomly generated VLAN.
3486 </column>
3487
3488 <column name="other_config" key="cfm_ccm_pcp"
3489 type='{"type": "integer", "minInteger": 1, "maxInteger": 7}'>
3490 When set, the CFM module will apply a VLAN tag to all CCMs it generates
3491 with the given PCP value, the VLAN ID of the tag is governed by the
3492 value of <ref column="other_config" key="cfm_ccm_vlan"/>. If
3493 <ref column="other_config" key="cfm_ccm_vlan"/> is unset, a VLAN ID of
3494 zero is used.
3495 </column>
3496
3497 </group>
3498
3499 <group title="Bonding Configuration">
3500 <column name="other_config" key="lacp-port-id"
3501 type='{"type": "integer", "minInteger": 1, "maxInteger": 65535}'>
3502 The LACP port ID of this <ref table="Interface"/>. Port IDs are
3503 used in LACP negotiations to identify individual ports
3504 participating in a bond.
3505 </column>
3506
3507 <column name="other_config" key="lacp-port-priority"
3508 type='{"type": "integer", "minInteger": 1, "maxInteger": 65535}'>
3509 The LACP port priority of this <ref table="Interface"/>. In LACP
3510 negotiations <ref table="Interface"/>s with numerically lower
3511 priorities are preferred for aggregation.
3512 </column>
3513
3514 <column name="other_config" key="lacp-aggregation-key"
3515 type='{"type": "integer", "minInteger": 1, "maxInteger": 65535}'>
3516 The LACP aggregation key of this <ref table="Interface"/>. <ref
3517 table="Interface"/>s with different aggregation keys may not be active
3518 within a given <ref table="Port"/> at the same time.
3519 </column>
3520 </group>
3521
3522 <group title="Virtual Machine Identifiers">
3523 <p>
3524 These key-value pairs specifically apply to an interface that
3525 represents a virtual Ethernet interface connected to a virtual
3526 machine. These key-value pairs should not be present for other types
3527 of interfaces. Keys whose names end in <code>-uuid</code> have
3528 values that uniquely identify the entity in question. For a Citrix
3529 XenServer hypervisor, these values are UUIDs in RFC 4122 format.
3530 Other hypervisors may use other formats.
3531 </p>
3532
3533 <column name="external_ids" key="attached-mac">
3534 The MAC address programmed into the ``virtual hardware'' for this
3535 interface, in the form
3536 <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>.
3537 For Citrix XenServer, this is the value of the <code>MAC</code> field
3538 in the VIF record for this interface.
3539 </column>
3540
3541 <column name="external_ids" key="iface-id">
3542 A system-unique identifier for the interface. On XenServer, this will
3543 commonly be the same as <ref column="external_ids" key="xs-vif-uuid"/>.
3544 </column>
3545
3546 <column name="external_ids" key="iface-status"
3547 type='{"type": "string",
3548 "enum": ["set", ["active", "inactive"]]}'>
3549 <p>
3550 Hypervisors may sometimes have more than one interface associated
3551 with a given <ref column="external_ids" key="iface-id"/>, only one of
3552 which is actually in use at a given time. For example, in some
3553 circumstances XenServer has both a ``tap'' and a ``vif'' interface
3554 for a single <ref column="external_ids" key="iface-id"/>, but only
3555 uses one of them at a time. A hypervisor that behaves this way must
3556 mark the currently in use interface <code>active</code> and the
3557 others <code>inactive</code>. A hypervisor that never has more than
3558 one interface for a given <ref column="external_ids" key="iface-id"/>
3559 may mark that interface <code>active</code> or omit <ref
3560 column="external_ids" key="iface-status"/> entirely.
3561 </p>
3562
3563 <p>
3564 During VM migration, a given <ref column="external_ids"
3565 key="iface-id"/> might transiently be marked <code>active</code> on
3566 two different hypervisors. That is, <code>active</code> means that
3567 this <ref column="external_ids" key="iface-id"/> is the active
3568 instance within a single hypervisor, not in a broader scope.
3569 There is one exception: some hypervisors support ``migration'' from a
3570 given hypervisor to itself (most often for test purposes). During
3571 such a ``migration,'' two instances of a single <ref
3572 column="external_ids" key="iface-id"/> might both be briefly marked
3573 <code>active</code> on a single hypervisor.
3574 </p>
3575 </column>
3576
3577 <column name="external_ids" key="xs-vif-uuid">
3578 The virtual interface associated with this interface.
3579 </column>
3580
3581 <column name="external_ids" key="xs-network-uuid">
3582 The virtual network to which this interface is attached.
3583 </column>
3584
3585 <column name="external_ids" key="vm-id">
3586 The VM to which this interface belongs. On XenServer, this will be the
3587 same as <ref column="external_ids" key="xs-vm-uuid"/>.
3588 </column>
3589
3590 <column name="external_ids" key="xs-vm-uuid">
3591 The VM to which this interface belongs.
3592 </column>
3593 </group>
3594
3595 <group title="Auto Attach Configuration">
3596 <p>
3597 Auto Attach configuration for a particular interface.
3598 </p>
3599
3600 <column name="lldp" key="enable" type='{"type": "boolean"}'>
3601 True to enable LLDP on this <ref table="Interface"/>. If not
3602 specified, LLDP will be disabled by default.
3603 </column>
3604 </group>
3605
3606 <group title="Flow control Configuration">
3607 <p>
3608 Ethernet flow control defined in IEEE 802.1Qbb provides link level flow
3609 control using MAC pause frames. Implemented only for interfaces with
3610 type <code>dpdk</code>.
3611 </p>
3612
3613 <column name="options" key="rx-flow-ctrl" type='{"type": "boolean"}'>
3614 Set to <code>true</code> to enable Rx flow control on physical ports.
3615 By default, Rx flow control is disabled.
3616 </column>
3617
3618 <column name="options" key="tx-flow-ctrl" type='{"type": "boolean"}'>
3619 Set to <code>true</code> to enable Tx flow control on physical ports.
3620 By default, Tx flow control is disabled.
3621 </column>
3622
3623 <column name="options" key="flow-ctrl-autoneg"
3624 type='{"type": "boolean"}'>
3625 Set to <code>true</code> to enable flow control auto negotiation on
3626 physical ports. By default, auto-neg is disabled.
3627 </column>
3628 </group>
3629
3630 <group title="Common Columns">
3631 The overall purpose of these columns is described under <code>Common
3632 Columns</code> at the beginning of this document.
3633
3634 <column name="other_config"/>
3635 <column name="external_ids"/>
3636 </group>
3637 </table>
3638
3639 <table name="Flow_Table" title="OpenFlow table configuration">
3640 <p>Configuration for a particular OpenFlow table.</p>
3641
3642 <column name="name">
3643 The table's name. Set this column to change the name that controllers
3644 will receive when they request table statistics, e.g. <code>ovs-ofctl
3645 dump-tables</code>. The name does not affect switch behavior.
3646 </column>
3647
3648 <group title="Eviction Policy">
3649 <p>
3650 Open vSwitch supports limiting the number of flows that may be
3651 installed in a flow table, via the <ref column="flow_limit"/> column.
3652 When adding a flow would exceed this limit, by default Open vSwitch
3653 reports an error, but there are two ways to configure Open vSwitch to
3654 instead delete (``evict'') a flow to make room for the new one:
3655 </p>
3656
3657 <ul>
3658 <li>
3659 Set the <ref column="overflow_policy"/> column to <code>evict</code>.
3660 </li>
3661
3662 <li>
3663 Send an OpenFlow 1.4+ ``table mod request'' to enable eviction for
3664 the flow table (e.g. <code>ovs-ofctl -O OpenFlow14 mod-table br0 0
3665 evict</code> to enable eviction on flow table 0 of bridge
3666 <code>br0</code>).
3667 </li>
3668 </ul>
3669
3670 <p>
3671 When a flow must be evicted due to overflow, the flow to evict is
3672 chosen through an approximation of the following algorithm. This
3673 algorithm is used regardless of how eviction was enabled:
3674 </p>
3675
3676 <ol>
3677 <li>
3678 Divide the flows in the table into groups based on the values of the
3679 fields or subfields specified in the <ref column="groups"/> column,
3680 so that all of the flows in a given group have the same values for
3681 those fields. If a flow does not specify a given field, that field's
3682 value is treated as 0. If <ref column="groups"/> is empty, then all
3683 of the flows in the flow table are treated as a single group.
3684 </li>
3685
3686 <li>
3687 Consider the flows in the largest group, that is, the group that
3688 contains the greatest number of flows. If two or more groups all
3689 have the same largest number of flows, consider the flows in all of
3690 those groups.
3691 </li>
3692
3693 <li>
3694 If the flows under consideration have different importance values,
3695 eliminate from consideration any flows except those with the lowest
3696 importance. (``Importance,'' a 16-bit integer value attached to each
3697 flow, was introduced in OpenFlow 1.4. Flows inserted with older
3698 versions of OpenFlow always have an importance of 0.)
3699 </li>
3700
3701 <li>
3702 Among the flows under consideration, choose the flow that expires
3703 soonest for eviction.
3704 </li>
3705 </ol>
3706
3707 <p>
3708 The eviction process only considers flows that have an idle timeout
3709 or a hard timeout. That is, eviction never deletes permanent flows.
3710 (Permanent flows do count against <ref column="flow_limit"/>.)
3711 </p>
3712
3713 <column name="flow_limit">
3714 If set, limits the number of flows that may be added to the table.
3715 Open vSwitch may limit the number of flows in a table for other
3716 reasons, e.g. due to hardware limitations or for resource availability
3717 or performance reasons.
3718 </column>
3719
3720 <column name="overflow_policy">
3721 <p>
3722 Controls the switch's behavior when an OpenFlow flow table
3723 modification request would add flows in excess of <ref
3724 column="flow_limit"/>. The supported values are:
3725 </p>
3726
3727 <dl>
3728 <dt><code>refuse</code></dt>
3729 <dd>
3730 Refuse to add the flow or flows. This is also the default policy
3731 when <ref column="overflow_policy"/> is unset.
3732 </dd>
3733
3734 <dt><code>evict</code></dt>
3735 <dd>
3736 Delete a flow chosen according to the algorithm described above.
3737 </dd>
3738 </dl>
3739 </column>
3740
3741 <column name="groups">
3742 <p>
3743 When <ref column="overflow_policy"/> is <code>evict</code>, this
3744 controls how flows are chosen for eviction when the flow table would
3745 otherwise exceed <ref column="flow_limit"/> flows. Its value is a
3746 set of NXM fields or sub-fields, each of which takes one of the forms
3747 <code><var>field</var>[]</code> or
3748 <code><var>field</var>[<var>start</var>..<var>end</var>]</code>,
3749 e.g. <code>NXM_OF_IN_PORT[]</code>. Please see
3750 <code>meta-flow.h</code> for a complete list of NXM field names.
3751 </p>
3752
3753 <p>
3754 Open vSwitch ignores any invalid or unknown field specifications.
3755 </p>
3756
3757 <p>
3758 When eviction is not enabled, via <ref column="overflow_policy"/> or
3759 an OpenFlow 1.4+ ``table mod,'' this column has no effect.
3760 </p>
3761 </column>
3762 </group>
3763
3764 <group title="Classifier Optimization">
3765 <column name="prefixes">
3766 <p>
3767 This string set specifies which fields should be used for
3768 address prefix tracking. Prefix tracking allows the
3769 classifier to skip rules with longer than necessary prefixes,
3770 resulting in better wildcarding for datapath flows.
3771 </p>
3772 <p>
3773 Prefix tracking may be beneficial when a flow table contains
3774 matches on IP address fields with different prefix lengths.
3775 For example, when a flow table contains IP address matches on
3776 both full addresses and proper prefixes, the full address
3777 matches will typically cause the datapath flow to un-wildcard
3778 the whole address field (depending on flow entry priorities).
3779 In this case each packet with a different address gets handed
3780 to the userspace for flow processing and generates its own
3781 datapath flow. With prefix tracking enabled for the address
3782 field in question packets with addresses matching shorter
3783 prefixes would generate datapath flows where the irrelevant
3784 address bits are wildcarded, allowing the same datapath flow
3785 to handle all the packets within the prefix in question. In
3786 this case many userspace upcalls can be avoided and the
3787 overall performance can be better.
3788 </p>
3789 <p>
3790 This is a performance optimization only, so packets will
3791 receive the same treatment with or without prefix tracking.
3792 </p>
3793 <p>
3794 The supported fields are: <code>tun_id</code>,
3795 <code>tun_src</code>, <code>tun_dst</code>,
3796 <code>tun_ipv6_src</code>, <code>tun_ipv6_dst</code>,
3797 <code>nw_src</code>, <code>nw_dst</code> (or aliases
3798 <code>ip_src</code> and <code>ip_dst</code>),
3799 <code>ipv6_src</code>, and <code>ipv6_dst</code>. (Using this
3800 feature for <code>tun_id</code> would only make sense if the
3801 tunnel IDs have prefix structure similar to IP addresses.)
3802 </p>
3803
3804 <p>
3805 By default, the <code>prefixes=ip_dst,ip_src</code> are used
3806 on each flow table. This instructs the flow classifier to
3807 track the IP destination and source addresses used by the
3808 rules in this specific flow table.
3809 </p>
3810
3811 <p>
3812 The keyword <code>none</code> is recognized as an explicit
3813 override of the default values, causing no prefix fields to be
3814 tracked.
3815 </p>
3816
3817 <p>
3818 To set the prefix fields, the flow table record needs to
3819 exist:
3820 </p>
3821
3822 <dl>
3823 <dt><code>ovs-vsctl set Bridge br0 flow_tables:0=@N1 -- --id=@N1 create Flow_Table name=table0</code></dt>
3824 <dd>
3825 Creates a flow table record for the OpenFlow table number 0.
3826 </dd>
3827
3828 <dt><code>ovs-vsctl set Flow_Table table0 prefixes=ip_dst,ip_src</code></dt>
3829 <dd>
3830 Enables prefix tracking for IP source and destination
3831 address fields.
3832 </dd>
3833 </dl>
3834
3835 <p>
3836 There is a maximum number of fields that can be enabled for any
3837 one flow table. Currently this limit is 3.
3838 </p>
3839 </column>
3840 </group>
3841
3842 <group title="Common Columns">
3843 The overall purpose of these columns is described under <code>Common
3844 Columns</code> at the beginning of this document.
3845
3846 <column name="external_ids"/>
3847 </group>
3848 </table>
3849
3850 <table name="QoS" title="Quality of Service configuration">
3851 <p>Quality of Service (QoS) configuration for each Port that
3852 references it.</p>
3853
3854 <column name="type">
3855 <p>The type of QoS to implement. The currently defined types are
3856 listed below:</p>
3857 <dl>
3858 <dt><code>linux-htb</code></dt>
3859 <dd>
3860 Linux ``hierarchy token bucket'' classifier. See tc-htb(8) (also at
3861 <code>http://linux.die.net/man/8/tc-htb</code>) and the HTB manual
3862 (<code>http://luxik.cdi.cz/~devik/qos/htb/manual/userg.htm</code>)
3863 for information on how this classifier works and how to configure it.
3864 </dd>
3865
3866 <dt><code>linux-hfsc</code></dt>
3867 <dd>
3868 Linux "Hierarchical Fair Service Curve" classifier.
3869 See <code>http://linux-ip.net/articles/hfsc.en/</code> for
3870 information on how this classifier works.
3871 </dd>
3872
3873 <dt><code>linux-sfq</code></dt>
3874 <dd>
3875 Linux ``Stochastic Fairness Queueing'' classifier. See
3876 <code>tc-sfq</code>(8) (also at
3877 <code>http://linux.die.net/man/8/tc-sfq</code>) for information on
3878 how this classifier works.
3879 </dd>
3880
3881 <dt><code>linux-codel</code></dt>
3882 <dd>
3883 Linux ``Controlled Delay'' classifier. See <code>tc-codel</code>(8)
3884 (also at
3885 <code>http://man7.org/linux/man-pages/man8/tc-codel.8.html</code>)
3886 for information on how this classifier works.
3887 </dd>
3888
3889 <dt><code>linux-fq_codel</code></dt>
3890 <dd>
3891 Linux ``Fair Queuing with Controlled Delay'' classifier. See
3892 <code>tc-fq_codel</code>(8) (also at
3893 <code>http://man7.org/linux/man-pages/man8/tc-fq_codel.8.html</code>)
3894 for information on how this classifier works.
3895 </dd>
3896
3897 <dt><code>linux-noop</code></dt>
3898 <dd>
3899 Linux ``No operation.'' By default, Open vSwitch manages quality of
3900 service on all of its configured ports. This can be helpful, but
3901 sometimes administrators prefer to use other software to manage QoS.
3902 This <ref column="type"/> prevents Open vSwitch from changing the QoS
3903 configuration for a port.
3904 </dd>
3905
3906 <dt><code>egress-policer</code></dt>
3907 <dd>
3908 A DPDK egress policer algorithm using the DPDK
3909 rte_meter library. The rte_meter library provides an implementation
3910 which allows the metering and policing of traffic. The implementation
3911 in OVS essentially creates a single token bucket used to police
3912 traffic. It should be noted that when the rte_meter is configured as
3913 part of QoS there will be a performance overhead as the rte_meter
3914 itself will consume CPU cycles in order to police traffic. These CPU
3915 cycles ordinarily are used for packet proccessing. As such the drop
3916 in performance will be noticed in terms of overall aggregate traffic
3917 throughput.
3918 </dd>
3919 </dl>
3920 </column>
3921
3922 <column name="queues">
3923 <p>A map from queue numbers to <ref table="Queue"/> records. The
3924 supported range of queue numbers depend on <ref column="type"/>. The
3925 queue numbers are the same as the <code>queue_id</code> used in
3926 OpenFlow in <code>struct ofp_action_enqueue</code> and other
3927 structures.</p>
3928
3929 <p>
3930 Queue 0 is the ``default queue.'' It is used by OpenFlow output
3931 actions when no specific queue has been set. When no configuration for
3932 queue 0 is present, it is automatically configured as if a <ref
3933 table="Queue"/> record with empty <ref table="Queue" column="dscp"/>
3934 and <ref table="Queue" column="other_config"/> columns had been
3935 specified.
3936 (Before version 1.6, Open vSwitch would leave queue 0 unconfigured in
3937 this case. With some queuing disciplines, this dropped all packets
3938 destined for the default queue.)
3939 </p>
3940 </column>
3941
3942 <group title="Configuration for linux-htb and linux-hfsc">
3943 <p>
3944 The <code>linux-htb</code> and <code>linux-hfsc</code> classes support
3945 the following key-value pair:
3946 </p>
3947
3948 <column name="other_config" key="max-rate" type='{"type": "integer"}'>
3949 Maximum rate shared by all queued traffic, in bit/s. Optional. If not
3950 specified, for physical interfaces, the default is the link rate. For
3951 other interfaces or if the link rate cannot be determined, the default
3952 is currently 100 Mbps.
3953 </column>
3954 </group>
3955
3956 <group title="Configuration for egress-policer QoS">
3957 <p>
3958 <ref table="QoS"/> <ref table="QoS" column="type"/>
3959 <code>egress-policer</code> provides egress policing for userspace
3960 port types with DPDK.
3961
3962 It has the following key-value pairs defined.
3963 </p>
3964
3965 <column name="other_config" key="cir" type='{"type": "integer"}'>
3966 The Committed Information Rate (CIR) is measured in bytes of IP
3967 packets per second, i.e. it includes the IP header, but not link
3968 specific (e.g. Ethernet) headers. This represents the bytes per second
3969 rate at which the token bucket will be updated. The cir value is
3970 calculated by (pps x packet data size). For example assuming a user
3971 wishes to limit a stream consisting of 64 byte packets to 1 million
3972 packets per second the CIR would be set to to to 46000000. This value
3973 can be broken into '1,000,000 x 46'. Where 1,000,000 is the policing
3974 rate for the number of packets per second and 46 represents the size
3975 of the packet data for a 64 byte ip packet.
3976 </column>
3977 <column name="other_config" key="cbs" type='{"type": "integer"}'>
3978 The Committed Burst Size (CBS) is measured in bytes and represents a
3979 token bucket. At a minimum this value should be be set to the expected
3980 largest size packet in the traffic stream. In practice larger values
3981 may be used to increase the size of the token bucket. If a packet can
3982 be transmitted then the cbs will be decremented by the number of
3983 bytes/tokens of the packet. If there are not enough tokens in the cbs
3984 bucket the packet will be dropped.
3985 </column>
3986 </group>
3987
3988 <group title="Configuration for linux-sfq">
3989 <p>
3990 The <code>linux-sfq</code> QoS supports the following key-value pairs:
3991 </p>
3992
3993 <column name="other_config" key="perturb" type='{"type": "integer"}'>
3994 Number of seconds between consecutive perturbations in hashing algorithm.
3995 Different flows can end up in the same hash bucket causing unfairness.
3996 Perturbation's goal is to remove possible unfairness.
3997 The default and recommended value is 10. Too low a value is discouraged
3998 because each perturbation can cause packet reordering.
3999 </column>
4000 <column name="other_config" key="quantum" type='{"type": "integer"}'>
4001 Number of bytes <code>linux-sfq</code> QoS can dequeue in one turn in
4002 round-robin from one flow. The default and recommended value is equal
4003 to interface's MTU.
4004 </column>
4005 </group>
4006
4007 <group title="Common Columns">
4008 The overall purpose of these columns is described under <code>Common
4009 Columns</code> at the beginning of this document.
4010
4011 <column name="other_config"/>
4012 <column name="external_ids"/>
4013 </group>
4014 </table>
4015
4016 <table name="Queue" title="QoS output queue.">
4017 <p>A configuration for a port output queue, used in configuring Quality of
4018 Service (QoS) features. May be referenced by <ref column="queues"
4019 table="QoS"/> column in <ref table="QoS"/> table.</p>
4020
4021 <column name="dscp">
4022 If set, Open vSwitch will mark all traffic egressing this
4023 <ref table="Queue"/> with the given DSCP bits. Traffic egressing the
4024 default <ref table="Queue"/> is only marked if it was explicitly selected
4025 as the <ref table="Queue"/> at the time the packet was output. If unset,
4026 the DSCP bits of traffic egressing this <ref table="Queue"/> will remain
4027 unchanged.
4028 </column>
4029
4030 <group title="Configuration for linux-htb QoS">
4031 <p>
4032 <ref table="QoS"/> <ref table="QoS" column="type"/>
4033 <code>linux-htb</code> may use <code>queue_id</code>s less than 61440.
4034 It has the following key-value pairs defined.
4035 </p>
4036
4037 <column name="other_config" key="min-rate"
4038 type='{"type": "integer", "minInteger": 1}'>
4039 Minimum guaranteed bandwidth, in bit/s.
4040 </column>
4041
4042 <column name="other_config" key="max-rate"
4043 type='{"type": "integer", "minInteger": 1}'>
4044 Maximum allowed bandwidth, in bit/s. Optional. If specified, the
4045 queue's rate will not be allowed to exceed the specified value, even
4046 if excess bandwidth is available. If unspecified, defaults to no
4047 limit.
4048 </column>
4049
4050 <column name="other_config" key="burst"
4051 type='{"type": "integer", "minInteger": 1}'>
4052 Burst size, in bits. This is the maximum amount of ``credits'' that a
4053 queue can accumulate while it is idle. Optional. Details of the
4054 <code>linux-htb</code> implementation require a minimum burst size, so
4055 a too-small <code>burst</code> will be silently ignored.
4056 </column>
4057
4058 <column name="other_config" key="priority"
4059 type='{"type": "integer", "minInteger": 0, "maxInteger": 4294967295}'>
4060 A queue with a smaller <code>priority</code> will receive all the
4061 excess bandwidth that it can use before a queue with a larger value
4062 receives any. Specific priority values are unimportant; only relative
4063 ordering matters. Defaults to 0 if unspecified.
4064 </column>
4065 </group>
4066
4067 <group title="Configuration for linux-hfsc QoS">
4068 <p>
4069 <ref table="QoS"/> <ref table="QoS" column="type"/>
4070 <code>linux-hfsc</code> may use <code>queue_id</code>s less than 61440.
4071 It has the following key-value pairs defined.
4072 </p>
4073
4074 <column name="other_config" key="min-rate"
4075 type='{"type": "integer", "minInteger": 1}'>
4076 Minimum guaranteed bandwidth, in bit/s.
4077 </column>
4078
4079 <column name="other_config" key="max-rate"
4080 type='{"type": "integer", "minInteger": 1}'>
4081 Maximum allowed bandwidth, in bit/s. Optional. If specified, the
4082 queue's rate will not be allowed to exceed the specified value, even if
4083 excess bandwidth is available. If unspecified, defaults to no
4084 limit.
4085 </column>
4086 </group>
4087
4088 <group title="Common Columns">
4089 The overall purpose of these columns is described under <code>Common
4090 Columns</code> at the beginning of this document.
4091
4092 <column name="other_config"/>
4093 <column name="external_ids"/>
4094 </group>
4095 </table>
4096
4097 <table name="Mirror" title="Port mirroring.">
4098 <p>A port mirror within a <ref table="Bridge"/>.</p>
4099 <p>A port mirror configures a bridge to send selected frames to special
4100 ``mirrored'' ports, in addition to their normal destinations. Mirroring
4101 traffic may also be referred to as SPAN or RSPAN, depending on how
4102 the mirrored traffic is sent.</p>
4103
4104 <p>
4105 When a packet enters an Open vSwitch bridge, it becomes eligible for
4106 mirroring based on its ingress port and VLAN. As the packet travels
4107 through the flow tables, each time it is output to a port, it becomes
4108 eligible for mirroring based on the egress port and VLAN. In Open
4109 vSwitch 2.5 and later, mirroring occurs just after a packet first becomes
4110 eligible, using the packet as it exists at that point; in Open vSwitch
4111 2.4 and earlier, mirroring occurs only after a packet has traversed all
4112 the flow tables, using the original packet as it entered the bridge.
4113 This makes a difference only when the flow table modifies the packet: in
4114 Open vSwitch 2.4, the modifications are never visible to mirrors, whereas
4115 in Open vSwitch 2.5 and later modifications made before the first output
4116 that makes it eligible for mirroring to a particular destination are
4117 visible.
4118 </p>
4119
4120 <p>
4121 A packet that enters an Open vSwitch bridge is mirrored to a particular
4122 destination only once, even if it is eligible for multiple reasons. For
4123 example, a packet would be mirrored to a particular <ref
4124 column="output_port"/> only once, even if it is selected for mirroring to
4125 that port by <ref column="select_dst_port"/> and <ref
4126 column="select_src_port"/> in the same or different <ref table="Mirror"/>
4127 records.
4128 </p>
4129
4130 <column name="name">
4131 Arbitrary identifier for the <ref table="Mirror"/>.
4132 </column>
4133
4134 <group title="Selecting Packets for Mirroring">
4135 <p>
4136 To be selected for mirroring, a given packet must enter or leave the
4137 bridge through a selected port and it must also be in one of the
4138 selected VLANs.
4139 </p>
4140
4141 <column name="select_all">
4142 If true, every packet arriving or departing on any port is
4143 selected for mirroring.
4144 </column>
4145
4146 <column name="select_dst_port">
4147 Ports on which departing packets are selected for mirroring.
4148 </column>
4149
4150 <column name="select_src_port">
4151 Ports on which arriving packets are selected for mirroring.
4152 </column>
4153
4154 <column name="select_vlan">
4155 VLANs on which packets are selected for mirroring. An empty set
4156 selects packets on all VLANs.
4157 </column>
4158 </group>
4159
4160 <group title="Mirroring Destination Configuration">
4161 <p>
4162 These columns are mutually exclusive. Exactly one of them must be
4163 nonempty.
4164 </p>
4165
4166 <column name="output_port">
4167 <p>Output port for selected packets, if nonempty.</p>
4168 <p>Specifying a port for mirror output reserves that port exclusively
4169 for mirroring. No frames other than those selected for mirroring
4170 via this column
4171 will be forwarded to the port, and any frames received on the port
4172 will be discarded.</p>
4173 <p>
4174 The output port may be any kind of port supported by Open vSwitch.
4175 It may be, for example, a physical port (sometimes called SPAN) or a
4176 GRE tunnel.
4177 </p>
4178 </column>
4179
4180 <column name="output_vlan">
4181 <p>Output VLAN for selected packets, if nonempty.</p>
4182 <p>The frames will be sent out all ports that trunk
4183 <ref column="output_vlan"/>, as well as any ports with implicit VLAN
4184 <ref column="output_vlan"/>. When a mirrored frame is sent out a
4185 trunk port, the frame's VLAN tag will be set to
4186 <ref column="output_vlan"/>, replacing any existing tag; when it is
4187 sent out an implicit VLAN port, the frame will not be tagged. This
4188 type of mirroring is sometimes called RSPAN.</p>
4189 <p>
4190 See the documentation for
4191 <ref column="other_config" key="forward-bpdu"/> in the
4192 <ref table="Interface"/> table for a list of destination MAC
4193 addresses which will not be mirrored to a VLAN to avoid confusing
4194 switches that interpret the protocols that they represent.
4195 </p>
4196 <p><em>Please note:</em> Mirroring to a VLAN can disrupt a network that
4197 contains unmanaged switches. Consider an unmanaged physical switch
4198 with two ports: port 1, connected to an end host, and port 2,
4199 connected to an Open vSwitch configured to mirror received packets
4200 into VLAN 123 on port 2. Suppose that the end host sends a packet on
4201 port 1 that the physical switch forwards to port 2. The Open vSwitch
4202 forwards this packet to its destination and then reflects it back on
4203 port 2 in VLAN 123. This reflected packet causes the unmanaged
4204 physical switch to replace the MAC learning table entry, which
4205 correctly pointed to port 1, with one that incorrectly points to port
4206 2. Afterward, the physical switch will direct packets destined for
4207 the end host to the Open vSwitch on port 2, instead of to the end
4208 host on port 1, disrupting connectivity. If mirroring to a VLAN is
4209 desired in this scenario, then the physical switch must be replaced
4210 by one that learns Ethernet addresses on a per-VLAN basis. In
4211 addition, learning should be disabled on the VLAN containing mirrored
4212 traffic. If this is not done then intermediate switches will learn
4213 the MAC address of each end host from the mirrored traffic. If
4214 packets being sent to that end host are also mirrored, then they will
4215 be dropped since the switch will attempt to send them out the input
4216 port. Disabling learning for the VLAN will cause the switch to
4217 correctly send the packet out all ports configured for that VLAN. If
4218 Open vSwitch is being used as an intermediate switch, learning can be
4219 disabled by adding the mirrored VLAN to <ref column="flood_vlans"/>
4220 in the appropriate <ref table="Bridge"/> table or tables.</p>
4221 <p>
4222 Mirroring to a GRE tunnel has fewer caveats than mirroring to a
4223 VLAN and should generally be preferred.
4224 </p>
4225 </column>
4226
4227 <column name="snaplen">
4228 <p>Maximum per-packet number of bytes to mirror.</p>
4229 <p>A mirrored packet with size larger than <ref column="snaplen"/>
4230 will be truncated in datapath to <ref column="snaplen"/> bytes
4231 before sending to the mirror output port. If omitted, packets
4232 are not truncated.
4233 </p>
4234 </column>
4235 </group>
4236
4237 <group title="Statistics: Mirror counters">
4238 <p>
4239 Key-value pairs that report mirror statistics. The update period
4240 is controlled by <ref column="other_config"
4241 key="stats-update-interval"/> in the <code>Open_vSwitch</code> table.
4242 </p>
4243 <column name="statistics" key="tx_packets">
4244 Number of packets transmitted through this mirror.
4245 </column>
4246 <column name="statistics" key="tx_bytes">
4247 Number of bytes transmitted through this mirror.
4248 </column>
4249 </group>
4250
4251 <group title="Common Columns">
4252 The overall purpose of these columns is described under <code>Common
4253 Columns</code> at the beginning of this document.
4254
4255 <column name="external_ids"/>
4256 </group>
4257 </table>
4258
4259 <table name="Controller" title="OpenFlow controller configuration.">
4260 <p>An OpenFlow controller.</p>
4261
4262 <p>
4263 Open vSwitch supports two kinds of OpenFlow controllers:
4264 </p>
4265
4266 <dl>
4267 <dt>Primary controllers</dt>
4268 <dd>
4269 <p>
4270 This is the kind of controller envisioned by the OpenFlow 1.0
4271 specification. Usually, a primary controller implements a network
4272 policy by taking charge of the switch's flow table.
4273 </p>
4274
4275 <p>
4276 Open vSwitch initiates and maintains persistent connections to
4277 primary controllers, retrying the connection each time it fails or
4278 drops. The <ref table="Bridge" column="fail_mode"/> column in the
4279 <ref table="Bridge"/> table applies to primary controllers.
4280 </p>
4281
4282 <p>
4283 Open vSwitch permits a bridge to have any number of primary
4284 controllers. When multiple controllers are configured, Open
4285 vSwitch connects to all of them simultaneously. Because
4286 OpenFlow 1.0 does not specify how multiple controllers
4287 coordinate in interacting with a single switch, more than
4288 one primary controller should be specified only if the
4289 controllers are themselves designed to coordinate with each
4290 other. (The Nicira-defined <code>NXT_ROLE</code> OpenFlow
4291 vendor extension may be useful for this.)
4292 </p>
4293 </dd>
4294 <dt>Service controllers</dt>
4295 <dd>
4296 <p>
4297 These kinds of OpenFlow controller connections are intended for
4298 occasional support and maintenance use, e.g. with
4299 <code>ovs-ofctl</code>. Usually a service controller connects only
4300 briefly to inspect or modify some of a switch's state.
4301 </p>
4302
4303 <p>
4304 Open vSwitch listens for incoming connections from service
4305 controllers. The service controllers initiate and, if necessary,
4306 maintain the connections from their end. The <ref table="Bridge"
4307 column="fail_mode"/> column in the <ref table="Bridge"/> table does
4308 not apply to service controllers.
4309 </p>
4310
4311 <p>
4312 Open vSwitch supports configuring any number of service controllers.
4313 </p>
4314 </dd>
4315 </dl>
4316
4317 <p>
4318 The <ref column="target"/> determines the type of controller.
4319 </p>
4320
4321 <group title="Core Features">
4322 <column name="target">
4323 <p>Connection method for controller.</p>
4324 <p>
4325 The following connection methods are currently supported for primary
4326 controllers:
4327 </p>
4328 <dl>
4329 <dt><code>ssl:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
4330 <dd>
4331 <p>The specified SSL <var>port</var> on the host at the
4332 given <var>ip</var>, which must be expressed as an IP
4333 address (not a DNS name). The <ref table="Open_vSwitch"
4334 column="ssl"/> column in the <ref table="Open_vSwitch"/>
4335 table must point to a valid SSL configuration when this form
4336 is used.</p>
4337 <p>If <var>port</var> is not specified, it defaults to 6653.</p>
4338 <p>SSL support is an optional feature that is not always built as
4339 part of Open vSwitch.</p>
4340 </dd>
4341 <dt><code>tcp:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
4342 <dd>
4343 <p>
4344 The specified TCP <var>port</var> on the host at the given
4345 <var>ip</var>, which must be expressed as an IP address (not a
4346 DNS name), where <var>ip</var> can be IPv4 or IPv6 address. If
4347 <var>ip</var> is an IPv6 address, wrap it in square brackets,
4348 e.g. <code>tcp:[::1]:6653</code>.
4349 </p>
4350 <p>
4351 If <var>port</var> is not specified, it defaults to 6653.
4352 </p>
4353 </dd>
4354 </dl>
4355 <p>
4356 The following connection methods are currently supported for service
4357 controllers:
4358 </p>
4359 <dl>
4360 <dt><code>pssl:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
4361 <dd>
4362 <p>
4363 Listens for SSL connections on the specified TCP <var>port</var>.
4364 If <var>ip</var>, which must be expressed as an IP address (not a
4365 DNS name), is specified, then connections are restricted to the
4366 specified local IP address (either IPv4 or IPv6). If
4367 <var>ip</var> is an IPv6 address, wrap it in square brackets,
4368 e.g. <code>pssl:6653:[::1]</code>.
4369 </p>
4370 <p>
4371 If <var>port</var> is not specified, it defaults to
4372 6653. If <var>ip</var> is not specified then it listens only on
4373 IPv4 (but not IPv6) addresses. The
4374 <ref table="Open_vSwitch" column="ssl"/>
4375 column in the <ref table="Open_vSwitch"/> table must point to a
4376 valid SSL configuration when this form is used.
4377 </p>
4378 <p>
4379 If <var>port</var> is not specified, it currently to 6653.
4380 </p>
4381 <p>
4382 SSL support is an optional feature that is not always built as
4383 part of Open vSwitch.
4384 </p>
4385 </dd>
4386 <dt><code>ptcp:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
4387 <dd>
4388 <p>
4389 Listens for connections on the specified TCP <var>port</var>. If
4390 <var>ip</var>, which must be expressed as an IP address (not a
4391 DNS name), is specified, then connections are restricted to the
4392 specified local IP address (either IPv4 or IPv6). If
4393 <var>ip</var> is an IPv6 address, wrap it in square brackets,
4394 e.g. <code>ptcp:6653:[::1]</code>. If <var>ip</var> is not
4395 specified then it listens only on IPv4 addresses.
4396 </p>
4397 <p>
4398 If <var>port</var> is not specified, it defaults to 6653.
4399 </p>
4400 </dd>
4401 </dl>
4402 <p>When multiple controllers are configured for a single bridge, the
4403 <ref column="target"/> values must be unique. Duplicate
4404 <ref column="target"/> values yield unspecified results.</p>
4405 </column>
4406
4407 <column name="connection_mode">
4408 <p>If it is specified, this setting must be one of the following
4409 strings that describes how Open vSwitch contacts this OpenFlow
4410 controller over the network:</p>
4411
4412 <dl>
4413 <dt><code>in-band</code></dt>
4414 <dd>In this mode, this controller's OpenFlow traffic travels over the
4415 bridge associated with the controller. With this setting, Open
4416 vSwitch allows traffic to and from the controller regardless of the
4417 contents of the OpenFlow flow table. (Otherwise, Open vSwitch
4418 would never be able to connect to the controller, because it did
4419 not have a flow to enable it.) This is the most common connection
4420 mode because it is not necessary to maintain two independent
4421 networks.</dd>
4422 <dt><code>out-of-band</code></dt>
4423 <dd>In this mode, OpenFlow traffic uses a control network separate
4424 from the bridge associated with this controller, that is, the
4425 bridge does not use any of its own network devices to communicate
4426 with the controller. The control network must be configured
4427 separately, before or after <code>ovs-vswitchd</code> is started.
4428 </dd>
4429 </dl>
4430
4431 <p>If not specified, the default is implementation-specific.</p>
4432 </column>
4433 </group>
4434
4435 <group title="Controller Failure Detection and Handling">
4436 <column name="max_backoff">
4437 Maximum number of milliseconds to wait between connection attempts.
4438 Default is implementation-specific.
4439 </column>
4440
4441 <column name="inactivity_probe">
4442 Maximum number of milliseconds of idle time on connection to
4443 controller before sending an inactivity probe message. If Open
4444 vSwitch does not communicate with the controller for the specified
4445 number of seconds, it will send a probe. If a response is not
4446 received for the same additional amount of time, Open vSwitch
4447 assumes the connection has been broken and attempts to reconnect.
4448 Default is implementation-specific. A value of 0 disables
4449 inactivity probes.
4450 </column>
4451 </group>
4452
4453 <group title="Asynchronous Messages">
4454 <p>
4455 OpenFlow switches send certain messages to controllers spontanenously,
4456 that is, not in response to any request from the controller. These
4457 messages are called ``asynchronous messages.'' These columns allow
4458 asynchronous messages to be limited or disabled to ensure the best use
4459 of network resources.
4460 </p>
4461
4462 <column name="enable_async_messages">
4463 The OpenFlow protocol enables asynchronous messages at time of
4464 connection establishment, which means that a controller can receive
4465 asynchronous messages, potentially many of them, even if it turns them
4466 off immediately after connecting. Set this column to
4467 <code>false</code> to change Open vSwitch behavior to disable, by
4468 default, all asynchronous messages. The controller can use the
4469 <code>NXT_SET_ASYNC_CONFIG</code> Nicira extension to OpenFlow to turn
4470 on any messages that it does want to receive, if any.
4471 </column>
4472
4473 <group title="Controller Rate Limiting">
4474 <p>
4475 A switch can forward packets to a controller over the OpenFlow
4476 protocol. Forwarding packets this way at too high a rate can
4477 overwhelm a controller, frustrate use of the OpenFlow connection for
4478 other purposes, increase the latency of flow setup, and use an
4479 unreasonable amount of bandwidth. Therefore, Open vSwitch supports
4480 limiting the rate of packet forwarding to a controller.
4481 </p>
4482
4483 <p>
4484 There are two main reasons in OpenFlow for a packet to be sent to a
4485 controller: either the packet ``misses'' in the flow table, that is,
4486 there is no matching flow, or a flow table action says to send the
4487 packet to the controller. Open vSwitch limits the rate of each kind
4488 of packet separately at the configured rate. Therefore, the actual
4489 rate that packets are sent to the controller can be up to twice the
4490 configured rate, when packets are sent for both reasons.
4491 </p>
4492
4493 <p>
4494 This feature is specific to forwarding packets over an OpenFlow
4495 connection. It is not general-purpose QoS. See the <ref
4496 table="QoS"/> table for quality of service configuration, and <ref
4497 column="ingress_policing_rate" table="Interface"/> in the <ref
4498 table="Interface"/> table for ingress policing configuration.
4499 </p>
4500
4501 <column name="controller_rate_limit">
4502 <p>
4503 The maximum rate at which the switch will forward packets to the
4504 OpenFlow controller, in packets per second. If no value is
4505 specified, rate limiting is disabled.
4506 </p>
4507 </column>
4508
4509 <column name="controller_burst_limit">
4510 <p>
4511 When a high rate triggers rate-limiting, Open vSwitch queues
4512 packets to the controller for each port and transmits them to the
4513 controller at the configured rate. This value limits the number of
4514 queued packets. Ports on a bridge share the packet queue fairly.
4515 </p>
4516
4517 <p>
4518 This value has no effect unless <ref
4519 column="controller_rate_limit"/> is configured. The current
4520 default when this value is not specified is one-quarter of <ref
4521 column="controller_rate_limit"/>, meaning that queuing can delay
4522 forwarding a packet to the controller by up to 250 ms.
4523 </p>
4524 </column>
4525
4526 <group title="Controller Rate Limiting Statistics">
4527 <p>
4528 These values report the effects of rate limiting. Their values are
4529 relative to establishment of the most recent OpenFlow connection,
4530 or since rate limiting was enabled, whichever happened more
4531 recently. Each consists of two values, one with <code>TYPE</code>
4532 replaced by <code>miss</code> for rate limiting flow table misses,
4533 and the other with <code>TYPE</code> replaced by
4534 <code>action</code> for rate limiting packets sent by OpenFlow
4535 actions.
4536 </p>
4537
4538 <p>
4539 These statistics are reported only when controller rate limiting is
4540 enabled.
4541 </p>
4542
4543 <column name="status" key="packet-in-TYPE-bypassed"
4544 type='{"type": "integer", "minInteger": 0}'>
4545 Number of packets sent directly to the controller, without queuing,
4546 because the rate did not exceed the configured maximum.
4547 </column>
4548
4549 <column name="status" key="packet-in-TYPE-queued"
4550 type='{"type": "integer", "minInteger": 0}'>
4551 Number of packets added to the queue to send later.
4552 </column>
4553
4554 <column name="status" key="packet-in-TYPE-dropped"
4555 type='{"type": "integer", "minInteger": 0}'>
4556 Number of packets added to the queue that were later dropped due to
4557 overflow. This value is less than or equal to <ref column="status"
4558 key="packet-in-TYPE-queued"/>.
4559 </column>
4560
4561 <column name="status" key="packet-in-TYPE-backlog"
4562 type='{"type": "integer", "minInteger": 0}'>
4563 Number of packets currently queued. The other statistics increase
4564 monotonically, but this one fluctuates between 0 and the <ref
4565 column="controller_burst_limit"/> as conditions change.
4566 </column>
4567 </group>
4568 </group>
4569 </group>
4570
4571 <group title="Additional In-Band Configuration">
4572 <p>These values are considered only in in-band control mode (see
4573 <ref column="connection_mode"/>).</p>
4574
4575 <p>When multiple controllers are configured on a single bridge, there
4576 should be only one set of unique values in these columns. If different
4577 values are set for these columns in different controllers, the effect
4578 is unspecified.</p>
4579
4580 <column name="local_ip">
4581 The IP address to configure on the local port,
4582 e.g. <code>192.168.0.123</code>. If this value is unset, then
4583 <ref column="local_netmask"/> and <ref column="local_gateway"/> are
4584 ignored.
4585 </column>
4586
4587 <column name="local_netmask">
4588 The IP netmask to configure on the local port,
4589 e.g. <code>255.255.255.0</code>. If <ref column="local_ip"/> is set
4590 but this value is unset, then the default is chosen based on whether
4591 the IP address is class A, B, or C.
4592 </column>
4593
4594 <column name="local_gateway">
4595 The IP address of the gateway to configure on the local port, as a
4596 string, e.g. <code>192.168.0.1</code>. Leave this column unset if
4597 this network has no gateway.
4598 </column>
4599 </group>
4600
4601 <group title="Controller Status">
4602 <column name="is_connected">
4603 <code>true</code> if currently connected to this controller,
4604 <code>false</code> otherwise.
4605 </column>
4606
4607 <column name="role"
4608 type='{"type": "string", "enum": ["set", ["other", "master", "slave"]]}'>
4609 <p>The level of authority this controller has on the associated
4610 bridge. Possible values are:</p>
4611 <dl>
4612 <dt><code>other</code></dt>
4613 <dd>Allows the controller access to all OpenFlow features.</dd>
4614 <dt><code>master</code></dt>
4615 <dd>Equivalent to <code>other</code>, except that there may be at
4616 most one master controller at a time. When a controller configures
4617 itself as <code>master</code>, any existing master is demoted to
4618 the <code>slave</code> role.</dd>
4619 <dt><code>slave</code></dt>
4620 <dd>Allows the controller read-only access to OpenFlow features.
4621 Attempts to modify the flow table will be rejected with an
4622 error. Slave controllers do not receive OFPT_PACKET_IN or
4623 OFPT_FLOW_REMOVED messages, but they do receive OFPT_PORT_STATUS
4624 messages.</dd>
4625 </dl>
4626 </column>
4627
4628 <column name="status" key="last_error">
4629 A human-readable description of the last error on the connection
4630 to the controller; i.e. <code>strerror(errno)</code>. This key
4631 will exist only if an error has occurred.
4632 </column>
4633
4634 <column name="status" key="state"
4635 type='{"type": "string", "enum": ["set", ["VOID", "BACKOFF", "CONNECTING", "ACTIVE", "IDLE"]]}'>
4636 <p>
4637 The state of the connection to the controller:
4638 </p>
4639 <dl>
4640 <dt><code>VOID</code></dt>
4641 <dd>Connection is disabled.</dd>
4642
4643 <dt><code>BACKOFF</code></dt>
4644 <dd>Attempting to reconnect at an increasing period.</dd>
4645
4646 <dt><code>CONNECTING</code></dt>
4647 <dd>Attempting to connect.</dd>
4648
4649 <dt><code>ACTIVE</code></dt>
4650 <dd>Connected, remote host responsive.</dd>
4651
4652 <dt><code>IDLE</code></dt>
4653 <dd>Connection is idle. Waiting for response to keep-alive.</dd>
4654 </dl>
4655 <p>
4656 These values may change in the future. They are provided only for
4657 human consumption.
4658 </p>
4659 </column>
4660
4661 <column name="status" key="sec_since_connect"
4662 type='{"type": "integer", "minInteger": 0}'>
4663 The amount of time since this controller last successfully connected to
4664 the switch (in seconds). Value is empty if controller has never
4665 successfully connected.
4666 </column>
4667
4668 <column name="status" key="sec_since_disconnect"
4669 type='{"type": "integer", "minInteger": 1}'>
4670 The amount of time since this controller last disconnected from
4671 the switch (in seconds). Value is empty if controller has never
4672 disconnected.
4673 </column>
4674 </group>
4675
4676 <group title="Connection Parameters">
4677 <p>
4678 Additional configuration for a connection between the controller
4679 and the Open vSwitch.
4680 </p>
4681
4682 <column name="other_config" key="dscp"
4683 type='{"type": "integer"}'>
4684 The Differentiated Service Code Point (DSCP) is specified using 6 bits
4685 in the Type of Service (TOS) field in the IP header. DSCP provides a
4686 mechanism to classify the network traffic and provide Quality of
4687 Service (QoS) on IP networks.
4688
4689 The DSCP value specified here is used when establishing the connection
4690 between the controller and the Open vSwitch. If no value is specified,
4691 a default value of 48 is chosen. Valid DSCP values must be in the
4692 range 0 to 63.
4693 </column>
4694 </group>
4695
4696
4697 <group title="Common Columns">
4698 The overall purpose of these columns is described under <code>Common
4699 Columns</code> at the beginning of this document.
4700
4701 <column name="external_ids"/>
4702 <column name="other_config"/>
4703 </group>
4704 </table>
4705
4706 <table name="Manager" title="OVSDB management connection.">
4707 <p>
4708 Configuration for a database connection to an Open vSwitch database
4709 (OVSDB) client.
4710 </p>
4711
4712 <p>
4713 This table primarily configures the Open vSwitch database
4714 (<code>ovsdb-server</code>), not the Open vSwitch switch
4715 (<code>ovs-vswitchd</code>). The switch does read the table to determine
4716 what connections should be treated as in-band.
4717 </p>
4718
4719 <p>
4720 The Open vSwitch database server can initiate and maintain active
4721 connections to remote clients. It can also listen for database
4722 connections.
4723 </p>
4724
4725 <group title="Core Features">
4726 <column name="target">
4727 <p>Connection method for managers.</p>
4728 <p>
4729 The following connection methods are currently supported:
4730 </p>
4731 <dl>
4732 <dt><code>ssl:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
4733 <dd>
4734 <p>
4735 The specified SSL <var>port</var> on the host at the given
4736 <var>ip</var>, which must be expressed as an IP address
4737 (not a DNS name). The <ref table="Open_vSwitch"
4738 column="ssl"/> column in the <ref table="Open_vSwitch"/>
4739 table must point to a valid SSL configuration when this
4740 form is used.
4741 </p>
4742 <p>
4743 If <var>port</var> is not specified, it defaults to 6640.
4744 </p>
4745 <p>
4746 SSL support is an optional feature that is not always
4747 built as part of Open vSwitch.
4748 </p>
4749 </dd>
4750
4751 <dt><code>tcp:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
4752 <dd>
4753 <p>
4754 The specified TCP <var>port</var> on the host at the given
4755 <var>ip</var>, which must be expressed as an IP address (not a
4756 DNS name), where <var>ip</var> can be IPv4 or IPv6 address. If
4757 <var>ip</var> is an IPv6 address, wrap it in square brackets,
4758 e.g. <code>tcp:[::1]:6640</code>.
4759 </p>
4760 <p>
4761 If <var>port</var> is not specified, it defaults to 6640.
4762 </p>
4763 </dd>
4764 <dt><code>pssl:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
4765 <dd>
4766 <p>
4767 Listens for SSL connections on the specified TCP <var>port</var>.
4768 Specify 0 for <var>port</var> to have the kernel automatically
4769 choose an available port. If <var>ip</var>, which must be
4770 expressed as an IP address (not a DNS name), is specified, then
4771 connections are restricted to the specified local IP address
4772 (either IPv4 or IPv6 address). If <var>ip</var> is an IPv6
4773 address, wrap in square brackets,
4774 e.g. <code>pssl:6640:[::1]</code>. If <var>ip</var> is not
4775 specified then it listens only on IPv4 (but not IPv6) addresses.
4776 The <ref table="Open_vSwitch" column="ssl"/> column in the <ref
4777 table="Open_vSwitch"/> table must point to a valid SSL
4778 configuration when this form is used.
4779 </p>
4780 <p>
4781 If <var>port</var> is not specified, it defaults to 6640.
4782 </p>
4783 <p>
4784 SSL support is an optional feature that is not always built as
4785 part of Open vSwitch.
4786 </p>
4787 </dd>
4788 <dt><code>ptcp:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
4789 <dd>
4790 <p>
4791 Listens for connections on the specified TCP <var>port</var>.
4792 Specify 0 for <var>port</var> to have the kernel automatically
4793 choose an available port. If <var>ip</var>, which must be
4794 expressed as an IP address (not a DNS name), is specified, then
4795 connections are restricted to the specified local IP address
4796 (either IPv4 or IPv6 address). If <var>ip</var> is an IPv6
4797 address, wrap it in square brackets,
4798 e.g. <code>ptcp:6640:[::1]</code>. If <var>ip</var> is not
4799 specified then it listens only on IPv4 addresses.
4800 </p>
4801 <p>
4802 If <var>port</var> is not specified, it defaults to 6640.
4803 </p>
4804 </dd>
4805 </dl>
4806 <p>When multiple managers are configured, the <ref column="target"/>
4807 values must be unique. Duplicate <ref column="target"/> values yield
4808 unspecified results.</p>
4809 </column>
4810
4811 <column name="connection_mode">
4812 <p>
4813 If it is specified, this setting must be one of the following strings
4814 that describes how Open vSwitch contacts this OVSDB client over the
4815 network:
4816 </p>
4817
4818 <dl>
4819 <dt><code>in-band</code></dt>
4820 <dd>
4821 In this mode, this connection's traffic travels over a bridge
4822 managed by Open vSwitch. With this setting, Open vSwitch allows
4823 traffic to and from the client regardless of the contents of the
4824 OpenFlow flow table. (Otherwise, Open vSwitch would never be able
4825 to connect to the client, because it did not have a flow to enable
4826 it.) This is the most common connection mode because it is not
4827 necessary to maintain two independent networks.
4828 </dd>
4829 <dt><code>out-of-band</code></dt>
4830 <dd>
4831 In this mode, the client's traffic uses a control network separate
4832 from that managed by Open vSwitch, that is, Open vSwitch does not
4833 use any of its own network devices to communicate with the client.
4834 The control network must be configured separately, before or after
4835 <code>ovs-vswitchd</code> is started.
4836 </dd>
4837 </dl>
4838
4839 <p>
4840 If not specified, the default is implementation-specific.
4841 </p>
4842 </column>
4843 </group>
4844
4845 <group title="Client Failure Detection and Handling">
4846 <column name="max_backoff">
4847 Maximum number of milliseconds to wait between connection attempts.
4848 Default is implementation-specific.
4849 </column>
4850
4851 <column name="inactivity_probe">
4852 Maximum number of milliseconds of idle time on connection to the client
4853 before sending an inactivity probe message. If Open vSwitch does not
4854 communicate with the client for the specified number of seconds, it
4855 will send a probe. If a response is not received for the same
4856 additional amount of time, Open vSwitch assumes the connection has been
4857 broken and attempts to reconnect. Default is implementation-specific.
4858 A value of 0 disables inactivity probes.
4859 </column>
4860 </group>
4861
4862 <group title="Status">
4863 <p>
4864 Key-value pair of <ref column="is_connected"/> is always updated.
4865 Other key-value pairs in the status columns may be updated depends
4866 on the <ref column="target"/> type.
4867 </p>
4868
4869 <p>
4870 When <ref column="target"/> specifies a connection method that
4871 listens for inbound connections (e.g. <code>ptcp:</code> or
4872 <code>punix:</code>), both <ref column="n_connections"/> and
4873 <ref column="is_connected"/> may also be updated while the
4874 remaining key-value pairs are omitted.
4875 </p>
4876
4877 <p>
4878 On the other hand, when <ref column="target"/> specifies an
4879 outbound connection, all key-value pairs may be updated, except
4880 the above-mentioned two key-value pairs associated with inbound
4881 connection targets. They are omitted.
4882 </p>
4883
4884 <column name="is_connected">
4885 <code>true</code> if currently connected to this manager,
4886 <code>false</code> otherwise.
4887 </column>
4888
4889 <column name="status" key="last_error">
4890 A human-readable description of the last error on the connection
4891 to the manager; i.e. <code>strerror(errno)</code>. This key
4892 will exist only if an error has occurred.
4893 </column>
4894
4895 <column name="status" key="state"
4896 type='{"type": "string", "enum": ["set", ["VOID", "BACKOFF", "CONNECTING", "ACTIVE", "IDLE"]]}'>
4897 <p>
4898 The state of the connection to the manager:
4899 </p>
4900 <dl>
4901 <dt><code>VOID</code></dt>
4902 <dd>Connection is disabled.</dd>
4903
4904 <dt><code>BACKOFF</code></dt>
4905 <dd>Attempting to reconnect at an increasing period.</dd>
4906
4907 <dt><code>CONNECTING</code></dt>
4908 <dd>Attempting to connect.</dd>
4909
4910 <dt><code>ACTIVE</code></dt>
4911 <dd>Connected, remote host responsive.</dd>
4912
4913 <dt><code>IDLE</code></dt>
4914 <dd>Connection is idle. Waiting for response to keep-alive.</dd>
4915 </dl>
4916 <p>
4917 These values may change in the future. They are provided only for
4918 human consumption.
4919 </p>
4920 </column>
4921
4922 <column name="status" key="sec_since_connect"
4923 type='{"type": "integer", "minInteger": 0}'>
4924 The amount of time since this manager last successfully connected
4925 to the database (in seconds). Value is empty if manager has never
4926 successfully connected.
4927 </column>
4928
4929 <column name="status" key="sec_since_disconnect"
4930 type='{"type": "integer", "minInteger": 0}'>
4931 The amount of time since this manager last disconnected from the
4932 database (in seconds). Value is empty if manager has never
4933 disconnected.
4934 </column>
4935
4936 <column name="status" key="locks_held">
4937 Space-separated list of the names of OVSDB locks that the connection
4938 holds. Omitted if the connection does not hold any locks.
4939 </column>
4940
4941 <column name="status" key="locks_waiting">
4942 Space-separated list of the names of OVSDB locks that the connection is
4943 currently waiting to acquire. Omitted if the connection is not waiting
4944 for any locks.
4945 </column>
4946
4947 <column name="status" key="locks_lost">
4948 Space-separated list of the names of OVSDB locks that the connection
4949 has had stolen by another OVSDB client. Omitted if no locks have been
4950 stolen from this connection.
4951 </column>
4952
4953 <column name="status" key="n_connections"
4954 type='{"type": "integer", "minInteger": 2}'>
4955 When <ref column="target"/> specifies a connection method that
4956 listens for inbound connections (e.g. <code>ptcp:</code> or
4957 <code>pssl:</code>) and more than one connection is actually active,
4958 the value is the number of active connections. Otherwise, this
4959 key-value pair is omitted.
4960 </column>
4961
4962 <column name="status" key="bound_port" type='{"type": "integer"}'>
4963 When <ref column="target"/> is <code>ptcp:</code> or
4964 <code>pssl:</code>, this is the TCP port on which the OVSDB server is
4965 listening. (This is particularly useful when <ref
4966 column="target"/> specifies a port of 0, allowing the kernel to
4967 choose any available port.)
4968 </column>
4969 </group>
4970
4971 <group title="Connection Parameters">
4972 <p>
4973 Additional configuration for a connection between the manager
4974 and the Open vSwitch Database.
4975 </p>
4976
4977 <column name="other_config" key="dscp"
4978 type='{"type": "integer"}'>
4979 The Differentiated Service Code Point (DSCP) is specified using 6 bits
4980 in the Type of Service (TOS) field in the IP header. DSCP provides a
4981 mechanism to classify the network traffic and provide Quality of
4982 Service (QoS) on IP networks.
4983
4984 The DSCP value specified here is used when establishing the connection
4985 between the manager and the Open vSwitch. If no value is specified, a
4986 default value of 48 is chosen. Valid DSCP values must be in the range
4987 0 to 63.
4988 </column>
4989 </group>
4990
4991 <group title="Common Columns">
4992 The overall purpose of these columns is described under <code>Common
4993 Columns</code> at the beginning of this document.
4994
4995 <column name="external_ids"/>
4996 <column name="other_config"/>
4997 </group>
4998 </table>
4999
5000 <table name="NetFlow">
5001 A NetFlow target. NetFlow is a protocol that exports a number of
5002 details about terminating IP flows, such as the principals involved
5003 and duration.
5004
5005 <column name="targets">
5006 NetFlow targets in the form
5007 <code><var>ip</var>:<var>port</var></code>. The <var>ip</var>
5008 must be specified numerically, not as a DNS name.
5009 </column>
5010
5011 <column name="engine_id">
5012 Engine ID to use in NetFlow messages. Defaults to datapath index
5013 if not specified.
5014 </column>
5015
5016 <column name="engine_type">
5017 Engine type to use in NetFlow messages. Defaults to datapath
5018 index if not specified.
5019 </column>
5020
5021 <column name="active_timeout">
5022 <p>
5023 The interval at which NetFlow records are sent for flows that
5024 are still active, in seconds. A value of <code>0</code>
5025 requests the default timeout (currently 600 seconds); a value
5026 of <code>-1</code> disables active timeouts.
5027 </p>
5028
5029 <p>
5030 The NetFlow passive timeout, for flows that become inactive,
5031 is not configurable. It will vary depending on the Open
5032 vSwitch version, the forms and contents of the OpenFlow flow
5033 tables, CPU and memory usage, and network activity. A typical
5034 passive timeout is about a second.
5035 </p>
5036 </column>
5037
5038 <column name="add_id_to_interface">
5039 <p>If this column's value is <code>false</code>, the ingress and egress
5040 interface fields of NetFlow flow records are derived from OpenFlow port
5041 numbers. When it is <code>true</code>, the 7 most significant bits of
5042 these fields will be replaced by the least significant 7 bits of the
5043 engine id. This is useful because many NetFlow collectors do not
5044 expect multiple switches to be sending messages from the same host, so
5045 they do not store the engine information which could be used to
5046 disambiguate the traffic.</p>
5047 <p>When this option is enabled, a maximum of 508 ports are supported.</p>
5048 </column>
5049
5050 <group title="Common Columns">
5051 The overall purpose of these columns is described under <code>Common
5052 Columns</code> at the beginning of this document.
5053
5054 <column name="external_ids"/>
5055 </group>
5056 </table>
5057
5058 <table name="SSL">
5059 SSL configuration for an Open_vSwitch.
5060
5061 <column name="private_key">
5062 Name of a PEM file containing the private key used as the switch's
5063 identity for SSL connections to the controller.
5064 </column>
5065
5066 <column name="certificate">
5067 Name of a PEM file containing a certificate, signed by the
5068 certificate authority (CA) used by the controller and manager,
5069 that certifies the switch's private key, identifying a trustworthy
5070 switch.
5071 </column>
5072
5073 <column name="ca_cert">
5074 Name of a PEM file containing the CA certificate used to verify
5075 that the switch is connected to a trustworthy controller.
5076 </column>
5077
5078 <column name="bootstrap_ca_cert">
5079 If set to <code>true</code>, then Open vSwitch will attempt to
5080 obtain the CA certificate from the controller on its first SSL
5081 connection and save it to the named PEM file. If it is successful,
5082 it will immediately drop the connection and reconnect, and from then
5083 on all SSL connections must be authenticated by a certificate signed
5084 by the CA certificate thus obtained. <em>This option exposes the
5085 SSL connection to a man-in-the-middle attack obtaining the initial
5086 CA certificate.</em> It may still be useful for bootstrapping.
5087 </column>
5088
5089 <group title="Common Columns">
5090 The overall purpose of these columns is described under <code>Common
5091 Columns</code> at the beginning of this document.
5092
5093 <column name="external_ids"/>
5094 </group>
5095 </table>
5096
5097 <table name="sFlow">
5098 <p>A set of sFlow(R) targets. sFlow is a protocol for remote
5099 monitoring of switches.</p>
5100
5101 <column name="agent">
5102 <p>
5103 Determines the agent address, that is, the IP address reported to
5104 collectors as the source of the sFlow data. It may be an IP address or
5105 the name of a network device. In the latter case, the network device's
5106 IP address is used,
5107 </p>
5108
5109 <p>
5110 If not specified, the agent device is figured from the first target
5111 address and the routing table. If the routing table does not contain a
5112 route to the target, the IP address defaults to the <ref
5113 table="Controller" column="local_ip"/> in the collector's <ref
5114 table="Controller"/>.
5115 </p>
5116
5117 <p>
5118 If an agent IP address cannot be determined, sFlow is disabled.
5119 </p>
5120 </column>
5121
5122 <column name="header">
5123 Number of bytes of a sampled packet to send to the collector.
5124 If not specified, the default is 128 bytes.
5125 </column>
5126
5127 <column name="polling">
5128 Polling rate in seconds to send port statistics to the collector.
5129 If not specified, defaults to 30 seconds.
5130 </column>
5131
5132 <column name="sampling">
5133 Rate at which packets should be sampled and sent to the collector.
5134 If not specified, defaults to 400, which means one out of 400
5135 packets, on average, will be sent to the collector.
5136 </column>
5137
5138 <column name="targets">
5139 sFlow targets in the form
5140 <code><var>ip</var>:<var>port</var></code>.
5141 </column>
5142
5143 <group title="Common Columns">
5144 The overall purpose of these columns is described under <code>Common
5145 Columns</code> at the beginning of this document.
5146
5147 <column name="external_ids"/>
5148 </group>
5149 </table>
5150
5151 <table name="IPFIX">
5152 <p>Configuration for sending packets to IPFIX collectors.</p>
5153
5154 <p>
5155 IPFIX is a protocol that exports a number of details about flows. The
5156 IPFIX implementation in Open vSwitch samples packets at a configurable
5157 rate, extracts flow information from those packets, optionally caches and
5158 aggregates the flow information, and sends the result to one or more
5159 collectors.
5160 </p>
5161
5162 <p>
5163 IPFIX in Open vSwitch can be configured two different ways:
5164 </p>
5165
5166 <ul>
5167 <li>
5168 With <em>per-bridge sampling</em>, Open vSwitch performs IPFIX sampling
5169 automatically on all packets that pass through a bridge. To configure
5170 per-bridge sampling, create an <ref table="IPFIX"/> record and point a
5171 <ref table="Bridge"/> table's <ref table="Bridge" column="ipfix"/>
5172 column to it. The <ref table="Flow_Sample_Collector_Set"/> table is
5173 not used for per-bridge sampling.
5174 </li>
5175
5176 <li>
5177 <p>
5178 With <em>flow-based sampling</em>, <code>sample</code> actions in the
5179 OpenFlow flow table drive IPFIX sampling. See
5180 <code>ovs-ofctl</code>(8) for a description of the
5181 <code>sample</code> action.
5182 </p>
5183
5184 <p>
5185 Flow-based sampling also requires database configuration: create a
5186 <ref table="IPFIX"/> record that describes the IPFIX configuration
5187 and a <ref table="Flow_Sample_Collector_Set"/> record that points to
5188 the <ref table="Bridge"/> whose flow table holds the
5189 <code>sample</code> actions and to <ref table="IPFIX"/> record. The
5190 <ref table="Bridge" column="ipfix"/> in the <ref table="Bridge"/>
5191 table is not used for flow-based sampling.
5192 </p>
5193 </li>
5194 </ul>
5195
5196 <column name="targets">
5197 IPFIX target collectors in the form
5198 <code><var>ip</var>:<var>port</var></code>.
5199 </column>
5200
5201 <column name="cache_active_timeout">
5202 The maximum period in seconds for which an IPFIX flow record is
5203 cached and aggregated before being sent. If not specified,
5204 defaults to 0. If 0, caching is disabled.
5205 </column>
5206
5207 <column name="cache_max_flows">
5208 The maximum number of IPFIX flow records that can be cached at a
5209 time. If not specified, defaults to 0. If 0, caching is
5210 disabled.
5211 </column>
5212
5213 <column name="other_config" key="enable-tunnel-sampling"
5214 type='{"type": "boolean"}'>
5215 <p>
5216 Set to <code>true</code> to enable sampling and reporting tunnel
5217 header 7-tuples in IPFIX flow records. Tunnel sampling is enabled
5218 by default.
5219 </p>
5220
5221 <p>
5222 The following enterprise entities report the sampled tunnel info:
5223 </p>
5224
5225 <dl>
5226 <dt>tunnelType:</dt>
5227 <dd>
5228 <p>ID: 891, and enterprise ID 6876 (VMware).</p>
5229 <p>type: unsigned 8-bit integer.</p>
5230 <p>data type semantics: identifier.</p>
5231 <p>description: Identifier of the layer 2 network overlay network
5232 encapsulation type: 0x01 VxLAN, 0x02 GRE, 0x03 LISP, 0x07 GENEVE.</p>
5233 </dd>
5234 <dt>tunnelKey:</dt>
5235 <dd>
5236 <p>ID: 892, and enterprise ID 6876 (VMware).</p>
5237 <p>type: variable-length octetarray.</p>
5238 <p>data type semantics: identifier.</p>
5239 <p>description: Key which is used for identifying an individual
5240 traffic flow within a VxLAN (24-bit VNI), GENEVE (24-bit VNI),
5241 GRE (32-bit key), or LISP (24-bit instance ID) tunnel. The
5242 key is encoded in this octetarray as a 3-, 4-, or 8-byte integer
5243 ID in network byte order.</p>
5244 </dd>
5245 <dt>tunnelSourceIPv4Address:</dt>
5246 <dd>
5247 <p>ID: 893, and enterprise ID 6876 (VMware).</p>
5248 <p>type: unsigned 32-bit integer.</p>
5249 <p>data type semantics: identifier.</p>
5250 <p>description: The IPv4 source address in the tunnel IP packet
5251 header.</p>
5252 </dd>
5253 <dt>tunnelDestinationIPv4Address:</dt>
5254 <dd>
5255 <p>ID: 894, and enterprise ID 6876 (VMware).</p>
5256 <p>type: unsigned 32-bit integer.</p>
5257 <p>data type semantics: identifier.</p>
5258 <p>description: The IPv4 destination address in the tunnel IP
5259 packet header.</p>
5260 </dd>
5261 <dt>tunnelProtocolIdentifier:</dt>
5262 <dd>
5263 <p>ID: 895, and enterprise ID 6876 (VMware).</p>
5264 <p>type: unsigned 8-bit integer.</p>
5265 <p>data type semantics: identifier.</p>
5266 <p>description: The value of the protocol number in the tunnel
5267 IP packet header. The protocol number identifies the tunnel IP
5268 packet payload type.</p>
5269 </dd>
5270 <dt>tunnelSourceTransportPort:</dt>
5271 <dd>
5272 <p>ID: 896, and enterprise ID 6876 (VMware).</p>
5273 <p>type: unsigned 16-bit integer.</p>
5274 <p>data type semantics: identifier.</p>
5275 <p>description: The source port identifier in the tunnel transport
5276 header. For the transport protocols UDP, TCP, and SCTP, this is
5277 the source port number given in the respective header.</p>
5278 </dd>
5279 <dt>tunnelDestinationTransportPort:</dt>
5280 <dd>
5281 <p>ID: 897, and enterprise ID 6876 (VMware).</p>
5282 <p>type: unsigned 16-bit integer.</p>
5283 <p>data type semantics: identifier.</p>
5284 <p>description: The destination port identifier in the tunnel
5285 transport header. For the transport protocols UDP, TCP, and SCTP,
5286 this is the destination port number given in the respective header.
5287 </p>
5288 </dd>
5289 </dl>
5290
5291 <p>
5292 Before Open vSwitch 2.5.90, <ref column="other_config"
5293 key="enable-tunnel-sampling"/> was only supported with per-bridge
5294 sampling, and ignored otherwise. Open vSwitch 2.5.90 and later support
5295 <ref column="other_config" key="enable-tunnel-sampling"/> for
5296 per-bridge and per-flow sampling.
5297 </p>
5298 </column>
5299
5300 <column name="other_config" key="virtual_obs_id"
5301 type='{"type": "string"}'>
5302 <p>
5303 A string that accompanies each IPFIX flow record. Its intended use is
5304 for the ``virtual observation ID,'' an identifier of a virtual
5305 observation point that is locally unique in a virtual network. It
5306 describes a location in the virtual network where IP packets can be
5307 observed. The maximum length is 254 bytes. If not specified, the
5308 field is omitted from the IPFIX flow record.
5309 </p>
5310
5311 <p>
5312 The following enterprise entity reports the specified virtual
5313 observation ID:
5314 </p>
5315
5316 <dl>
5317 <dt>virtualObsID:</dt>
5318 <dd>
5319 <p>ID: 898, and enterprise ID 6876 (VMware).</p>
5320 <p>type: variable-length string.</p>
5321 <p>data type semantics: identifier.</p>
5322 <p>description: A virtual observation domain ID that is locally
5323 unique in a virtual network.
5324 </p>
5325 </dd>
5326 </dl>
5327
5328 <p>
5329 This feature was introduced in Open vSwitch 2.5.90.
5330 </p>
5331 </column>
5332
5333 <group title="Per-Bridge Sampling">
5334 <p>
5335 These values affect only per-bridge sampling. See above for a
5336 description of the differences between per-bridge and flow-based
5337 sampling.
5338 </p>
5339
5340 <column name="sampling">
5341 The rate at which packets should be sampled and sent to each target
5342 collector. If not specified, defaults to 400, which means one out of
5343 400 packets, on average, will be sent to each target collector.
5344 </column>
5345
5346 <column name="obs_domain_id">
5347 The IPFIX Observation Domain ID sent in each IPFIX packet. If not
5348 specified, defaults to 0.
5349 </column>
5350
5351 <column name="obs_point_id">
5352 The IPFIX Observation Point ID sent in each IPFIX flow record. If not
5353 specified, defaults to 0.
5354 </column>
5355
5356 <column name="other_config" key="enable-input-sampling"
5357 type='{"type": "boolean"}'>
5358 By default, Open vSwitch samples and reports flows at bridge port input
5359 in IPFIX flow records. Set this column to <code>false</code> to
5360 disable input sampling.
5361 </column>
5362
5363 <column name="other_config" key="enable-output-sampling"
5364 type='{"type": "boolean"}'>
5365 By default, Open vSwitch samples and reports flows at bridge port
5366 output in IPFIX flow records. Set this column to <code>false</code> to
5367 disable output sampling.
5368 </column>
5369 </group>
5370
5371 <group title="Common Columns">
5372 The overall purpose of these columns is described under <code>Common
5373 Columns</code> at the beginning of this document.
5374
5375 <column name="external_ids"/>
5376 </group>
5377 </table>
5378
5379 <table name="Flow_Sample_Collector_Set">
5380 <p>
5381 A set of IPFIX collectors of packet samples generated by OpenFlow
5382 <code>sample</code> actions. This table is used only for IPFIX
5383 flow-based sampling, not for per-bridge sampling (see the <ref
5384 table="IPFIX"/> table for a description of the two forms).
5385 </p>
5386
5387 <column name="id">
5388 The ID of this collector set, unique among the bridge's
5389 collector sets, to be used as the <code>collector_set_id</code>
5390 in OpenFlow <code>sample</code> actions.
5391 </column>
5392
5393 <column name="bridge">
5394 The bridge into which OpenFlow <code>sample</code> actions can
5395 be added to send packet samples to this set of IPFIX collectors.
5396 </column>
5397
5398 <column name="ipfix">
5399 Configuration of the set of IPFIX collectors to send one flow
5400 record per sampled packet to.
5401 </column>
5402
5403 <group title="Common Columns">
5404 The overall purpose of these columns is described under <code>Common
5405 Columns</code> at the beginning of this document.
5406
5407 <column name="external_ids"/>
5408 </group>
5409 </table>
5410
5411 <table name="AutoAttach">
5412 <p>
5413 Auto Attach configuration within a bridge. The IETF Auto-Attach SPBM
5414 draft standard describes a compact method of using IEEE 802.1AB Link
5415 Layer Discovery Protocol (LLDP) together with a IEEE 802.1aq Shortest
5416 Path Bridging (SPB) network to automatically attach network devices
5417 to individual services in a SPB network. The intent here is to allow
5418 network applications and devices using OVS to be able to easily take
5419 advantage of features offered by industry standard SPB networks.
5420 </p>
5421
5422 <p>
5423 Auto Attach (AA) uses LLDP to communicate between a directly connected
5424 Auto Attach Client (AAC) and Auto Attach Server (AAS). The LLDP protocol
5425 is extended to add two new Type-Length-Value tuples (TLVs). The first
5426 new TLV supports the ongoing discovery of directly connected AA
5427 correspondents. Auto Attach operates by regularly transmitting AA
5428 discovery TLVs between the AA client and AA server. By exchanging these
5429 discovery messages, both the AAC and AAS learn the system name and
5430 system description of their peer. In the OVS context, OVS operates as
5431 the AA client and the AA server resides on a switch at the edge of the
5432 SPB network.
5433 </p>
5434
5435 <p>
5436 Once AA discovery has been completed the AAC then uses the second new TLV
5437 to deliver identifier mappings from the AAC to the AAS. A primary feature
5438 of Auto Attach is to facilitate the mapping of VLANs defined outside the
5439 SPB network onto service ids (ISIDs) defined within the SPM network. By
5440 doing so individual external VLANs can be mapped onto specific SPB
5441 network services. These VLAN id to ISID mappings can be configured and
5442 managed locally using new options added to the ovs-vsctl command.
5443 </p>
5444
5445 <p>
5446 The Auto Attach OVS feature does not provide a full implementation of
5447 the LLDP protocol. Support for the mandatory TLVs as defined by the LLDP
5448 standard and support for the AA TLV extensions is provided. LLDP
5449 protocol support in OVS can be enabled or disabled on a port by port
5450 basis. LLDP support is disabled by default.
5451 </p>
5452
5453 <column name="system_name">
5454 The system_name string is exported in LLDP messages. It should uniquely
5455 identify the bridge in the network.
5456 </column>
5457
5458 <column name="system_description">
5459 The system_description string is exported in LLDP messages. It should
5460 describe the type of software and hardware.
5461 </column>
5462
5463 <column name="mappings">
5464 A mapping from SPB network Individual Service Identifier (ISID) to VLAN
5465 id.
5466 </column>
5467 </table>
5468 </database>