cea198a9724641b10c4560540283c930874e35f4
[openvswitch] / vswitchd / vswitch.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <database 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 noted below.
13   </p>
14
15   <table name="Open_vSwitch" title="Open vSwitch configuration.">
16     Configuration for an Open vSwitch daemon.  There must be exactly
17     one record in the <ref table="Open_vSwitch"/> table.
18
19     <group title="Configuration">
20       <column name="bridges">
21         Set of bridges managed by the daemon.
22       </column>
23
24       <column name="ssl">
25         SSL used globally by the daemon.
26       </column>
27
28       <column name="external_ids">
29         Key-value pairs for use by external frameworks that integrate
30         with Open vSwitch, rather than by Open vSwitch itself.  System
31         integrators should either use the Open vSwitch development
32         mailing list to coordinate on common key-value definitions, or
33         choose key names that are likely to be unique.  The currently
34         defined common key-value pairs are:
35         <dl>
36           <dt><code>system-id</code></dt>
37           <dd>A unique identifier for the Open vSwitch's physical host.
38             The form of the identifier depends on the type of the host.
39             On a Citrix XenServer, this will likely be the same as
40             <code>xs-system-uuid</code>.</dd>
41           <dt><code>xs-system-uuid</code></dt>
42           <dd>The Citrix XenServer universally unique identifier for the
43             physical host as displayed by <code>xe host-list</code>.</dd>
44         </dl>
45       </column>
46     </group>
47
48     <group title="Status">
49       <column name="next_cfg">
50         Sequence number for client to increment.  When a client modifies
51         any part of the database configuration and wishes to wait for
52         Open vSwitch to finish applying the changes, it may increment
53         this sequence number.
54       </column>
55
56       <column name="cur_cfg">
57         Sequence number that Open vSwitch sets to the current value of
58         <ref column="next_cfg"/> after it finishes applying a set of
59         configuration changes.
60       </column>
61
62       <column name="capabilities">
63         Describes functionality supported by the hardware and software platform
64         on which this Open vSwitch is based.  Clients should not modify this
65         column.  See the <ref table="Capability"/> description for defined
66         capability categories and the meaning of associated
67         <ref table="Capability"/> records.
68       </column>
69
70       <column name="statistics">
71         <p>
72           Key-value pairs that report statistics about a system running an Open
73           vSwitch.  These are updated periodically (currently, every 5
74           seconds).  Key-value pairs that cannot be determined or that do not
75           apply to a platform are omitted.
76         </p>
77
78         <dl>
79           <dt><code>cpu</code></dt>
80           <dd>
81             <p>
82               Number of CPU processors, threads, or cores currently online and
83               available to the operating system on which Open vSwitch is
84               running, as an integer.  This may be less than the number
85               installed, if some are not online or if they are not available to
86               the operating system.
87             </p>
88             <p>
89               Open vSwitch userspace processes are not multithreaded, but the
90               Linux kernel-based datapath is.
91             </p>
92           </dd>
93
94           <dt><code>load_average</code></dt>
95           <dd>
96             <p>
97               A comma-separated list of three floating-point numbers,
98               representing the system load average over the last 1, 5, and 15
99               minutes, respectively.
100             </p>
101           </dd>
102
103           <dt><code>memory</code></dt>
104           <dd>
105             <p>
106               A comma-separated list of integers, each of which represents a
107               quantity of memory in kilobytes that describes the operating
108               system on which Open vSwitch is running.  In respective order,
109               these values are:
110             </p>
111
112             <ol>
113               <li>Total amount of RAM allocated to the OS.</li>
114               <li>RAM allocated to the OS that is in use.</li>
115               <li>RAM that can be flushed out to disk or otherwise discarded
116               if that space is needed for another purpose.  This number is
117               necessarily less than or equal to the previous value.</li>
118               <li>Total disk space allocated for swap.</li>
119               <li>Swap space currently in use.</li>
120             </ol>
121
122             <p>
123               On Linux, all five values can be determined and are included.  On
124               other operating systems, only the first two values can be
125               determined, so the list will only have two values.
126             </p>
127           </dd>
128
129           <dt><code>process_</code><var>name</var></dt>
130           <dd>
131             <p>
132               One such key-value pair will exist for each running Open vSwitch
133               daemon process, with <var>name</var> replaced by the daemon's
134               name (e.g. <code>process_ovs-vswitchd</code>).  The value is a
135               comma-separated list of integers.  The integers represent the
136               following, with memory measured in kilobytes and durations in
137               milliseconds:
138             </p>
139
140             <ol>
141               <li>The process's virtual memory size.</li>
142               <li>The process's resident set size.</li>
143               <li>The amount of user and system CPU time consumed by the
144               process.</li>
145               <li>The number of times that the process has crashed and been
146               automatically restarted by the monitor.</li>
147               <li>The duration since the process was started.</li>
148               <li>The duration for which the process has been running.</li>
149             </ol>
150
151             <p>
152               The interpretation of some of these values depends on whether the
153               process was started with the <option>--monitor</option>.  If it
154               was not, then the crash count will always be 0 and the two
155               durations will always be the same.  If <option>--monitor</option>
156               was given, then the crash count may be positive; if it is, the
157               latter duration is the amount of time since the most recent crash
158               and restart.
159             </p>
160
161             <p>
162               There will be one key-value pair for each file in Open vSwitch's
163               ``run directory'' (usually <code>/var/run/openvswitch</code>)
164               whose name ends in <code>.pid</code>, whose contents are a
165               process ID, and which is locked by a running process.  The
166               <var>name</var> is taken from the pidfile's name.
167             </p>
168
169             <p>
170               Currently Open vSwitch is only able to obtain all of the above
171               detail on Linux systems.  On other systems, the same key-value
172               pairs will be present but the values will always be the empty
173               string.
174             </p>
175           </dd>
176
177           <dt><code>file_systems</code></dt>
178           <dd>
179             <p>
180               A space-separated list of information on local, writable file
181               systems.  Each item in the list describes one file system and
182               consists in turn of a comma-separated list of the following:
183             </p>
184
185             <ol>
186               <li>Mount point, e.g. <code>/</code> or <code>/var/log</code>.
187               Any spaces or commas in the mount point are replaced by
188               underscores.</li>
189               <li>Total size, in kilobytes, as an integer.</li>
190               <li>Amount of storage in use, in kilobytes, as an integer.</li>
191             </ol>
192
193             <p>
194               This key-value pair is omitted if there are no local, writable
195               file systems or if Open vSwitch cannot obtain the needed
196               information.
197             </p>
198           </dd>
199         </dl>
200       </column>
201     </group>
202
203     <group title="Version Reporting">
204       <p>
205         These columns report the types and versions of the hardware and
206         software running Open vSwitch.  We recommend in general that software
207         should test whether specific features are supported instead of relying
208         on version number checks.  These values are primarily intended for
209         reporting to human administrators.
210       </p>
211
212       <column name="ovs_version">
213         The Open vSwitch version number, e.g. <code>1.1.0pre2</code>.
214         If Open vSwitch was configured with a build number, then it is
215         also included, e.g. <code>1.1.0pre2+build4948</code>.
216       </column>
217
218       <column name="db_version">
219         <p>
220           The database schema version number in the form
221           <code><var>major</var>.<var>minor</var>.<var>tweak</var></code>,
222           e.g. <code>1.2.3</code>.  Whenever the database schema is changed in
223           a non-backward compatible way (e.g. deleting a column or a table),
224           <var>major</var> is incremented.  When the database schema is changed
225           in a backward compatible way (e.g. adding a new column),
226           <var>minor</var> is incremented.  When the database schema is changed
227           cosmetically (e.g. reindenting its syntax), <var>tweak</var> is
228           incremented.
229         </p>
230
231         <p>
232           The schema version is part of the database schema, so it can also be
233           retrieved by fetching the schema using the Open vSwitch database
234           protocol.
235         </p>
236       </column>
237
238       <column name="system_type">
239         <p>
240           An identifier for the type of system on top of which Open vSwitch
241           runs, e.g. <code>XenServer</code> or <code>KVM</code>.
242         </p>
243         <p>
244           System integrators are responsible for choosing and setting an
245           appropriate value for this column.
246         </p>
247       </column>
248
249       <column name="system_version">
250         <p>
251           The version of the system identified by <ref column="system_type"/>,
252           e.g. <code>5.6.100-39265p</code> on XenServer 5.6.100 build 39265.
253         </p>
254         <p>
255           System integrators are responsible for choosing and setting an
256           appropriate value for this column.
257         </p>
258       </column>
259
260     </group>
261
262     <group title="Database Configuration">
263       <p>
264         These columns primarily configure the Open vSwitch database
265         (<code>ovsdb-server</code>), not the Open vSwitch switch
266         (<code>ovs-vswitchd</code>).  The OVSDB database also uses the <ref
267         column="ssl"/> settings.
268       </p>
269
270       <p>
271         The Open vSwitch switch does read the database configuration to
272         determine remote IP addresses to which in-band control should apply.
273       </p>
274
275       <column name="manager_options">
276         Database clients to which the Open vSwitch database server should
277         connect or to which it should listen, along with options for how these
278         connection should be configured.  See the <ref table="Manager"/> table
279         for more information.
280       </column>
281     </group>
282   </table>
283
284   <table name="Bridge">
285     <p>
286       Configuration for a bridge within an
287       <ref table="Open_vSwitch"/>.
288     </p>
289     <p>
290       A <ref table="Bridge"/> record represents an Ethernet switch with one or
291       more ``ports,'' which are the <ref table="Port"/> records pointed to by
292       the <ref table="Bridge"/>'s <ref column="ports"/> column.
293     </p>
294
295     <group title="Core Features">
296       <column name="name">
297         Bridge identifier.  Should be alphanumeric and no more than about 8
298         bytes long.  Must be unique among the names of ports, interfaces, and
299         bridges on a host.
300       </column>
301
302       <column name="ports">
303         Ports included in the bridge.
304       </column>
305
306       <column name="mirrors">
307         Port mirroring configuration.
308       </column>
309
310       <column name="netflow">
311         NetFlow configuration.
312       </column>
313
314       <column name="sflow">
315         sFlow configuration.
316       </column>
317
318       <column name="flood_vlans">
319         VLAN IDs of VLANs on which MAC address learning should be disabled, so
320         that packets are flooded instead of being sent to specific ports that
321         are believed to contain packets' destination MACs.  This should
322         ordinarily be used to disable MAC learning on VLANs used for mirroring
323         (RSPAN VLANs).  It may also be useful for debugging.
324       </column>
325     </group>
326
327     <group title="OpenFlow Configuration">
328       <column name="controller">
329         OpenFlow controller set.  If unset, then no OpenFlow controllers
330         will be used.
331       </column>
332
333       <column name="fail_mode">
334         <p>When a controller is configured, it is, ordinarily, responsible
335           for setting up all flows on the switch.  Thus, if the connection to
336           the controller fails, no new network connections can be set up.
337           If the connection to the controller stays down long enough,
338           no packets can pass through the switch at all.  This setting
339           determines the switch's response to such a situation.  It may be set
340           to one of the following:
341           <dl>
342             <dt><code>standalone</code></dt>
343             <dd>If no message is received from the controller for three
344               times the inactivity probe interval
345               (see <ref column="inactivity_probe"/>), then Open vSwitch
346               will take over responsibility for setting up flows.  In
347               this mode, Open vSwitch causes the bridge to act like an
348               ordinary MAC-learning switch.  Open vSwitch will continue
349               to retry connecting to the controller in the background
350               and, when the connection succeeds, it will discontinue its
351               standalone behavior.</dd>
352             <dt><code>secure</code></dt>
353             <dd>Open vSwitch will not set up flows on its own when the
354               controller connection fails or when no controllers are
355               defined.  The bridge will continue to retry connecting to
356               any defined controllers forever.</dd>
357           </dl>
358         </p>
359         <p>If this value is unset, the default is implementation-specific.</p>
360         <p>When more than one controller is configured,
361           <ref column="fail_mode"/> is considered only when none of the
362           configured controllers can be contacted.</p>
363       </column>
364
365       <column name="datapath_id">
366         Reports the OpenFlow datapath ID in use.  Exactly 16 hex
367         digits.  (Setting this column will have no useful effect.  Set
368         <ref column="other_config"/>:<code>other-config</code>
369         instead.)
370       </column>
371     </group>
372
373     <group title="Other Features">
374       <column name="datapath_type">
375         Name of datapath provider.  The kernel datapath has
376         type <code>system</code>.  The userspace datapath has
377         type <code>netdev</code>.
378       </column>
379
380       <column name="external_ids">
381         Key-value pairs for use by external frameworks that integrate
382         with Open vSwitch, rather than by Open vSwitch itself.  System
383         integrators should either use the Open vSwitch development
384         mailing list to coordinate on common key-value definitions, or
385         choose key names that are likely to be unique.  The currently
386         defined key-value pairs are:
387         <dl>
388           <dt><code>bridge-id</code></dt>
389           <dd>A unique identifier of the bridge.  On Citrix XenServer this
390             will commonly be the same as <code>xs-network-uuids</code>.</dd>
391           <dt><code>xs-network-uuids</code></dt>
392           <dd>Semicolon-delimited set of universally unique identifier(s) for
393             the network with which this bridge is associated on a Citrix
394             XenServer host.  The network identifiers are RFC 4122 UUIDs as
395             displayed by, e.g., <code>xe network-list</code>.</dd>
396         </dl>
397       </column>
398
399       <column name="other_config">
400         Key-value pairs for configuring rarely used bridge
401         features.  The currently defined key-value pairs are:
402         <dl>
403           <dt><code>datapath-id</code></dt>
404           <dd>Exactly 16 hex
405             digits to set the OpenFlow datapath ID to a specific
406             value.  May not be all-zero.</dd>
407           <dt><code>disable-in-band</code></dt>
408           <dd>If set to <code>true</code>, disable in-band control on
409             the bridge regardless of controller and manager settings.</dd>
410           <dt><code>hwaddr</code></dt>
411           <dd>An Ethernet address in the form
412             <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>
413             to set the hardware address of the local port and influence the
414             datapath ID.</dd>
415           <dt><code>in-band-queue</code></dt>
416           <dd>
417             A queue ID as a nonnegative integer.  This sets the OpenFlow queue
418             ID that will be used by flows set up by in-band control on this
419             bridge.  If unset, or if the port used by an in-band control flow
420             does not have QoS configured, or if the port does not have a queue
421             with the specified ID, the default queue is used instead.
422           </dd>
423         </dl>
424       </column>
425     </group>
426   </table>
427
428   <table name="Port" table="Port or bond configuration.">
429     <p>A port within a <ref table="Bridge"/>.</p>
430     <p>Most commonly, a port has exactly one ``interface,'' pointed to by its
431       <ref column="interfaces"/> column.  Such a port logically
432       corresponds to a port on a physical Ethernet switch.  A port
433       with more than one interface is a ``bonded port'' (see
434       <ref group="Bonding Configuration"/>).</p>
435     <p>Some properties that one might think as belonging to a port are actually
436       part of the port's <ref table="Interface"/> members.</p>
437
438     <column name="name">
439       Port name.  Should be alphanumeric and no more than about 8
440       bytes long.  May be the same as the interface name, for
441       non-bonded ports.  Must otherwise be unique among the names of
442       ports, interfaces, and bridges on a host.
443     </column>
444
445     <column name="interfaces">
446       The port's interfaces.  If there is more than one, this is a
447       bonded Port.
448     </column>
449
450     <group title="VLAN Configuration">
451       <p>A bridge port must be configured for VLANs in one of two
452         mutually exclusive ways:
453         <ul>
454           <li>A ``trunk port'' has an empty value for <ref
455             column="tag"/>.  Its <ref column="trunks"/> value may be
456             empty or non-empty.</li>
457           <li>An ``implicitly tagged VLAN port'' or ``access port''
458             has an nonempty value for <ref column="tag"/>.  Its
459             <ref column="trunks"/> value must be empty.</li>
460         </ul>
461         If <ref column="trunks"/> and <ref column="tag"/> are both
462         nonempty, the configuration is ill-formed.
463       </p>
464
465       <column name="tag">
466         <p>
467           If this is an access port (see above), the port's implicitly
468           tagged VLAN.  Must be empty if this is a trunk port.
469         </p>
470         <p>
471           Frames arriving on trunk ports will be forwarded to this
472           port only if they are tagged with the given VLAN (or, if
473           <ref column="tag"/> is 0, then if they lack a VLAN header).
474           Frames arriving on other access ports will be forwarded to
475           this port only if they have the same <ref column="tag"/>
476           value.  Frames forwarded to this port will not have an
477           802.1Q header.
478         </p>
479         <p>
480           When a frame with a 802.1Q header that indicates a nonzero
481           VLAN is received on an access port, it is discarded.
482         </p>
483       </column>
484
485       <column name="trunks">
486         <p>
487           If this is a trunk port (see above), the 802.1Q VLAN(s) that
488           this port trunks; if it is empty, then the port trunks all
489           VLANs.  Must be empty if this is an access port.
490         </p>
491         <p>
492           Frames arriving on trunk ports are dropped if they are not
493           in one of the specified VLANs.  For this purpose, packets
494           that have no VLAN header are treated as part of VLAN 0.
495         </p>
496       </column>
497     </group>
498
499     <group title="Bonding Configuration">
500       <p>A port that has more than one interface is a ``bonded port.'' Bonding
501         allows for load balancing and fail-over.  Some kinds of bonding will
502         work with any kind of upstream switch:</p>
503
504       <dl>
505         <dt><code>balance-slb</code></dt>
506         <dd>
507           Balances flows among slaves based on source MAC address and output
508           VLAN, with periodic rebalancing as traffic patterns change.
509         </dd>
510
511         <dt><code>active-backup</code></dt>
512         <dd>
513           Assigns all flows to one slave, failing over to a backup slave when
514           the active slave is disabled.
515         </dd>
516       </dl>
517
518       <p>
519         The following mode requires the upstream switch to support 802.3ad with
520         successful LACP negotiation.  If LACP negotiation fails then
521         <code>balance-slb</code> mode is used as a fallback:
522       </p>
523
524       <dl>
525         <dt><code>balance-tcp</code></dt>
526         <dd>
527           Balances flows among slaves based on L2, L3, and L4 protocol
528           information such as destination MAC address, IP address, and TCP
529           port.
530         </dd>
531       </dl>
532
533       <p>These columns apply only to bonded ports.  Their values are
534         otherwise ignored.</p>
535
536       <column name="bond_mode">
537         <p>The type of bonding used for a bonded port.  Defaults to
538           <code>balance-slb</code> if unset.
539         </p>
540       </column>
541
542       <column name="bond_updelay">
543         <p>For a bonded port, the number of milliseconds for which carrier must
544           stay up on an interface before the interface is considered to be up.
545           Specify <code>0</code> to enable the interface immediately.</p>
546         <p>This setting is honored only when at least one bonded interface is
547           already enabled.  When no interfaces are enabled, then the first bond
548           interface to come up is enabled immediately.</p>
549       </column>
550
551       <column name="bond_downdelay">
552         For a bonded port, the number of milliseconds for which carrier must
553         stay down on an interface before the interface is considered to be
554         down.  Specify <code>0</code> to disable the interface immediately.
555       </column>
556
557       <column name="bond_fake_iface">
558         For a bonded port, whether to create a fake internal interface with the
559         name of the port.  Use only for compatibility with legacy software that
560         requires this.
561       </column>
562
563       <column name="lacp">
564         <p>Configures LACP on this port.  LACP allows directly connected
565           switches to negotiate which links may be bonded.  LACP may be enabled
566           on non-bonded ports for the benefit of any switches they may be
567           connected to.  <code>active</code> ports are allowed to initiate LACP
568           negotiations.  <code>passive</code> ports are allowed to participate
569           in LACP negotiations initiated by a remote switch, but not allowed to
570           initiate such negotiations themselves. If unset Open vSwitch will
571           choose a reasonable default. </p>
572       </column>
573
574     </group>
575
576     <group title="Other Features">
577       <column name="qos">
578         Quality of Service configuration for this port.
579       </column>
580
581       <column name="mac">
582         The MAC address to use for this port for the purpose of choosing the
583         bridge's MAC address.  This column does not necessarily reflect the
584         port's actual MAC address, nor will setting it change the port's actual
585         MAC address.
586       </column>
587
588       <column name="fake_bridge">
589         Does this port represent a sub-bridge for its tagged VLAN within the
590         Bridge?  See ovs-vsctl(8) for more information.
591       </column>
592
593       <column name="external_ids">
594         <p>
595           Key-value pairs for use by external frameworks that integrate with
596           Open vSwitch, rather than by Open vSwitch itself.  System integrators
597           should either use the Open vSwitch development mailing list to
598           coordinate on common key-value definitions, or choose key names that
599           are likely to be unique.
600         </p>
601         <p>
602           No key-value pairs native to <ref table="Port"/> are currently
603           defined.  For fake bridges (see the <ref column="fake_bridge"/>
604           column), external IDs for the fake bridge are defined here by
605           prefixing a <ref table="Bridge"/> <ref table="Bridge"
606           column="external_ids"/> key with <code>fake-bridge-</code>,
607           e.g. <code>fake-bridge-xs-network-uuids</code>.
608         </p>
609       </column>
610
611       <column name="other_config">
612         Key-value pairs for configuring rarely used port features.  The
613         currently defined key-value pairs are:
614         <dl>
615           <dt><code>hwaddr</code></dt>
616           <dd>An Ethernet address in the form
617             <code><var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var></code>.</dd>
618           <dt><code>bond-rebalance-interval</code></dt>
619           <dd>For an SLB bonded port, the number of milliseconds between
620             successive attempts to rebalance the bond, that is, to
621             move source MACs and their flows from one interface on
622             the bond to another in an attempt to keep usage of each
623             interface roughly equal.  The default is 10000 (10
624             seconds), and the minimum is 1000 (1 second).</dd>
625           <dt><code>bond-detect-mode</code></dt>
626           <dd> Sets the method used to detect link failures in a bonded port.
627             Options are <code>carrier</code> and <code>miimon</code>. Defaults
628             to <code>carrier</code> which uses each interface's carrier to detect
629             failures.  When set to <code>miimon</code>, will check for failures
630             by polling each interface's MII. </dd>
631           <dt><code>bond-miimon-interval</code></dt>
632           <dd> The number of milliseconds between successive attempts to
633             poll each interface's MII.  Only relevant on ports which use
634             <code>miimon</code> to detect failures. </dd>
635           <dt><code>lacp-system-priority</code></dt>
636           <dd> The LACP system priority of this <ref table="Port"/>.  In
637             LACP negotiations, link status decisions are made by the system
638             with the numerically lower priority.  Must be a number between 1
639             and 65535.</dd>
640           <dt><code>lacp-time</code></dt>
641           <dd> The LACP timing which should be used on this
642             <ref table="Port"/>.  Possible values are <code>fast</code> and
643             <code>slow</code>.  By default <code>slow</code> is used.  When
644             configured to be <code>fast</code> more frequent LACP heartbeats
645             will be requested causing connectivity problems to be detected more
646             quickly.</dd>
647         </dl>
648       </column>
649     </group>
650   </table>
651
652   <table name="Interface" title="One physical network device in a Port.">
653     An interface within a <ref table="Port"/>.
654
655     <group title="Core Features">
656       <column name="name">
657         Interface name.  Should be alphanumeric and no more than about 8 bytes
658         long.  May be the same as the port name, for non-bonded ports.  Must
659         otherwise be unique among the names of ports, interfaces, and bridges
660         on a host.
661       </column>
662
663       <column name="mac">
664         <p>Ethernet address to set for this interface.  If unset then the
665           default MAC address is used:</p>
666         <ul>
667           <li>For the local interface, the default is the lowest-numbered MAC
668             address among the other bridge ports, either the value of the
669             <ref table="Port" column="mac"/> in its <ref table="Port"/> record,
670             if set, or its actual MAC (for bonded ports, the MAC of its slave
671             whose name is first in alphabetical order).  Internal ports and
672             bridge ports that are used as port mirroring destinations (see the
673             <ref table="Mirror"/> table) are ignored.</li>
674           <li>For other internal interfaces, the default MAC is randomly
675             generated.</li>
676           <li>External interfaces typically have a MAC address associated with
677             their hardware.</li>
678         </ul>
679         <p>Some interfaces may not have a software-controllable MAC
680         address.</p>
681       </column>
682
683       <column name="ofport">
684         <p>OpenFlow port number for this interface.  Unlike most columns, this
685           column's value should be set only by Open vSwitch itself.  Other
686           clients should set this column to an empty set (the default) when
687           creating an <ref table="Interface"/>.</p>
688         <p>Open vSwitch populates this column when the port number becomes
689           known.  If the interface is successfully added,
690           <ref column="ofport"/> will be set to a number between 1 and 65535
691           (generally either in the range 1 to 65279, inclusive, or 65534, the
692           port number for the OpenFlow ``local port'').  If the interface
693           cannot be added then Open vSwitch sets this column
694           to -1.</p>
695       </column>
696     </group>
697
698     <group title="System-Specific Details">
699       <column name="type">
700         The interface type, one of:
701         <dl>
702           <dt><code>system</code></dt>
703           <dd>An ordinary network device, e.g. <code>eth0</code> on Linux.
704             Sometimes referred to as ``external interfaces'' since they are
705             generally connected to hardware external to that on which the Open
706             vSwitch is running.  The empty string is a synonym for
707             <code>system</code>.</dd>
708           <dt><code>internal</code></dt>
709           <dd>A simulated network device that sends and receives traffic.  An
710             internal interface whose <ref column="name"/> is the same as its
711             bridge's <ref table="Open_vSwitch" column="name"/> is called the
712             ``local interface.''  It does not make sense to bond an internal
713             interface, so the terms ``port'' and ``interface'' are often used
714             imprecisely for internal interfaces.</dd>
715           <dt><code>tap</code></dt>
716           <dd>A TUN/TAP device managed by Open vSwitch.</dd>
717           <dt><code>gre</code></dt>
718           <dd>An Ethernet over RFC 2890 Generic Routing Encapsulation over IPv4
719              tunnel.  Each tunnel must be uniquely identified by the
720              combination of <code>remote_ip</code>, <code>local_ip</code>, and
721              <code>in_key</code>.  Note that if two ports are defined that are
722              the same except one has an optional identifier and the other does
723              not, the more specific one is matched first.  <code>in_key</code>
724              is considered more specific than <code>local_ip</code> if a port
725              defines one and another port defines the other.  The following
726              options may be specified in the <ref column="options"/> column:
727             <dl>
728               <dt><code>remote_ip</code></dt>
729               <dd>Required.  The tunnel endpoint.</dd>
730             </dl>
731             <dl>
732               <dt><code>local_ip</code></dt>
733               <dd>Optional.  The destination IP that received packets must
734                 match.  Default is to match all addresses.</dd>
735             </dl>
736             <dl>
737               <dt><code>in_key</code></dt>
738               <dd>Optional.  The GRE key that received packets must contain.
739                 It may either be a 32-bit number (no key and a key of 0 are
740                 treated as equivalent) or the word <code>flow</code>.  If
741                 <code>flow</code> is specified then any key will be accepted
742                 and the key will be placed in the <code>tun_id</code> field
743                 for matching in the flow table.  The ovs-ofctl manual page
744                 contains additional information about matching fields in
745                 OpenFlow flows.  Default is no key.</dd>
746             </dl>
747             <dl>
748               <dt><code>out_key</code></dt>
749               <dd>Optional.  The GRE key to be set on outgoing packets.  It may
750                 either be a 32-bit number or the word <code>flow</code>.  If
751                 <code>flow</code> is specified then the key may be set using
752                 the <code>set_tunnel</code> Nicira OpenFlow vendor extension (0
753                 is used in the absence of an action).  The ovs-ofctl manual
754                 page contains additional information about the Nicira OpenFlow
755                 vendor extensions.  Default is no key.</dd>
756             </dl>
757             <dl>
758               <dt><code>key</code></dt>
759               <dd>Optional.  Shorthand to set <code>in_key</code> and
760                 <code>out_key</code> at the same time.</dd>
761             </dl>
762             <dl>
763               <dt><code>tos</code></dt>
764               <dd>Optional.  The value of the ToS bits to be set on the
765                 encapsulating packet.  It may also be the word
766                 <code>inherit</code>, in which case the ToS will be copied from
767                 the inner packet if it is IPv4 or IPv6 (otherwise it will be
768                 0).  Note that the ECN fields are always inherited.  Default is
769                 0.</dd>
770             </dl>
771             <dl>
772               <dt><code>ttl</code></dt>
773               <dd>Optional.  The TTL to be set on the encapsulating packet.
774                 It may also be the word <code>inherit</code>, in which case the
775                 TTL will be copied from the inner packet if it is IPv4 or IPv6
776                 (otherwise it will be the system default, typically 64).
777                 Default is the system default TTL.</dd>
778             </dl>
779             <dl>
780               <dt><code>csum</code></dt>
781               <dd>Optional.  Compute GRE checksums on outgoing packets.
782                 Checksums present on incoming packets will be validated
783                 regardless of this setting.  Note that GRE checksums
784                 impose a significant performance penalty as they cover the
785                 entire packet.  As the contents of the packet is typically
786                 covered by L3 and L4 checksums, this additional checksum only
787                 adds value for the GRE and encapsulated Ethernet headers.
788                 Default is disabled, set to <code>true</code> to enable.</dd>
789             </dl>
790             <dl>
791               <dt><code>pmtud</code></dt>
792               <dd>Optional.  Enable tunnel path MTU discovery.  If enabled
793                 ``ICMP destination unreachable - fragmentation'' needed
794                 messages will be generated for IPv4 packets with the DF bit set
795                 and IPv6 packets above the minimum MTU if the packet size
796                 exceeds the path MTU minus the size of the tunnel headers.  It
797                 also forces the encapsulating packet DF bit to be set (it is
798                 always set if the inner packet implies path MTU discovery).
799                 Note that this option causes behavior that is typically
800                 reserved for routers and therefore is not entirely in
801                 compliance with the IEEE 802.1D specification for bridges.
802                 Default is enabled, set to <code>false</code> to disable.</dd>
803             </dl>
804             <dl>
805               <dt><code>header_cache</code></dt>
806               <dd>Optional.  Enable caching of tunnel headers and the output
807                 path.  This can lead to a significant performance increase
808                 without changing behavior.  In general it should not be
809                 necessary to adjust this setting.  However, the caching can
810                 bypass certain components of the IP stack (such as IP tables)
811                 and it may be useful to disable it if these features are
812                 required or as a debugging measure.  Default is enabled, set to
813                 <code>false</code> to disable.</dd>
814             </dl>
815           </dd>
816           <dt><code>ipsec_gre</code></dt>
817           <dd>An Ethernet over RFC 2890 Generic Routing Encapsulation
818             over IPv4 IPsec tunnel.  Each tunnel (including those of type
819             <code>gre</code>) must be uniquely identified by the
820             combination of <code>remote_ip</code> and
821             <code>local_ip</code>.  Note that if two ports are defined
822             that are the same except one has an optional identifier and
823             the other does not, the more specific one is matched first.
824             An authentication method of <code>peer_cert</code> or
825             <code>psk</code> must be defined.  The following options may
826             be specified in the <ref column="options"/> column:
827             <dl>
828               <dt><code>remote_ip</code></dt>
829               <dd>Required.  The tunnel endpoint.</dd>
830             </dl>
831             <dl>
832               <dt><code>local_ip</code></dt>
833               <dd>Optional.  The destination IP that received packets must
834                 match.  Default is to match all addresses.</dd>
835             </dl>
836             <dl>
837               <dt><code>peer_cert</code></dt>
838               <dd>Required for certificate authentication.  A string
839                 containing the peer's certificate in PEM format.
840                 Additionally the host's certificate must be specified
841                 with the <code>certificate</code> option.</dd>
842             </dl>
843             <dl>
844               <dt><code>certificate</code></dt>
845               <dd>Required for certificate authentication.  The name of a
846                 PEM file containing a certificate that will be presented
847                 to the peer during authentication.</dd>
848             </dl>
849             <dl>
850               <dt><code>private_key</code></dt>
851               <dd>Optional for certificate authentication.  The name of
852                 a PEM file containing the private key associated with
853                 <code>certificate</code>.  If <code>certificate</code>
854                 contains the private key, this option may be omitted.</dd>
855             </dl>
856             <dl>
857               <dt><code>psk</code></dt>
858               <dd>Required for pre-shared key authentication.  Specifies a
859                 pre-shared key for authentication that must be identical on
860                 both sides of the tunnel.</dd>
861             </dl>
862             <dl>
863               <dt><code>in_key</code></dt>
864               <dd>Optional.  The GRE key that received packets must contain.
865                 It may either be a 32-bit number (no key and a key of 0 are
866                 treated as equivalent) or the word <code>flow</code>.  If
867                 <code>flow</code> is specified then any key will be accepted
868                 and the key will be placed in the <code>tun_id</code> field
869                 for matching in the flow table.  The ovs-ofctl manual page
870                 contains additional information about matching fields in
871                 OpenFlow flows.  Default is no key.</dd>
872             </dl>
873             <dl>
874               <dt><code>out_key</code></dt>
875               <dd>Optional.  The GRE key to be set on outgoing packets.  It may
876                 either be a 32-bit number or the word <code>flow</code>.  If
877                 <code>flow</code> is specified then the key may be set using
878                 the <code>set_tunnel</code> Nicira OpenFlow vendor extension (0
879                 is used in the absence of an action).  The ovs-ofctl manual
880                 page contains additional information about the Nicira OpenFlow
881                 vendor extensions.  Default is no key.</dd>
882             </dl>
883             <dl>
884               <dt><code>key</code></dt>
885               <dd>Optional.  Shorthand to set <code>in_key</code> and
886                 <code>out_key</code> at the same time.</dd>
887             </dl>
888             <dl>
889               <dt><code>tos</code></dt>
890               <dd>Optional.  The value of the ToS bits to be set on the
891                 encapsulating packet.  It may also be the word
892                 <code>inherit</code>, in which case the ToS will be copied from
893                 the inner packet if it is IPv4 or IPv6 (otherwise it will be
894                 0).  Note that the ECN fields are always inherited.  Default is
895                 0.</dd>
896             </dl>
897             <dl>
898               <dt><code>ttl</code></dt>
899               <dd>Optional.  The TTL to be set on the encapsulating packet.
900                 It may also be the word <code>inherit</code>, in which case the
901                 TTL will be copied from the inner packet if it is IPv4 or IPv6
902                 (otherwise it will be the system default, typically 64).
903                 Default is the system default TTL.</dd>
904             </dl>
905             <dl>
906               <dt><code>csum</code></dt>
907               <dd>Optional.  Compute GRE checksums on outgoing packets.
908                 Checksums present on incoming packets will be validated
909                 regardless of this setting.  Note that GRE checksums
910                 impose a significant performance penalty as they cover the
911                 entire packet.  As the contents of the packet is typically
912                 covered by L3 and L4 checksums, this additional checksum only
913                 adds value for the GRE and encapsulated Ethernet headers.
914                 Default is disabled, set to <code>true</code> to enable.</dd>
915             </dl>
916             <dl>
917               <dt><code>pmtud</code></dt>
918               <dd>Optional.  Enable tunnel path MTU discovery.  If enabled
919                 ``ICMP destination unreachable - fragmentation'' needed
920                 messages will be generated for IPv4 packets with the DF bit set
921                 and IPv6 packets above the minimum MTU if the packet size
922                 exceeds the path MTU minus the size of the tunnel headers.  It
923                 also forces the encapsulating packet DF bit to be set (it is
924                 always set if the inner packet implies path MTU discovery).
925                 Note that this option causes behavior that is typically
926                 reserved for routers and therefore is not entirely in
927                 compliance with the IEEE 802.1D specification for bridges.
928                 Default is enabled, set to <code>false</code> to disable.</dd>
929             </dl>
930           </dd>
931           <dt><code>capwap</code></dt>
932           <dd>Ethernet tunneling over the UDP transport portion of CAPWAP
933              (RFC 5415).  This allows interoperability with certain switches
934              where GRE is not available.  Note that only the tunneling component
935              of the protocol is implemented.  Due to the non-standard use of
936              CAPWAP, UDP ports 58881 and 58882 are used as the source and
937              destination ports respectively.  Each tunnel must be uniquely
938              identified by the combination of <code>remote_ip</code> and
939              <code>local_ip</code>.  If two ports are defined that are the same
940              except one includes <code>local_ip</code> and the other does not,
941              the more specific one is matched first.  CAPWAP support is not
942              available on all platforms.  Currently it is only supported in the
943              Linux kernel module with kernel versions >= 2.6.25.  The following
944              options may be specified in the <ref column="options"/> column:
945             <dl>
946               <dt><code>remote_ip</code></dt>
947               <dd>Required.  The tunnel endpoint.</dd>
948             </dl>
949             <dl>
950               <dt><code>local_ip</code></dt>
951               <dd>Optional.  The destination IP that received packets must
952                 match.  Default is to match all addresses.</dd>
953             </dl>
954             <dl>
955               <dt><code>tos</code></dt>
956               <dd>Optional.  The value of the ToS bits to be set on the
957                 encapsulating packet.  It may also be the word
958                 <code>inherit</code>, in which case the ToS will be copied from
959                 the inner packet if it is IPv4 or IPv6 (otherwise it will be
960                 0).  Note that the ECN fields are always inherited.  Default is
961                 0.</dd>
962             </dl>
963             <dl>
964               <dt><code>ttl</code></dt>
965               <dd>Optional.  The TTL to be set on the encapsulating packet.
966                 It may also be the word <code>inherit</code>, in which case the
967                 TTL will be copied from the inner packet if it is IPv4 or IPv6
968                 (otherwise it will be the system default, typically 64).
969                 Default is the system default TTL.</dd>
970             </dl>
971             <dl>
972               <dt><code>pmtud</code></dt>
973               <dd>Optional.  Enable tunnel path MTU discovery.  If enabled
974                 ``ICMP destination unreachable - fragmentation'' needed
975                 messages will be generated for IPv4 packets with the DF bit set
976                 and IPv6 packets above the minimum MTU if the packet size
977                 exceeds the path MTU minus the size of the tunnel headers.  It
978                 also forces the encapsulating packet DF bit to be set (it is
979                 always set if the inner packet implies path MTU discovery).
980                 Note that this option causes behavior that is typically
981                 reserved for routers and therefore is not entirely in
982                 compliance with the IEEE 802.1D specification for bridges.
983                 Default is enabled, set to <code>false</code> to disable.</dd>
984             </dl>
985             <dl>
986               <dt><code>header_cache</code></dt>
987               <dd>Optional.  Enable caching of tunnel headers and the output
988                 path.  This can lead to a significant performance increase
989                 without changing behavior.  In general it should not be
990                 necessary to adjust this setting.  However, the caching can
991                 bypass certain components of the IP stack (such as IP tables)
992                 and it may be useful to disable it if these features are
993                 required or as a debugging measure.  Default is enabled, set to
994                 <code>false</code> to disable.</dd>
995             </dl>
996           </dd>
997           <dt><code>patch</code></dt>
998           <dd>
999             <p>
1000               A pair of virtual devices that act as a patch cable.  The <ref
1001               column="options"/> column must have the following key-value pair:
1002             </p>
1003             <dl>
1004               <dt><code>peer</code></dt>
1005               <dd>
1006                 The <ref column="name"/> of the <ref table="Interface"/> for
1007                 the other side of the patch.  The named <ref
1008                 table="Interface"/>'s own <code>peer</code> option must specify
1009                 this <ref table="Interface"/>'s name.  That is, the two patch
1010                 interfaces must have reversed <ref column="name"/> and
1011                 <code>peer</code> values.
1012               </dd>
1013             </dl>
1014           </dd>
1015         </dl>
1016       </column>
1017
1018       <column name="options">
1019         Configuration options whose interpretation varies based on
1020         <ref column="type"/>.
1021       </column>
1022     </group>
1023
1024     <group title="Interface Status">
1025       <p>
1026         Status information about interfaces attached to bridges, updated every
1027         5 seconds.  Not all interfaces have all of these properties; virtual
1028         interfaces don't have a link speed, for example.  Non-applicable
1029         columns will have empty values.
1030       </p>
1031       <column name="admin_state">
1032         <p>
1033           The administrative state of the physical network link.
1034         </p>
1035       </column>
1036
1037       <column name="link_state">
1038         <p>
1039           The observed state of the physical network link;
1040           i.e. whether a carrier is detected by the interface.
1041         </p>
1042       </column>
1043
1044       <column name="link_speed">
1045         <p>
1046           The negotiated speed of the physical network link.
1047           Valid values are positive integers greater than 0.
1048         </p>
1049       </column>
1050
1051       <column name="duplex">
1052         <p>
1053           The duplex mode of the physical network link.
1054         </p>
1055       </column>
1056
1057       <column name="mtu">
1058         <p>
1059           The MTU (maximum transmission unit); i.e. the largest
1060           amount of data that can fit into a single Ethernet frame.
1061           The standard Ethernet MTU is 1500 bytes.  Some physical media
1062           and many kinds of virtual interfaces can be configured with
1063           higher MTUs.
1064         </p>
1065         <p>
1066           This column will be empty for an interface that does not
1067           have an MTU as, for example, some kinds of tunnels do not.
1068         </p>
1069       </column>
1070
1071       <column name="status">
1072         <p>
1073           Key-value pairs that report port status.  Supported status
1074           values are <code>type</code>-dependent; some interfaces may not have
1075           a valid <code>driver_name</code>, for example.
1076         </p>
1077         <p>The currently defined key-value pairs are:</p>
1078         <dl>
1079           <dt><code>driver_name</code></dt>
1080           <dd>The name of the device driver controlling the network
1081             adapter.</dd>
1082         </dl>
1083         <dl>
1084           <dt><code>driver_version</code></dt>
1085           <dd>The version string of the device driver controlling the
1086             network adapter.</dd>
1087         </dl>
1088         <dl>
1089           <dt><code>firmware_version</code></dt>
1090           <dd>The version string of the network adapter's firmware, if
1091             available.</dd>
1092         </dl>
1093         <dl>
1094           <dt><code>source_ip</code></dt>
1095           <dd>The source IP address used for an IPv4 tunnel end-point,
1096             such as <code>gre</code> or <code>capwap</code>.</dd>
1097         </dl>
1098         <dl>
1099             <dt><code>tunnel_egress_iface</code></dt>
1100             <dd>Egress interface for tunnels.  Currently only relevant for GRE
1101                 and CAPWAP tunnels.  On Linux systems, this column will show
1102                 the name of the interface which is responsible for routing
1103                 traffic destined for the configured <code>remote_ip</code>.
1104                 This could be an internal interface such as a bridge port.</dd>
1105         </dl>
1106         <dl>
1107             <dt><code>tunnel_egress_iface_carrier</code></dt>
1108             <dd>Whether a carrier is detected on <ref
1109             column="tunnel_egress_iface"/>.  Valid values are <code>down</code>
1110             and <code>up</code>.</dd>
1111         </dl>
1112       </column>
1113     </group>
1114
1115     <group title="Ingress Policing">
1116       <p>
1117         These settings control ingress policing for packets received on this
1118         interface.  On a physical interface, this limits the rate at which
1119         traffic is allowed into the system from the outside; on a virtual
1120         interface (one connected to a virtual machine), this limits the rate at
1121         which the VM is able to transmit.
1122       </p>
1123       <p>
1124         Policing is a simple form of quality-of-service that simply drops
1125         packets received in excess of the configured rate.  Due to its
1126         simplicity, policing is usually less accurate and less effective than
1127         egress QoS (which is configured using the <ref table="QoS"/> and <ref
1128         table="Queue"/> tables).
1129       </p>
1130       <p>
1131         Policing is currently implemented only on Linux.  The Linux
1132         implementation uses a simple ``token bucket'' approach:
1133       </p>
1134       <ul>
1135         <li>
1136           The size of the bucket corresponds to <ref
1137           column="ingress_policing_burst"/>.  Initially the bucket is full.
1138         </li>
1139         <li>
1140           Whenever a packet is received, its size (converted to tokens) is
1141           compared to the number of tokens currently in the bucket.  If the
1142           required number of tokens are available, they are removed and the
1143           packet is forwarded.  Otherwise, the packet is dropped.
1144         </li>
1145         <li>
1146           Whenever it is not full, the bucket is refilled with tokens at the
1147           rate specified by <ref column="ingress_policing_rate"/>.
1148         </li>
1149       </ul>
1150       <p>
1151         Policing interacts badly with some network protocols, and especially
1152         with fragmented IP packets.  Suppose that there is enough network
1153         activity to keep the bucket nearly empty all the time.  Then this token
1154         bucket algorithm will forward a single packet every so often, with the
1155         period depending on packet size and on the configured rate.  All of the
1156         fragments of an IP packets are normally transmitted back-to-back, as a
1157         group.  In such a situation, therefore, only one of these fragments
1158         will be forwarded and the rest will be dropped.  IP does not provide
1159         any way for the intended recipient to ask for only the remaining
1160         fragments.  In such a case there are two likely possibilities for what
1161         will happen next: either all of the fragments will eventually be
1162         retransmitted (as TCP will do), in which case the same problem will
1163         recur, or the sender will not realize that its packet has been dropped
1164         and data will simply be lost (as some UDP-based protocols will do).
1165         Either way, it is possible that no forward progress will ever occur.
1166       </p>
1167       <column name="ingress_policing_rate">
1168         <p>
1169           Maximum rate for data received on this interface, in kbps.  Data
1170           received faster than this rate is dropped.  Set to <code>0</code>
1171           (the default) to disable policing.
1172         </p>
1173       </column>
1174
1175       <column name="ingress_policing_burst">
1176         <p>Maximum burst size for data received on this interface, in kb.  The
1177           default burst size if set to <code>0</code> is 1000 kb.  This value
1178           has no effect if <ref column="ingress_policing_rate"/>
1179           is <code>0</code>.</p>
1180         <p>
1181           Specifying a larger burst size lets the algorithm be more forgiving,
1182           which is important for protocols like TCP that react severely to
1183           dropped packets.  The burst size should be at least the size of the
1184           interface's MTU.  Specifying a value that is numerically at least as
1185           large as 10% of <ref column="ingress_policing_rate"/> helps TCP come
1186           closer to achieving the full rate.
1187         </p>
1188       </column>
1189     </group>
1190
1191     <group title="Other Features">
1192
1193       <column name="monitor">
1194         Connectivity monitor configuration for this interface.
1195       </column>
1196
1197       <column name="external_ids">
1198         Key-value pairs for use by external frameworks that integrate
1199         with Open vSwitch, rather than by Open vSwitch itself.  System
1200         integrators should either use the Open vSwitch development
1201         mailing list to coordinate on common key-value definitions, or
1202         choose key names that are likely to be unique.  The currently
1203         defined common key-value pairs are:
1204         <dl>
1205           <dt><code>attached-mac</code></dt>
1206           <dd>
1207             The MAC address programmed into the ``virtual hardware'' for this
1208             interface, in the form
1209             <var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>:<var>xx</var>.
1210             For Citrix XenServer, this is the value of the <code>MAC</code>
1211             field in the VIF record for this interface.</dd>
1212           <dt><code>iface-id</code></dt>
1213           <dd>A system-unique identifier for the interface.  On XenServer,
1214             this will commonly be the same as <code>xs-vif-uuid</code>.</dd>
1215         </dl>
1216         <p>
1217           Additionally the following key-value pairs specifically
1218           apply to an interface that represents a virtual Ethernet interface
1219           connected to a virtual machine.  These key-value pairs should not be
1220           present for other types of interfaces.  Keys whose names end
1221           in <code>-uuid</code> have values that uniquely identify the entity
1222           in question.  For a Citrix XenServer hypervisor, these values are
1223           UUIDs in RFC 4122 format.  Other hypervisors may use other
1224           formats.
1225         </p>
1226         <p>The currently defined key-value pairs for XenServer are:</p>
1227         <dl>
1228           <dt><code>xs-vif-uuid</code></dt>
1229           <dd>The virtual interface associated with this interface.</dd>
1230           <dt><code>xs-network-uuid</code></dt>
1231           <dd>The virtual network to which this interface is attached.</dd>
1232           <dt><code>xs-vm-uuid</code></dt>
1233           <dd>The VM to which this interface belongs.</dd>
1234         </dl>
1235       </column>
1236
1237       <column name="other_config">
1238         Key-value pairs for rarely used interface features.
1239         <dl>
1240           <dt><code>lacp-port-priority</code></dt>
1241           <dd> The LACP port priority of this <ref table="Interface"/>.  In
1242             LACP negotiations <ref table="Interface"/>s with numerically lower
1243             priorities are preferred for aggregation.  Must be a number between
1244             1 and 65535.</dd>
1245         </dl>
1246       </column>
1247
1248       <column name="statistics">
1249         <p>
1250           Key-value pairs that report interface statistics.  The current
1251           implementation updates these counters periodically.  In the future,
1252           we plan to, instead, update them when an interface is created, when
1253           they are queried (e.g. using an OVSDB <code>select</code> operation),
1254           and just before an interface is deleted due to virtual interface
1255           hot-unplug or VM shutdown, and perhaps at other times, but not on any
1256           regular periodic basis.</p>
1257         <p>
1258           The currently defined key-value pairs are listed below.  These are
1259           the same statistics reported by OpenFlow in its <code>struct
1260           ofp_port_stats</code> structure.  If an interface does not support a
1261           given statistic, then that pair is omitted.</p>
1262         <ul>
1263           <li>
1264             Successful transmit and receive counters:
1265             <dl>
1266               <dt><code>rx_packets</code></dt>
1267               <dd>Number of received packets.</dd>
1268               <dt><code>rx_bytes</code></dt>
1269               <dd>Number of received bytes.</dd>
1270               <dt><code>tx_packets</code></dt>
1271               <dd>Number of transmitted packets.</dd>
1272               <dt><code>tx_bytes</code></dt>
1273               <dd>Number of transmitted bytes.</dd>
1274             </dl>
1275           </li>
1276           <li>
1277             Receive errors:
1278             <dl>
1279               <dt><code>rx_dropped</code></dt>
1280               <dd>Number of packets dropped by RX.</dd>
1281               <dt><code>rx_frame_err</code></dt>
1282               <dd>Number of frame alignment errors.</dd>
1283               <dt><code>rx_over_err</code></dt>
1284               <dd>Number of packets with RX overrun.</dd>
1285               <dt><code>rx_crc_err</code></dt>
1286               <dd>Number of CRC errors.</dd>
1287               <dt><code>rx_errors</code></dt>
1288               <dd>
1289                 Total number of receive errors, greater than or equal
1290                 to the sum of the above.
1291               </dd>
1292             </dl>
1293           </li>
1294           <li>
1295             Transmit errors:
1296             <dl>
1297               <dt><code>tx_dropped</code></dt>
1298               <dd>Number of packets dropped by TX.</dd>
1299               <dt><code>collisions</code></dt>
1300               <dd>Number of collisions.</dd>
1301               <dt><code>tx_errors</code></dt>
1302               <dd>
1303                 Total number of transmit errors, greater
1304                 than or equal to the sum of the above.
1305               </dd>
1306             </dl>
1307           </li>
1308         </ul>
1309       </column>
1310     </group>
1311   </table>
1312
1313   <table name="QoS" title="Quality of Service configuration">
1314     <p>Quality of Service (QoS) configuration for each Port that
1315       references it.</p>
1316
1317     <column name="type">
1318       <p>The type of QoS to implement.  The <ref table="Open_vSwitch"
1319         column="capabilities"/> column in the <ref table="Open_vSwitch"/> table
1320         identifies the types that a switch actually supports.  The currently
1321         defined types are listed below:</p>
1322       <dl>
1323         <dt><code>linux-htb</code></dt>
1324         <dd>
1325           Linux ``hierarchy token bucket'' classifier.  See tc-htb(8) (also at
1326           <code>http://linux.die.net/man/8/tc-htb</code>) and the HTB manual
1327           (<code>http://luxik.cdi.cz/~devik/qos/htb/manual/userg.htm</code>)
1328           for information on how this classifier works and how to configure it.
1329         </dd>
1330       </dl>
1331       <dl>
1332         <dt><code>linux-hfsc</code></dt>
1333         <dd>
1334           Linux "Hierarchical Fair Service Curve" classifier.
1335           See <code>http://linux-ip.net/articles/hfsc.en/</code> for
1336           information on how this classifier works.
1337         </dd>
1338       </dl>
1339     </column>
1340
1341     <column name="queues">
1342       <p>A map from queue numbers to <ref table="Queue"/> records.  The
1343         supported range of queue numbers depend on <ref column="type"/>.  The
1344         queue numbers are the same as the <code>queue_id</code> used in
1345         OpenFlow in <code>struct ofp_action_enqueue</code> and other
1346         structures.  Queue 0 is used by OpenFlow output actions that do not
1347         specify a specific queue.</p>
1348     </column>
1349
1350     <column name="other_config">
1351       <p>Key-value pairs for configuring QoS features that depend on
1352         <ref column="type"/>.</p>
1353       <p>The <code>linux-htb</code> and <code>linux-hfsc</code> classes support
1354           the following key-value pairs:</p>
1355       <dl>
1356         <dt><code>max-rate</code></dt>
1357         <dd>Maximum rate shared by all queued traffic, in bit/s.
1358           Optional.  If not specified, for physical interfaces, the
1359           default is the link rate.  For other interfaces or if the
1360           link rate cannot be determined, the default is currently 100
1361           Mbps.</dd>
1362       </dl>
1363     </column>
1364
1365     <column name="external_ids">
1366       Key-value pairs for use by external frameworks that integrate with Open
1367       vSwitch, rather than by Open vSwitch itself.  System integrators should
1368       either use the Open vSwitch development mailing list to coordinate on
1369       common key-value definitions, or choose key names that are likely to be
1370       unique.  No common key-value pairs are currently defined.
1371     </column>
1372   </table>
1373
1374   <table name="Queue" title="QoS output queue.">
1375     <p>A configuration for a port output queue, used in configuring Quality of
1376       Service (QoS) features.  May be referenced by <ref column="queues"
1377       table="QoS"/> column in <ref table="QoS"/> table.</p>
1378
1379     <column name="other_config">
1380       <p>Key-value pairs for configuring the output queue.  The supported
1381         key-value pairs and their meanings depend on the <ref column="type"/>
1382         of the <ref column="QoS"/> records that reference this row.</p>
1383       <p>The key-value pairs defined for <ref table="QoS"/> <ref table="QoS"
1384         column="type"/> of <code>min-rate</code> are:</p>
1385       <dl>
1386         <dt><code>min-rate</code></dt>
1387         <dd>Minimum guaranteed bandwidth, in bit/s.  Required.  The
1388           floor value is 1500 bytes/s (12,000 bit/s).</dd>
1389       </dl>
1390       <p>The key-value pairs defined for <ref table="QoS"/> <ref table="QoS"
1391         column="type"/> of <code>linux-htb</code> are:</p>
1392       <dl>
1393         <dt><code>min-rate</code></dt>
1394         <dd>Minimum guaranteed bandwidth, in bit/s.</dd>
1395         <dt><code>max-rate</code></dt>
1396         <dd>Maximum allowed bandwidth, in bit/s.  Optional.  If specified, the
1397           queue's rate will not be allowed to exceed the specified value, even
1398           if excess bandwidth is available.  If unspecified, defaults to no
1399           limit.</dd>
1400         <dt><code>burst</code></dt>
1401         <dd>Burst size, in bits.  This is the maximum amount of ``credits''
1402           that a queue can accumulate while it is idle.  Optional.  Details of
1403           the <code>linux-htb</code> implementation require a minimum burst
1404           size, so a too-small <code>burst</code> will be silently
1405           ignored.</dd>
1406         <dt><code>priority</code></dt>
1407         <dd>A nonnegative 32-bit integer.  Defaults to 0 if
1408           unspecified.  A queue with a smaller <code>priority</code>
1409           will receive all the excess bandwidth that it can use before
1410           a queue with a larger value receives any.  Specific priority
1411           values are unimportant; only relative ordering matters.</dd>
1412       </dl>
1413       <p>The key-value pairs defined for <ref table="QoS"/> <ref table="QoS"
1414         column="type"/> of <code>linux-hfsc</code> are:</p>
1415       <dl>
1416         <dt><code>min-rate</code></dt>
1417         <dd>Minimum guaranteed bandwidth, in bit/s.</dd>
1418         <dt><code>max-rate</code></dt>
1419         <dd>Maximum allowed bandwidth, in bit/s.  Optional.  If specified, the
1420           queue's rate will not be allowed to exceed the specified value, even
1421           if excess bandwidth is available.  If unspecified, defaults to no
1422           limit.</dd>
1423       </dl>
1424     </column>
1425
1426     <column name="external_ids">
1427       Key-value pairs for use by external frameworks that integrate with Open
1428       vSwitch, rather than by Open vSwitch itself.  System integrators should
1429       either use the Open vSwitch development mailing list to coordinate on
1430       common key-value definitions, or choose key names that are likely to be
1431       unique.  No common key-value pairs are currently defined.
1432     </column>
1433   </table>
1434
1435   <table name="Monitor" title="Connectivity Monitor configuration">
1436     <p>
1437       A <ref table="Monitor"/> attaches to an <ref table="Interface"/> to
1438       implement 802.1ag Connectivity Fault Management (CFM).  CFM allows a
1439       group of Maintenance Points (MPs) called a Maintenance Association (MA)
1440       to detect connectivity problems with each other.  MPs within a MA should
1441       have complete and exclusive interconnectivity.  This is verified by
1442       occasionally broadcasting Continuity Check Messages (CCMs) at a
1443       configurable transmission interval.  A <ref table="Monitor"/> is
1444       responsible for collecting data about other MPs in its MA and
1445       broadcasting CCMs.
1446     </p>
1447
1448     <group title="Monitor Configuration">
1449       <column name="mpid">
1450         A Maintenance Point ID (MPID) uniquely identifies each endpoint within
1451         a Maintenance Association (see <ref column="ma_name"/>).  The MPID is
1452         used to identify this <ref table="Monitor"/> to other endpoints in the
1453         MA.
1454       </column>
1455
1456       <column name="remote_mps">
1457         A set of <ref table="Maintenance_Points"/> which this
1458         <ref table="Monitor"/> should have connectivity to.  If this
1459         <ref table="Monitor"/> does not have connectivity to any MPs in this
1460         set, or has connectivity to any MPs not in this set, a fault is
1461         signaled.
1462       </column>
1463
1464       <column name="ma_name">
1465         A Maintenance Association (MA) name pairs with a Maintenance Domain
1466         (MD) name to uniquely identify a MA.  A MA is a group of endpoints who
1467         have complete and exclusive interconnectivity. Defaults to
1468         <code>ovs</code> if unset.
1469       </column>
1470
1471       <column name="md_name">
1472         A Maintenance Domain name pairs with a Maintenance Association name to
1473         uniquely identify a MA. Defaults to <code>ovs</code> if unset.
1474       </column>
1475
1476       <column name="interval">
1477         The transmission interval of CCMs in milliseconds.  Three missed CCMs
1478         indicate a connectivity fault.  Defaults to 1000ms.
1479       </column>
1480     </group>
1481
1482     <group title="Monitor Status">
1483       <column name="unexpected_remote_mpids">
1484         A set of MPIDs representing MPs to which this <ref table="Monitor"/>
1485         has detected connectivity that are not in the
1486         <ref column="remote_mps"/> set.  This <ref table="Monitor"/> should not
1487         have connectivity to any MPs not listed in <ref column="remote_mps"/>.
1488         Thus, if this set is non-empty a fault is indicated.
1489       </column>
1490
1491       <column name="unexpected_remote_maids">
1492         A set of MAIDs representing foreign Maintenance Associations (MAs)
1493         which this <ref table="Monitor"/> has detected connectivity to. A
1494         <ref table="Monitor"/> should not have connectivity to a Maintenance
1495         Association other than its own.  Thus, if this set is non-empty a fault
1496         is indicated.
1497       </column>
1498
1499       <column name="fault">
1500         Indicates a Connectivity Fault caused by a configuration error, a down
1501         remote MP, or unexpected connectivity to a remote MAID or remote MP.
1502       </column>
1503     </group>
1504   </table>
1505
1506   <table name="Maintenance_Point" title="Maintenance Point configuration">
1507     <p>
1508       A <ref table="Maintenance_Point"/> represents a MP which a
1509       <ref table="Monitor"/> has or should have connectivity to.
1510     </p>
1511
1512     <group title="Maintenance_Point Configuration">
1513       <column name="mpid">
1514         A Maintenance Point ID (MPID) uniquely identifies each endpoint within
1515         a Maintenance Association. All MPs within a MA should have a unique
1516         MPID.
1517       </column>
1518     </group>
1519
1520     <group title="Maintenance_Point Status">
1521       <column name="fault">
1522         Indicates a connectivity fault.
1523       </column>
1524     </group>
1525   </table>
1526
1527   <table name="Mirror" title="Port mirroring (SPAN/RSPAN).">
1528     <p>A port mirror within a <ref table="Bridge"/>.</p>
1529     <p>A port mirror configures a bridge to send selected frames to special
1530       ``mirrored'' ports, in addition to their normal destinations.  Mirroring
1531       traffic may also be referred to as SPAN or RSPAN, depending on the
1532       mechanism used for delivery.</p>
1533
1534     <column name="name">
1535       Arbitrary identifier for the <ref table="Mirror"/>.
1536     </column>
1537
1538     <group title="Selecting Packets for Mirroring">
1539       <column name="select_all">
1540         If true, every packet arriving or departing on any port is
1541         selected for mirroring.
1542       </column>
1543
1544       <column name="select_dst_port">
1545         Ports on which departing packets are selected for mirroring.
1546       </column>
1547
1548       <column name="select_src_port">
1549         Ports on which arriving packets are selected for mirroring.
1550       </column>
1551
1552       <column name="select_vlan">
1553         VLANs on which packets are selected for mirroring.  An empty set
1554         selects packets on all VLANs.
1555       </column>
1556     </group>
1557
1558     <group title="Mirroring Destination Configuration">
1559       <column name="output_port">
1560         <p>Output port for selected packets, if nonempty.  Mutually exclusive
1561           with <ref column="output_vlan"/>.</p>
1562         <p>Specifying a port for mirror output reserves that port exclusively
1563           for mirroring.  No frames other than those selected for mirroring
1564           will be forwarded to the port, and any frames received on the port
1565           will be discarded.</p>
1566         <p>This type of mirroring is sometimes called SPAN.</p>
1567       </column>
1568
1569       <column name="output_vlan">
1570         <p>Output VLAN for selected packets, if nonempty.  Mutually exclusive
1571           with <ref column="output_port"/>.</p>
1572         <p>The frames will be sent out all ports that trunk
1573           <ref column="output_vlan"/>, as well as any ports with implicit VLAN
1574           <ref column="output_vlan"/>.  When a mirrored frame is sent out a
1575           trunk port, the frame's VLAN tag will be set to
1576           <ref column="output_vlan"/>, replacing any existing tag; when it is
1577           sent out an implicit VLAN port, the frame will not be tagged.  This
1578           type of mirroring is sometimes called RSPAN.</p>
1579         <p><em>Please note:</em> Mirroring to a VLAN can disrupt a network that
1580           contains unmanaged switches.  Consider an unmanaged physical switch
1581           with two ports: port 1, connected to an end host, and port 2,
1582           connected to an Open vSwitch configured to mirror received packets
1583           into VLAN 123 on port 2.  Suppose that the end host sends a packet on
1584           port 1 that the physical switch forwards to port 2.  The Open vSwitch
1585           forwards this packet to its destination and then reflects it back on
1586           port 2 in VLAN 123.  This reflected packet causes the unmanaged
1587           physical switch to replace the MAC learning table entry, which
1588           correctly pointed to port 1, with one that incorrectly points to port
1589           2.  Afterward, the physical switch will direct packets destined for
1590           the end host to the Open vSwitch on port 2, instead of to the end
1591           host on port 1, disrupting connectivity.  If mirroring to a VLAN is
1592           desired in this scenario, then the physical switch must be replaced
1593           by one that learns Ethernet addresses on a per-VLAN basis.  In
1594           addition, learning should be disabled on the VLAN containing mirrored
1595           traffic. If this is not done then intermediate switches will learn
1596           the MAC address of each end host from the mirrored traffic.  If
1597           packets being sent to that end host are also mirrored, then they will
1598           be dropped since the switch will attempt to send them out the input
1599           port. Disabling learning for the VLAN will cause the switch to
1600           correctly send the packet out all ports configured for that VLAN.  If
1601           Open vSwitch is being used as an intermediate switch, learning can be
1602           disabled by adding the mirrored VLAN to <ref column="flood_vlans"/>
1603           in the appropriate <ref table="Bridge"/> table or tables.</p>
1604       </column>
1605     </group>
1606
1607     <group title="Other Features">
1608       <column name="external_ids">
1609         Key-value pairs for use by external frameworks that integrate with Open
1610         vSwitch, rather than by Open vSwitch itself.  System integrators should
1611         either use the Open vSwitch development mailing list to coordinate on
1612         common key-value definitions, or choose key names that are likely to be
1613         unique.  No common key-value pairs are currently defined.
1614       </column>
1615     </group>
1616   </table>
1617
1618   <table name="Controller" title="OpenFlow controller configuration.">
1619     <p>An OpenFlow controller.</p>
1620
1621     <p>
1622       Open vSwitch supports two kinds of OpenFlow controllers:
1623     </p>
1624
1625     <dl>
1626       <dt>Primary controllers</dt>
1627       <dd>
1628         <p>
1629           This is the kind of controller envisioned by the OpenFlow 1.0
1630           specification.  Usually, a primary controller implements a network
1631           policy by taking charge of the switch's flow table.
1632         </p>
1633
1634         <p>
1635           Open vSwitch initiates and maintains persistent connections to
1636           primary controllers, retrying the connection each time it fails or
1637           drops.  The <ref table="Bridge" column="fail_mode"/> column in the
1638           <ref table="Bridge"/> table applies to primary controllers.
1639         </p>
1640
1641         <p>
1642           Open vSwitch permits a bridge to have any number of primary
1643           controllers.  When multiple controllers are configured, Open
1644           vSwitch connects to all of them simultaneously.  Because
1645           OpenFlow 1.0 does not specify how multiple controllers
1646           coordinate in interacting with a single switch, more than
1647           one primary controller should be specified only if the
1648           controllers are themselves designed to coordinate with each
1649           other.  (The Nicira-defined <code>NXT_ROLE</code> OpenFlow
1650           vendor extension may be useful for this.)
1651         </p>
1652       </dd>
1653       <dt>Service controllers</dt>
1654       <dd>
1655         <p>
1656           These kinds of OpenFlow controller connections are intended for
1657           occasional support and maintenance use, e.g. with
1658           <code>ovs-ofctl</code>.  Usually a service controller connects only
1659           briefly to inspect or modify some of a switch's state.
1660         </p>
1661
1662         <p>
1663           Open vSwitch listens for incoming connections from service
1664           controllers.  The service controllers initiate and, if necessary,
1665           maintain the connections from their end.  The <ref table="Bridge"
1666           column="fail_mode"/> column in the <ref table="Bridge"/> table does
1667           not apply to service controllers.
1668         </p>
1669
1670         <p>
1671           Open vSwitch supports configuring any number of service controllers.
1672         </p>
1673       </dd>
1674     </dl>
1675
1676     <p>
1677       The <ref column="target"/> determines the type of controller.
1678     </p>
1679
1680     <group title="Core Features">
1681       <column name="target">
1682         <p>Connection method for controller.</p>
1683         <p>
1684           The following connection methods are currently supported for primary
1685           controllers:
1686         </p>
1687         <dl>
1688           <dt><code>ssl:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
1689           <dd>
1690             <p>The specified SSL <var>port</var> (default: 6633) on the host at
1691             the given <var>ip</var>, which must be expressed as an IP address
1692             (not a DNS name).  The <ref table="Open_vSwitch" column="ssl"/>
1693             column in the <ref table="Open_vSwitch"/> table must point to a
1694             valid SSL configuration when this form is used.</p>
1695             <p>SSL support is an optional feature that is not always built as
1696               part of Open vSwitch.</p>
1697           </dd>
1698           <dt><code>tcp:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
1699           <dd>The specified TCP <var>port</var> (default: 6633) on the host at
1700             the given <var>ip</var>, which must be expressed as an IP address
1701             (not a DNS name).</dd>
1702         </dl>
1703         <p>
1704           The following connection methods are currently supported for service
1705           controllers:
1706         </p>
1707         <dl>
1708           <dt><code>pssl:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
1709           <dd>
1710             <p>
1711               Listens for SSL connections on the specified TCP <var>port</var>
1712               (default: 6633).  If <var>ip</var>, which must be expressed as an
1713               IP address (not a DNS name), is specified, then connections are
1714               restricted to the specified local IP address.
1715             </p>
1716             <p>
1717               The <ref table="Open_vSwitch" column="ssl"/> column in the <ref
1718               table="Open_vSwitch"/> table must point to a valid SSL
1719               configuration when this form is used.
1720             </p>
1721             <p>SSL support is an optional feature that is not always built as
1722               part of Open vSwitch.</p>
1723           </dd>
1724           <dt><code>ptcp:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
1725           <dd>
1726             Listens for connections on the specified TCP <var>port</var>
1727             (default: 6633).  If <var>ip</var>, which must be expressed as an
1728             IP address (not a DNS name), is specified, then connections are
1729             restricted to the specified local IP address.
1730           </dd>
1731         </dl>
1732         <p>When multiple controllers are configured for a single bridge, the
1733           <ref column="target"/> values must be unique.  Duplicate
1734           <ref column="target"/> values yield unspecified results.</p>
1735       </column>
1736
1737       <column name="connection_mode">
1738         <p>If it is specified, this setting must be one of the following
1739         strings that describes how Open vSwitch contacts this OpenFlow
1740         controller over the network:</p>
1741
1742         <dl>
1743           <dt><code>in-band</code></dt>
1744           <dd>In this mode, this controller's OpenFlow traffic travels over the
1745             bridge associated with the controller.  With this setting, Open
1746             vSwitch allows traffic to and from the controller regardless of the
1747             contents of the OpenFlow flow table.  (Otherwise, Open vSwitch
1748             would never be able to connect to the controller, because it did
1749             not have a flow to enable it.)  This is the most common connection
1750             mode because it is not necessary to maintain two independent
1751             networks.</dd>
1752           <dt><code>out-of-band</code></dt>
1753           <dd>In this mode, OpenFlow traffic uses a control network separate
1754             from the bridge associated with this controller, that is, the
1755             bridge does not use any of its own network devices to communicate
1756             with the controller.  The control network must be configured
1757             separately, before or after <code>ovs-vswitchd</code> is started.
1758           </dd>
1759         </dl>
1760
1761         <p>If not specified, the default is implementation-specific.</p>
1762       </column>
1763     </group>
1764
1765     <group title="Controller Failure Detection and Handling">
1766       <column name="max_backoff">
1767         Maximum number of milliseconds to wait between connection attempts.
1768         Default is implementation-specific.
1769       </column>
1770
1771       <column name="inactivity_probe">
1772         Maximum number of milliseconds of idle time on connection to
1773         controller before sending an inactivity probe message.  If Open
1774         vSwitch does not communicate with the controller for the specified
1775         number of seconds, it will send a probe.  If a response is not
1776         received for the same additional amount of time, Open vSwitch
1777         assumes the connection has been broken and attempts to reconnect.
1778         Default is implementation-specific.
1779       </column>
1780     </group>
1781
1782     <group title="OpenFlow Rate Limiting">
1783         <column name="controller_rate_limit">
1784           <p>The maximum rate at which packets in unknown flows will be
1785             forwarded to the OpenFlow controller, in packets per second.  This
1786             feature prevents a single bridge from overwhelming the controller.
1787             If not specified, the default is implementation-specific.</p>
1788           <p>In addition, when a high rate triggers rate-limiting, Open
1789             vSwitch queues controller packets for each port and transmits
1790             them to the controller at the configured rate.  The number of
1791             queued packets is limited by
1792             the <ref column="controller_burst_limit"/> value.  The packet
1793             queue is shared fairly among the ports on a bridge.</p><p>Open
1794             vSwitch maintains two such packet rate-limiters per bridge.
1795             One of these applies to packets sent up to the controller
1796             because they do not correspond to any flow.  The other applies
1797             to packets sent up to the controller by request through flow
1798             actions. When both rate-limiters are filled with packets, the
1799             actual rate that packets are sent to the controller is up to
1800             twice the specified rate.</p>
1801         </column>
1802
1803         <column name="controller_burst_limit">
1804           In conjunction with <ref column="controller_rate_limit"/>,
1805           the maximum number of unused packet credits that the bridge will
1806           allow to accumulate, in packets.  If not specified, the default
1807           is implementation-specific.
1808         </column>
1809     </group>
1810
1811     <group title="Additional In-Band Configuration">
1812       <p>These values are considered only in in-band control mode (see
1813         <ref column="connection_mode"/>).</p>
1814
1815       <p>When multiple controllers are configured on a single bridge, there
1816         should be only one set of unique values in these columns.  If different
1817         values are set for these columns in different controllers, the effect
1818         is unspecified.</p>
1819
1820       <column name="local_ip">
1821         The IP address to configure on the local port,
1822         e.g. <code>192.168.0.123</code>.  If this value is unset, then
1823         <ref column="local_netmask"/> and <ref column="local_gateway"/> are
1824         ignored.
1825       </column>
1826
1827       <column name="local_netmask">
1828         The IP netmask to configure on the local port,
1829         e.g. <code>255.255.255.0</code>.  If <ref column="local_ip"/> is set
1830         but this value is unset, then the default is chosen based on whether
1831         the IP address is class A, B, or C.
1832       </column>
1833
1834       <column name="local_gateway">
1835         The IP address of the gateway to configure on the local port, as a
1836         string, e.g. <code>192.168.0.1</code>.  Leave this column unset if
1837         this network has no gateway.
1838       </column>
1839     </group>
1840
1841     <group title="Other Features">
1842       <column name="external_ids">
1843         Key-value pairs for use by external frameworks that integrate with Open
1844         vSwitch, rather than by Open vSwitch itself.  System integrators should
1845         either use the Open vSwitch development mailing list to coordinate on
1846         common key-value definitions, or choose key names that are likely to be
1847         unique.  No common key-value pairs are currently defined.
1848       </column>
1849     </group>
1850
1851     <group title="Controller Status">
1852       <column name="is_connected">
1853         <code>true</code> if currently connected to this controller,
1854         <code>false</code> otherwise.
1855       </column>
1856
1857       <column name="role">
1858         <p>The level of authority this controller has on the associated
1859           bridge. Possible values are:</p>
1860         <dl>
1861           <dt><code>other</code></dt>
1862           <dd>Allows the controller access to all OpenFlow features.</dd>
1863           <dt><code>master</code></dt>
1864           <dd>Equivalent to <code>other</code>, except that there may be at
1865             most one master controller at a time.  When a controller configures
1866             itself as <code>master</code>, any existing master is demoted to
1867             the <code>slave</code>role.</dd>
1868           <dt><code>slave</code></dt>
1869           <dd>Allows the controller read-only access to OpenFlow features.
1870             Attempts to modify the flow table will be rejected with an
1871             error.  Slave controllers do not receive OFPT_PACKET_IN or
1872             OFPT_FLOW_REMOVED messages, but they do receive OFPT_PORT_STATUS
1873             messages.</dd>
1874         </dl>
1875       </column>
1876
1877       <column name="status">
1878         <p>Key-value pairs that report controller status.</p>
1879         <dl>
1880           <dt><code>last_error</code></dt>
1881           <dd>A human-readable description of the last error on the connection
1882             to the controller; i.e. <code>strerror(errno)</code>.  This key
1883             will exist only if an error has occurred.</dd>
1884           <dt><code>state</code></dt>
1885           <dd>The state of the connection to the controller.  Possible values
1886             are: <code>VOID</code> (connection is disabled),
1887             <code>BACKOFF</code> (attempting to reconnect at an increasing
1888             period), <code>CONNECTING</code> (attempting to connect),
1889             <code>ACTIVE</code> (connected, remote host responsive), and
1890             <code>IDLE</code> (remote host idle, sending keep-alive).  These
1891             values may change in the future.  They are provided only for human
1892             consumption.</dd>
1893           <dt><code>sec_since_connect</code></dt>
1894           <dd>The amount of time since this controller last successfully
1895             connected to the switch (in seconds). Value is empty if controller
1896             has never successfully connected.</dd>
1897           <dt><code>sec_since_disconnect</code></dt>
1898           <dd>The amount of time since this controller last disconnected from
1899             the switch (in seconds). Value is empty if controller has never
1900             disconnected.</dd>
1901         </dl>
1902       </column>
1903     </group>
1904   </table>
1905
1906   <table name="Manager" title="OVSDB management connection.">
1907     <p>
1908       Configuration for a database connection to an Open vSwitch database
1909       (OVSDB) client.
1910     </p>
1911
1912     <p>
1913       This table primarily configures the Open vSwitch database
1914       (<code>ovsdb-server</code>), not the Open vSwitch switch
1915       (<code>ovs-vswitchd</code>).  The switch does read the table to determine
1916       what connections should be treated as in-band.
1917     </p>
1918
1919     <p>
1920       The Open vSwitch database server can initiate and maintain active
1921       connections to remote clients.  It can also listen for database
1922       connections.
1923     </p>
1924
1925     <group title="Core Features">
1926       <column name="target">
1927         <p>Connection method for managers.</p>
1928         <p>
1929           The following connection methods are currently supported:
1930         </p>
1931         <dl>
1932           <dt><code>ssl:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
1933           <dd>
1934             <p>
1935               The specified SSL <var>port</var> (default: 6632) on the host at
1936               the given <var>ip</var>, which must be expressed as an IP address
1937               (not a DNS name).  The <ref table="Open_vSwitch" column="ssl"/>
1938               column in the <ref table="Open_vSwitch"/> table must point to a
1939               valid SSL configuration when this form is used.
1940             </p>
1941             <p>
1942               SSL support is an optional feature that is not always built as
1943               part of Open vSwitch.
1944             </p>
1945           </dd>
1946
1947           <dt><code>tcp:<var>ip</var></code>[<code>:<var>port</var></code>]</dt>
1948           <dd>
1949             The specified TCP <var>port</var> (default: 6632) on the host at
1950             the given <var>ip</var>, which must be expressed as an IP address
1951             (not a DNS name).
1952           </dd>
1953           <dt><code>pssl:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
1954           <dd>
1955             <p>
1956               Listens for SSL connections on the specified TCP <var>port</var>
1957               (default: 6632).  If <var>ip</var>, which must be expressed as an
1958               IP address (not a DNS name), is specified, then connections are
1959               restricted to the specified local IP address.
1960             </p>
1961             <p>
1962               The <ref table="Open_vSwitch" column="ssl"/> column in the <ref
1963               table="Open_vSwitch"/> table must point to a valid SSL
1964               configuration when this form is used.
1965             </p>
1966             <p>
1967               SSL support is an optional feature that is not always built as
1968               part of Open vSwitch.
1969             </p>
1970           </dd>
1971           <dt><code>ptcp:</code>[<var>port</var>][<code>:<var>ip</var></code>]</dt>
1972           <dd>
1973             Listens for connections on the specified TCP <var>port</var>
1974             (default: 6632).  If <var>ip</var>, which must be expressed as an
1975             IP address (not a DNS name), is specified, then connections are
1976             restricted to the specified local IP address.
1977           </dd>
1978         </dl>
1979         <p>When multiple managers are configured, the <ref column="target"/>
1980         values must be unique.  Duplicate <ref column="target"/> values yield
1981         unspecified results.</p>
1982       </column>
1983
1984       <column name="connection_mode">
1985         <p>
1986           If it is specified, this setting must be one of the following strings
1987           that describes how Open vSwitch contacts this OVSDB client over the
1988           network:
1989         </p>
1990
1991         <dl>
1992           <dt><code>in-band</code></dt>
1993           <dd>
1994             In this mode, this connection's traffic travels over a bridge
1995             managed by Open vSwitch.  With this setting, Open vSwitch allows
1996             traffic to and from the client regardless of the contents of the
1997             OpenFlow flow table.  (Otherwise, Open vSwitch would never be able
1998             to connect to the client, because it did not have a flow to enable
1999             it.)  This is the most common connection mode because it is not
2000             necessary to maintain two independent networks.
2001           </dd>
2002           <dt><code>out-of-band</code></dt>
2003           <dd>
2004             In this mode, the client's traffic uses a control network separate
2005             from that managed by Open vSwitch, that is, Open vSwitch does not
2006             use any of its own network devices to communicate with the client.
2007             The control network must be configured separately, before or after
2008             <code>ovs-vswitchd</code> is started.
2009           </dd>
2010         </dl>
2011
2012         <p>
2013           If not specified, the default is implementation-specific.
2014         </p>
2015       </column>
2016     </group>
2017
2018     <group title="Client Failure Detection and Handling">
2019       <column name="max_backoff">
2020         Maximum number of milliseconds to wait between connection attempts.
2021         Default is implementation-specific.
2022       </column>
2023
2024       <column name="inactivity_probe">
2025         Maximum number of milliseconds of idle time on connection to the client
2026         before sending an inactivity probe message.  If Open vSwitch does not
2027         communicate with the client for the specified number of seconds, it
2028         will send a probe.  If a response is not received for the same
2029         additional amount of time, Open vSwitch assumes the connection has been
2030         broken and attempts to reconnect.  Default is implementation-specific.
2031       </column>
2032     </group>
2033
2034     <group title="Other Features">
2035       <column name="external_ids">
2036         Key-value pairs for use by external frameworks that integrate with Open
2037         vSwitch, rather than by Open vSwitch itself.  System integrators should
2038         either use the Open vSwitch development mailing list to coordinate on
2039         common key-value definitions, or choose key names that are likely to be
2040         unique.  No common key-value pairs are currently defined.
2041       </column>
2042     </group>
2043
2044     <group title="Status">
2045       <column name="is_connected">
2046         <code>true</code> if currently connected to this manager,
2047         <code>false</code> otherwise.
2048       </column>
2049
2050       <column name="status">
2051         <p>Key-value pairs that report manager status.</p>
2052         <dl>
2053           <dt><code>last_error</code></dt>
2054           <dd>A human-readable description of the last error on the connection
2055             to the manager; i.e. <code>strerror(errno)</code>.  This key
2056             will exist only if an error has occurred.</dd>
2057         </dl>
2058         <dl>
2059           <dt><code>state</code></dt>
2060           <dd>The state of the connection to the manager.  Possible values
2061             are: <code>VOID</code> (connection is disabled),
2062             <code>BACKOFF</code> (attempting to reconnect at an increasing
2063             period), <code>CONNECTING</code> (attempting to connect),
2064             <code>ACTIVE</code> (connected, remote host responsive), and
2065             <code>IDLE</code> (remote host idle, sending keep-alive).  These
2066             values may change in the future.  They are provided only for human
2067             consumption.</dd>
2068         </dl>
2069         <dl>
2070           <dt><code>sec_since_connect</code></dt>
2071           <dd>The amount of time since this manager last successfully connected
2072             to the database (in seconds). Value is empty if manager has never
2073             successfully connected.</dd>
2074         </dl>
2075         <dl>
2076           <dt><code>sec_since_disconnect</code></dt>
2077           <dd>The amount of time since this manager last disconnected from the
2078             database (in seconds). Value is empty if manager has never
2079             disconnected.</dd>
2080         </dl>
2081       </column>
2082     </group>
2083   </table>
2084
2085   <table name="NetFlow">
2086     A NetFlow target.  NetFlow is a protocol that exports a number of
2087     details about terminating IP flows, such as the principals involved
2088     and duration.
2089
2090     <column name="targets">
2091       NetFlow targets in the form
2092       <code><var>ip</var>:<var>port</var></code>.  The <var>ip</var>
2093       must be specified numerically, not as a DNS name.
2094     </column>
2095
2096     <column name="engine_id">
2097       Engine ID to use in NetFlow messages.  Defaults to datapath index
2098       if not specified.
2099     </column>
2100
2101     <column name="engine_type">
2102       Engine type to use in NetFlow messages.  Defaults to datapath
2103       index if not specified.
2104     </column>
2105
2106     <column name="active_timeout">
2107       The interval at which NetFlow records are sent for flows that are
2108       still active, in seconds.  A value of <code>0</code> requests the
2109       default timeout (currently 600 seconds); a value of <code>-1</code>
2110       disables active timeouts.
2111     </column>
2112
2113     <column name="add_id_to_interface">
2114       <p>If this column's value is <code>false</code>, the ingress and egress
2115         interface fields of NetFlow flow records are derived from OpenFlow port
2116         numbers.  When it is <code>true</code>, the 7 most significant bits of
2117         these fields will be replaced by the least significant 7 bits of the
2118         engine id.  This is useful because many NetFlow collectors do not
2119         expect multiple switches to be sending messages from the same host, so
2120         they do not store the engine information which could be used to
2121         disambiguate the traffic.</p>
2122       <p>When this option is enabled, a maximum of 508 ports are supported.</p>
2123     </column>
2124
2125     <column name="external_ids">
2126       Key-value pairs for use by external frameworks that integrate with Open
2127       vSwitch, rather than by Open vSwitch itself.  System integrators should
2128       either use the Open vSwitch development mailing list to coordinate on
2129       common key-value definitions, or choose key names that are likely to be
2130       unique.  No common key-value pairs are currently defined.
2131     </column>
2132   </table>
2133
2134   <table name="SSL">
2135     SSL configuration for an Open_vSwitch.
2136
2137     <column name="private_key">
2138       Name of a PEM file containing the private key used as the switch's
2139       identity for SSL connections to the controller.
2140     </column>
2141
2142     <column name="certificate">
2143       Name of a PEM file containing a certificate, signed by the
2144       certificate authority (CA) used by the controller and manager,
2145       that certifies the switch's private key, identifying a trustworthy
2146       switch.
2147     </column>
2148
2149     <column name="ca_cert">
2150       Name of a PEM file containing the CA certificate used to verify
2151       that the switch is connected to a trustworthy controller.
2152     </column>
2153
2154     <column name="bootstrap_ca_cert">
2155       If set to <code>true</code>, then Open vSwitch will attempt to
2156       obtain the CA certificate from the controller on its first SSL
2157       connection and save it to the named PEM file. If it is successful,
2158       it will immediately drop the connection and reconnect, and from then
2159       on all SSL connections must be authenticated by a certificate signed
2160       by the CA certificate thus obtained.  <em>This option exposes the
2161         SSL connection to a man-in-the-middle attack obtaining the initial
2162         CA certificate.</em>  It may still be useful for bootstrapping.
2163     </column>
2164
2165     <column name="external_ids">
2166       Key-value pairs for use by external frameworks that integrate with Open
2167       vSwitch, rather than by Open vSwitch itself.  System integrators should
2168       either use the Open vSwitch development mailing list to coordinate on
2169       common key-value definitions, or choose key names that are likely to be
2170       unique.  No common key-value pairs are currently defined.
2171     </column>
2172   </table>
2173
2174   <table name="sFlow">
2175     <p>An sFlow(R) target.  sFlow is a protocol for remote monitoring
2176       of switches.</p>
2177
2178     <column name="agent">
2179       Name of the network device whose IP address should be reported as the
2180       ``agent address'' to collectors.  If not specified, the IP address
2181       defaults to the <ref table="Controller" column="local_ip"/> in the
2182       collector's <ref table="Controller"/>.  If an agent IP address cannot be
2183       determined either way, sFlow is disabled.
2184     </column>
2185
2186     <column name="header">
2187       Number of bytes of a sampled packet to send to the collector.
2188       If not specified, the default is 128 bytes.
2189     </column>
2190
2191     <column name="polling">
2192       Polling rate in seconds to send port statistics to the collector.
2193       If not specified, defaults to 30 seconds.
2194     </column>
2195
2196     <column name="sampling">
2197       Rate at which packets should be sampled and sent to the collector.
2198       If not specified, defaults to 400, which means one out of 400
2199       packets, on average, will be sent to the collector.
2200     </column>
2201
2202     <column name="targets">
2203       sFlow targets in the form
2204       <code><var>ip</var>:<var>port</var></code>.
2205     </column>
2206
2207     <column name="external_ids">
2208       Key-value pairs for use by external frameworks that integrate with Open
2209       vSwitch, rather than by Open vSwitch itself.  System integrators should
2210       either use the Open vSwitch development mailing list to coordinate on
2211       common key-value definitions, or choose key names that are likely to be
2212       unique.  No common key-value pairs are currently defined.
2213     </column>
2214   </table>
2215
2216   <table name="Capability">
2217     <p>Records in this table describe functionality supported by the hardware
2218       and software platform on which this Open vSwitch is based.  Clients
2219       should not modify this table.</p>
2220
2221     <p>A record in this table is meaningful only if it is referenced by the
2222       <ref table="Open_vSwitch" column="capabilities"/> column in the
2223       <ref table="Open_vSwitch"/> table.  The key used to reference it, called
2224       the record's ``category,'' determines the meanings of the
2225       <ref column="details"/> column.  The following general forms of
2226       categories are currently defined:</p>
2227
2228     <dl>
2229       <dt><code>qos-<var>type</var></code></dt>
2230       <dd><var>type</var> is supported as the value for
2231         <ref column="type" table="QoS"/> in the <ref table="QoS"/> table.
2232       </dd>
2233     </dl>
2234
2235     <column name="details">
2236       <p>Key-value pairs that describe capabilities.  The meaning of the pairs
2237       depends on the category key that the <ref table="Open_vSwitch"
2238       column="capabilities"/> column in the <ref table="Open_vSwitch"/> table
2239       uses to reference this record, as described above.</p>
2240
2241       <p>The presence of a record for category <code>qos-<var>type</var></code>
2242           indicates that the switch supports <var>type</var> as the value of
2243           the <ref table="QoS" column="type"/> column in the <ref table="QoS"/>
2244           table.  The following key-value pairs are defined to further describe
2245           QoS capabilities:</p>
2246
2247       <dl>
2248         <dt><code>n-queues</code></dt>
2249         <dd>Number of supported queues, as a positive integer.  Keys in the
2250           <ref table="QoS" column="queues"/> column for <ref table="QoS"/>
2251           records whose <ref table="QoS" column="type"/> value
2252           equals <var>type</var> must range between 0 and this value minus one,
2253           inclusive.</dd>
2254       </dl>
2255     </column>
2256   </table>
2257 </database>