ovn-controller(8)
๐ ovn-controller โ the manual, but make it make sense ๐
ovn-controller(8) ยท OVN Manual ยท bestie edition โจ
๐ธ NAME ๐ธ
ovn-controller โ the Open Virtual Network local controller. she's the girl on the ground, the one actually doing the work ๐
๐ SYNOPSIS ๐
ovn-controller [options] [ovs-database]
๐ฆ DESCRIPTION ๐ฆ
okay so. ovn-controller is the local controller daemon for OVN, aka the Open Virtual Network. she's got two jobs and she's doing both of them at the same time, no cap.
Upward ๐ she connects to the OVN Southbound database (see ovn-sb(5)) over the OVSDB protocol.
Downward ๐ธ she connects to the Open vSwitch database (see ovs-vswitchd.conf.db(5)) over the OVSDB protocol, and also to ovs-vswitchd(8) via OpenFlow.
the way that every single hypervisor and software gateway in an OVN deployment runs its own independent copy of ovn-controllerโฆ iconic. which means her downward connections are machine-local and do not run over a physical network. local girl, local business ๐
๐ ACL LOGGING ๐
ACL log messages get logged through ovn-controller's logging mechanism. ACL log entries have the module acl_log at log level info. how do you configure logging, you ask? it's described below in the Logging Options section, keep reading bestie ๐ซถ
โจ OPTIONS โจ
๐ Daemon Options
--pidfile[=pidfile]โ causes a file (by default,program.pid) to be created indicating the PID of the running process. if the pidfile argument isn't specified, or if it doesn't begin with/, then it is created in.
if --pidfile is not specified, no pidfile is created. periodt.
--overwrite-pidfileโ by default, when--pidfileis specified and that pidfile already exists and is locked by a running process, the daemon refuses to start. specify--overwrite-pidfileand instead she'll overwrite the pidfile. slay.
when --pidfile is not specified, this option has no effect.
--detachโ runs this program as a background process. the process forks, and in the child it starts a new session, closes the standard file descriptors (which has the side effect of disabling logging to the console), and changes its current directory to the root (unless--no-chdiris specified). after the child completes its initialization, the parent exits. bye mom ๐--monitorโ creates an additional process to monitor this program. if it dies due to a signal that indicates a programming error (SIGABRT,SIGALRM,SIGBUS,SIGFPE,SIGILL,SIGPIPE,SIGSEGV,SIGXCPU, orSIGXFSZ) then the monitor process starts a new copy of it. if the daemon dies or exits for another reason, the monitor process exits.
this option is normally used with --detach, but it also functions without it. versatile queen โจ
--no-chdirโ by default, when--detachis specified, the daemon changes its current working directory to the root directory after it detaches. otherwise, invoking the daemon from a carelessly chosen directory would prevent the administrator from unmounting the file system that holds that directory. ๐ญ
specifying --no-chdir suppresses this behavior, preventing the daemon from changing its current working directory. this may be useful for collecting core files, since it's common behavior to write core dumps into the current working directory and the root directory is not a good directory to use.
this option has no effect when --detach is not specified.
--no-self-confinementโ by default this daemon will try to self-confine itself to work with files under well-known directories determined at build time. it is better to stick with this default behavior and not to use this flag unless some other Access Control is used to confine daemon. note that in contrast to other access control implementations that are typically enforced from kernel-space (e.g. DAC or MAC), self-confinement is imposed from the user-space daemon itself and hence should not be considered as a full confinement strategy, but instead should be viewed as an additional layer of security. ๐--user=user:groupโ causes this program to run as a different user specified in user:group, thus dropping most of the root privileges. short forms user and :group are also allowed, with current user or group assumed, respectively. only daemons started by the root user accepts this argument.
on Linux, daemons will be granted CAP_IPC_LOCK and CAP_NET_BIND_SERVICES before dropping root privileges. daemons that interact with a datapath, such as ovs-vswitchd, will be granted three additional capabilities, namely CAP_NET_ADMIN, CAP_NET_BROADCAST and CAP_NET_RAW. the capability change will apply even if the new user is root. ๐
๐ Logging Options
-v[spec]--verbose=[spec]โ sets logging levels. without any spec, sets the log level for every module and destination todbg. otherwise, spec is a list of words separated by spaces or commas or colons, up to one from each category below:- a valid module name, as displayed by the
vlog/listcommand onovs-appctl(8), limits the log level change to the specified module. syslog,console, orfile, to limit the log level change to only to the system log, to the console, or to a file, respectively. (if--detachis specified, the daemon closes its standard file descriptors, so logging to the console will have no effect.)off,emer,err,warn,info, ordbg, to control the log level. messages of the given severity or higher will be logged, and messages of lower severity will be filtered out.offfilters out all messages. seeovs-appctl(8)for a definition of each log level.
- a valid module name, as displayed by the
case is not significant within spec.
regardless of the log levels set for file, logging to a file will not take place unless --log-file is also specified (see below).
for compatibility with older versions of OVS, any is accepted as a word but has no effect. (she's just there for the vibes ๐
)
-v--verboseโ sets the maximum logging verbosity level, equivalent to--verbose=dbg.-vPATTERN:destination:pattern--verbose=PATTERN:destination:patternโ sets the log pattern for destination to pattern. refer toovs-appctl(8)for a description of the valid syntax for pattern.-vFACILITY:facility--verbose=FACILITY:facilityโ sets the RFC5424 facility of the log message. facility can be one ofkern,user,mail,daemon,auth,syslog,lpr,news,uucp,clock,ftp,ntp,audit,alert,clock2,local0,local1,local2,local3,local4,local5,local6orlocal7. if this option is not specified,daemonis used as the default for the local system syslog andlocal0is used while sending a message to the target provided via the--syslog-targetoption.--log-file[=file]โ enables logging to a file. if file is specified, then it is used as the exact name for the log file. the default log file name used if file is omitted is/var/log/ovn/program.log. ๐--syslog-target=host:portโ send syslog messages to UDP port on host, in addition to the system syslog. the host must be a numerical IP address, not a hostname.--syslog-method=methodโ specify method as how syslog messages should be sent to syslog daemon. the following forms are supported:libc, to use the libcsyslog()function. downside of using this options is that libc adds fixed prefix to every message before it is actually sent to the syslog daemon over/dev/logUNIX domain socket.unix:file, to use a UNIX domain socket directly. it is possible to specify arbitrary message format with this option. however,rsyslogd8.9 and older versions use hard coded parser function anyway that limits UNIX domain socket use. if you want to use arbitrary message format with olderrsyslogdversions, then use UDP socket to localhost IP address instead.udp:ip:port, to use a UDP socket. with this method it is possible to use arbitrary message format also with olderrsyslogd. when sending syslog messages over UDP socket extra precaution needs to be taken into account, for example, syslog daemon needs to be configured to listen on the specified UDP port, accidental iptables rules could be interfering with local syslog traffic and there are some security considerations that apply to UDP sockets, but do not apply to UNIX domain sockets.null, to discard all messages logged to syslog.
the default is taken from the OVS_SYSLOG_METHOD environment variable; if it is unset, the default is libc.
๐ PKI Options
PKI configuration is required in order to use SSL/TLS for the connections to the Northbound and Southbound databases. no PKI, no TLS, sorry bestie ๐ญ
-pprivkey.pem--private-key=privkey.pem โ specifies a PEM file containing the private key used as identity for outgoing SSL/TLS connections.-ccert.pem--certificate=cert.pem โ specifies a PEM file containing a certificate that certifies the private key specified on-por--private-keyto be trustworthy. the certificate must be signed by the certificate authority (CA) that the peer in SSL/TLS connections will use to verify it.-Ccacert.pem--ca-cert=cacert.pem โ specifies a PEM file containing the CA certificate for verifying certificates presented to this program by SSL/TLS peers. (this may be the same certificate that SSL/TLS peers use to verify the certificate specified on-cor--certificate, or it may be a different one, depending on the PKI design in use.)-C none--ca-cert=noneโ disables verification of certificates presented by SSL/TLS peers.
โ ๏ธ this introduces a security risk, because it means that certificates cannot be verified to be those of known trusted hosts. do not do this unless you truly know what you're doing, fr fr.
--ssl-server-name=servername โ specifies the server name to use for TLS Server Name Indication (SNI). by default, the hostname from the connection string is used for SNI. this option allows overriding the SNI hostname, which is useful when connecting through proxies or service meshes where the connection endpoint differs from the intended server name. ๐ง
to be continuedโฆ part 2 is coming, don't go anywhere ๐
--bootstrap-ca-cert=cacert.pemโ okay so ifcacert.pemis already there, this does literally the exact same thing as-Cor--ca-cert. If it is not there, then the executable goes and tries to obtain the CA certificate from the SSL/TLS peer on its very first SSL/TLS connection, and saves it into the named PEM file. And if that works out? It immediately drops the connection and reconnects, and from then on every single SSL/TLS connection must be authenticated by a certificate signed by the CA certificate it just grabbed. slay, but read on.
๐จ Warning time, bestie: this option exposes the SSL/TLS connection to a man-in-the-middle attack obtaining that initial CA certificate. It may still be useful for bootstrapping, but like, that's the tradeoff, fr fr.
This option is only useful if the SSL/TLS peer actually sends its CA certificate as part of the SSL/TLS certificate chain. And here's the tea: SSL/TLS protocols do not require the server to send the CA certificate. So it's giving "hope for the best" ๐.
This option is mutually exclusive with -C and --ca-cert. Choose one, queen. ๐
--peer-ca-cert=peer-cacert.pemโ this one specifies a PEM file that contains one or more additional certificates to send to SSL/TLS peers. Andpeer-cacert.pemshould be the CA certificate used to sign the program's own certificate โ that is, the certificate you specified on-cor--certificate. If the program's certificate is self-signed, then--certificateand--peer-ca-certshould point at the same file. Same file! ๐ฏ
Ngl, this option is not useful in normal operation, because the SSL/TLS peer must already have the CA certificate for the peer to have any confidence in the program's identity. But it does offer a way for a new installation to bootstrap the CA certificate on its first SSL/TLS connection. baby's first handshake ๐
๐ Other Options ๐
--unixctl=socketโ sets the name of the control socket that the program listens on for runtime management commands (peepRUNTIME MANAGEMENT COMMANDS, below ๐). If socket does not begin with/, it is interpreted as relative to.. If--unixctlis not used at all, the default socket is/program.pid.ctl, where pid is the program's process ID.
And if you specify none for socket? That disables the control socket feature entirely. bye ๐
-h,--helpโ prints a brief help message to the console. classic.-V,--versionโ prints version information to the console. also classic.
๐ CONFIGURATION ๐
okay so here's the whole vibe of how this thing gets configured. ovn-controller retrieves most of its configuration information from the local Open vSwitch's ovsdb-server instance. The default location is db.sock in the local Open vSwitch's "run" directory. You can override that by specifying the ovs-database argument as an OVSDB active or passive connection method, exactly as described in ovsdb(7).
ovn-controller assumes it gets configuration information from the following keys in the Open_vSwitch table of the local OVS instance:
external_ids:system-idโ the chassis name to use in theChassistable. Changing thesystem-idwhileovn-controlleris running is not directly supported. You've got two options, bestie: either gracefully stopovn-controllerfirst, or manually delete the staleChassisandChassis_Privaterecords after you change thesystem-id.
Also important: the chassis name can also be provided via the system-id-override file in the local OVN "etc" directory, or via the -n command-line option. And the precedence goes like this, in order:
- the command-line option is read;
- if it's not present, the
system-id-overridefile is read; - if that's not present, then the name configured in the database is used.
external_ids:hostnameโ the hostname to use in theChassistable. that's it, that's the key ๐ซถexternal_ids:ovn-bridgeโ the integration bridge to which logical ports are attached. The default isbr-int. And if this bridge doesn't exist whenovn-controllerstarts, it'll be created automatically with the default configuration suggested inovn-architecture(7).
Now, when more than one controller is running on the same host, external_ids:ovn-bridge-CHASSIS_NAME should be set for each of them, pointing to a unique bridge. This is required to avoid controllers stepping on each others' feet. no tripping, please ๐
external_ids:ovn-bridge-datapath-typeโ this configuration is optional. If it's set, then the datapath type of the integration bridge gets set to the configured value. If this option is not set, thenovn-controllerwill not modify the existing datapath-type of the integration bridge. it minds its business ๐external_ids:ovn-remoteโ the OVN database that this system should connect to for its configuration, in one of the same forms documented above for the ovs-database.external_ids:ovn-monitor-allโ a boolean value that tells whetherovn-controllershould monitor all records of tables in theOVN_Southbound. If this option is set tofalse,ovn-controllerwill conditionally monitor only the records that are needed for the local chassis.
It's more efficient to set it to true in use cases where the chassis would anyway need to monitor most of the records in the OVN_Southbound database, because that saves the overhead of conditions processing, especially for server side. Typically, set it to true for environments where all workloads need to be reachable from each other.
๐ NOTE: for efficiency and scalability in common scenarios,ovn-controllerunconditionally monitors all sub-ports (ports withparent_portset) regardless of theovn-monitor-allvalue.
Default value is false.
external_ids:ovn-remote-probe-intervalโ the inactivity probe interval of the connection to the OVN database, in milliseconds. If the value is zero, it disables the connection keepalive feature.
If the value is nonzero, then it will be forced to a value of at least 1000 ms. no sneaky tiny probes โฑ๏ธ
external_ids:ovn-encap-typeโ the encapsulation type that a chassis should use to connect to this node. Multiple encapsulation types may be specified with a comma-separated list. Each listed encapsulation type will be paired withovn-encap-ip. ๐
Supported tunnel types for connecting hypervisors and gateways are geneve and vxlan.
โ ๏ธ Due to the limited amount of metadata in vxlan, the capabilities and performance of connected gateways and hypervisors will be reduced versus other tunnel formats.
external_ids:ovn-encap-ipโ the IP address that a chassis should use to connect to this node using the encapsulation types specified byexternal_ids:ovn-encap-type. Multiple encapsulation IPs may be specified with a comma-separated list.
In scenarios where multiple encapsulation IPs are present, distinct tunnels are established for each remote chassis. These tunnels are differentiated by setting unique options:local_ip and options:remote_ip values in the tunnel interface. When transmitting a packet to a remote chassis, the selection of local_ip is guided by the Interface:external_ids:encap-ip from the local OVSDB, corresponding to the VIF originating the packet, if specified. The Interface:external_ids:encap-ip setting of the VIF is also populated to the Port_Binding table in the OVN SB database via the encap column. Consequently, when a remote chassis needs to send a packet to a port-binding associated with this VIF, it utilizes the tunnel with the appropriate options:remote_ip that matches the ip in Port_Binding:encap.
This mechanism is particularly beneficial for chassis with multiple physical interfaces designated for tunneling, where each interface is optimized for handling specific traffic associated with particular VIFs. it's giving load balancing, but make it tunnel ๐
external_ids:ovn-encap-ip-defaultโ whenovn-encap-ipcontains multiple IPs, this field indicates the default one. the favorite child, if you will ๐external_ids:ovn-encap-df_defaultโ indicates the DF flag handling of the encapsulation. Set totrueto set the DF flag for new data paths, orfalseto clear the DF flag.external_ids:ovn-enable-flow-based-tunnelsโ the boolean flag that indicates whetherovn-controllershould use flow-based tunnels instead of port-based tunnels for overlay network connectivity. Default value isfalse.
Port-based tunnels (the default mode) create a dedicated tunnel port for each combination of remote chassis and local encap IP, while flow-based tunnels create a single shared tunnel port for each tunnel type, and use OpenFlow set_field actions to dynamically set tunnel source and destination IP addresses per packet. very main character energy โจ
๐งช This feature is experimental and is disabled by default. There are some known limitations to the feature, bestie, don't say I didn't warn you: - IPSec is not supported. - BFD between tunnel endpoints is not supported, thus HA chassis (e.g. for Distributed Gateway Port redundancy) is not supported.
external_ids:ovn-bridge-mappingsโ a list of key-value pairs that map a physical network name to a local ovs bridge that provides connectivity to that network. An example value mapping two physical network names to two ovs bridges would be:physnet1:br-eth0,physnet2:br-eth1.external_ids:ovn-encap-csumโ bestie this one says "hey, encapsulation checksums can be sent and received with reasonable performance on this chassis" ๐ซ It's literally a lil hint to anyone sending data to this chassis that they should use checksums to protect OVN metadata. Set it totrueto enable orfalseto disable. Heads up tho: depending on what your network interface card can actually do, enabling encapsulation checksum may cost you performance ๐ญ and in those cases, encapsulation checksums can be disabled.external_ids:ovn-encap-tosโ this tells you the value that gets applied to the OVN tunnel interface'soption:tos, exactly as specified in theOpen_vSwitchdatabaseInterfacetable. Please refer to the Open VSwitch Manual for the details, iykyk ๐external_ids:ovn-cms-optionsโ a list of options that the CMS Plugin will consume, and they're specific to this particular chassis. An example would be:cms_option1,cms_option2:foo. Simple as ๐external_ids:ovn-transport-zonesโ the transport zone(s) this chassis belongs to ๐บ๏ธ Transport zones are literally just a way to group different chassis together so tunnels only form between members of the same group(s). You can specify multiple transport zones with a comma-separated list, like:tz1,tz2,tz3.
If it's not set, the Chassis gets considered part of a default transport zone. No stress ๐
external_ids:ovn-chassis-mac-mappingsโ a list of key-value pairs mapping a chassis-specific mac to a physical network name ๐ฆ An example value mapping two chassis macs to two physical network names would be:physnet1:aa:bb:cc:dd:ee:ff,physnet2:a1:b2:c3:d4:e5:f6. These are the macs thatovn-controllerwill replace a router port mac with, if a packet is going from a distributed router port on a vlan type logical switch.external_ids:ovn-is-interconnโ the boolean flag that tells you whether this chassis is being used as an interconnection gateway ๐external_ids:ovn-match-northd-versionโ the boolean flag for whetherovn-controllerneeds to check theovn-northdversion ๐ If this flag is set totrueandovn-northd's version (the one reported in the Southbound database) doesn't matchovn-controller's internal version, then it will stop processing the southbound and local Open vSwitch database changes. The default value is consideredfalseif this option isn't defined.external_ids:ovn-enable-lflow-cacheโ the boolean flag for whetherovn-controllershould enable/disable the logical flow in-memory cache it uses when processing Southbound database logical flow changes โจ By default, caching is enabled.external_ids:ovn-limit-lflow-cacheโ when you use this, the configuration value determines the maximum number of logical flow cache entriesovn-controllermay create when the logical flow cache is enabled. By default the size of the cache is unlimited ๐ซถexternal_ids:ovn-memlimit-lflow-cache-kbโ when used, this configuration value determines the maximum size of the logical flow cache (in KB) thatovn-controllermay create when the logical flow cache is enabled. By default the size of the cache is unlimited.external_ids:ovn-trim-limit-lflow-cacheโ when used, this configuration value sets the minimum number of entries in the logical flow cache starting with which automatic memory trimming is performed ๐งน By default this is set to10000entries.external_ids:ovn-trim-wmark-perc-lflow-cacheโ when used, this configuration value sets the percentage from the high watermark number of entries in the logical flow cache under which automatic memory trimming is performed. E.g., if the trim watermark percentage is set to50%, automatic memory trimming happens only when the number of entries in the logical flow cache gets reduced to less than half of the last measured high watermark. By default this is set to50.external_ids:ovn-trim-timeout-msโ when used, this configuration value specifies the time, in milliseconds, since the last logical flow cache operation, after whichovn-controllerperforms memory trimming regardless of how many entries there are in the cache ๐ค By default this is set to30000(30 seconds).external_ids:garp-max-timeout-secโ when used, this configuration value specifies the maximum timeout (in seconds) between two consecutive GARP packets sent byovn-controller๐ฃ By default,ovn-controllersends just4GARP packets with an exponential backoff timeout. Settingexternal_ids:garp-max-timeout-secallows you to cap that exponential backoff used byovn-controllerto send GARP packets.external_ids:arp-nd-max-timeout-secโ when used, this configuration value specifies the maximum timeout (in seconds) between two consecutive ARP/ND packets sent byovn-controllerto resolve the ECMP nexthop mac address ๐ By default,ovn-controllercontinuously sends ARP/ND packets. Settingexternal_ids:arp-nd-max-timeout-secallows you to cap the exponential backoff used byovn-controllerto send ARPs/NDs packets.external_ids:ovn-bridge-remoteโ the connection to the OVN management bridge in OvS ๐ It defaults tounix:br-int.mgmtwhen not specified.external_ids:ovn-bridge-remote-probe-intervalโ the inactivity probe interval of the connection to the OVN management bridge, in milliseconds โฑ๏ธ It defaults to zero. If the value is zero, it disables the inactivity probe.external_ids:dynamic-routing-port-mappingโ this setting works together with the Northbounddynamic-routing-port-nameoption onLogical_Router_Ports. See theovn-nb(5)for more details ๐
Note: when using therouting-protocol-redirectoption with veth pairs on Linux systems, this mapping may not be necessary, sinceovn-controllercan automatically discover the veth peer interface name. See therouting-protocol-redirectoption documentation inovn-nb(5)for details.
external_ids:ovn-cleanup-on-exitโ the boolean flag for whetherovn-controllershould perform cleanup on exit ๐งผ In order to keep backward compatibility, the--restartexit flag has priority over this flag.external_ids:ovn-evpn-vxlan-portsโ a comma-separated list of UDP ports used as a destination port for the EVPN tunnels created by thisovn-controller๐external_ids:ovn-evpn-local-ipโ the IP address list used as source addresses for the EVPN traffic leaving this OVN setup. Theovn-evpn-local-ipcan be specified by the CMS according to the following syntax:
external_ids:ovn-evpn-local-ip=vni0-IPv4,vni1-IPv4,vni1-IPv6,IPv4,IPv6
where, if no VNI value is specified, OVN will use the provided IP as default IP. Slay ๐
Most of the configuration options listed above can also be set for a particular chassis name (see external_ids:system-id for more information) ๐ You do it by setting external_ids:option-[chassis] instead of external_ids:option. For example, set external_ids:ovn-encap-ip-otherhv to use a particular IP address for the controller instance named otherhv. And bestie, name-specific configuration options always override any global options set in the database. Periodt ๐
Chassis-specific configuration options in the database, plus the ability to configure the chassis name to use via the system-id-override file or command line, allows you to run multiple ovn-controller instances with unique chassis names on the same host using the same vswitchd instance ๐ฅ This may be useful when running a hybrid setup with more than one CMS managing ports on the host, or to use different datapath types on the same host. And in order to support stateful features (ACLs, LBs, NAT) in multiple OVN deployments co-hosted on the same chassis, the CMS also needs to separate conntrack zone ranges between the co-hosted ovn-controllers through the external_ids:ct-zone-range configuration described in upcoming sections ๐ธ
ovn-controller reads the following values from the Open_vSwitch database of the local OVS instance:
datapath-typefromBridgetable โ this value is read from the local OVS integration bridge row of theBridgetable and populated inother_config:datapath-typeof theChassistable in theOVN_Southbounddatabase ๐งiface-typesfromOpen_vSwitchtable โ this value is populated inexternal_ids:iface-typesof theChassistable in theOVN_Southbounddatabase โจprivate_key,certificate,ca_cert, andbootstrap_ca_certfromSSLtable โ these values provide the SSL/TLS configuration used for connecting to the OVN southbound database server when an SSL/TLS connection type is configured viaexternal_ids:ovn-remote๐ Note that this SSL/TLS configuration can also be provided via command-line options, but the configuration in the database takes precedence if both are present.
โจ OPEN VSWITCH DATABASE USAGE โจ
so like, ovn-controller keeps a whole lil bookmark collection in the Open vSwitch database using external_ids keys, tracking ports and interfaces and stuff ๐ซถ. and bestie, listen โ for it to actually work right, users should not change or clear these keys. hands off the keys. they're not yours. ๐
external_ids:ovn-chassis-id in the Port table
if this key is there, it's flagging a tunnel port inside the integration bridge as one that ovn-controller made to reach a remote chassis ๐. its value = the chassis ID of that remote chassis.
external_ids:ct-zone-range in the Open_vSwitch table
this key being present means "hey, here's a min and a max for the ct-zone ids that ovn-controller picks dynamically" (and yes, the boundaries are included in the range, inclusive girlies โจ). minimum value is 1, maximum value is 65535.
external_ids:ct-zone-* in the Bridge table
logical ports and gateway routers get assigned a connection tracking zone by ovn-controller for stateful services ๐. and because we want that state to survive restarts of ovn-controller, these keys live in the integration bridge's Bridge table. the name has a prefix of ct-zone- followed by the name of the logical port or gateway router's zone key. the value for this key tells you which zone that port is using.
external_ids:ovn-localnet-port in the Port table
this key existing means a patch port was made by ovn-controller to connect the integration bridge to another bridge, implementing a localnet logical port ๐ฆ. its value is the name of the logical port whose type is set to localnet that the port implements. check external_ids:ovn-bridge-mappings, above, for more.
each localnet logical port is implemented as a pair of patch ports โ one in the integration bridge, one in a different bridge โ with the same external_ids:ovn-localnet-port value ๐ฏ
external_ids:ovn-l2gateway-port in the Port table
same vibe, different layer: this key marks a patch port as one created by ovn-controller to connect the integration bridge and another bridge to implement an l2gateway logical port. its value is the name of the logical port with type set to l2gateway that it implements. again, peep external_ids:ovn-bridge-mappings, above, for more.
each l2gateway logical port is also implemented as a pair of patch ports, one in the integration bridge, one in a different bridge, with the same external_ids:ovn-l2gateway-port value ๐ซ
external-ids:ovn-l3gateway-port in the Port table
(yes this one's external-ids: with a hyphen, not external_ids:, don't come for me, that's just how it is ๐) this key identifies a patch port as one created by ovn-controller to implement an l3gateway logical port. its value is the name of the logical port with type l3gateway. this patch port is similar to the OVN logical patch port, except that an l3gateway port can only be bound to a particular chassis. picky queen ๐
external-ids:ovn-logical-patch-port in the Port table
this key identifies a patch port as one created by ovn-controller to implement an OVN logical patch port within the integration bridge. its value is the name of the OVN logical patch port that it implements ๐
external-ids:ovn-startup-ts in the Bridge table
the timestamp (in milliseconds) of when the ovn-controller process was started โฐ
external-ids:ovn-nb-cfg in the Bridge table
this one's the last known OVN_Southbound.SB_Global.nb_cfg value for which all flows have been successfully installed in OVS โ
external-ids:ovn-nb-cfg-ts in the Bridge table
the timestamp (in milliseconds) of that last known OVN_Southbound.SB_Global.nb_cfg value for which all flows have been successfully installed in OVS ๐
external-ids:ovn-nb-cfg-sb-ts in the Bridge table
okay this one's the receipts ๐ it records the value of OVN_Southbound.SB_Global.nb_cfg_timestamp that corresponded to the ovn-nb-cfg generation for which all flows have been successfully installed in OVS. it's the wall-clock time (in milliseconds since the Unix epoch) at which ovn-northd wrote that nb_cfg value to the Southbound database. and the glow-up math: the difference between this timestamp and ovn-nb-cfg-ts gives you the per-chassis end-to-end propagation latency for that configuration generation ๐
the key is absent when no timestamp is available (e.g. whenNB_Global.options:enable_chassis_nb_cfg_updateisfalse).
external_ids:ovn-installed and external_ids:ovn-installed-ts in the Interface table
this key gets set after all the openflow operations corresponding to the OVS interface have been processed by ovs-vswitchd ๐ฅ. and at the same time, a timestamp โ in milliseconds since the epoch โ is stored in external_ids:ovn-installed-ts.
external_ids:ovn-evpn-tunnel in the Port and Interface table
if this key is present, it means the Port/Interface was created by ovn-controller to be used as a tunnel port for EVPN traffic ๐ฐ๏ธ
๐ OVN SOUTHBOUND DATABASE USAGE ๐
ovn-controller reads from a whole bunch of the OVN_Southbound database to guide its operation โ it's giving main character energy, absorbing everything โจ. but it also writes to these tables:
Chassis
on startup, ovn-controller creates a row in this table to represent its own chassis ๐
. and on graceful termination โ like with ovn-appctl -t ovn-controller exit (but not SIGTERM, bestie, that one's not graceful ๐ญ) โ ovn-controller removes its row.
Encap
on startup, ovn-controller creates a row or rows in this table representing the tunnel encapsulations by which its chassis can be reached, and points its Chassis row at them ๐. on graceful termination, ovn-controller removes these rows.
Port_Binding
at runtime, ovn-controller sets the chassis columns of ports that are resident on its chassis to point to its Chassis row ๐ and, conversely, clears the chassis column of ports that point to its Chassis row but are no longer resident on its chassis. the chassis column has a weak reference type, so when ovn-controller gracefully exits and removes its Chassis row, the database server automatically clears any remaining references to that row. self-cleaning icon behavior ๐งผ
MAC_Binding
at runtime, ovn-controller updates the MAC_Binding table as instructed by put_arp and put_nd logical actions ๐ฎ. heads up though: these changes persist beyond the lifetime of ovn-controller โ they outlive her, no cap ๐
โจ RUNTIME MANAGEMENT COMMANDS โจ
okay bestie so ovn-appctl can slide into a running ovn-controller process and send it commands ๐
The ones it supports rn are right here, all listed out, no cap:
exitโ makesovn-controllerterminate gracefully. like, politely. it says bye and leaves ๐ซถct-zone-listโ lists every local logical port and its connection tracking zone. receipts for all of them ๐meter-table-listโ lists each meter table entry plus its local meter id.group-table-listโ lists each group table entry plus its local group id.inject-pkt microflowโ injectsmicroflowinto the connected Open vSwitch instance. the microflow must contain an ingress logical port (that's theinportargument) that's actually present on the Open vSwitch instance, okay? otherwise it's not giving what it needs to give.
the microflow argument describes the packet whose forwarding is gonna be simulated, and it's written in the syntax of an OVN logical expression โ same as described in ovn-sb(5) โ used to express constraints. the parser understands prerequisites which is so iconic of it: so if your expression refers to ip4.src, you literally do not need to explicitly state ip4 or eth.type == 0x800. it already knows ๐
connection-statusโ shows the OVN SBDB connection status for the chassis. vibe check on the connection fr fr.recomputeโ triggers a full compute iteration inovn-controllerbased on the contents of the Southbound database and the local OVS database.
โ ๏ธ okay so this one is intended to be used only in the event of a bug in the incremental processing engine in ovn-controller, to avoid inconsistent states. so please use it with care bestie, because full recomputes are cpu intensive. it's giving heavy. respect the CPU ๐ญ
sb-cluster-state-resetโ resets southbound database cluster status for when databases are destroyed and rebuilt.
if all databases in a clustered southbound database get removed from disk, then the stored index of all databases will be reset to zero. and that causes ovn-controller to be unable to read or write to the southbound database, because it will always detect the data as stale. ๐ in that case, run this command so that ovn-controller resets its local index so it can interact with the southbound database again. slay, fixed.
debug/delay-nb-cfg-report secondsโ this command delaysovn-controllerupdating thenb_cfgback to theOVN_Southbounddatabase. it's useful whenovn-nbctl --wait=hvis used to measure end-to-end latency in a large scale environment. seeovn-nbctl(8)for more details ๐ฆlflow-cache/flushโ flushes theovn-controllerlogical flow cache. clean sweep, so satisfying โจlflow-cache/show-statsโ displays logical flow cache statistics: enabled/disabled, per cache type entry counts. the numbers, the tea โinc-engine/show-statsโ displaysovn-controllerengine counters. for each engine node the following counters have been added:recomputecomputecancel
inc-engine/show-stats engine_node_name counter_nameโ displays theovn-controllerengine counter(s) for the specifiedengine_node_name.counter_nameis optional and can be one ofrecompute,computeorcancel. pick your fighter ๐inc-engine/clear-statsโ resetsovn-controllerengine counters. back to zero, fresh start, main character energy ๐inc-engine/enable-stopwatch [node]โ enables the per-node and per-handler stopwatches in the incremental processing engine. ifnodeis specified, only that node's stopwatches are enabled; otherwise all nodes are affected. while enabled, every engine noderecomputeand change handler invocation gets timed, and the results can be viewed with thestopwatch/showcommand. stopwatches are disabled by default because they add measurable CPU overhead. so like, it's cute but it costs ๐inc-engine/disable-stopwatch [node]โ disables the per-node and per-handler stopwatches in the incremental processing engine. ifnodeis specified, only that node's stopwatches are disabled; otherwise all nodes are affected. this is the default state. the chill, unbothered baseline ๐
and that's the whole page bestie, we did it ๐ this was ovn-controller(8), from OVN version 26.09.1, dated ovn-controller. go forth and be iconic with your chassis, mwah ๐๐ธ
๐ฆ where this page comes from
- fedora 44: ovn-host 26.09.0-33.fc44 ยท Apache-2.0
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms