1<?xml version='1.0'?> 2<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" 3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> 4<!-- SPDX-License-Identifier: LGPL-2.1-or-later --> 5 6<refentry id="systemd.network" conditional='ENABLE_NETWORKD' 7 xmlns:xi="http://www.w3.org/2001/XInclude"> 8 9 <refentryinfo> 10 <title>systemd.network</title> 11 <productname>systemd</productname> 12 </refentryinfo> 13 14 <refmeta> 15 <refentrytitle>systemd.network</refentrytitle> 16 <manvolnum>5</manvolnum> 17 </refmeta> 18 19 <refnamediv> 20 <refname>systemd.network</refname> 21 <refpurpose>Network configuration</refpurpose> 22 </refnamediv> 23 24 <refsynopsisdiv> 25 <para><filename><replaceable>network</replaceable>.network</filename></para> 26 </refsynopsisdiv> 27 28 <refsect1> 29 <title>Description</title> 30 31 <para>A plain ini-style text file that encodes network configuration for matching network 32 interfaces, used by 33 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 34 See <citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>7</manvolnum></citerefentry> 35 for a general description of the syntax.</para> 36 37 <para>The main network file must have the extension <filename>.network</filename>; other 38 extensions are ignored. Networks are applied to links whenever the links appear.</para> 39 40 <para>The <filename>.network</filename> files are read from the files located in the system network 41 directories <filename>/usr/lib/systemd/network</filename> and 42 <filename>/usr/local/lib/systemd/network</filename>, the volatile runtime network directory 43 <filename>/run/systemd/network</filename> and the local administration network directory 44 <filename>/etc/systemd/network</filename>. All configuration files are collectively sorted and 45 processed in alphanumeric order, regardless of the directories in which they live. However, files 46 with identical filenames replace each other. It is recommended that each filename is prefixed with 47 a number (e.g. <filename>10-eth0.network</filename>). Otherwise, the default 48 <filename>.network</filename> files or those generated by 49 <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> 50 may take precedence over user configured files. Files in <filename>/etc/</filename> have the highest 51 priority, files in <filename>/run/</filename> take precedence over files with the same name under 52 <filename>/usr/</filename>. This can be used to override a system-supplied configuration file with 53 a local file if needed. As a special case, an empty file (file size 0) or symlink with the same 54 name pointing to <filename>/dev/null</filename> disables the configuration file entirely (it is 55 "masked").</para> 56 57 <para>Along with the network file <filename>foo.network</filename>, a "drop-in" directory 58 <filename>foo.network.d/</filename> may exist. All files with the suffix 59 <literal>.conf</literal> from this directory will be merged in the alphanumeric order and parsed 60 after the main file itself has been parsed. This is useful to alter or add configuration settings, 61 without having to modify the main configuration file. Each drop-in file must have appropriate 62 section headers.</para> 63 64 <para>In addition to <filename>/etc/systemd/network</filename>, drop-in <literal>.d</literal> 65 directories can be placed in <filename>/usr/lib/systemd/network</filename> or 66 <filename>/run/systemd/network</filename> directories. Drop-in files in 67 <filename>/etc/</filename> take precedence over those in <filename>/run/</filename> which in turn 68 take precedence over those in <filename>/usr/lib/</filename>. Drop-in files under any of these 69 directories take precedence over the main network file wherever located.</para> 70 </refsect1> 71 72 <refsect1> 73 <title>[Match] Section Options</title> 74 75 <para>The network file contains a [Match] section, which determines if a given network file may 76 be applied to a given interface; and a [Network] section specifying how the interface should be 77 configured. The first (in alphanumeric order) of the network files that matches a given interface 78 is applied, all later files are ignored, even if they match as well.</para> 79 80 <para>A network file is said to match a network interface if all matches specified by the [Match] 81 section are satisfied. When a network file does not contain valid settings in [Match] section, then 82 the file will match all interfaces and <command>systemd-networkd</command> warns about that. Hint: 83 to avoid the warning and to make it clear that all interfaces shall be matched, add the following: 84 <programlisting>Name=*</programlisting> The following keys are accepted:</para> 85 86 <variablelist class='network-directives'> 87 <xi:include href="systemd.link.xml" xpointer="mac-address" /> 88 <xi:include href="systemd.link.xml" xpointer="permanent-mac-address" /> 89 <xi:include href="systemd.link.xml" xpointer="path" /> 90 <xi:include href="systemd.link.xml" xpointer="driver" /> 91 <xi:include href="systemd.link.xml" xpointer="type" /> 92 <xi:include href="systemd.link.xml" xpointer="kind" /> 93 <xi:include href="systemd.link.xml" xpointer="property" /> 94 95 <varlistentry> 96 <term><varname>Name=</varname></term> 97 <listitem> 98 <para>A whitespace-separated list of shell-style globs matching the device name, as exposed 99 by the udev property <literal>INTERFACE</literal>, or device's alternative names. If the 100 list is prefixed with a "!", the test is inverted.</para> 101 </listitem> 102 </varlistentry> 103 104 <varlistentry> 105 <term><varname>WLANInterfaceType=</varname></term> 106 <listitem> 107 <para>A whitespace-separated list of wireless network type. Supported values are 108 <literal>ad-hoc</literal>, <literal>station</literal>, <literal>ap</literal>, 109 <literal>ap-vlan</literal>, <literal>wds</literal>, <literal>monitor</literal>, 110 <literal>mesh-point</literal>, <literal>p2p-client</literal>, <literal>p2p-go</literal>, 111 <literal>p2p-device</literal>, <literal>ocb</literal>, and <literal>nan</literal>. If the 112 list is prefixed with a "!", the test is inverted. </para> 113 </listitem> 114 </varlistentry> 115 116 <varlistentry> 117 <term><varname>SSID=</varname></term> 118 <listitem> 119 <para>A whitespace-separated list of shell-style globs matching the SSID of the currently 120 connected wireless LAN. If the list is prefixed with a "!", the test is inverted.</para> 121 </listitem> 122 </varlistentry> 123 124 <varlistentry> 125 <term><varname>BSSID=</varname></term> 126 <listitem> 127 <para>A whitespace-separated list of hardware address of the currently connected wireless 128 LAN. Use full colon-, hyphen- or dot-delimited hexadecimal. See the example in 129 <varname>MACAddress=</varname>. This option may appear more than once, in which case the 130 lists are merged. If the empty string is assigned to this option, the list is reset.</para> 131 </listitem> 132 </varlistentry> 133 134 <xi:include href="systemd.link.xml" xpointer="host" /> 135 <xi:include href="systemd.link.xml" xpointer="virtualization" /> 136 <xi:include href="systemd.link.xml" xpointer="kernel-command-line" /> 137 <xi:include href="systemd.link.xml" xpointer="kernel-version" /> 138 <xi:include href="systemd.link.xml" xpointer="architecture" /> 139 <xi:include href="systemd.link.xml" xpointer="firmware" /> 140 </variablelist> 141 </refsect1> 142 143 <refsect1> 144 <title>[Link] Section Options</title> 145 146 <para>The [Link] section accepts the following keys:</para> 147 148 <variablelist class='network-directives'> 149 <varlistentry> 150 <term><varname>MACAddress=</varname></term> 151 <listitem> 152 <para>The hardware address to set for the device.</para> 153 </listitem> 154 </varlistentry> 155 156 <varlistentry> 157 <term><varname>MTUBytes=</varname></term> 158 <listitem> 159 <para>The maximum transmission unit in bytes to set for the device. The usual suffixes K, M, 160 G, are supported and are understood to the base of 1024.</para> 161 <para>Note that if IPv6 is enabled on the interface, and the MTU is chosen below 1280 (the 162 minimum MTU for IPv6) it will automatically be increased to this value.</para> 163 </listitem> 164 </varlistentry> 165 166 <varlistentry> 167 <term><varname>ARP=</varname></term> 168 <listitem> 169 <para>Takes a boolean. If set to true, the ARP (low-level Address Resolution Protocol) 170 for this interface is enabled. When unset, the kernel's default will be used.</para> 171 <para> For example, disabling ARP is useful when creating multiple MACVLAN or VLAN virtual 172 interfaces atop a single lower-level physical interface, which will then only serve as a 173 link/"bridge" device aggregating traffic to the same physical link and not participate in 174 the network otherwise. Defaults to unset.</para> 175 </listitem> 176 </varlistentry> 177 178 <varlistentry> 179 <term><varname>Multicast=</varname></term> 180 <listitem> 181 <para>Takes a boolean. If set to true, the multicast flag on the device is enabled. Defaults 182 to unset.</para> 183 </listitem> 184 </varlistentry> 185 186 <varlistentry> 187 <term><varname>AllMulticast=</varname></term> 188 <listitem> 189 <para>Takes a boolean. If set to true, the driver retrieves all multicast packets from the 190 network. This happens when multicast routing is enabled. Defaults to unset.</para> 191 </listitem> 192 </varlistentry> 193 194 <varlistentry> 195 <term><varname>Promiscuous=</varname></term> 196 <listitem> 197 <para>Takes a boolean. If set to true, promiscuous mode of the interface is enabled. Defaults 198 to unset.</para> 199 <para>If this is set to false for the underlying link of a <literal>passthru</literal> mode 200 MACVLAN/MACVTAP, the virtual interface will be created with the <literal>nopromisc</literal> 201 flag set.</para> 202 </listitem> 203 </varlistentry> 204 205 <varlistentry> 206 <term><varname>Unmanaged=</varname></term> 207 <listitem> 208 <para>Takes a boolean. When <literal>yes</literal>, no attempts are made to bring up or 209 configure matching links, equivalent to when there are no matching network files. Defaults to 210 <literal>no</literal>.</para> 211 <para>This is useful for preventing later matching network files from interfering with 212 certain interfaces that are fully controlled by other applications.</para> 213 </listitem> 214 </varlistentry> 215 216 <varlistentry> 217 <term><varname>Group=</varname></term> 218 <listitem> 219 <para>Link groups are similar to port ranges found in managed switches. When network 220 interfaces are added to a numbered group, operations on all the interfaces from that group 221 can be performed at once. Takes an unsigned integer in the range 0…2147483647. Defaults to 222 unset.</para> 223 </listitem> 224 </varlistentry> 225 226 <varlistentry> 227 <term><varname>RequiredForOnline=</varname></term> 228 <listitem> 229 <para>Takes a boolean or a minimum operational state and an optional maximum operational 230 state. Please see 231 <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> 232 for possible operational states. When <literal>yes</literal>, the network is deemed required 233 when determining whether the system is online (including when running 234 <command>systemd-networkd-wait-online</command>). When <literal>no</literal>, the network is 235 ignored when determining the online state. When a minimum operational state and an optional 236 maximum operational state are set, <literal>yes</literal> is implied, and this controls the 237 minimum and maximum operational state required for the network interface to be considered 238 online.</para> 239 240 <para>Defaults to <literal>yes</literal> when <varname>ActivationPolicy=</varname> is not 241 set, or set to <literal>up</literal>, <literal>always-up</literal>, or 242 <literal>bound</literal>. Defaults to <literal>no</literal> when 243 <varname>ActivationPolicy=</varname> is set to <literal>manual</literal> or 244 <literal>down</literal>. This is forced to <literal>no</literal> when 245 <varname>ActivationPolicy=</varname> is set to <literal>always-down</literal>.</para> 246 247 <para>The network will be brought up normally (as configured by 248 <varname>ActivationPolicy=</varname>), but in the event that there is no address being 249 assigned by DHCP or the cable is not plugged in, the link will simply remain offline and be 250 skipped automatically by <command>systemd-networkd-wait-online</command> if 251 <literal>RequiredForOnline=no</literal>.</para> 252 </listitem> 253 </varlistentry> 254 255 <varlistentry> 256 <term><varname>RequiredFamilyForOnline=</varname></term> 257 <listitem> 258 <para>Takes an address family. When specified, an IP address in the given family is deemed 259 required when determining whether the link is online (including when running 260 <command>systemd-networkd-wait-online</command>). Takes one of <literal>ipv4</literal>, 261 <literal>ipv6</literal>, <literal>both</literal>, or <literal>any</literal>. Defaults to 262 <literal>any</literal>. Note that this option has no effect if 263 <literal>RequiredForOnline=no</literal>, or if <literal>RequiredForOnline=</literal> 264 specifies a minimum operational state below <literal>degraded</literal>.</para> 265 </listitem> 266 </varlistentry> 267 268 <varlistentry> 269 <term><varname>ActivationPolicy=</varname></term> 270 <listitem> 271 <para>Specifies the policy for <command>systemd-networkd</command> managing the link 272 administrative state. Specifically, this controls how <command>systemd-networkd</command> 273 changes the network device's <literal>IFF_UP</literal> flag, which is sometimes 274 controlled by system administrators by running e.g., 275 <command>ip link set dev eth0 up</command> or <command>ip link set dev eth0 down</command>, 276 and can also be changed with <command>networkctl up eth0</command> or 277 <command>networkctl down eth0</command>.</para> 278 279 <para>Takes one of <literal>up</literal>, <literal>always-up</literal>, 280 <literal>manual</literal>, <literal>always-down</literal>, <literal>down</literal>, 281 or <literal>bound</literal>. When <literal>manual</literal>, 282 <command>systemd-networkd</command> will not change the link's admin state automatically; 283 the system administrator must bring the interface up or down manually, as desired. When 284 <literal>up</literal> (the default) or <literal>always-up</literal>, or 285 <literal>down</literal> or <literal>always-down</literal>, 286 <command>systemd-networkd</command> will set the link up or down, respectively, when the 287 interface is (re)configured. When <literal>always-up</literal> or 288 <literal>always-down</literal>, <command>systemd-networkd</command> will set the link up or 289 down, respectively, any time <command>systemd-networkd</command> detects a change in the 290 administrative state. When <varname>BindCarrier=</varname> is also set, this is automatically 291 set to <literal>bound</literal> and any other value is ignored.</para> 292 293 <para>When the policy is set to <literal>down</literal> or <literal>manual</literal>, the 294 default value of <varname>RequiredForOnline=</varname> is <literal>no</literal>. When the 295 policy is set to <literal>always-down</literal>, the value of 296 <varname>RequiredForOnline=</varname> forced to <literal>no</literal>.</para> 297 298 <para>The administrative state is not the same as the carrier state, so using 299 <literal>always-up</literal> does not mean the link will never lose carrier. The link carrier 300 depends on both the administrative state as well as the network device's physical connection. 301 However, to avoid reconfiguration failures, when using <literal>always-up</literal>, 302 <varname>IgnoreCarrierLoss=</varname> is forced to true.</para> 303 </listitem> 304 </varlistentry> 305 </variablelist> 306 </refsect1> 307 308 <xi:include href="systemd.link.xml" xpointer="sr-iov" /> 309 310 <refsect1> 311 <title>[Network] Section Options</title> 312 313 <para>The [Network] section accepts the following keys:</para> 314 315 <variablelist class='network-directives'> 316 <varlistentry> 317 <term><varname>Description=</varname></term> 318 <listitem> 319 <para>A description of the device. This is only used for presentation purposes.</para> 320 </listitem> 321 </varlistentry> 322 323 <varlistentry> 324 <term><varname>DHCP=</varname></term> 325 <listitem> 326 <para>Enables DHCPv4 and/or DHCPv6 client support. Accepts <literal>yes</literal>, 327 <literal>no</literal>, <literal>ipv4</literal>, or <literal>ipv6</literal>. Defaults to 328 <literal>no</literal>.</para> 329 330 <para>Note that DHCPv6 will by default be triggered by Router Advertisement, if that is 331 enabled, regardless of this parameter. By explicitly enabling DHCPv6 support here, the 332 DHCPv6 client will be started in the mode specified by the <variable>WithoutRA=</variable> 333 setting in the [DHCPv6] section, regardless of the presence of routers on the link, or 334 what flags the routers pass. See <literal>IPv6AcceptRA=</literal>.</para> 335 336 <para>Furthermore, note that by default the domain name specified through DHCP is not used 337 for name resolution. See option <option>UseDomains=</option> below.</para> 338 339 <para>See the [DHCPv4] or [DHCPv6] sections below for further configuration options for the 340 DHCP client support.</para> 341 </listitem> 342 </varlistentry> 343 344 <varlistentry> 345 <term><varname>DHCPServer=</varname></term> 346 <listitem> 347 <para>Takes a boolean. If set to <literal>yes</literal>, DHCPv4 server will be started. 348 Defaults to <literal>no</literal>. Further settings for the DHCP server may be set in the 349 [DHCPServer] section described below.</para> 350 </listitem> 351 </varlistentry> 352 353 <varlistentry> 354 <term><varname>LinkLocalAddressing=</varname></term> 355 <listitem> 356 <para>Enables link-local address autoconfiguration. Accepts <option>yes</option>, 357 <option>no</option>, <option>ipv4</option>, and <option>ipv6</option>. An IPv6 link-local 358 address is configured when <option>yes</option> or <option>ipv6</option>. An IPv4 link-local 359 address is configured when <option>yes</option> or <option>ipv4</option> and when DHCPv4 360 autoconfiguration has been unsuccessful for some time. (IPv4 link-local address 361 autoconfiguration will usually happen in parallel with repeated attempts to acquire a DHCPv4 362 lease).</para> 363 364 <para>Defaults to <option>no</option> when <varname>KeepMaster=</varname> or 365 <varname>Bridge=</varname> is set or when the specified 366 <varname>MACVLAN=</varname>/<varname>MACVTAP=</varname> has <varname>Mode=passthru</varname>, 367 or <option>ipv6</option> otherwise.</para> 368 </listitem> 369 </varlistentry> 370 371 <varlistentry> 372 <term><varname>IPv6LinkLocalAddressGenerationMode=</varname></term> 373 <listitem> 374 <para>Specifies how IPv6 link-local address is generated. Takes one of 375 <literal>eui64</literal>, <literal>none</literal>, <literal>stable-privacy</literal> and 376 <literal>random</literal>. When unset, <literal>stable-privacy</literal> is used if 377 <varname>IPv6StableSecretAddress=</varname> is specified, and if not, 378 <literal>eui64</literal> is used. Note that if <varname>LinkLocalAddressing=</varname> is 379 <literal>no</literal> or <literal>ipv4</literal>, then 380 <varname>IPv6LinkLocalAddressGenerationMode=</varname> will be ignored. Also, even if 381 <varname>LinkLocalAddressing=</varname> is <literal>yes</literal> or <literal>ipv6</literal>, 382 setting <varname>IPv6LinkLocalAddressGenerationMode=none</varname> 383 disables to configure an IPv6 link-local address.</para> 384 </listitem> 385 </varlistentry> 386 387 <varlistentry> 388 <term><varname>IPv6StableSecretAddress=</varname></term> 389 <listitem> 390 <para>Takes an IPv6 address. The specified address will be used as a stable secret for 391 generating IPv6 link-local address. If this setting is specified, and 392 <varname>IPv6LinkLocalAddressGenerationMode=</varname> is unset, then 393 <varname>IPv6LinkLocalAddressGenerationMode=stable-privacy</varname> is implied. 394 If this setting is not specified, and <literal>stable-privacy</literal> is set to 395 <varname>IPv6LinkLocalAddressGenerationMode=</varname>, 396 then a stable secret address will be generated from the local machine ID and the interface 397 name.</para> 398 </listitem> 399 </varlistentry> 400 401 <varlistentry> 402 <term><varname>IPv4LLRoute=</varname></term> 403 <listitem> 404 <para>Takes a boolean. If set to true, sets up the route needed for non-IPv4LL hosts to 405 communicate with IPv4LL-only hosts. Defaults to false.</para> 406 </listitem> 407 </varlistentry> 408 409 <varlistentry> 410 <term><varname>DefaultRouteOnDevice=</varname></term> 411 <listitem> 412 <para>Takes a boolean. If set to true, sets up the default route bound to the interface. 413 Defaults to false. This is useful when creating routes on point-to-point interfaces. This is 414 equivalent to e.g. the following, 415 <programlisting>ip route add default dev veth99</programlisting> 416 or, 417 <programlisting>[Route] 418Gateway=0.0.0.0</programlisting></para> 419 <para>Currently, there are no way to specify e.g., the table for the route configured by this 420 setting. To configure the default route with such an additional property, please use the 421 following instead: 422 <programlisting>[Route] 423Gateway=0.0.0.0 424Table=1234</programlisting></para> 425 </listitem> 426 </varlistentry> 427 428 <varlistentry> 429 <term><varname>LLMNR=</varname></term> 430 <listitem> 431 <para>Takes a boolean or <literal>resolve</literal>. When true, enables 432 <ulink url="https://tools.ietf.org/html/rfc4795">Link-Local Multicast Name Resolution</ulink> 433 on the link. When set to <literal>resolve</literal>, only resolution is enabled, but not host 434 registration and announcement. Defaults to true. This setting is read by 435 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 436 </para> 437 </listitem> 438 </varlistentry> 439 440 <varlistentry> 441 <term><varname>MulticastDNS=</varname></term> 442 <listitem> 443 <para>Takes a boolean or <literal>resolve</literal>. When true, enables 444 <ulink url="https://tools.ietf.org/html/rfc6762">Multicast DNS</ulink> support on the link. 445 When set to <literal>resolve</literal>, only resolution is enabled, but not host or service 446 registration and announcement. Defaults to false. This setting is read by 447 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 448 </para> 449 </listitem> 450 </varlistentry> 451 452 <varlistentry> 453 <term><varname>DNSOverTLS=</varname></term> 454 <listitem> 455 <para>Takes a boolean or <literal>opportunistic</literal>. When true, enables 456 <ulink url="https://tools.ietf.org/html/rfc7858">DNS-over-TLS</ulink> support on the link. 457 When set to <literal>opportunistic</literal>, compatibility with non-DNS-over-TLS servers is 458 increased, by automatically turning off DNS-over-TLS servers in this case. This option 459 defines a per-interface setting for 460 <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s 461 global <varname>DNSOverTLS=</varname> option. Defaults to unset, and the global setting will 462 be used. This setting is read by 463 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 464 </para> 465 </listitem> 466 </varlistentry> 467 468 <varlistentry> 469 <term><varname>DNSSEC=</varname></term> 470 <listitem> 471 <para>Takes a boolean or <literal>allow-downgrade</literal>. When true, enables 472 <ulink url="https://tools.ietf.org/html/rfc4033">DNSSEC</ulink> DNS validation support on the 473 link. When set to <literal>allow-downgrade</literal>, compatibility with non-DNSSEC capable 474 networks is increased, by automatically turning off DNSSEC in this case. This option defines 475 a per-interface setting for 476 <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s 477 global <varname>DNSSEC=</varname> option. Defaults to unset, and the global setting will be 478 used. This setting is read by 479 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 480 </para> 481 </listitem> 482 </varlistentry> 483 484 <varlistentry> 485 <term><varname>DNSSECNegativeTrustAnchors=</varname></term> 486 <listitem> 487 <para>A space-separated list of DNSSEC negative trust anchor domains. If specified and DNSSEC 488 is enabled, look-ups done via the interface's DNS server will be subject to the list of 489 negative trust anchors, and not require authentication for the specified domains, or anything 490 below it. Use this to disable DNSSEC authentication for specific private domains, that cannot 491 be proven valid using the Internet DNS hierarchy. Defaults to the empty list. This setting is 492 read by 493 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 494 </para> 495 </listitem> 496 </varlistentry> 497 498 <varlistentry> 499 <term><varname>LLDP=</varname></term> 500 <listitem> 501 <para>Controls support for Ethernet LLDP packet reception. LLDP is a link-layer protocol 502 commonly implemented on professional routers and bridges which announces which physical port 503 a system is connected to, as well as other related data. Accepts a boolean or the special 504 value <literal>routers-only</literal>. When true, incoming LLDP packets are accepted and a 505 database of all LLDP neighbors maintained. If <literal>routers-only</literal> is set only 506 LLDP data of various types of routers is collected and LLDP data about other types of devices 507 ignored (such as stations, telephones and others). If false, LLDP reception is disabled. 508 Defaults to <literal>routers-only</literal>. Use 509 <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> 510 to query the collected neighbor data. LLDP is only available on Ethernet links. See 511 <varname>EmitLLDP=</varname> below for enabling LLDP packet emission from the local system. 512 </para> 513 </listitem> 514 </varlistentry> 515 516 <varlistentry> 517 <term><varname>EmitLLDP=</varname></term> 518 <listitem> 519 <para>Controls support for Ethernet LLDP packet emission. Accepts a boolean parameter or the 520 special values <literal>nearest-bridge</literal>, <literal>non-tpmr-bridge</literal> and 521 <literal>customer-bridge</literal>. Defaults to false, which turns off LLDP packet emission. 522 If not false, a short LLDP packet with information about the local system is sent out in 523 regular intervals on the link. The LLDP packet will contain information about the local 524 hostname, the local machine ID (as stored in 525 <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>) 526 and the local interface name, as well as the pretty hostname of the system (as set in 527 <citerefentry><refentrytitle>machine-info</refentrytitle><manvolnum>5</manvolnum></citerefentry>). 528 LLDP emission is only available on Ethernet links. Note that this setting passes data 529 suitable for identification of host to the network and should thus not be enabled on 530 untrusted networks, where such identification data should not be made available. Use this 531 option to permit other systems to identify on which interfaces they are connected to this 532 system. The three special values control propagation of the LLDP packets. The 533 <literal>nearest-bridge</literal> setting permits propagation only to the nearest connected 534 bridge, <literal>non-tpmr-bridge</literal> permits propagation across Two-Port MAC Relays, 535 but not any other bridges, and <literal>customer-bridge</literal> permits propagation until 536 a customer bridge is reached. For details about these concepts, see 537 <ulink url="https://standards.ieee.org/findstds/standard/802.1AB-2016.html">IEEE 802.1AB-2016</ulink>. 538 Note that configuring this setting to true is equivalent to 539 <literal>nearest-bridge</literal>, the recommended and most restricted level of propagation. 540 See <varname>LLDP=</varname> above for an option to enable LLDP reception.</para> 541 </listitem> 542 </varlistentry> 543 544 <varlistentry> 545 <term><varname>BindCarrier=</varname></term> 546 <listitem> 547 <para>A link name or a list of link names. When set, controls the behavior of the current 548 link. When all links in the list are in an operational down state, the current link is 549 brought down. When at least one link has carrier, the current interface is brought up.</para> 550 551 <para>This forces <varname>ActivationPolicy=</varname> to be set to <literal>bound</literal>. 552 </para> 553 </listitem> 554 </varlistentry> 555 556 <varlistentry> 557 <term><varname>Address=</varname></term> 558 <listitem> 559 <para>A static IPv4 or IPv6 address and its prefix length, separated by a 560 <literal>/</literal> character. Specify this key more than once to configure several 561 addresses. The format of the address must be as described in 562 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 563 This is a short-hand for an [Address] section only containing an Address key (see below). 564 This option may be specified more than once.</para> 565 566 <para>If the specified address is <literal>0.0.0.0</literal> (for IPv4) or 567 <literal>::</literal> (for IPv6), a new address range of the requested size is automatically 568 allocated from a system-wide pool of unused ranges. Note that the prefix length must be equal 569 or larger than 8 for IPv4, and 64 for IPv6. The allocated range is checked against all 570 current network interfaces and all known network configuration files to avoid address range 571 conflicts. The default system-wide pool consists of 192.168.0.0/16, 172.16.0.0/12 and 572 10.0.0.0/8 for IPv4, and fd00::/8 for IPv6. This functionality is useful to manage a large 573 number of dynamically created network interfaces with the same network configuration and 574 automatic address range assignment.</para> 575 </listitem> 576 </varlistentry> 577 578 <varlistentry> 579 <term><varname>Gateway=</varname></term> 580 <listitem> 581 <para>The gateway address, which must be in the format described in 582 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 583 This is a short-hand for a [Route] section only containing a <varname>Gateway=</varname> key. 584 This option may be specified more than once.</para> 585 </listitem> 586 </varlistentry> 587 588 <varlistentry> 589 <term><varname>DNS=</varname></term> 590 <listitem> 591 <para>A DNS server address, which must be in the format described in 592 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 593 This option may be specified more than once. Each address can optionally take a port number 594 separated with <literal>:</literal>, a network interface name or index separated with 595 <literal>%</literal>, and a Server Name Indication (SNI) separated with <literal>#</literal>. 596 When IPv6 address is specified with a port number, then the address must be in the square 597 brackets. That is, the acceptable full formats are 598 <literal>111.222.333.444:9953%ifname#example.com</literal> for IPv4 and 599 <literal>[1111:2222::3333]:9953%ifname#example.com</literal> for IPv6. If an empty string is 600 assigned, then the all previous assignments are cleared. This setting is read by 601 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 602 </para> 603 </listitem> 604 </varlistentry> 605 606 <varlistentry> 607 <term><varname>Domains=</varname></term> 608 <listitem> 609 <para>A whitespace-separated list of domains which should be resolved using the DNS servers 610 on this link. Each item in the list should be a domain name, optionally prefixed with a tilde 611 (<literal>~</literal>). The domains with the prefix are called "routing-only domains". The 612 domains without the prefix are called "search domains" and are first used as search suffixes 613 for extending single-label hostnames (hostnames containing no dots) to become fully qualified 614 domain names (FQDNs). If a single-label hostname is resolved on this interface, each of the 615 specified search domains are appended to it in turn, converting it into a fully qualified 616 domain name, until one of them may be successfully resolved.</para> 617 618 <para>Both "search" and "routing-only" domains are used for routing of DNS queries: look-ups 619 for hostnames ending in those domains (hence also single label names, if any "search domains" 620 are listed), are routed to the DNS servers configured for this interface. The domain routing 621 logic is particularly useful on multi-homed hosts with DNS servers serving particular private 622 DNS zones on each interface.</para> 623 624 <para>The "routing-only" domain <literal>~.</literal> (the tilde indicating definition of a 625 routing domain, the dot referring to the DNS root domain which is the implied suffix of all 626 valid DNS names) has special effect. It causes all DNS traffic which does not match another 627 configured domain routing entry to be routed to DNS servers specified for this interface. 628 This setting is useful to prefer a certain set of DNS servers if a link on which they are 629 connected is available.</para> 630 631 <para>This setting is read by 632 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 633 "Search domains" correspond to the <varname>domain</varname> and <varname>search</varname> 634 entries in 635 <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. 636 Domain name routing has no equivalent in the traditional glibc API, which has no concept of 637 domain name servers limited to a specific link.</para> 638 </listitem> 639 </varlistentry> 640 641 <varlistentry> 642 <term><varname>DNSDefaultRoute=</varname></term> 643 <listitem> 644 <para>Takes a boolean argument. If true, this link's configured DNS servers are used for 645 resolving domain names that do not match any link's configured <varname>Domains=</varname> 646 setting. If false, this link's configured DNS servers are never used for such domains, and 647 are exclusively used for resolving names that match at least one of the domains configured on 648 this link. If not specified defaults to an automatic mode: queries not matching any link's 649 configured domains will be routed to this link if it has no routing-only domains configured. 650 </para> 651 </listitem> 652 </varlistentry> 653 654 <varlistentry> 655 <term><varname>NTP=</varname></term> 656 <listitem> 657 <para>An NTP server address (either an IP address, or a hostname). This option may be 658 specified more than once. This setting is read by 659 <citerefentry><refentrytitle>systemd-timesyncd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 660 </para> 661 </listitem> 662 </varlistentry> 663 664 <varlistentry> 665 <term><varname>IPForward=</varname></term> 666 <listitem> 667 <para>Configures IP packet forwarding for the system. If enabled, incoming packets on any 668 network interface will be forwarded to any other interfaces according to the routing table. 669 Takes a boolean, or the values <literal>ipv4</literal> or <literal>ipv6</literal>, which only 670 enable IP packet forwarding for the specified address family. This controls the 671 <filename>net.ipv4.ip_forward</filename> and <filename>net.ipv6.conf.all.forwarding</filename> 672 sysctl options of the network interface (see 673 <ulink url="https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt</ulink> 674 for details about sysctl options). Defaults to <literal>no</literal>.</para> 675 676 <para>Note: this setting controls a global kernel option, and does so one way only: if a 677 network that has this setting enabled is set up the global setting is turned on. However, 678 it is never turned off again, even after all networks with this setting enabled are shut 679 down again.</para> 680 681 <para>To allow IP packet forwarding only between specific network interfaces use a firewall. 682 </para> 683 </listitem> 684 </varlistentry> 685 686 <varlistentry> 687 <term><varname>IPMasquerade=</varname></term> 688 <listitem> 689 <para>Configures IP masquerading for the network interface. If enabled, packets forwarded 690 from the network interface will be appear as coming from the local host. Takes one of 691 <literal>ipv4</literal>, <literal>ipv6</literal>, <literal>both</literal>, or 692 <literal>no</literal>. Defaults to <literal>no</literal>. If enabled, this automatically sets 693 <varname>IPForward=</varname> to one of <literal>ipv4</literal>, <literal>ipv6</literal> or 694 <literal>yes</literal>.</para> 695 <para>Note. Any positive boolean values such as <literal>yes</literal> or 696 <literal>true</literal> are now deprecated. Please use one of the values in the above.</para> 697 </listitem> 698 </varlistentry> 699 700 <varlistentry> 701 <term><varname>IPv6PrivacyExtensions=</varname></term> 702 <listitem> 703 <para>Configures use of stateless temporary addresses that change over time (see 704 <ulink url="https://tools.ietf.org/html/rfc4941">RFC 4941</ulink>, 705 Privacy Extensions for Stateless Address Autoconfiguration in IPv6). Takes a boolean or the 706 special values <literal>prefer-public</literal> and <literal>kernel</literal>. When true, 707 enables the privacy extensions and prefers temporary addresses over public addresses. When 708 <literal>prefer-public</literal>, enables the privacy extensions, but prefers public 709 addresses over temporary addresses. When false, the privacy extensions remain disabled. When 710 <literal>kernel</literal>, the kernel's default setting will be left in place. Defaults to 711 <literal>no</literal>.</para> 712 </listitem> 713 </varlistentry> 714 715 <varlistentry> 716 <term><varname>IPv6AcceptRA=</varname></term> 717 <listitem> 718 <para>Takes a boolean. Controls IPv6 Router Advertisement (RA) reception support for the 719 interface. If true, RAs are accepted; if false, RAs are ignored. When RAs are accepted, they 720 may trigger the start of the DHCPv6 client if the relevant flags are set in the RA data, or 721 if no routers are found on the link. The default is to disable RA reception for bridge 722 devices or when IP forwarding is enabled, and to enable it otherwise. Cannot be enabled on 723 bond devices and when link-local addressing is disabled.</para> 724 725 <para>Further settings for the IPv6 RA support may be configured in the [IPv6AcceptRA] 726 section, see below.</para> 727 728 <para>Also see 729 <ulink url="https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt</ulink> 730 in the kernel documentation regarding <literal>accept_ra</literal>, but note that systemd's 731 setting of <constant>1</constant> (i.e. true) corresponds to kernel's setting of 732 <constant>2</constant>.</para> 733 734 <para>Note that kernel's implementation of the IPv6 RA protocol is always disabled, 735 regardless of this setting. If this option is enabled, a userspace implementation of the IPv6 736 RA protocol is used, and the kernel's own implementation remains disabled, since 737 <command>systemd-networkd</command> needs to know all details supplied in the advertisements, 738 and these are not available from the kernel if the kernel's own implementation is used. 739 </para> 740 </listitem> 741 </varlistentry> 742 743 <varlistentry> 744 <term><varname>IPv6DuplicateAddressDetection=</varname></term> 745 <listitem> 746 <para>Configures the amount of IPv6 Duplicate Address Detection (DAD) probes to send. When 747 unset, the kernel's default will be used.</para> 748 </listitem> 749 </varlistentry> 750 751 <varlistentry> 752 <term><varname>IPv6HopLimit=</varname></term> 753 <listitem> 754 <para>Configures IPv6 Hop Limit. For each router that forwards the packet, the hop limit is 755 decremented by 1. When the hop limit field reaches zero, the packet is discarded. When unset, 756 the kernel's default will be used.</para> 757 </listitem> 758 </varlistentry> 759 760 <varlistentry> 761 <term><varname>IPv4AcceptLocal=</varname></term> 762 <listitem> 763 <para>Takes a boolean. Accept packets with local source addresses. In combination with 764 suitable routing, this can be used to direct packets between two local interfaces over the 765 wire and have them accepted properly. When unset, the kernel's default will be used.</para> 766 </listitem> 767 </varlistentry> 768 769 <varlistentry> 770 <term><varname>IPv4RouteLocalnet=</varname></term> 771 <listitem> 772 <para>Takes a boolean. When true, the kernel does not consider loopback addresses as martian 773 source or destination while routing. This enables the use of 127.0.0.0/8 for local routing 774 purposes. When unset, the kernel's default will be used.</para> 775 </listitem> 776 </varlistentry> 777 778 <varlistentry> 779 <term><varname>IPv4ProxyARP=</varname></term> 780 <listitem> 781 <para>Takes a boolean. Configures proxy ARP for IPv4. Proxy ARP is the technique in which one 782 host, usually a router, answers ARP requests intended for another machine. By "faking" its 783 identity, the router accepts responsibility for routing packets to the "real" destination. 784 See <ulink url="https://tools.ietf.org/html/rfc1027">RFC 1027</ulink>. When unset, the 785 kernel's default will be used.</para> 786 </listitem> 787 </varlistentry> 788 789 <varlistentry> 790 <term><varname>IPv6ProxyNDP=</varname></term> 791 <listitem> 792 <para>Takes a boolean. Configures proxy NDP for IPv6. Proxy NDP (Neighbor Discovery Protocol) 793 is a technique for IPv6 to allow routing of addresses to a different destination when peers 794 expect them to be present on a certain physical link. In this case a router answers Neighbour 795 Advertisement messages intended for another machine by offering its own MAC address as 796 destination. Unlike proxy ARP for IPv4, it is not enabled globally, but will only send 797 Neighbour Advertisement messages for addresses in the IPv6 neighbor proxy table, which can 798 also be shown by <command>ip -6 neighbour show proxy</command>. systemd-networkd will control 799 the per-interface `proxy_ndp` switch for each configured interface depending on this option. 800 When unset, the kernel's default will be used.</para> 801 </listitem> 802 </varlistentry> 803 804 <varlistentry> 805 <term><varname>IPv6ProxyNDPAddress=</varname></term> 806 <listitem> 807 <para>An IPv6 address, for which Neighbour Advertisement messages will be proxied. This 808 option may be specified more than once. systemd-networkd will add the 809 <varname>IPv6ProxyNDPAddress=</varname> entries to the kernel's IPv6 neighbor proxy table. 810 This setting implies <varname>IPv6ProxyNDP=yes</varname> but has no effect if 811 <varname>IPv6ProxyNDP=</varname> has been set to false. When unset, the kernel's default will 812 be used.</para> 813 </listitem> 814 </varlistentry> 815 816 <varlistentry> 817 <term><varname>IPv6SendRA=</varname></term> 818 <listitem> 819 <para>Whether to enable or disable Router Advertisement sending on a link. Takes a boolean 820 value. When enabled, prefixes configured in [IPv6Prefix] sections and routes configured in 821 the [IPv6RoutePrefix] sections are distributed as defined in the [IPv6SendRA] section. If 822 <varname>DHCPPrefixDelegation=</varname> is enabled, then the delegated prefixes are also 823 distributed. See <varname>DCHPPrefixDelegation=</varname> setting and the [IPv6SendRA], 824 [IPv6Prefix], [IPv6RoutePrefix], and [DHCPPrefixDelegation] sections for more configuration 825 options.</para> 826 </listitem> 827 </varlistentry> 828 829 <varlistentry> 830 <term><varname>DHCPPrefixDelegation=</varname></term> 831 <listitem> 832 <para>Takes a boolean value. When enabled, requests subnet prefixes on another link via the DHCPv6 833 protocol or via the 6RD option in the DHCPv4 protocol. An address within each delegated prefix will 834 be assigned, and the prefixes will be announced through IPv6 Router Advertisement if 835 <varname>IPv6SendRA=</varname> is enabled. This behaviour can be configured in the 836 [DHCPPrefixDelegation] section. Defaults to disabled.</para> 837 </listitem> 838 </varlistentry> 839 840 <varlistentry> 841 <term><varname>IPv6MTUBytes=</varname></term> 842 <listitem> 843 <para>Configures IPv6 maximum transmission unit (MTU). An integer greater than or equal to 844 1280 bytes. When unset, the kernel's default will be used.</para> 845 </listitem> 846 </varlistentry> 847 848 <varlistentry> 849 <term><varname>KeepMaster=</varname></term> 850 <listitem> 851 <para>Takes a boolean value. When enabled, the current master interface index will not be 852 changed, and <varname>BatmanAdvanced=</varname>, <varname>Bond=</varname>, 853 <varname>Bridge=</varname>, and <varname>VRF=</varname> settings are ignored. This may be 854 useful when a netdev with a master interface is created by another program, e.g. 855 <citerefentry><refentrytitle>systemd-nspawn</refentrytitle><manvolnum>1</manvolnum></citerefentry>. 856 Defaults to false.</para> 857 </listitem> 858 </varlistentry> 859 860 <varlistentry> 861 <term><varname>BatmanAdvanced=</varname></term> 862 <term><varname>Bond=</varname></term> 863 <term><varname>Bridge=</varname></term> 864 <term><varname>VRF=</varname></term> 865 <listitem> 866 <para>The name of the B.A.T.M.A.N. Advanced, bond, bridge, or VRF interface to add the link 867 to. See 868 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>. 869 </para> 870 </listitem> 871 </varlistentry> 872 873 <varlistentry> 874 <term><varname>IPoIB=</varname></term> 875 <term><varname>IPVLAN=</varname></term> 876 <term><varname>IPVTAP=</varname></term> 877 <term><varname>MACsec=</varname></term> 878 <term><varname>MACVLAN=</varname></term> 879 <term><varname>MACVTAP=</varname></term> 880 <term><varname>Tunnel=</varname></term> 881 <term><varname>VLAN=</varname></term> 882 <term><varname>VXLAN=</varname></term> 883 <term><varname>Xfrm=</varname></term> 884 <listitem> 885 <para>The name of an IPoIB, IPVLAN, IPVTAP, MACsec, MACVLAN, MACVTAP, tunnel, VLAN, 886 VXLAN, or Xfrm to be created on the link. See 887 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>. 888 This option may be specified more than once.</para> 889 </listitem> 890 </varlistentry> 891 892 <varlistentry> 893 <term><varname>ActiveSlave=</varname></term> 894 <listitem> 895 <para>Takes a boolean. Specifies the new active slave. The <literal>ActiveSlave=</literal> 896 option is only valid for following modes: <literal>active-backup</literal>, 897 <literal>balance-alb</literal>, and <literal>balance-tlb</literal>. Defaults to false.</para> 898 </listitem> 899 </varlistentry> 900 901 <varlistentry> 902 <term><varname>PrimarySlave=</varname></term> 903 <listitem> 904 <para>Takes a boolean. Specifies which slave is the primary device. The specified device will 905 always be the active slave while it is available. Only when the primary is off-line will 906 alternate devices be used. This is useful when one slave is preferred over another, e.g. 907 when one slave has higher throughput than another. The <literal>PrimarySlave=</literal> 908 option is only valid for following modes: <literal>active-backup</literal>, 909 <literal>balance-alb</literal>, and <literal>balance-tlb</literal>. Defaults to false.</para> 910 </listitem> 911 </varlistentry> 912 913 <varlistentry> 914 <term><varname>ConfigureWithoutCarrier=</varname></term> 915 <listitem> 916 <para>Takes a boolean. Allows networkd to configure a specific link even if it has no 917 carrier. Defaults to false. If enabled, and the <varname>IgnoreCarrierLoss=</varname> setting 918 is not explicitly set, then it is enabled as well.</para> 919 </listitem> 920 </varlistentry> 921 922 <varlistentry> 923 <term><varname>IgnoreCarrierLoss=</varname></term> 924 <listitem> 925 <para>Takes a boolean or a timespan. When true, <command>systemd-networkd</command> retains 926 both the static and dynamic configuration of the interface even if its carrier is lost. When 927 false, <command>systemd-networkd</command> drops both the static and dynamic configuration of 928 the interface. When a timespan is specified, <command>systemd-networkd</command> waits for 929 the specified timespan, and ignores the carrier loss if the link regain its carrier within 930 the timespan. Setting 0 seconds is equivalent to <literal>no</literal>, and 931 <literal>infinite</literal> is equivalent to <literal>yes</literal>.</para> 932 933 <para>Setting a finite timespan may be useful when e.g. in the following cases: 934 <itemizedlist> 935 <listitem> 936 <para>A wireless interface connecting to a network which has multiple access points with 937 the same SSID.</para> 938 </listitem> 939 <listitem> 940 <para>Enslaving a wireless interface to a bond interface, which may disconnect from the 941 connected access point and causes its carrier to be lost.</para> 942 </listitem> 943 <listitem> 944 <para>The driver of the interface resets when the MTU is changed.</para> 945 </listitem> 946 </itemizedlist> 947 </para> 948 949 <para>When <varname>Bond=</varname> is specified to a wireless interface, defaults to 3 950 seconds. When the DHCPv4 client is enabled and <varname>UseMTU=</varname> in the [DHCPv4] 951 section enabled, defaults to 5 seconds. Otherwise, defaults to the value specified with 952 <varname>ConfigureWithoutCarrier=</varname>. When <varname>ActivationPolicy=</varname> is set 953 to <literal>always-up</literal>, this is forced to <literal>yes</literal>, and ignored any 954 user specified values.</para> 955 </listitem> 956 </varlistentry> 957 958 <varlistentry> 959 <term><varname>KeepConfiguration=</varname></term> 960 <listitem> 961 <para>Takes a boolean or one of <literal>static</literal>, <literal>dhcp-on-stop</literal>, 962 <literal>dhcp</literal>. When <literal>static</literal>, <command>systemd-networkd</command> 963 will not drop static addresses and routes on starting up process. When set to 964 <literal>dhcp-on-stop</literal>, <command>systemd-networkd</command> will not drop addresses 965 and routes on stopping the daemon. When <literal>dhcp</literal>, 966 the addresses and routes provided by a DHCP server will never be dropped even if the DHCP 967 lease expires. This is contrary to the DHCP specification, but may be the best choice if, 968 e.g., the root filesystem relies on this connection. The setting <literal>dhcp</literal> 969 implies <literal>dhcp-on-stop</literal>, and <literal>yes</literal> implies 970 <literal>dhcp</literal> and <literal>static</literal>. Defaults to 971 <literal>dhcp-on-stop</literal> when <command>systemd-networkd</command> is running in 972 initrd, <literal>yes</literal> when the root filesystem is a network filesystem, and 973 <literal>no</literal> otherwise.</para> 974 </listitem> 975 </varlistentry> 976 </variablelist> 977 </refsect1> 978 979 <refsect1> 980 <title>[Address] Section Options</title> 981 982 <para>An [Address] section accepts the following keys. Specify several [Address] sections to 983 configure several addresses.</para> 984 985 <variablelist class='network-directives'> 986 <varlistentry> 987 <term><varname>Address=</varname></term> 988 <listitem> 989 <para>As in the [Network] section. This setting is mandatory. Each [Address] section can 990 contain one <varname>Address=</varname> setting.</para> 991 </listitem> 992 </varlistentry> 993 994 <varlistentry> 995 <term><varname>Peer=</varname></term> 996 <listitem> 997 <para>The peer address in a point-to-point connection. Accepts the same format as the 998 <varname>Address=</varname> setting.</para> 999 </listitem> 1000 </varlistentry> 1001 1002 <varlistentry> 1003 <term><varname>Broadcast=</varname></term> 1004 <listitem> 1005 <para>Takes an IPv4 address or boolean value. The address must be in the format described in 1006 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 1007 If set to true, then the IPv4 broadcast address will be derived from the 1008 <varname>Address=</varname> setting. If set to false, then the broadcast address will not be 1009 set. Defaults to true, except for wireguard interfaces, where it default to false.</para> 1010 </listitem> 1011 </varlistentry> 1012 1013 <varlistentry> 1014 <term><varname>Label=</varname></term> 1015 <listitem> 1016 <para>Specifies the label for the IPv4 address. The label must be a 7-bit ASCII string with 1017 a length of 1…15 characters. Defaults to unset.</para> 1018 </listitem> 1019 </varlistentry> 1020 1021 <varlistentry> 1022 <term><varname>PreferredLifetime=</varname></term> 1023 <listitem> 1024 <para>Allows the default "preferred lifetime" of the address to be overridden. Only three 1025 settings are accepted: <literal>forever</literal>, <literal>infinity</literal>, which is the 1026 default and means that the address never expires, and <literal>0</literal>, which means that 1027 the address is considered immediately "expired" and will not be used, unless explicitly 1028 requested. A setting of <option>PreferredLifetime=0</option> is useful for addresses which 1029 are added to be used only by a specific application, which is then configured to use them 1030 explicitly.</para> 1031 </listitem> 1032 </varlistentry> 1033 1034 <varlistentry> 1035 <term><varname>Scope=</varname></term> 1036 <listitem> 1037 <para>The scope of the address, which can be <literal>global</literal> (valid everywhere on 1038 the network, even through a gateway), <literal>link</literal> (only valid on this device, 1039 will not traverse a gateway) or <literal>host</literal> (only valid within the device itself, 1040 e.g. 127.0.0.1) or an integer in the range 0…255. Defaults to <literal>global</literal>. 1041 </para> 1042 </listitem> 1043 </varlistentry> 1044 1045 <varlistentry> 1046 <term><varname>RouteMetric=</varname></term> 1047 <listitem> 1048 <para>The metric of the prefix route, which is pointing to the subnet of the configured IP 1049 address, taking the configured prefix length into account. Takes an unsigned integer in the 1050 range 0…4294967295. When unset or set to 0, the kernel's default value is used. This 1051 setting will be ignored when <varname>AddPrefixRoute=</varname> is false.</para> 1052 </listitem> 1053 </varlistentry> 1054 1055 <varlistentry> 1056 <term><varname>HomeAddress=</varname></term> 1057 <listitem> 1058 <para>Takes a boolean. Designates this address the "home address" as defined in 1059 <ulink url="https://tools.ietf.org/html/rfc6275">RFC 6275</ulink>. Supported only on IPv6. 1060 Defaults to false.</para> 1061 </listitem> 1062 </varlistentry> 1063 1064 <varlistentry> 1065 <term><varname>DuplicateAddressDetection=</varname></term> 1066 <listitem> 1067 <para>Takes one of <literal>ipv4</literal>, <literal>ipv6</literal>, <literal>both</literal>, 1068 or <literal>none</literal>. When <literal>ipv4</literal>, performs IPv4 Address Conflict 1069 Detection. See <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5227</ulink>. 1070 When <literal>ipv6</literal>, performs IPv6 Duplicate Address Detection. See 1071 <ulink url="https://tools.ietf.org/html/rfc4862">RFC 4862</ulink>. Defaults to 1072 <literal>ipv4</literal> for IPv4 link-local addresses, <literal>ipv6</literal> for IPv6 1073 addresses, and <literal>none</literal> otherwise.</para> 1074 </listitem> 1075 </varlistentry> 1076 1077 <varlistentry> 1078 <term><varname>ManageTemporaryAddress=</varname></term> 1079 <listitem> 1080 <para>Takes a boolean. If true the kernel manage temporary addresses created from this one as 1081 template on behalf of Privacy Extensions 1082 <ulink url="https://tools.ietf.org/html/rfc3041">RFC 3041</ulink>. For this to become active, 1083 the use_tempaddr sysctl setting has to be set to a value greater than zero. The given address 1084 needs to have a prefix length of 64. This flag allows using privacy extensions in a manually 1085 configured network, just like if stateless auto-configuration was active. Defaults to false. 1086 </para> 1087 </listitem> 1088 </varlistentry> 1089 1090 <varlistentry> 1091 <term><varname>AddPrefixRoute=</varname></term> 1092 <listitem> 1093 <para>Takes a boolean. When true, the prefix route for the address is automatically added. 1094 Defaults to true.</para> 1095 </listitem> 1096 </varlistentry> 1097 1098 <varlistentry> 1099 <term><varname>AutoJoin=</varname></term> 1100 <listitem> 1101 <para>Takes a boolean. Joining multicast group on ethernet level via 1102 <command>ip maddr</command> command would not work if we have an Ethernet switch that does 1103 IGMP snooping since the switch would not replicate multicast packets on ports that did not 1104 have IGMP reports for the multicast addresses. Linux vxlan interfaces created via 1105 <command>ip link add vxlan</command> or networkd's netdev kind vxlan have the group option 1106 that enables then to do the required join. By extending ip address command with option 1107 <literal>autojoin</literal> we can get similar functionality for openvswitch (OVS) vxlan 1108 interfaces as well as other tunneling mechanisms that need to receive multicast traffic. 1109 Defaults to <literal>no</literal>.</para> 1110 </listitem> 1111 </varlistentry> 1112 </variablelist> 1113 </refsect1> 1114 1115 <refsect1> 1116 <title>[Neighbor] Section Options</title> 1117 1118 <para>A [Neighbor] section accepts the following keys. The neighbor section adds a permanent, 1119 static entry to the neighbor table (IPv6) or ARP table (IPv4) for the given hardware address on the 1120 links matched for the network. Specify several [Neighbor] sections to configure several static 1121 neighbors.</para> 1122 1123 <variablelist class='network-directives'> 1124 <varlistentry> 1125 <term><varname>Address=</varname></term> 1126 <listitem> 1127 <para>The IP address of the neighbor.</para> 1128 </listitem> 1129 </varlistentry> 1130 1131 <varlistentry> 1132 <term><varname>LinkLayerAddress=</varname></term> 1133 <listitem> 1134 <para>The link layer address (MAC address or IP address) of the neighbor.</para> 1135 </listitem> 1136 </varlistentry> 1137 </variablelist> 1138 </refsect1> 1139 1140 <refsect1> 1141 <title>[IPv6AddressLabel] Section Options</title> 1142 1143 <para>An [IPv6AddressLabel] section accepts the following keys. Specify several [IPv6AddressLabel] 1144 sections to configure several address labels. IPv6 address labels are used for address selection. 1145 See <ulink url="https://tools.ietf.org/html/rfc3484">RFC 3484</ulink>. Precedence is managed by 1146 userspace, and only the label itself is stored in the kernel.</para> 1147 1148 <variablelist class='network-directives'> 1149 <varlistentry> 1150 <term><varname>Label=</varname></term> 1151 <listitem> 1152 <para>The label for the prefix, an unsigned integer in the range 0…4294967294. 0xffffffff is 1153 reserved. This setting is mandatory.</para> 1154 </listitem> 1155 </varlistentry> 1156 1157 <varlistentry> 1158 <term><varname>Prefix=</varname></term> 1159 <listitem> 1160 <para>IPv6 prefix is an address with a prefix length, separated by a slash 1161 <literal>/</literal> character. This setting is mandatory. </para> 1162 </listitem> 1163 </varlistentry> 1164 </variablelist> 1165 </refsect1> 1166 1167 <refsect1> 1168 <title>[RoutingPolicyRule] Section Options</title> 1169 1170 <para>An [RoutingPolicyRule] section accepts the following settings. Specify several 1171 [RoutingPolicyRule] sections to configure several rules.</para> 1172 1173 <variablelist class='network-directives'> 1174 <varlistentry> 1175 <term><varname>TypeOfService=</varname></term> 1176 <listitem> 1177 <para>Takes a number between 0 and 255 that specifies the type of service to match.</para> 1178 </listitem> 1179 </varlistentry> 1180 1181 <varlistentry> 1182 <term><varname>From=</varname></term> 1183 <listitem> 1184 <para>Specifies the source address prefix to match. Possibly followed by a slash and the 1185 prefix length.</para> 1186 </listitem> 1187 </varlistentry> 1188 1189 <varlistentry> 1190 <term><varname>To=</varname></term> 1191 <listitem> 1192 <para>Specifies the destination address prefix to match. Possibly followed by a slash and the 1193 prefix length.</para> 1194 </listitem> 1195 </varlistentry> 1196 1197 <varlistentry> 1198 <term><varname>FirewallMark=</varname></term> 1199 <listitem> 1200 <para>Specifies the iptables firewall mark value to match (a number in the range 1201 1…4294967295). Optionally, the firewall mask (also a number between 1…4294967295) can be 1202 suffixed with a slash (<literal>/</literal>), e.g., <literal>7/255</literal>.</para> 1203 </listitem> 1204 </varlistentry> 1205 1206 <varlistentry> 1207 <term><varname>Table=</varname></term> 1208 <listitem> 1209 <para>Specifies the routing table identifier to lookup if the rule selector matches. Takes 1210 one of predefined names <literal>default</literal>, <literal>main</literal>, and 1211 <literal>local</literal>, and names defined in <varname>RouteTable=</varname> in 1212 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, 1213 or a number between 1 and 4294967295. Defaults to <literal>main</literal>.</para> 1214 </listitem> 1215 </varlistentry> 1216 1217 <varlistentry> 1218 <term><varname>Priority=</varname></term> 1219 <listitem> 1220 <para>Specifies the priority of this rule. <varname>Priority=</varname> is an integer in the 1221 range 0…4294967295. Higher number means lower priority, and rules get processed in order of 1222 increasing number. Defaults to unset, and the kernel will pick a value dynamically.</para> 1223 </listitem> 1224 </varlistentry> 1225 1226 <varlistentry> 1227 <term><varname>IncomingInterface=</varname></term> 1228 <listitem> 1229 <para>Specifies incoming device to match. If the interface is loopback, the rule only matches 1230 packets originating from this host.</para> 1231 </listitem> 1232 </varlistentry> 1233 1234 <varlistentry> 1235 <term><varname>OutgoingInterface=</varname></term> 1236 <listitem> 1237 <para>Specifies the outgoing device to match. The outgoing interface is only available for 1238 packets originating from local sockets that are bound to a device.</para> 1239 </listitem> 1240 </varlistentry> 1241 1242 <varlistentry> 1243 <term><varname>SourcePort=</varname></term> 1244 <listitem> 1245 <para>Specifies the source IP port or IP port range match in forwarding information base 1246 (FIB) rules. A port range is specified by the lower and upper port separated by a dash. 1247 Defaults to unset.</para> 1248 </listitem> 1249 </varlistentry> 1250 1251 <varlistentry> 1252 <term><varname>DestinationPort=</varname></term> 1253 <listitem> 1254 <para>Specifies the destination IP port or IP port range match in forwarding information base 1255 (FIB) rules. A port range is specified by the lower and upper port separated by a dash. 1256 Defaults to unset.</para> 1257 </listitem> 1258 </varlistentry> 1259 1260 <varlistentry> 1261 <term><varname>IPProtocol=</varname></term> 1262 <listitem> 1263 <para>Specifies the IP protocol to match in forwarding information base (FIB) rules. Takes IP 1264 protocol name such as <literal>tcp</literal>, <literal>udp</literal> or 1265 <literal>sctp</literal>, or IP protocol number such as <literal>6</literal> for 1266 <literal>tcp</literal> or <literal>17</literal> for <literal>udp</literal>. Defaults to unset. 1267 </para> 1268 </listitem> 1269 </varlistentry> 1270 1271 <varlistentry> 1272 <term><varname>InvertRule=</varname></term> 1273 <listitem> 1274 <para>A boolean. Specifies whether the rule is to be inverted. Defaults to false.</para> 1275 </listitem> 1276 </varlistentry> 1277 1278 <varlistentry> 1279 <term><varname>Family=</varname></term> 1280 <listitem> 1281 <para>Takes a special value <literal>ipv4</literal>, <literal>ipv6</literal>, or 1282 <literal>both</literal>. By default, the address family is determined by the address 1283 specified in <varname>To=</varname> or <varname>From=</varname>. If neither 1284 <varname>To=</varname> nor <varname>From=</varname> are specified, then defaults to 1285 <literal>ipv4</literal>.</para> 1286 </listitem> 1287 </varlistentry> 1288 1289 <varlistentry> 1290 <term><varname>User=</varname></term> 1291 <listitem> 1292 <para>Takes a username, a user ID, or a range of user IDs separated by a dash. Defaults to 1293 unset.</para> 1294 </listitem> 1295 </varlistentry> 1296 1297 <varlistentry> 1298 <term><varname>SuppressPrefixLength=</varname></term> 1299 <listitem> 1300 <para>Takes a number <replaceable>N</replaceable> in the range 0…128 and rejects routing 1301 decisions that have a prefix length of <replaceable>N</replaceable> or less. Defaults to 1302 unset.</para> 1303 </listitem> 1304 </varlistentry> 1305 1306 <varlistentry> 1307 <term><varname>SuppressInterfaceGroup=</varname></term> 1308 <listitem> 1309 <para>Takes an integer in the range 0…2147483647 and rejects routing decisions that have 1310 an interface with the same group id. It has the same meaning as 1311 <option>suppress_ifgroup</option> in <command>ip rule</command>. Defaults to unset.</para> 1312 </listitem> 1313 </varlistentry> 1314 1315 <varlistentry> 1316 <term><varname>Type=</varname></term> 1317 <listitem> 1318 <para>Specifies Routing Policy Database (RPDB) rule type. Takes one of 1319 <literal>blackhole</literal>, <literal>unreachable</literal> or <literal>prohibit</literal>. 1320 </para> 1321 </listitem> 1322 </varlistentry> 1323 </variablelist> 1324 </refsect1> 1325 1326 <refsect1> 1327 <title>[NextHop] Section Options</title> 1328 1329 <para>The [NextHop] section is used to manipulate entries in the kernel's "nexthop" tables. The 1330 [NextHop] section accepts the following settings. Specify several [NextHop] sections to configure 1331 several hops.</para> 1332 1333 <variablelist class='network-directives'> 1334 <varlistentry> 1335 <term><varname>Id=</varname></term> 1336 <listitem> 1337 <para>The id of the next hop. Takes an integer in the range 1…4294967295. If unspecified, 1338 then automatically chosen by kernel.</para> 1339 </listitem> 1340 </varlistentry> 1341 1342 <varlistentry> 1343 <term><varname>Gateway=</varname></term> 1344 <listitem> 1345 <para>As in the [Network] section.</para> 1346 </listitem> 1347 </varlistentry> 1348 1349 <varlistentry> 1350 <term><varname>Family=</varname></term> 1351 <listitem> 1352 <para>Takes one of the special values <literal>ipv4</literal> or <literal>ipv6</literal>. 1353 By default, the family is determined by the address specified in 1354 <varname>Gateway=</varname>. If <varname>Gateway=</varname> is not specified, then defaults 1355 to <literal>ipv4</literal>.</para> 1356 </listitem> 1357 </varlistentry> 1358 1359 <varlistentry> 1360 <term><varname>OnLink=</varname></term> 1361 <listitem> 1362 <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is 1363 reachable directly by the current machine (i.e., attached to the local network), so that we 1364 can insert the nexthop in the kernel table without it being complained about. Defaults to 1365 <literal>no</literal>.</para> 1366 </listitem> 1367 </varlistentry> 1368 1369 <varlistentry> 1370 <term><varname>Blackhole=</varname></term> 1371 <listitem> 1372 <para>Takes a boolean. If enabled, packets to the corresponding routes are discarded 1373 silently, and <varname>Gateway=</varname> cannot be specified. Defaults to 1374 <literal>no</literal>.</para> 1375 </listitem> 1376 </varlistentry> 1377 1378 <varlistentry> 1379 <term><varname>Group=</varname></term> 1380 <listitem> 1381 <para>Takes a whitespace separated list of nexthop IDs. Each ID must be in the range 1382 1…4294967295. Optionally, each nexthop ID can take a weight after a colon 1383 (<literal><replaceable>id</replaceable><optional>:<replaceable>weight</replaceable></optional></literal>). 1384 The weight must be in the range 1…255. If the weight is not specified, then it is assumed 1385 that the weight is 1. This setting cannot be specified with <varname>Gateway=</varname>, 1386 <varname>Family=</varname>, <varname>Blackhole=</varname>. This setting can be specified 1387 multiple times. If an empty string is assigned, then the all previous assignments are 1388 cleared. Defaults to unset.</para> 1389 </listitem> 1390 </varlistentry> 1391 </variablelist> 1392 </refsect1> 1393 1394 <refsect1> 1395 <title>[Route] Section Options</title> 1396 1397 <para>The [Route] section accepts the following settings. Specify several [Route] sections to 1398 configure several routes.</para> 1399 1400 <variablelist class='network-directives'> 1401 <varlistentry> 1402 <term><varname>Gateway=</varname></term> 1403 <listitem> 1404 <para>Takes the gateway address or the special values <literal>_dhcp4</literal> and 1405 <literal>_ipv6ra</literal>. If <literal>_dhcp4</literal> or <literal>_ipv6ra</literal> is 1406 set, then the gateway address provided by DHCPv4 or IPv6 RA is used.</para> 1407 </listitem> 1408 </varlistentry> 1409 1410 <varlistentry> 1411 <term><varname>GatewayOnLink=</varname></term> 1412 <listitem> 1413 <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is 1414 reachable directly by the current machine (i.e., attached to the local network), so that we 1415 can insert the route in the kernel table without it being complained about. Defaults to 1416 <literal>no</literal>.</para> 1417 </listitem> 1418 </varlistentry> 1419 1420 <varlistentry> 1421 <term><varname>Destination=</varname></term> 1422 <listitem> 1423 <para>The destination prefix of the route. Possibly followed by a slash and the prefix 1424 length. If omitted, a full-length host route is assumed.</para> 1425 </listitem> 1426 </varlistentry> 1427 1428 <varlistentry> 1429 <term><varname>Source=</varname></term> 1430 <listitem> 1431 <para>The source prefix of the route. Possibly followed by a slash and the prefix length. If 1432 omitted, a full-length host route is assumed.</para> 1433 </listitem> 1434 </varlistentry> 1435 1436 <varlistentry> 1437 <term><varname>Metric=</varname></term> 1438 <listitem> 1439 <para>The metric of the route. Takes an unsigned integer in the range 0…4294967295. Defaults 1440 to unset, and the kernel's default will be used.</para> 1441 </listitem> 1442 </varlistentry> 1443 1444 <varlistentry> 1445 <term><varname>IPv6Preference=</varname></term> 1446 <listitem> 1447 <para>Specifies the route preference as defined in 1448 <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> for Router Discovery 1449 messages. Which can be one of <literal>low</literal> the route has a lowest priority, 1450 <literal>medium</literal> the route has a default priority or <literal>high</literal> the 1451 route has a highest priority.</para> 1452 </listitem> 1453 </varlistentry> 1454 1455 <varlistentry> 1456 <term><varname>Scope=</varname></term> 1457 <listitem> 1458 <para>The scope of the IPv4 route, which can be <literal>global</literal>, 1459 <literal>site</literal>, <literal>link</literal>, <literal>host</literal>, or 1460 <literal>nowhere</literal>:</para> 1461 <itemizedlist> 1462 <listitem> 1463 <para><literal>global</literal> means the route can reach hosts more than one hop away. 1464 </para> 1465 </listitem> 1466 1467 <listitem> 1468 <para><literal>site</literal> means an interior route in the local autonomous system. 1469 </para> 1470 </listitem> 1471 1472 <listitem> 1473 <para><literal>link</literal> means the route can only reach hosts on the local network 1474 (one hop away).</para> 1475 </listitem> 1476 1477 <listitem> 1478 <para><literal>host</literal> means the route will not leave the local machine (used for 1479 internal addresses like 127.0.0.1).</para> 1480 </listitem> 1481 1482 <listitem> 1483 <para><literal>nowhere</literal> means the destination doesn't exist.</para> 1484 </listitem> 1485 </itemizedlist> 1486 1487 <para>For IPv4 route, defaults to <literal>host</literal> if <varname>Type=</varname> is 1488 <literal>local</literal> or <literal>nat</literal>, and <literal>link</literal> if 1489 <varname>Type=</varname> is <literal>broadcast</literal>, <literal>multicast</literal>, 1490 <literal>anycast</literal>, or direct <literal>unicast</literal> routes. In other cases, 1491 defaults to <literal>global</literal>. The value is not used for IPv6.</para> 1492 </listitem> 1493 </varlistentry> 1494 1495 <varlistentry> 1496 <term><varname>PreferredSource=</varname></term> 1497 <listitem> 1498 <para>The preferred source address of the route. The address must be in the format described 1499 in 1500 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 1501 </para> 1502 </listitem> 1503 </varlistentry> 1504 1505 <varlistentry> 1506 <term><varname>Table=</varname></term> 1507 <listitem> 1508 <para>The table identifier for the route. Takes one of predefined names 1509 <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, and names 1510 defined in <varname>RouteTable=</varname> in 1511 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, 1512 or a number between 1 and 4294967295. The table can be retrieved using 1513 <command>ip route show table <replaceable>num</replaceable></command>. If unset and 1514 <varname>Type=</varname> is <literal>local</literal>, <literal>broadcast</literal>, 1515 <literal>anycast</literal>, or <literal>nat</literal>, then <literal>local</literal> is used. 1516 In other cases, defaults to <literal>main</literal>.</para> 1517 </listitem> 1518 </varlistentry> 1519 1520 <varlistentry> 1521 <term><varname>Protocol=</varname></term> 1522 <listitem> 1523 <para>The protocol identifier for the route. Takes a number between 0 and 255 or the special 1524 values <literal>kernel</literal>, <literal>boot</literal>, <literal>static</literal>, 1525 <literal>ra</literal> and <literal>dhcp</literal>. Defaults to <literal>static</literal>. 1526 </para> 1527 </listitem> 1528 </varlistentry> 1529 1530 <varlistentry> 1531 <term><varname>Type=</varname></term> 1532 <listitem> 1533 <para>Specifies the type for the route. Takes one of <literal>unicast</literal>, 1534 <literal>local</literal>, <literal>broadcast</literal>, <literal>anycast</literal>, 1535 <literal>multicast</literal>, <literal>blackhole</literal>, <literal>unreachable</literal>, 1536 <literal>prohibit</literal>, <literal>throw</literal>, <literal>nat</literal>, and 1537 <literal>xresolve</literal>. If <literal>unicast</literal>, a regular route is defined, i.e. 1538 a route indicating the path to take to a destination network address. If 1539 <literal>blackhole</literal>, packets to the defined route are discarded silently. If 1540 <literal>unreachable</literal>, packets to the defined route are discarded and the ICMP 1541 message "Host Unreachable" is generated. If <literal>prohibit</literal>, packets to the 1542 defined route are discarded and the ICMP message "Communication Administratively Prohibited" 1543 is generated. If <literal>throw</literal>, route lookup in the current routing table will 1544 fail and the route selection process will return to Routing Policy Database (RPDB). Defaults 1545 to <literal>unicast</literal>.</para> 1546 </listitem> 1547 </varlistentry> 1548 1549 <varlistentry> 1550 <term><varname>InitialCongestionWindow=</varname></term> 1551 <listitem> 1552 <para>The TCP initial congestion window is used during the start of a TCP connection. 1553 During the start of a TCP session, when a client requests a resource, the server's initial 1554 congestion window determines how many packets will be sent during the initial burst of data 1555 without waiting for acknowledgement. Takes a number between 1 and 1023. Note that 100 is 1556 considered an extremely large value for this option. When unset, the kernel's default 1557 (typically 10) will be used.</para> 1558 </listitem> 1559 </varlistentry> 1560 1561 <varlistentry> 1562 <term><varname>InitialAdvertisedReceiveWindow=</varname></term> 1563 <listitem> 1564 <para>The TCP initial advertised receive window is the amount of receive data (in bytes) 1565 that can initially be buffered at one time on a connection. The sending host can send only 1566 that amount of data before waiting for an acknowledgment and window update from the 1567 receiving host. Takes a number between 1 and 1023. Note that 100 is considered an extremely 1568 large value for this option. When unset, the kernel's default will be used.</para> 1569 </listitem> 1570 </varlistentry> 1571 1572 <varlistentry> 1573 <term><varname>QuickAck=</varname></term> 1574 <listitem> 1575 <para>Takes a boolean. When true enables TCP quick ack mode for the route. When unset, the 1576 kernel's default will be used.</para> 1577 </listitem> 1578 </varlistentry> 1579 1580 <varlistentry> 1581 <term><varname>FastOpenNoCookie=</varname></term> 1582 <listitem> 1583 <para>Takes a boolean. When true enables TCP fastopen without a cookie on a per-route basis. 1584 When unset, the kernel's default will be used.</para> 1585 </listitem> 1586 </varlistentry> 1587 1588 <varlistentry> 1589 <term><varname>TTLPropagate=</varname></term> 1590 <listitem> 1591 <para>Takes a boolean. When true enables TTL propagation at Label Switched Path (LSP) egress. 1592 When unset, the kernel's default will be used.</para> 1593 </listitem> 1594 </varlistentry> 1595 1596 <varlistentry> 1597 <term><varname>MTUBytes=</varname></term> 1598 <listitem> 1599 <para>The maximum transmission unit in bytes to set for the route. The usual suffixes K, M, 1600 G, are supported and are understood to the base of 1024.</para> 1601 </listitem> 1602 </varlistentry> 1603 1604 <varlistentry> 1605 <term><varname>TCPAdvertisedMaximumSegmentSize=</varname></term> 1606 <listitem> 1607 <para>Specifies the Path MSS (in bytes) hints given on TCP layer. The usual suffixes K, M, G, 1608 are supported and are understood to the base of 1024. An unsigned integer in the range 1609 1…4294967294. When unset, the kernel's default will be used.</para> 1610 </listitem> 1611 </varlistentry> 1612 1613 <varlistentry> 1614 <term><varname>MultiPathRoute=<replaceable>address</replaceable>[@<replaceable>name</replaceable>] [<replaceable>weight</replaceable>]</varname></term> 1615 <listitem> 1616 <para>Configures multipath route. Multipath routing is the technique of using multiple 1617 alternative paths through a network. Takes gateway address. Optionally, takes a network 1618 interface name or index separated with <literal>@</literal>, and a weight in 1..256 for this 1619 multipath route separated with whitespace. This setting can be specified multiple times. If 1620 an empty string is assigned, then the all previous assignments are cleared.</para> 1621 </listitem> 1622 </varlistentry> 1623 1624 <varlistentry> 1625 <term><varname>NextHop=</varname></term> 1626 <listitem> 1627 <para>Specifies the nexthop id. Takes an unsigned integer in the range 1…4294967295. If set, 1628 the corresponding [NextHop] section must be configured. Defaults to unset.</para> 1629 </listitem> 1630 </varlistentry> 1631 </variablelist> 1632 </refsect1> 1633 1634 <refsect1> 1635 <title>[DHCPv4] Section Options</title> 1636 1637 <para>The [DHCPv4] section configures the DHCPv4 client, if it is enabled with the 1638 <varname>DHCP=</varname> setting described above:</para> 1639 1640 <variablelist class='network-directives'> 1641 1642 <!-- DHCP packet contents --> 1643 1644 <varlistentry> 1645 <term><varname>SendHostname=</varname></term> 1646 <listitem> 1647 <para>When true (the default), the machine's hostname (or the value specified with 1648 <varname>Hostname=</varname>, described below) will be sent to the DHCP server. Note that the 1649 hostname must consist only of 7-bit ASCII lower-case characters and no spaces or dots, and be 1650 formatted as a valid DNS domain name. Otherwise, the hostname is not sent even if this option 1651 is true.</para> 1652 </listitem> 1653 </varlistentry> 1654 1655 <varlistentry> 1656 <term><varname>Hostname=</varname></term> 1657 <listitem> 1658 <para>Use this value for the hostname which is sent to the DHCP server, instead of machine's 1659 hostname. Note that the specified hostname must consist only of 7-bit ASCII lower-case 1660 characters and no spaces or dots, and be formatted as a valid DNS domain name.</para> 1661 </listitem> 1662 </varlistentry> 1663 1664 <varlistentry> 1665 <term><varname>MUDURL=</varname></term> 1666 <listitem> 1667 <para>When configured, the specified Manufacturer Usage Description (MUD) URL will be sent 1668 to the DHCPv4 server. Takes a URL of length up to 255 characters. A superficial verification 1669 that the string is a valid URL will be performed. DHCPv4 clients are intended to have at most 1670 one MUD URL associated with them. See 1671 <ulink url="https://tools.ietf.org/html/rfc8520">RFC 8520</ulink>.</para> 1672 1673 <para>MUD is an embedded software standard defined by the IETF that allows IoT device makers 1674 to advertise device specifications, including the intended communication patterns for their 1675 device when it connects to the network. The network can then use this to author a 1676 context-specific access policy, so the device functions only within those parameters.</para> 1677 </listitem> 1678 </varlistentry> 1679 1680 <varlistentry> 1681 <term><varname>ClientIdentifier=</varname></term> 1682 <listitem> 1683 <para>The DHCPv4 client identifier to use. Takes one of <option>mac</option>, 1684 <option>duid</option> or <option>duid-only</option>. If set to <option>mac</option>, the 1685 MAC address of the link is used. If set to <option>duid</option>, an RFC4361-compliant Client 1686 ID, which is the combination of IAID and DUID (see below), is used. If set to 1687 <option>duid-only</option>, only DUID is used, this may not be RFC compliant, but some setups 1688 may require to use this. Defaults to <option>duid</option>.</para> 1689 </listitem> 1690 </varlistentry> 1691 1692 <varlistentry> 1693 <term><varname>VendorClassIdentifier=</varname></term> 1694 <listitem> 1695 <para>The vendor class identifier used to identify vendor type and configuration.</para> 1696 </listitem> 1697 </varlistentry> 1698 1699 <varlistentry> 1700 <term><varname>UserClass=</varname></term> 1701 <listitem> 1702 <para>A DHCPv4 client can use UserClass option to identify the type or category of user or 1703 applications it represents. The information contained in this option is a string that 1704 represents the user class of which the client is a member. Each class sets an identifying 1705 string of information to be used by the DHCP service to classify clients. Takes a 1706 whitespace-separated list of strings.</para> 1707 </listitem> 1708 </varlistentry> 1709 1710 <varlistentry> 1711 <term><varname>DUIDType=</varname></term> 1712 <listitem> 1713 <para>Override the global <varname>DUIDType=</varname> setting for this network. See 1714 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> 1715 for a description of possible values.</para> 1716 </listitem> 1717 </varlistentry> 1718 1719 <varlistentry> 1720 <term><varname>DUIDRawData=</varname></term> 1721 <listitem> 1722 <para>Override the global <varname>DUIDRawData=</varname> setting for this network. See 1723 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> 1724 for a description of possible values.</para> 1725 </listitem> 1726 </varlistentry> 1727 1728 <varlistentry> 1729 <term><varname>IAID=</varname></term> 1730 <listitem> 1731 <para>The DHCP Identity Association Identifier (IAID) for the interface, a 32-bit unsigned 1732 integer.</para> 1733 </listitem> 1734 </varlistentry> 1735 1736 <varlistentry> 1737 <term><varname>Anonymize=</varname></term> 1738 <listitem> 1739 <para>Takes a boolean. When true, the options sent to the DHCP server will follow the 1740 <ulink url="https://tools.ietf.org/html/rfc7844">RFC 7844</ulink> (Anonymity Profiles for 1741 DHCP Clients) to minimize disclosure of identifying information. Defaults to false.</para> 1742 1743 <para>This option should only be set to true when <varname>MACAddressPolicy=</varname> is set 1744 to <option>random</option> (see 1745 <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>). 1746 </para> 1747 1748 <para>When true, <varname>SendHostname=</varname>, <varname>ClientIdentifier=</varname>, 1749 <varname>VendorClassIdentifier=</varname>, <varname>UserClass=</varname>, 1750 <varname>RequestOptions=</varname>, <varname>SendOption=</varname>, 1751 <varname>SendVendorOption=</varname>, and <varname>MUDURL=</varname> are ignored.</para> 1752 1753 <para>With this option enabled DHCP requests will mimic those generated by Microsoft 1754 Windows, in order to reduce the ability to fingerprint and recognize installations. This 1755 means DHCP request sizes will grow and lease data will be more comprehensive than normally, 1756 though most of the requested data is not actually used.</para> 1757 </listitem> 1758 </varlistentry> 1759 1760 <varlistentry> 1761 <term><varname>RequestOptions=</varname></term> 1762 <listitem> 1763 <para>Sets request options to be sent to the server in the DHCPv4 request options list. A 1764 whitespace-separated list of integers in the range 1…254. Defaults to unset.</para> 1765 </listitem> 1766 </varlistentry> 1767 1768 <varlistentry> 1769 <term><varname>SendOption=</varname></term> 1770 <listitem> 1771 <para>Send an arbitrary raw option in the DHCPv4 request. Takes a DHCP option number, data 1772 type and data separated with a colon 1773 (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). 1774 The option number must be an integer in the range 1…254. The type takes one of 1775 <literal>uint8</literal>, <literal>uint16</literal>, <literal>uint32</literal>, 1776 <literal>ipv4address</literal>, or <literal>string</literal>. Special characters in the data 1777 string may be escaped using 1778 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 1779 escapes</ulink>. This setting can be specified multiple times. If an empty string is 1780 specified, then all options specified earlier are cleared. Defaults to unset.</para> 1781 </listitem> 1782 </varlistentry> 1783 1784 <varlistentry> 1785 <term><varname>SendVendorOption=</varname></term> 1786 <listitem> 1787 <para>Send an arbitrary vendor option in the DHCPv4 request. Takes a DHCP option number, data 1788 type and data separated with a colon 1789 (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). 1790 The option number must be an integer in the range 1…254. The type takes one of 1791 <literal>uint8</literal>, <literal>uint16</literal>, <literal>uint32</literal>, 1792 <literal>ipv4address</literal>, or <literal>string</literal>. Special characters in the data 1793 string may be escaped using 1794 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 1795 escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, 1796 then all options specified earlier are cleared. Defaults to unset.</para> 1797 </listitem> 1798 </varlistentry> 1799 1800 <varlistentry> 1801 <term><varname>IPServiceType=</varname></term> 1802 <listitem> 1803 <para>Takes one of the special values <literal>none</literal>, <literal>CS6</literal>, or 1804 <literal>CS4</literal>. When <literal>none</literal> no IP service type is set to the packet 1805 sent from the DHCPv4 client. When <literal>CS6</literal> (network control) or 1806 <literal>CS4</literal> (realtime), the corresponding service type will be set. Defaults to 1807 <literal>CS6</literal>.</para> 1808 </listitem> 1809 </varlistentry> 1810 1811 <!-- How to use the DHCP lease --> 1812 1813 <varlistentry> 1814 <term><varname>Label=</varname></term> 1815 <listitem> 1816 <para>Specifies the label for the IPv4 address received from the DHCP server. The label must 1817 be a 7-bit ASCII string with a length of 1…15 characters. Defaults to unset.</para> 1818 </listitem> 1819 </varlistentry> 1820 1821 <varlistentry> 1822 <term><varname>UseDNS=</varname></term> 1823 <listitem> 1824 <para>When true (the default), the DNS servers received from the DHCP server will be used. 1825 </para> 1826 1827 <para>This corresponds to the <option>nameserver</option> option in 1828 <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. 1829 </para> 1830 </listitem> 1831 </varlistentry> 1832 1833 <varlistentry> 1834 <term><varname>RoutesToDNS=</varname></term> 1835 <listitem> 1836 <para>When true, the routes to the DNS servers received from the DHCP server will be 1837 configured. When <varname>UseDNS=</varname> is disabled, this setting is ignored. Defaults to 1838 true.</para> 1839 </listitem> 1840 </varlistentry> 1841 1842 <varlistentry> 1843 <term><varname>UseNTP=</varname></term> 1844 <listitem> 1845 <para>When true (the default), the NTP servers received from the DHCP server will be used by 1846 <filename>systemd-timesyncd.service</filename>.</para> 1847 </listitem> 1848 </varlistentry> 1849 1850 <varlistentry> 1851 <term><varname>RoutesToNTP=</varname></term> 1852 <listitem> 1853 <para>When true, the routes to the NTP servers received from the DHCP server will be 1854 configured. When <varname>UseNTP=</varname> is disabled, this setting is ignored. Defaults to 1855 true.</para> 1856 </listitem> 1857 </varlistentry> 1858 1859 <varlistentry> 1860 <term><varname>UseSIP=</varname></term> 1861 <listitem> 1862 <para>When true (the default), the SIP servers received from the DHCP server will be collected 1863 and made available to client programs.</para> 1864 </listitem> 1865 </varlistentry> 1866 1867 <varlistentry> 1868 <term><varname>UseMTU=</varname></term> 1869 <listitem> 1870 <para>When true, the interface maximum transmission unit from the DHCP server will be used on 1871 the current link. If <varname>MTUBytes=</varname> is set, then this setting is ignored. 1872 Defaults to false.</para> 1873 1874 <para>Note, some drivers will reset the interfaces if the MTU is changed. For such 1875 interfaces, please try to use <varname>IgnoreCarrierLoss=</varname> with a short timespan, 1876 e.g. <literal>3 seconds</literal>.</para> 1877 </listitem> 1878 </varlistentry> 1879 1880 <varlistentry> 1881 <term><varname>UseHostname=</varname></term> 1882 <listitem> 1883 <para>When true (the default), the hostname received from the DHCP server will be set as the 1884 transient hostname of the system.</para> 1885 </listitem> 1886 </varlistentry> 1887 1888 <varlistentry> 1889 <term><varname>UseDomains=</varname></term> 1890 <listitem> 1891 <para>Takes a boolean, or the special value <option>route</option>. When true, the domain 1892 name received from the DHCP server will be used as DNS search domain over this link, similar 1893 to the effect of the <option>Domains=</option> setting. If set to <option>route</option>, the 1894 domain name received from the DHCP server will be used for routing DNS queries only, but not 1895 for searching, similar to the effect of the <option>Domains=</option> setting when the 1896 argument is prefixed with <literal>~</literal>. Defaults to false.</para> 1897 1898 <para>It is recommended to enable this option only on trusted networks, as setting this 1899 affects resolution of all hostnames, in particular of single-label names. It is generally 1900 safer to use the supplied domain only as routing domain, rather than as search domain, in 1901 order to not have it affect local resolution of single-label names.</para> 1902 1903 <para>When set to true, this setting corresponds to the <option>domain</option> option in 1904 <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. 1905 </para> 1906 </listitem> 1907 </varlistentry> 1908 1909 <varlistentry> 1910 <term><varname>UseRoutes=</varname></term> 1911 <listitem> 1912 <para>When true (the default), the static routes will be requested from the DHCP server and 1913 added to the routing table with a metric of 1024, and a scope of <option>global</option>, 1914 <option>link</option> or <option>host</option>, depending on the route's destination and 1915 gateway. If the destination is on the local host, e.g., 127.x.x.x, or the same as the link's 1916 own address, the scope will be set to <option>host</option>. Otherwise if the gateway is null 1917 (a direct route), a <option>link</option> scope will be used. For anything else, scope 1918 defaults to <option>global</option>.</para> 1919 </listitem> 1920 </varlistentry> 1921 1922 <varlistentry> 1923 <term><varname>RouteMetric=</varname></term> 1924 <listitem> 1925 <para>Set the routing metric for routes specified by the DHCP server (including the prefix 1926 route added for the specified prefix). Takes an unsigned integer in the range 0…4294967295. 1927 Defaults to 1024.</para> 1928 </listitem> 1929 </varlistentry> 1930 1931 <varlistentry> 1932 <term><varname>RouteTable=<replaceable>num</replaceable></varname></term> 1933 <listitem> 1934 <para>The table identifier for DHCP routes (a number between 1 and 4294967295, or 0 to 1935 unset). The table can be retrieved using 1936 <command>ip route show table <replaceable>num</replaceable></command>.</para> 1937 1938 <para>When used in combination with <varname>VRF=</varname>, the VRF's routing table is 1939 used when this parameter is not specified.</para> 1940 </listitem> 1941 </varlistentry> 1942 1943 <varlistentry> 1944 <term><varname>RouteMTUBytes=</varname></term> 1945 <listitem> 1946 <para>Specifies the MTU for the DHCP routes. Please see the [Route] section for further 1947 details.</para> 1948 </listitem> 1949 </varlistentry> 1950 1951 <varlistentry> 1952 <term><varname>UseGateway=</varname></term> 1953 <listitem> 1954 <para>When true, the gateway will be requested from the DHCP server and added to the routing 1955 table with a metric of 1024, and a scope of <option>link</option>. When unset, the value 1956 specified with <varname>UseRoutes=</varname> is used.</para> 1957 </listitem> 1958 </varlistentry> 1959 1960 <varlistentry> 1961 <term><varname>UseTimezone=</varname></term> 1962 <listitem><para>When true, the timezone received from the DHCP server will be set as timezone 1963 of the local system. Defaults to false.</para></listitem> 1964 </varlistentry> 1965 1966 <varlistentry> 1967 <term><varname>Use6RD=</varname></term> 1968 <listitem> 1969 <para>When true, subnets of the received IPv6 prefix are assigned to downstream interfaces 1970 which enables <varname>DHCPPrefixDelegation=</varname>. See also 1971 <varname>DHCPPrefixDelegation=</varname> in the [Network] section, the [DHCPPrefixDelegation] 1972 section, and <ulink url="https://tools.ietf.org/html/rfc5969">RFC 5969</ulink>. Defaults to 1973 false.</para> 1974 </listitem> 1975 </varlistentry> 1976 1977 <varlistentry> 1978 <term><varname>FallbackLeaseLifetimeSec=</varname></term> 1979 <listitem> 1980 <para>Allows one to set DHCPv4 lease lifetime when DHCPv4 server does not send the lease 1981 lifetime. Takes one of <literal>forever</literal> or <literal>infinity</literal>. If 1982 specified, the acquired address never expires. Defaults to unset.</para> 1983 </listitem> 1984 </varlistentry> 1985 1986 <!-- How to communicate with the server --> 1987 1988 <varlistentry> 1989 <term><varname>RequestBroadcast=</varname></term> 1990 <listitem> 1991 <para>Request the server to use broadcast messages before the IP address has been configured. 1992 This is necessary for devices that cannot receive RAW packets, or that cannot receive packets 1993 at all before an IP address has been configured. On the other hand, this must not be enabled 1994 on networks where broadcasts are filtered out.</para> 1995 </listitem> 1996 </varlistentry> 1997 1998 <varlistentry> 1999 <term><varname>MaxAttempts=</varname></term> 2000 <listitem> 2001 <para>Specifies how many times the DHCPv4 client configuration should be attempted. Takes a 2002 number or <literal>infinity</literal>. Defaults to <literal>infinity</literal>. Note that the 2003 time between retries is increased exponentially, up to approximately one per minute, so the 2004 network will not be overloaded even if this number is high. The default is suitable in most 2005 circumstances.</para> 2006 </listitem> 2007 </varlistentry> 2008 2009 <varlistentry> 2010 <term><varname>ListenPort=</varname></term> 2011 <listitem> 2012 <para>Set the port from which the DHCP client packets originate.</para> 2013 </listitem> 2014 </varlistentry> 2015 2016 <varlistentry> 2017 <term><varname>DenyList=</varname></term> 2018 <listitem> 2019 <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a 2020 prefix length after <literal>/</literal>. DHCP offers from servers in the list are rejected. 2021 Note that if <varname>AllowList=</varname> is configured then <varname>DenyList=</varname> is 2022 ignored.</para> 2023 </listitem> 2024 </varlistentry> 2025 2026 <varlistentry> 2027 <term><varname>AllowList=</varname></term> 2028 <listitem> 2029 <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a 2030 prefix length after <literal>/</literal>. DHCP offers from servers in the list are accepted. 2031 </para> 2032 </listitem> 2033 </varlistentry> 2034 2035 <varlistentry> 2036 <term><varname>SendRelease=</varname></term> 2037 <listitem> 2038 <para>When true, the DHCPv4 client sends a DHCP release packet when it stops. Defaults to 2039 true.</para> 2040 </listitem> 2041 </varlistentry> 2042 2043 <varlistentry> 2044 <term><varname>SendDecline=</varname></term> 2045 <listitem> 2046 <para>A boolean. When true, <command>systemd-networkd</command> performs IPv4 Duplicate 2047 Address Detection to the acquired address by the DHCPv4 client. If duplicate is detected, 2048 the DHCPv4 client rejects the address by sending a <constant>DHCPDECLINE</constant> packet to 2049 the DHCP server, and tries to obtain an IP address again. See 2050 <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5227</ulink>. Defaults to false.</para> 2051 </listitem> 2052 </varlistentry> 2053 </variablelist> 2054 </refsect1> 2055 2056 <refsect1> 2057 <title>[DHCPv6] Section Options</title> 2058 2059 <para>The [DHCPv6] section configures the DHCPv6 client, if it is enabled with the 2060 <varname>DHCP=</varname> setting described above, or invoked by the IPv6 Router Advertisement: 2061 </para> 2062 2063 <variablelist class='network-directives'> 2064 2065 <!-- DHCP packet contents --> 2066 2067 <varlistentry> 2068 <term><varname>MUDURL=</varname></term> 2069 <term><varname>IAID=</varname></term> 2070 <term><varname>DUIDType=</varname></term> 2071 <term><varname>DUIDRawData=</varname></term> 2072 <term><varname>RequestOptions=</varname></term> 2073 <listitem> 2074 <para>As in the [DHCPv4] section.</para> 2075 </listitem> 2076 </varlistentry> 2077 2078 <varlistentry> 2079 <term><varname>SendOption=</varname></term> 2080 <listitem> 2081 <para>As in the [DHCPv4] section, however because DHCPv6 uses 16-bit fields to store option 2082 numbers, the option number is an integer in the range 1…65536.</para> 2083 </listitem> 2084 </varlistentry> 2085 2086 <varlistentry> 2087 <term><varname>SendVendorOption=</varname></term> 2088 <listitem> 2089 <para>Send an arbitrary vendor option in the DHCPv6 request. Takes an enterprise identifier, 2090 DHCP option number, data type, and data separated with a colon 2091 (<literal><replaceable>enterprise identifier</replaceable>:<replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). 2092 Enterprise identifier is an unsigned integer in the range 1…4294967294. The option number 2093 must be an integer in the range 1…254. Data type takes one of <literal>uint8</literal>, 2094 <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, 2095 <literal>ipv6address</literal>, or <literal>string</literal>. Special characters in the data 2096 string may be escaped using 2097 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 2098 escapes</ulink>. This setting can be specified multiple times. If an empty string is 2099 specified, then all options specified earlier are cleared. Defaults to unset.</para> 2100 </listitem> 2101 </varlistentry> 2102 2103 <varlistentry> 2104 <term><varname>UserClass=</varname></term> 2105 <listitem> 2106 <para>A DHCPv6 client can use User Class option to identify the type or category of user or 2107 applications it represents. The information contained in this option is a string that 2108 represents the user class of which the client is a member. Each class sets an identifying 2109 string of information to be used by the DHCP service to classify clients. Special characters 2110 in the data string may be escaped using 2111 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 2112 escapes</ulink>. This setting can be specified multiple times. If an empty string is 2113 specified, then all options specified earlier are cleared. Takes a whitespace-separated list 2114 of strings. Note that currently <constant>NUL</constant> bytes are not allowed.</para> 2115 </listitem> 2116 </varlistentry> 2117 2118 <varlistentry> 2119 <term><varname>VendorClass=</varname></term> 2120 <listitem> 2121 <para>A DHCPv6 client can use VendorClass option to identify the vendor that manufactured the 2122 hardware on which the client is running. The information contained in the data area of this 2123 option is contained in one or more opaque fields that identify details of the hardware 2124 configuration. Takes a whitespace-separated list of strings.</para> 2125 </listitem> 2126 </varlistentry> 2127 2128 <varlistentry> 2129 <term><varname>PrefixDelegationHint=</varname></term> 2130 <listitem> 2131 <para>Takes an IPv6 address with prefix length in the same format as the 2132 <varname>Address=</varname> in the [Network] section. The DHCPv6 client will include a prefix 2133 hint in the DHCPv6 solicitation sent to the server. The prefix length must be in the range 2134 1…128. Defaults to unset.</para> 2135 </listitem> 2136 </varlistentry> 2137 2138 <!-- How to use the DHCP lease --> 2139 2140 <varlistentry> 2141 <term><varname>UseAddress=</varname></term> 2142 <listitem> 2143 <para>When true (the default), the IP addresses provided by the DHCPv6 server will be 2144 assigned.</para> 2145 </listitem> 2146 </varlistentry> 2147 2148 <varlistentry> 2149 <term><varname>UseDelegatedPrefix=</varname></term> 2150 <listitem> 2151 <para>When true (the default), the client will request the DHCPv6 server to delegate 2152 prefixes. If the server provides prefixes to be delegated, then subnets of the prefixes are 2153 assigned to the interfaces that have <varname>DHCPPrefixDelegation=yes</varname>. 2154 See also the <varname>DHCPPrefixDelegation=</varname> setting in the [Network] section, 2155 settings in the [DHCPPrefixDelegation] section, and 2156 <ulink url="https://www.rfc-editor.org/rfc/rfc8415.html#section-6.3">RFC 8415</ulink>. 2157 </para> 2158 </listitem> 2159 </varlistentry> 2160 2161 <varlistentry> 2162 <term><varname>UseDNS=</varname></term> 2163 <term><varname>UseNTP=</varname></term> 2164 <term><varname>UseHostname=</varname></term> 2165 <term><varname>UseDomains=</varname></term> 2166 <listitem> 2167 <para>As in the [DHCPv4] section.</para> 2168 </listitem> 2169 </varlistentry> 2170 2171 <!-- How to communicate with the server --> 2172 2173 <varlistentry> 2174 <term><varname>WithoutRA=</varname></term> 2175 <listitem> 2176 <para>Allows DHCPv6 client to start without router advertisements's 2177 <literal>managed</literal> or <literal>other configuration</literal> flag. Takes one of 2178 <literal>no</literal>, <literal>solicit</literal>, or 2179 <literal>information-request</literal>. If this is not specified, 2180 <literal>solicit</literal> is used when <varname>DHCPPrefixDelegation=</varname> is enabled 2181 and <varname>UplinkInterface=:self</varname> is specified in the [DHCPPrefixDelegation] 2182 section. Otherwise, defaults to <literal>no</literal>, and the DHCPv6 client will be started 2183 when an RA is received. See also the <varname>DHCPv6Client=</varname> setting in the 2184 [IPv6AcceptRA] section.</para> 2185 </listitem> 2186 </varlistentry> 2187 </variablelist> 2188 </refsect1> 2189 2190 <refsect1> 2191 <title>[DHCPPrefixDelegation] Section Options</title> 2192 <para>The [DHCPPrefixDelegation] section configures subnet prefixes of the delegated prefixes 2193 acquired by a DHCPv6 client, or by a DHCPv4 client through the 6RD option on another interface. 2194 The settings in this section are used only when the <varname>DHCPPrefixDelegation=</varname> 2195 setting in the [Network] section is enabled.</para> 2196 2197 <variablelist class='network-directives'> 2198 <varlistentry> 2199 <term><varname>UplinkInterface=</varname></term> 2200 <listitem> 2201 <para>Specifies the name or the index of the uplink interface, or one of the special values 2202 <literal>:self</literal> and <literal>:auto</literal>. When <literal>:self</literal>, the 2203 interface itself is considered the uplink interface, and 2204 <varname>WithoutRA=solicit</varname> is implied if the setting is not explicitly specified. 2205 When <literal>:auto</literal>, the first link which acquired prefixes to be delegated from 2206 the DHCPv6 or DHCPv4 server is selected. Defaults to <literal>:auto</literal>.</para> 2207 </listitem> 2208 </varlistentry> 2209 2210 <varlistentry> 2211 <term><varname>SubnetId=</varname></term> 2212 <listitem> 2213 <para>Configure a specific subnet ID on the interface from a (previously) received prefix 2214 delegation. You can either set "auto" (the default) or a specific subnet ID (as defined in 2215 <ulink url="https://tools.ietf.org/html/rfc4291#section-2.5.4">RFC 4291</ulink>, section 2216 2.5.4), in which case the allowed value is hexadecimal, from 0 to 0x7fffffffffffffff 2217 inclusive.</para> 2218 </listitem> 2219 </varlistentry> 2220 2221 <varlistentry> 2222 <term><varname>Announce=</varname></term> 2223 <listitem> 2224 <para>Takes a boolean. When enabled, and <varname>IPv6SendRA=</varname> in [Network] section 2225 is enabled, the delegated prefixes are distributed through the IPv6 Router Advertisement. 2226 This setting will be ignored when the <varname>DHCPPrefixDelegation=</varname> setting is 2227 enabled on the upstream interface. Defaults to yes.</para> 2228 </listitem> 2229 </varlistentry> 2230 2231 <varlistentry> 2232 <term><varname>Assign=</varname></term> 2233 <listitem> 2234 <para>Takes a boolean. Specifies whether to add an address from the delegated prefixes which 2235 are received from the WAN interface by the DHCPv6 Prefix Delegation. When true (on LAN 2236 interfce), the EUI-64 algorithm will be used by default to form an interface identifier from 2237 the delegated prefixes. See also <varname>Token=</varname> setting below. Defaults to yes. 2238 </para> 2239 </listitem> 2240 </varlistentry> 2241 2242 <varlistentry> 2243 <term><varname>Token=</varname></term> 2244 <listitem> 2245 <para>Specifies an optional address generation mode for assigning an address in each 2246 delegated prefix. This accepts the same syntax as <varname>Token=</varname> in the 2247 [IPv6AcceptRA] section. If <varname>Assign=</varname> is set to false, then this setting will 2248 be ignored. Defaults to unset, which means the EUI-64 algorithm will be used.</para> 2249 </listitem> 2250 </varlistentry> 2251 2252 <varlistentry> 2253 <term><varname>ManageTemporaryAddress=</varname></term> 2254 <listitem> 2255 <para>As in the [Address] section, but defaults to true.</para> 2256 </listitem> 2257 </varlistentry> 2258 2259 <varlistentry> 2260 <term><varname>RouteMetric=</varname></term> 2261 <listitem> 2262 <para>The metric of the route to the delegated prefix subnet. Takes an unsigned integer in 2263 the range 0…4294967295. When set to 0, the kernel's default value is used. Defaults to 256. 2264 </para> 2265 </listitem> 2266 </varlistentry> 2267 </variablelist> 2268 </refsect1> 2269 2270 <refsect1> 2271 <title>[IPv6AcceptRA] Section Options</title> 2272 <para>The [IPv6AcceptRA] section configures the IPv6 Router Advertisement (RA) client, if it is enabled 2273 with the <varname>IPv6AcceptRA=</varname> setting described above:</para> 2274 2275 <variablelist class='network-directives'> 2276 <varlistentry> 2277 <term><varname>Token=</varname></term> 2278 <listitem> 2279 <para>Specifies an optional address generation mode for the Stateless Address 2280 Autoconfiguration (SLAAC). The following values are supported:</para> 2281 2282 <variablelist> 2283 <varlistentry> 2284 <term><option>eui64</option></term> 2285 <listitem> 2286 <para> 2287 The EUI-64 algorithm will be used to generate an address for that prefix. Only 2288 supported by Ethernet or InfiniBand interfaces. 2289 </para> 2290 </listitem> 2291 </varlistentry> 2292 <varlistentry> 2293 <term><option>static:<replaceable>ADDRESS</replaceable></option></term> 2294 <listitem> 2295 <para> 2296 An IPv6 address must be specified after a colon (<literal>:</literal>), and the 2297 lower bits of the supplied address are combined with the upper bits of a prefix 2298 received in a Router Advertisement (RA) message to form a complete address. Note 2299 that if multiple prefixes are received in an RA message, or in multiple RA messages, 2300 addresses will be formed from each of them using the supplied address. This mode 2301 implements SLAAC but uses a static interface identifier instead of an identifier 2302 generated by using the EUI-64 algorithm. Because the interface identifier is static, 2303 if Duplicate Address Detection detects that the computed address is a duplicate 2304 (in use by another node on the link), then this mode will fail to provide an address 2305 for that prefix. If an IPv6 address without mode is specified, then 2306 <literal>static</literal> mode is assumed. 2307 </para> 2308 </listitem> 2309 </varlistentry> 2310 <varlistentry> 2311 <term><option>prefixstable[:<replaceable>ADDRESS</replaceable>][,<replaceable>UUID</replaceable>]</option></term> 2312 <listitem> 2313 <para> 2314 The algorithm specified in 2315 <ulink url="https://tools.ietf.org/html/rfc7217">RFC 7217</ulink> will be used to 2316 generate interface identifiers. This mode can optionally take an IPv6 address 2317 separated with a colon (<literal>:</literal>). If an IPv6 address is specified, 2318 then an interface identifier is generated only when a prefix received in an RA 2319 message matches the supplied address. 2320 </para> 2321 <para> 2322 This mode can also optionally take a non-null UUID in the format which 2323 <function>sd_id128_from_string()</function> accepts, e.g. 2324 <literal>86b123b969ba4b7eb8b3d8605123525a</literal> or 2325 <literal>86b123b9-69ba-4b7e-b8b3-d8605123525a</literal>. If a UUID is specified, the 2326 value is used as the secret key to generate interface identifiers. If not specified, 2327 then an application specific ID generated with the system's machine-ID will be used 2328 as the secret key. See 2329 <citerefentry><refentrytitle>sd-id128</refentrytitle><manvolnum>3</manvolnum></citerefentry>, 2330 <citerefentry><refentrytitle>sd_id128_from_string</refentrytitle><manvolnum>3</manvolnum></citerefentry>, 2331 and 2332 <citerefentry><refentrytitle>sd_id128_get_machine</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 2333 </para> 2334 <para> 2335 Note that the <literal>prefixstable</literal> algorithm uses both the interface 2336 name and MAC address as input to the hash to compute the interface identifier, so 2337 if either of those are changed the resulting interface identifier (and address) 2338 will be changed, even if the prefix received in the RA message has not been 2339 changed. 2340 </para> 2341 </listitem> 2342 </varlistentry> 2343 </variablelist> 2344 2345 <para>If no address generation mode is specified (which is the default), or a received 2346 prefix does not match any of the addresses provided in <literal>prefixstable</literal> 2347 mode, then the EUI-64 algorithm will be used for Ethernet or InfiniBand interfaces, 2348 otherwise <literal>prefixstable</literal> will be used to form an interface identifier for 2349 that prefix.</para> 2350 2351 <para>This setting can be specified multiple times. If an empty string is assigned, then 2352 the all previous assignments are cleared.</para> 2353 2354 <para>Examples: 2355 <programlisting>Token=eui64 2356Token=::1a:2b:3c:4d 2357Token=static:::1a:2b:3c:4d 2358Token=prefixstable 2359Token=prefixstable:2002:da8:1::</programlisting></para> 2360 </listitem> 2361 </varlistentry> 2362 2363 <varlistentry> 2364 <term><varname>UseDNS=</varname></term> 2365 <listitem> 2366 <para>When true (the default), the DNS servers received in the Router Advertisement will be used.</para> 2367 2368 <para>This corresponds to the <option>nameserver</option> option in <citerefentry 2369 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> 2370 </listitem> 2371 </varlistentry> 2372 2373 <varlistentry> 2374 <term><varname>UseDomains=</varname></term> 2375 <listitem> 2376 <para>Takes a boolean, or the special value <literal>route</literal>. When true, the domain name 2377 received via IPv6 Router Advertisement (RA) will be used as DNS search domain over this link, similar to 2378 the effect of the <option>Domains=</option> setting. If set to <literal>route</literal>, the domain name 2379 received via IPv6 RA will be used for routing DNS queries only, but not for searching, similar to the 2380 effect of the <option>Domains=</option> setting when the argument is prefixed with 2381 <literal>~</literal>. Defaults to false.</para> 2382 2383 <para>It is recommended to enable this option only on trusted networks, as setting this affects resolution 2384 of all hostnames, in particular of single-label names. It is generally safer to use the supplied domain 2385 only as routing domain, rather than as search domain, in order to not have it affect local resolution of 2386 single-label names.</para> 2387 2388 <para>When set to true, this setting corresponds to the <option>domain</option> option in <citerefentry 2389 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> 2390 </listitem> 2391 </varlistentry> 2392 2393 <varlistentry> 2394 <term><varname>RouteTable=<replaceable>num</replaceable></varname></term> 2395 <listitem> 2396 <para>The table identifier for the routes received in the Router Advertisement 2397 (a number between 1 and 4294967295, or 0 to unset). 2398 The table can be retrieved using <command>ip route show table <replaceable>num</replaceable></command>. 2399 </para> 2400 </listitem> 2401 </varlistentry> 2402 2403 <varlistentry> 2404 <term><varname>RouteMetric=</varname></term> 2405 <listitem> 2406 <para>Set the routing metric for the routes received in the Router Advertisement. Takes an 2407 unsigned integer in the range 0…4294967295. Defaults to 1024.</para> 2408 </listitem> 2409 </varlistentry> 2410 2411 <varlistentry> 2412 <term><varname>UseMTU=</varname></term> 2413 <listitem> 2414 <para>Takes a boolean. When true, the MTU received in the Router Advertisement will be 2415 used. Defaults to true.</para> 2416 </listitem> 2417 </varlistentry> 2418 2419 <varlistentry> 2420 <term><varname>UseGateway=</varname></term> 2421 <listitem> 2422 <para>When true (the default), the router address will be configured as the default gateway. 2423 </para> 2424 </listitem> 2425 </varlistentry> 2426 2427 <varlistentry> 2428 <term><varname>UseRoutePrefix=</varname></term> 2429 <listitem> 2430 <para>When true (the default), the routes corresponding to the route prefixes received in 2431 the Router Advertisement will be configured.</para> 2432 </listitem> 2433 </varlistentry> 2434 2435 <varlistentry> 2436 <term><varname>UseAutonomousPrefix=</varname></term> 2437 <listitem> 2438 <para>When true (the default), the autonomous prefix received in the Router Advertisement will be used and take 2439 precedence over any statically configured ones.</para> 2440 </listitem> 2441 </varlistentry> 2442 2443 <varlistentry> 2444 <term><varname>UseOnLinkPrefix=</varname></term> 2445 <listitem> 2446 <para>When true (the default), the onlink prefix received in the Router Advertisement will be 2447 used and takes precedence over any statically configured ones.</para> 2448 </listitem> 2449 </varlistentry> 2450 2451 <varlistentry> 2452 <term><varname>RouterDenyList=</varname></term> 2453 <listitem> 2454 <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally 2455 take a prefix length after <literal>/</literal>. Any information advertised by the listed 2456 router is ignored.</para> 2457 </listitem> 2458 </varlistentry> 2459 2460 <varlistentry> 2461 <term><varname>RouterAllowList=</varname></term> 2462 <listitem> 2463 <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally 2464 take a prefix length after <literal>/</literal>. Only information advertised by the listed 2465 router is accepted. Note that if <varname>RouterAllowList=</varname> is configured then 2466 <varname>RouterDenyList=</varname> is ignored.</para> 2467 </listitem> 2468 </varlistentry> 2469 2470 <varlistentry> 2471 <term><varname>PrefixDenyList=</varname></term> 2472 <listitem> 2473 <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its 2474 prefix length after <literal>/</literal>. IPv6 prefixes supplied via router advertisements 2475 in the list are ignored.</para> 2476 </listitem> 2477 </varlistentry> 2478 2479 <varlistentry> 2480 <term><varname>PrefixAllowList=</varname></term> 2481 <listitem> 2482 <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its 2483 prefix length after <literal>/</literal>. IPv6 prefixes supplied via router advertisements 2484 in the list are allowed. Note that if <varname>PrefixAllowList=</varname> is configured 2485 then <varname>PrefixDenyList=</varname> is ignored.</para> 2486 </listitem> 2487 </varlistentry> 2488 2489 <varlistentry> 2490 <term><varname>RouteDenyList=</varname></term> 2491 <listitem> 2492 <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take 2493 its prefix length after <literal>/</literal>. IPv6 route prefixes supplied via router 2494 advertisements in the list are ignored.</para> 2495 </listitem> 2496 </varlistentry> 2497 2498 <varlistentry> 2499 <term><varname>RouteAllowList=</varname></term> 2500 <listitem> 2501 <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take 2502 its prefix length after <literal>/</literal>. IPv6 route prefixes supplied via router 2503 advertisements in the list are allowed. Note that if <varname>RouteAllowList=</varname> is 2504 configured then <varname>RouteDenyList=</varname> is ignored.</para> 2505 </listitem> 2506 </varlistentry> 2507 2508 <varlistentry> 2509 <term><varname>DHCPv6Client=</varname></term> 2510 <listitem> 2511 <para>Takes a boolean, or the special value <literal>always</literal>. When true, the 2512 DHCPv6 client will be started in <literal>solicit</literal> mode if the RA has the 2513 <literal>managed</literal> flag or <literal>information-request</literal> mode if the RA 2514 lacks the <literal>managed</literal> flag but has the 2515 <literal>other configuration</literal> flag. If set to <literal>always</literal>, the 2516 DHCPv6 client will be started in <literal>solicit</literal> mode when an RA is received, 2517 even if neither the <literal>managed</literal> nor the 2518 <literal>other configuration</literal> flag is set in the RA. This will be ignored when 2519 <varname>WithoutRA=</varname> in the [DHCPv6] section is enabled, or 2520 <varname>UplinkInterface=:self</varname> in the [DHCPPrefixDelegation] section is 2521 specified. Defaults to true.</para> 2522 </listitem> 2523 </varlistentry> 2524 </variablelist> 2525 </refsect1> 2526 2527 <refsect1> 2528 <title>[DHCPServer] Section Options</title> 2529 <para>The [DHCPServer] section contains settings for the DHCP server, if enabled via the 2530 <varname>DHCPServer=</varname> option described above:</para> 2531 2532 <variablelist class='network-directives'> 2533 2534 <varlistentry> 2535 <term><varname>ServerAddress=</varname></term> 2536 <listitem><para>Specifies server address for the DHCP server. Takes an IPv4 address with prefix 2537 length, for example <literal>192.168.0.1/24</literal>. This setting may be useful when the link on 2538 which the DHCP server is running has multiple static addresses. When unset, one of static addresses 2539 in the link will be automatically selected. Defaults to unset.</para></listitem> 2540 </varlistentry> 2541 2542 <varlistentry> 2543 <term><varname>PoolOffset=</varname></term> 2544 <term><varname>PoolSize=</varname></term> 2545 2546 <listitem><para>Configures the pool of addresses to hand out. The pool 2547 is a contiguous sequence of IP addresses in the subnet configured for 2548 the server address, which does not include the subnet nor the broadcast 2549 address. <varname>PoolOffset=</varname> takes the offset of the pool 2550 from the start of subnet, or zero to use the default value. 2551 <varname>PoolSize=</varname> takes the number of IP addresses in the 2552 pool or zero to use the default value. By default, the pool starts at 2553 the first address after the subnet address and takes up the rest of 2554 the subnet, excluding the broadcast address. If the pool includes 2555 the server address (the default), this is reserved and not handed 2556 out to clients.</para></listitem> 2557 </varlistentry> 2558 2559 <varlistentry> 2560 <term><varname>DefaultLeaseTimeSec=</varname></term> 2561 <term><varname>MaxLeaseTimeSec=</varname></term> 2562 2563 <listitem><para>Control the default and maximum DHCP lease 2564 time to pass to clients. These settings take time values in seconds or 2565 another common time unit, depending on the suffix. The default 2566 lease time is used for clients that did not ask for a specific 2567 lease time. If a client asks for a lease time longer than the 2568 maximum lease time, it is automatically shortened to the 2569 specified time. The default lease time defaults to 1h, the 2570 maximum lease time to 12h. Shorter lease times are beneficial 2571 if the configuration data in DHCP leases changes frequently 2572 and clients shall learn the new settings with shorter 2573 latencies. Longer lease times reduce the generated DHCP 2574 network traffic.</para></listitem> 2575 </varlistentry> 2576 2577 <varlistentry> 2578 <term><varname>UplinkInterface=</varname></term> 2579 <listitem><para>Specifies the name or the index of the uplink interface, or one of the special 2580 values <literal>:none</literal> and <literal>:auto</literal>. When emitting DNS, NTP, or SIP 2581 servers is enabled but no servers are specified, the servers configured in the uplink interface 2582 will be emitted. When <literal>:auto</literal>, the link which has a default gateway with the 2583 highest priority will be automatically selected. When <literal>:none</literal>, no uplink 2584 interface will be selected. Defaults to <literal>:auto</literal>.</para></listitem> 2585 </varlistentry> 2586 2587 <varlistentry> 2588 <term><varname>EmitDNS=</varname></term> 2589 <term><varname>DNS=</varname></term> 2590 2591 <listitem><para><varname>EmitDNS=</varname> takes a boolean. Configures whether the DHCP leases 2592 handed out to clients shall contain DNS server information. Defaults to <literal>yes</literal>. 2593 The DNS servers to pass to clients may be configured with the <varname>DNS=</varname> option, 2594 which takes a list of IPv4 addresses, or special value <literal>_server_address</literal> which 2595 will be converted to the address used by the DHCP server.</para> 2596 2597 <para>If the <varname>EmitDNS=</varname> option is enabled but no servers configured, the 2598 servers are automatically propagated from an "uplink" interface that has appropriate servers 2599 set. The "uplink" interface is determined by the default route of the system with the highest 2600 priority. Note that this information is acquired at the time the lease is handed out, and does 2601 not take uplink interfaces into account that acquire DNS server information at a later point. 2602 If no suitable uplink interface is found the DNS server data from 2603 <filename>/etc/resolv.conf</filename> is used. Also, note that the leases are not refreshed if 2604 the uplink network configuration changes. To ensure clients regularly acquire the most current 2605 uplink DNS server information, it is thus advisable to shorten the DHCP lease time via 2606 <varname>MaxLeaseTimeSec=</varname> described above.</para> 2607 2608 <para>This setting can be specified multiple times. If an empty string is specified, then all 2609 DNS servers specified earlier are cleared.</para></listitem> 2610 </varlistentry> 2611 2612 <varlistentry> 2613 <term><varname>EmitNTP=</varname></term> 2614 <term><varname>NTP=</varname></term> 2615 <term><varname>EmitSIP=</varname></term> 2616 <term><varname>SIP=</varname></term> 2617 <term><varname>EmitPOP3=</varname></term> 2618 <term><varname>POP3=</varname></term> 2619 <term><varname>EmitSMTP=</varname></term> 2620 <term><varname>SMTP=</varname></term> 2621 <term><varname>EmitLPR=</varname></term> 2622 <term><varname>LPR=</varname></term> 2623 2624 <listitem><para>Similar to the <varname>EmitDNS=</varname> and <varname>DNS=</varname> settings 2625 described above, these settings configure whether and what server information for the indicate 2626 protocol shall be emitted as part of the DHCP lease. The same syntax, propagation semantics and 2627 defaults apply as for <varname>EmitDNS=</varname> and <varname>DNS=</varname>.</para></listitem> 2628 </varlistentry> 2629 2630 <varlistentry> 2631 <term><varname>EmitRouter=</varname></term> 2632 <term><varname>Router=</varname></term> 2633 2634 <listitem><para>The <varname>EmitRouter=</varname> setting takes a boolean value, and configures 2635 whether the DHCP lease should contain the router option. The <varname>Router=</varname> setting 2636 takes an IPv4 address, and configures the router address to be emitted. When the 2637 <varname>Router=</varname> setting is not specified, then the server address will be used for 2638 the router option. When the <varname>EmitRouter=</varname> setting is disabled, the 2639 <varname>Router=</varname> setting will be ignored. The <varname>EmitRouter=</varname> setting 2640 defaults to true, and the <varname>Router=</varname> setting defaults to unset. 2641 </para></listitem> 2642 </varlistentry> 2643 2644 <varlistentry> 2645 <term><varname>EmitTimezone=</varname></term> 2646 <term><varname>Timezone=</varname></term> 2647 2648 <listitem><para>Takes a boolean. Configures whether the DHCP leases handed out 2649 to clients shall contain timezone information. Defaults to <literal>yes</literal>. The 2650 <varname>Timezone=</varname> setting takes a timezone string 2651 (such as <literal>Europe/Berlin</literal> or 2652 <literal>UTC</literal>) to pass to clients. If no explicit 2653 timezone is set, the system timezone of the local host is 2654 propagated, as determined by the 2655 <filename>/etc/localtime</filename> symlink.</para></listitem> 2656 </varlistentry> 2657 2658 <varlistentry> 2659 <term><varname>BootServerAddress=</varname></term> 2660 2661 <listitem> 2662 <para>Takes an IPv4 address of the boot server used by e.g. PXE boot systems. When specified, this 2663 address is sent in the <option>siaddr</option> field of the DHCP message header. See <ulink 2664 url="https://www.rfc-editor.org/rfc/rfc2131.html">RFC 2131</ulink> for more details. Defaults to 2665 unset.</para> 2666 </listitem> 2667 </varlistentry> 2668 2669 <varlistentry> 2670 <term><varname>BootServerName=</varname></term> 2671 2672 <listitem> 2673 <para>Takes a name of the boot server used by e.g. PXE boot systems. When specified, this name is 2674 sent in the DHCP option 66 ("TFTP server name"). See <ulink 2675 url="https://www.rfc-editor.org/rfc/rfc2132.html">RFC 2132</ulink> for more details. Defaults to 2676 unset.</para> 2677 2678 <para>Note that typically setting one of <varname>BootServerName=</varname> or 2679 <varname>BootServerAddress=</varname> is sufficient, but both can be set too, if desired.</para> 2680 </listitem> 2681 </varlistentry> 2682 2683 <varlistentry> 2684 <term><varname>BootFilename=</varname></term> 2685 2686 <listitem> 2687 <para>Takes a path or URL to a file loaded by e.g. a PXE boot loader. When specified, this path is 2688 sent in the DHCP option 67 ("Bootfile name"). See <ulink 2689 url="https://www.rfc-editor.org/rfc/rfc2132.html">RFC 2132</ulink> for more details. Defaults to 2690 unset.</para> 2691 </listitem> 2692 </varlistentry> 2693 2694 <varlistentry> 2695 <term><varname>SendOption=</varname></term> 2696 <listitem> 2697 <para>Send a raw option with value via DHCPv4 server. Takes a DHCP option number, data type 2698 and data (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). 2699 The option number is an integer in the range 1…254. The type takes one of <literal>uint8</literal>, 2700 <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, <literal>ipv6address</literal>, or 2701 <literal>string</literal>. Special characters in the data string may be escaped using 2702 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 2703 escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, 2704 then all options specified earlier are cleared. Defaults to unset.</para> 2705 </listitem> 2706 </varlistentry> 2707 2708 <varlistentry> 2709 <term><varname>SendVendorOption=</varname></term> 2710 <listitem> 2711 <para>Send a vendor option with value via DHCPv4 server. Takes a DHCP option number, data type 2712 and data (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). 2713 The option number is an integer in the range 1…254. The type takes one of <literal>uint8</literal>, 2714 <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, or 2715 <literal>string</literal>. Special characters in the data string may be escaped using 2716 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style 2717 escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, 2718 then all options specified earlier are cleared. Defaults to unset.</para> 2719 </listitem> 2720 </varlistentry> 2721 <varlistentry> 2722 <term><varname>BindToInterface=</varname></term> 2723 <listitem> 2724 <para>Takes a boolean value. When <literal>yes</literal>, DHCP server socket will be bound 2725 to its network interface and all socket communication will be restricted to this interface. 2726 Defaults to <literal>yes</literal>, except if <varname>RelayTarget=</varname> is used (see below), 2727 in which case it defaults to <literal>no</literal>.</para> 2728 </listitem> 2729 </varlistentry> 2730 <varlistentry> 2731 <term><varname>RelayTarget=</varname></term> 2732 <listitem> 2733 <para>Takes an IPv4 address, which must be in the format described in 2734 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. 2735 Turns this DHCP server into a DHCP relay agent. See <ulink url="https://tools.ietf.org/html/rfc1542">RFC 1542</ulink>. 2736 The address is the address of DHCP server or another relay agent to forward DHCP messages to and from.</para> 2737 </listitem> 2738 </varlistentry> 2739 <varlistentry> 2740 <term><varname>RelayAgentCircuitId=</varname></term> 2741 <listitem> 2742 <para>Specifies value for Agent Circuit ID suboption of Relay Agent Information option. 2743 Takes a string, which must be in the format <literal>string:<replaceable>value</replaceable></literal>, 2744 where <literal><replaceable>value</replaceable></literal> should be replaced with the value of the suboption. 2745 Defaults to unset (means no Agent Circuit ID suboption is generated). 2746 Ignored if <varname>RelayTarget=</varname> is not specified.</para> 2747 </listitem> 2748 </varlistentry> 2749 <varlistentry> 2750 <term><varname>RelayAgentRemoteId=</varname></term> 2751 <listitem> 2752 <para>Specifies value for Agent Remote ID suboption of Relay Agent Information option. 2753 Takes a string, which must be in the format <literal>string:<replaceable>value</replaceable></literal>, 2754 where <literal><replaceable>value</replaceable></literal> should be replaced with the value of the suboption. 2755 Defaults to unset (means no Agent Remote ID suboption is generated). 2756 Ignored if <varname>RelayTarget=</varname> is not specified.</para> 2757 </listitem> 2758 </varlistentry> 2759 2760 </variablelist> 2761 </refsect1> 2762 2763 <refsect1> 2764 <title>[DHCPServerStaticLease] Section Options</title> 2765 <para>The <literal>[DHCPServerStaticLease]</literal> section configures a static DHCP lease to assign a 2766 fixed IPv4 address to a specific device based on its MAC address. This section can be specified multiple 2767 times.</para> 2768 2769 <variablelist class='network-directives'> 2770 <varlistentry> 2771 <term><varname>MACAddress=</varname></term> 2772 2773 <listitem><para>The hardware address of a device to match. This key is mandatory.</para></listitem> 2774 </varlistentry> 2775 2776 <varlistentry> 2777 <term><varname>Address=</varname></term> 2778 2779 <listitem><para>The IPv4 address that should be assigned to the device that was matched with 2780 <varname>MACAddress=</varname>. This key is mandatory.</para></listitem> 2781 </varlistentry> 2782 </variablelist> 2783 </refsect1> 2784 2785 <refsect1> 2786 <title>[IPv6SendRA] Section Options</title> 2787 <para>The [IPv6SendRA] section contains settings for sending IPv6 Router Advertisements and whether 2788 to act as a router, if enabled via the <varname>IPv6SendRA=</varname> option described above. IPv6 2789 network prefixes or routes are defined with one or more [IPv6Prefix] or [IPv6RoutePrefix] sections. 2790 </para> 2791 2792 <variablelist class='network-directives'> 2793 2794 <varlistentry> 2795 <term><varname>Managed=</varname></term> 2796 <term><varname>OtherInformation=</varname></term> 2797 2798 <listitem><para>Takes a boolean. Controls whether a DHCPv6 server is used to acquire IPv6 2799 addresses on the network link when <varname>Managed=</varname> 2800 is set to <literal>true</literal> or if only additional network 2801 information can be obtained via DHCPv6 for the network link when 2802 <varname>OtherInformation=</varname> is set to 2803 <literal>true</literal>. Both settings default to 2804 <literal>false</literal>, which means that a DHCPv6 server is not being 2805 used.</para></listitem> 2806 </varlistentry> 2807 2808 <varlistentry> 2809 <term><varname>RouterLifetimeSec=</varname></term> 2810 2811 <listitem><para>Takes a timespan. Configures the IPv6 router lifetime in seconds. The value must be 0 2812 seconds, or between 4 seconds and 9000 seconds. When set to 0, the host is not acting as a router. 2813 Defaults to 1800 seconds (30 minutes).</para> 2814 </listitem> 2815 </varlistentry> 2816 2817 <varlistentry> 2818 <term><varname>RouterPreference=</varname></term> 2819 2820 <listitem><para>Configures IPv6 router preference if 2821 <varname>RouterLifetimeSec=</varname> is non-zero. Valid values are 2822 <literal>high</literal>, <literal>medium</literal> and 2823 <literal>low</literal>, with <literal>normal</literal> and 2824 <literal>default</literal> added as synonyms for 2825 <literal>medium</literal> just to make configuration easier. See 2826 <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> 2827 for details. Defaults to <literal>medium</literal>.</para></listitem> 2828 </varlistentry> 2829 2830 <varlistentry> 2831 <term><varname>UplinkInterface=</varname></term> 2832 <listitem><para>Specifies the name or the index of the uplink interface, or one of the special 2833 values <literal>:none</literal> and <literal>:auto</literal>. When emitting DNS servers or 2834 search domains is enabled but no servers are specified, the servers configured in the uplink 2835 interface will be emitted. When <literal>:auto</literal>, the value specified to the same 2836 setting in the [DHCPPrefixDelegation] section will be used if 2837 <varname>DHCPPrefixDelegation=</varname> is enabled, otherwise the link which has a default 2838 gateway with the highest priority will be automatically selected. When <literal>:none</literal>, 2839 no uplink interface will be selected. Defaults to <literal>:auto</literal>.</para></listitem> 2840 </varlistentry> 2841 2842 <varlistentry> 2843 <term><varname>EmitDNS=</varname></term> 2844 <term><varname>DNS=</varname></term> 2845 2846 <listitem><para><varname>DNS=</varname> specifies a list of recursive DNS server IPv6 addresses 2847 that are distributed via Router Advertisement messages when <varname>EmitDNS=</varname> is true. 2848 <varname>DNS=</varname> also takes special value <literal>_link_local</literal>; in that case 2849 the IPv6 link-local address is distributed. If <varname>DNS=</varname> is empty, DNS servers are 2850 read from the [Network] section. If the [Network] section does not contain any DNS servers 2851 either, DNS servers from the uplink interface specified in <varname>UplinkInterface=</varname> 2852 will be used. When <varname>EmitDNS=</varname> is false, no DNS server information is sent in 2853 Router Advertisement messages. <varname>EmitDNS=</varname> defaults to true.</para></listitem> 2854 </varlistentry> 2855 2856 <varlistentry> 2857 <term><varname>EmitDomains=</varname></term> 2858 <term><varname>Domains=</varname></term> 2859 2860 <listitem><para>A list of DNS search domains distributed via Router Advertisement messages when 2861 <varname>EmitDomains=</varname> is true. If <varname>Domains=</varname> is empty, DNS search 2862 domains are read from the [Network] section. If the [Network] section does not contain any DNS 2863 search domains either, DNS search domains from the uplink interface specified in 2864 <varname>UplinkInterface=</varname> will be used. When <varname>EmitDomains=</varname> is false, 2865 no DNS search domain information is sent in Router Advertisement messages. 2866 <varname>EmitDomains=</varname> defaults to true.</para></listitem> 2867 </varlistentry> 2868 2869 <varlistentry> 2870 <term><varname>DNSLifetimeSec=</varname></term> 2871 2872 <listitem><para>Lifetime in seconds for the DNS server addresses listed in 2873 <varname>DNS=</varname> and search domains listed in <varname>Domains=</varname>. Defaults to 2874 3600 seconds (one hour).</para></listitem> 2875 </varlistentry> 2876 2877 </variablelist> 2878 </refsect1> 2879 2880 <refsect1> 2881 <title>[IPv6Prefix] Section Options</title> 2882 <para>One or more [IPv6Prefix] sections contain the IPv6 prefixes that are announced via Router 2883 Advertisements. See <ulink url="https://tools.ietf.org/html/rfc4861">RFC 4861</ulink> for further 2884 details.</para> 2885 2886 <variablelist class='network-directives'> 2887 2888 <varlistentry> 2889 <term><varname>AddressAutoconfiguration=</varname></term> 2890 <term><varname>OnLink=</varname></term> 2891 2892 <listitem><para>Takes a boolean to specify whether IPv6 addresses can be 2893 autoconfigured with this prefix and whether the prefix can be used for 2894 onlink determination. Both settings default to <literal>true</literal> 2895 in order to ease configuration. 2896 </para></listitem> 2897 </varlistentry> 2898 2899 <varlistentry> 2900 <term><varname>Prefix=</varname></term> 2901 2902 <listitem><para>The IPv6 prefix that is to be distributed to hosts. Similarly to configuring static 2903 IPv6 addresses, the setting is configured as an IPv6 prefix and its prefix length, separated by a 2904 <literal>/</literal> character. Use multiple [IPv6Prefix] sections to configure multiple IPv6 2905 prefixes since prefix lifetimes, address autoconfiguration and onlink status may differ from one 2906 prefix to another.</para></listitem> 2907 </varlistentry> 2908 2909 <varlistentry> 2910 <term><varname>PreferredLifetimeSec=</varname></term> 2911 <term><varname>ValidLifetimeSec=</varname></term> 2912 2913 <listitem><para>Preferred and valid lifetimes for the prefix measured in seconds. 2914 <varname>PreferredLifetimeSec=</varname> defaults to 1800 seconds (30 minutes) and 2915 <varname>ValidLifetimeSec=</varname> defaults to 3600 seconds (one hour).</para></listitem> 2916 </varlistentry> 2917 2918 <varlistentry> 2919 <term><varname>Assign=</varname></term> 2920 <listitem><para>Takes a boolean. When true, adds an address from the prefix. Default to false. 2921 </para></listitem> 2922 </varlistentry> 2923 2924 <varlistentry> 2925 <term><varname>Token=</varname></term> 2926 <listitem> 2927 <para>Specifies an optional address generation mode for assigning an address in each 2928 prefix. This accepts the same syntax as <varname>Token=</varname> in the [IPv6AcceptRA] 2929 section. If <varname>Assign=</varname> is set to false, then this setting will be ignored. 2930 Defaults to unset, which means the EUI-64 algorithm will be used.</para> 2931 </listitem> 2932 </varlistentry> 2933 2934 <varlistentry> 2935 <term><varname>RouteMetric=</varname></term> 2936 <listitem> 2937 <para>The metric of the prefix route. Takes an unsigned integer in the range 0…4294967295. 2938 When unset or set to 0, the kernel's default value is used. This setting is ignored when 2939 <varname>Assign=</varname> is false.</para> 2940 </listitem> 2941 </varlistentry> 2942 </variablelist> 2943 </refsect1> 2944 2945 <refsect1> 2946 <title>[IPv6RoutePrefix] Section Options</title> 2947 <para>One or more [IPv6RoutePrefix] sections contain the IPv6 2948 prefix routes that are announced via Router Advertisements. See 2949 <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> 2950 for further details.</para> 2951 2952 <variablelist class='network-directives'> 2953 2954 <varlistentry> 2955 <term><varname>Route=</varname></term> 2956 2957 <listitem><para>The IPv6 route that is to be distributed to hosts. Similarly to configuring static 2958 IPv6 routes, the setting is configured as an IPv6 prefix routes and its prefix route length, 2959 separated by a <literal>/</literal> character. Use multiple [IPv6PrefixRoutes] sections to configure 2960 multiple IPv6 prefix routes.</para></listitem> 2961 </varlistentry> 2962 2963 <varlistentry> 2964 <term><varname>LifetimeSec=</varname></term> 2965 2966 <listitem><para>Lifetime for the route prefix measured in seconds. 2967 <varname>LifetimeSec=</varname> defaults to 3600 seconds (one hour).</para></listitem> 2968 </varlistentry> 2969 2970 </variablelist> 2971 </refsect1> 2972 2973 <refsect1> 2974 <title>[Bridge] Section Options</title> 2975 <para>The [Bridge] section accepts the following keys:</para> 2976 <variablelist class='network-directives'> 2977 <varlistentry> 2978 <term><varname>UnicastFlood=</varname></term> 2979 <listitem> 2980 <para>Takes a boolean. Controls whether the bridge should flood 2981 traffic for which an FDB entry is missing and the destination 2982 is unknown through this port. When unset, the kernel's default will be used. 2983 </para> 2984 </listitem> 2985 </varlistentry> 2986 <varlistentry> 2987 <term><varname>MulticastFlood=</varname></term> 2988 <listitem> 2989 <para>Takes a boolean. Controls whether the bridge should flood 2990 traffic for which an MDB entry is missing and the destination 2991 is unknown through this port. When unset, the kernel's default will be used. 2992 </para> 2993 </listitem> 2994 </varlistentry> 2995 <varlistentry> 2996 <term><varname>MulticastToUnicast=</varname></term> 2997 <listitem> 2998 <para>Takes a boolean. Multicast to unicast works on top of the multicast snooping feature of 2999 the bridge. Which means unicast copies are only delivered to hosts which are interested in it. 3000 When unset, the kernel's default will be used. 3001 </para> 3002 </listitem> 3003 </varlistentry> 3004 <varlistentry> 3005 <term><varname>NeighborSuppression=</varname></term> 3006 <listitem> 3007 <para>Takes a boolean. Configures whether ARP and ND neighbor suppression is enabled for 3008 this port. When unset, the kernel's default will be used. 3009 </para> 3010 </listitem> 3011 </varlistentry> 3012 <varlistentry> 3013 <term><varname>Learning=</varname></term> 3014 <listitem> 3015 <para>Takes a boolean. Configures whether MAC address learning is enabled for 3016 this port. When unset, the kernel's default will be used. 3017 </para> 3018 </listitem> 3019 </varlistentry> 3020 <varlistentry> 3021 <term><varname>HairPin=</varname></term> 3022 <listitem> 3023 <para>Takes a boolean. Configures whether traffic may be sent back out of the port on which it 3024 was received. When this flag is false, then the bridge will not forward traffic back out of the 3025 receiving port. When unset, the kernel's default will be used.</para> 3026 </listitem> 3027 </varlistentry> 3028 <varlistentry> 3029 <term><varname>Isolated=</varname></term> 3030 <listitem> 3031 <para>Takes a boolean. Configures whether this port is isolated or not. Within a bridge, 3032 isolated ports can only communicate with non-isolated ports. When set to true, this port can only 3033 communicate with other ports whose Isolated setting is false. When set to false, this port 3034 can communicate with any other ports. When unset, the kernel's default will be used.</para> 3035 </listitem> 3036 </varlistentry> 3037 <varlistentry> 3038 <term><varname>UseBPDU=</varname></term> 3039 <listitem> 3040 <para>Takes a boolean. Configures whether STP Bridge Protocol Data Units will be 3041 processed by the bridge port. When unset, the kernel's default will be used.</para> 3042 </listitem> 3043 </varlistentry> 3044 <varlistentry> 3045 <term><varname>FastLeave=</varname></term> 3046 <listitem> 3047 <para>Takes a boolean. This flag allows the bridge to immediately stop multicast 3048 traffic on a port that receives an IGMP Leave message. It is only used with 3049 IGMP snooping if enabled on the bridge. When unset, the kernel's default will be used.</para> 3050 </listitem> 3051 </varlistentry> 3052 <varlistentry> 3053 <term><varname>AllowPortToBeRoot=</varname></term> 3054 <listitem> 3055 <para>Takes a boolean. Configures whether a given port is allowed to 3056 become a root port. Only used when STP is enabled on the bridge. 3057 When unset, the kernel's default will be used.</para> 3058 </listitem> 3059 </varlistentry> 3060 <varlistentry> 3061 <term><varname>ProxyARP=</varname></term> 3062 <listitem> 3063 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port. 3064 When unset, the kernel's default will be used.</para> 3065 </listitem> 3066 </varlistentry> 3067 <varlistentry> 3068 <term><varname>ProxyARPWiFi=</varname></term> 3069 <listitem> 3070 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port 3071 which meets extended requirements by IEEE 802.11 and Hotspot 2.0 specifications. 3072 When unset, the kernel's default will be used.</para> 3073 </listitem> 3074 </varlistentry> 3075 <varlistentry> 3076 <term><varname>MulticastRouter=</varname></term> 3077 <listitem> 3078 <para>Configures this port for having multicast routers attached. A port with a multicast 3079 router will receive all multicast traffic. Takes one of <literal>no</literal> 3080 to disable multicast routers on this port, <literal>query</literal> to let the system detect 3081 the presence of routers, <literal>permanent</literal> to permanently enable multicast traffic 3082 forwarding on this port, or <literal>temporary</literal> to enable multicast routers temporarily 3083 on this port, not depending on incoming queries. When unset, the kernel's default will be used.</para> 3084 </listitem> 3085 </varlistentry> 3086 <varlistentry> 3087 <term><varname>Cost=</varname></term> 3088 <listitem> 3089 <para>Sets the "cost" of sending packets of this interface. 3090 Each port in a bridge may have a different speed and the cost 3091 is used to decide which link to use. Faster interfaces 3092 should have lower costs. It is an integer value between 1 and 3093 65535.</para> 3094 </listitem> 3095 </varlistentry> 3096 <varlistentry> 3097 <term><varname>Priority=</varname></term> 3098 <listitem> 3099 <para>Sets the "priority" of sending packets on this interface. 3100 Each port in a bridge may have a different priority which is used 3101 to decide which link to use. Lower value means higher priority. 3102 It is an integer value between 0 to 63. Networkd does not set any 3103 default, meaning the kernel default value of 32 is used.</para> 3104 </listitem> 3105 </varlistentry> 3106 </variablelist> 3107 </refsect1> 3108 <refsect1> 3109 <title>[BridgeFDB] Section Options</title> 3110 <para>The [BridgeFDB] section manages the forwarding database table of a port and accepts the following 3111 keys. Specify several [BridgeFDB] sections to configure several static MAC table entries.</para> 3112 3113 <variablelist class='network-directives'> 3114 <varlistentry> 3115 <term><varname>MACAddress=</varname></term> 3116 <listitem> 3117 <para>As in the [Network] section. This key is mandatory.</para> 3118 </listitem> 3119 </varlistentry> 3120 <varlistentry> 3121 <term><varname>Destination=</varname></term> 3122 <listitem> 3123 <para>Takes an IP address of the destination VXLAN tunnel endpoint.</para> 3124 </listitem> 3125 </varlistentry> 3126 <varlistentry> 3127 <term><varname>VLANId=</varname></term> 3128 <listitem> 3129 <para>The VLAN ID for the new static MAC table entry. If 3130 omitted, no VLAN ID information is appended to the new static MAC 3131 table entry.</para> 3132 </listitem> 3133 </varlistentry> 3134 <varlistentry> 3135 <term><varname>VNI=</varname></term> 3136 <listitem> 3137 <para>The VXLAN Network Identifier (or VXLAN Segment ID) to use to connect to 3138 the remote VXLAN tunnel endpoint. Takes a number in the range 1…16777215. 3139 Defaults to unset.</para> 3140 </listitem> 3141 </varlistentry> 3142 <varlistentry> 3143 <term><varname>AssociatedWith=</varname></term> 3144 <listitem> 3145 <para>Specifies where the address is associated with. Takes one of <literal>use</literal>, 3146 <literal>self</literal>, <literal>master</literal> or <literal>router</literal>. 3147 <literal>use</literal> means the address is in use. User space can use this option to 3148 indicate to the kernel that the fdb entry is in use. <literal>self</literal> means 3149 the address is associated with the port drivers fdb. Usually hardware. <literal>master</literal> 3150 means the address is associated with master devices fdb. <literal>router</literal> means 3151 the destination address is associated with a router. Note that it's valid if the referenced 3152 device is a VXLAN type device and has route shortcircuit enabled. Defaults to <literal>self</literal>.</para> 3153 </listitem> 3154 </varlistentry> 3155 <varlistentry> 3156 <term><varname>OutgoingInterface=</varname></term> 3157 <listitem> 3158 <para>Specifies the name or index of the outgoing interface for the VXLAN device driver to 3159 reach the remote VXLAN tunnel endpoint. Defaults to unset.</para> 3160 </listitem> 3161 </varlistentry> 3162 </variablelist> 3163 </refsect1> 3164 <refsect1> 3165 <title>[BridgeMDB] Section Options</title> 3166 <para>The [BridgeMDB] section manages the multicast membership entries forwarding database table of a port and accepts the following 3167 keys. Specify several [BridgeMDB] sections to configure several permanent multicast membership entries.</para> 3168 3169 <variablelist class='network-directives'> 3170 <varlistentry> 3171 <term><varname>MulticastGroupAddress=</varname></term> 3172 <listitem> 3173 <para>Specifies the IPv4 or IPv6 multicast group address to add. This setting is mandatory.</para> 3174 </listitem> 3175 </varlistentry> 3176 <varlistentry> 3177 <term><varname>VLANId=</varname></term> 3178 <listitem> 3179 <para>The VLAN ID for the new entry. Valid ranges are 0 (no VLAN) to 4094. Optional, defaults to 0.</para> 3180 </listitem> 3181 </varlistentry> 3182 </variablelist> 3183 </refsect1> 3184 3185 <refsect1> 3186 <title>[LLDP] Section Options</title> 3187 <para>The [LLDP] section manages the Link Layer Discovery Protocol (LLDP) and accepts the following 3188 keys:</para> 3189 <variablelist class='network-directives'> 3190 <varlistentry> 3191 <term><varname>MUDURL=</varname></term> 3192 <listitem> 3193 <para>When configured, the specified Manufacturer Usage Descriptions (MUD) URL will be sent in 3194 LLDP packets. The syntax and semantics are the same as for <varname>MUDURL=</varname> in the 3195 [DHCPv4] section described above.</para> 3196 3197 <para>The MUD URLs received via LLDP packets are saved and can be read using the 3198 <function>sd_lldp_neighbor_get_mud_url()</function> function.</para> 3199 </listitem> 3200 </varlistentry> 3201 </variablelist> 3202 </refsect1> 3203 3204 <refsect1> 3205 <title>[CAN] Section Options</title> 3206 <para>The [CAN] section manages the Controller Area Network (CAN bus) and accepts the 3207 following keys:</para> 3208 <variablelist class='network-directives'> 3209 <varlistentry> 3210 <term><varname>BitRate=</varname></term> 3211 <listitem> 3212 <para>The bitrate of CAN device in bits per second. The usual SI prefixes (K, M) with the base of 1000 can 3213 be used here. Takes a number in the range 1…4294967295.</para> 3214 </listitem> 3215 </varlistentry> 3216 <varlistentry> 3217 <term><varname>SamplePoint=</varname></term> 3218 <listitem> 3219 <para>Optional sample point in percent with one decimal (e.g. <literal>75%</literal>, 3220 <literal>87.5%</literal>) or permille (e.g. <literal>875‰</literal>). This will be ignored when 3221 <varname>BitRate=</varname> is unspecified.</para> 3222 </listitem> 3223 </varlistentry> 3224 <varlistentry> 3225 <term><varname>TimeQuantaNSec=</varname></term> 3226 <term><varname>PropagationSegment=</varname></term> 3227 <term><varname>PhaseBufferSegment1=</varname></term> 3228 <term><varname>PhaseBufferSegment2=</varname></term> 3229 <term><varname>SyncJumpWidth=</varname></term> 3230 <listitem> 3231 <para>Specifies the time quanta, propagation segment, phase buffer segment 1 and 2, and the 3232 synchronization jump width, which allow one to define the CAN bit-timing in a hardware 3233 independent format as proposed by the Bosch CAN 2.0 Specification. 3234 <varname>TimeQuantaNSec=</varname> takes a timespan in nanoseconds. 3235 <varname>PropagationSegment=</varname>, <varname>PhaseBufferSegment1=</varname>, 3236 <varname>PhaseBufferSegment2=</varname>, and <varname>SyncJumpWidth=</varname> take number 3237 of time quantum specified in <varname>TimeQuantaNSec=</varname> and must be an unsigned 3238 integer in the range 0…4294967295. These settings except for 3239 <varname>SyncJumpWidth=</varname> will be ignored when <varname>BitRate=</varname> is 3240 specified.</para> 3241 </listitem> 3242 </varlistentry> 3243 <varlistentry> 3244 <term><varname>DataBitRate=</varname></term> 3245 <term><varname>DataSamplePoint=</varname></term> 3246 <listitem> 3247 <para>The bitrate and sample point for the data phase, if CAN-FD is used. These settings are 3248 analogous to the <varname>BitRate=</varname> and <varname>SamplePoint=</varname> keys.</para> 3249 </listitem> 3250 </varlistentry> 3251 <varlistentry> 3252 <term><varname>DataTimeQuantaNSec=</varname></term> 3253 <term><varname>DataPropagationSegment=</varname></term> 3254 <term><varname>DataPhaseBufferSegment1=</varname></term> 3255 <term><varname>DataPhaseBufferSegment2=</varname></term> 3256 <term><varname>DataSyncJumpWidth=</varname></term> 3257 <listitem> 3258 <para>Specifies the time quanta, propagation segment, phase buffer segment 1 and 2, and the 3259 synchronization jump width for the data phase, if CAN-FD is used. These settings are 3260 analogous to the <varname>TimeQuantaNSec=</varname> or related settings.</para> 3261 </listitem> 3262 </varlistentry> 3263 <varlistentry> 3264 <term><varname>FDMode=</varname></term> 3265 <listitem> 3266 <para>Takes a boolean. When <literal>yes</literal>, CAN-FD mode is enabled for the interface. 3267 Note, that a bitrate and optional sample point should also be set for the CAN-FD data phase using 3268 the <varname>DataBitRate=</varname> and <varname>DataSamplePoint=</varname> keys, or 3269 <varname>DataTimeQuanta=</varname> and related settings.</para> 3270 </listitem> 3271 </varlistentry> 3272 <varlistentry> 3273 <term><varname>FDNonISO=</varname></term> 3274 <listitem> 3275 <para>Takes a boolean. When <literal>yes</literal>, non-ISO CAN-FD mode is enabled for the 3276 interface. When unset, the kernel's default will be used.</para> 3277 </listitem> 3278 </varlistentry> 3279 <varlistentry> 3280 <term><varname>RestartSec=</varname></term> 3281 <listitem> 3282 <para>Automatic restart delay time. If set to a non-zero value, a restart of the CAN controller will be 3283 triggered automatically in case of a bus-off condition after the specified delay time. Subsecond delays can 3284 be specified using decimals (e.g. <literal>0.1s</literal>) or a <literal>ms</literal> or 3285 <literal>us</literal> postfix. Using <literal>infinity</literal> or <literal>0</literal> will turn the 3286 automatic restart off. By default automatic restart is disabled.</para> 3287 </listitem> 3288 </varlistentry> 3289 <varlistentry> 3290 <term><varname>Termination=</varname></term> 3291 <listitem> 3292 <para>Takes a boolean or a termination resistor value in ohm in the range 0…65535. When 3293 <literal>yes</literal>, the termination resistor is set to 120 ohm. When 3294 <literal>no</literal> or <literal>0</literal> is set, the termination resistor is disabled. 3295 When unset, the kernel's default will be used.</para> 3296 </listitem> 3297 </varlistentry> 3298 <varlistentry> 3299 <term><varname>TripleSampling=</varname></term> 3300 <listitem> 3301 <para>Takes a boolean. When <literal>yes</literal>, three samples (instead of one) are used to determine 3302 the value of a received bit by majority rule. When unset, the kernel's default will be used.</para> 3303 </listitem> 3304 </varlistentry> 3305 <varlistentry> 3306 <term><varname>BusErrorReporting=</varname></term> 3307 <listitem> 3308 <para>Takes a boolean. When <literal>yes</literal>, reporting of CAN bus errors is activated 3309 (those include single bit, frame format, and bit stuffing errors, unable to send dominant bit, 3310 unable to send recessive bit, bus overload, active error announcement, error occurred on 3311 transmission). When unset, the kernel's default will be used. Note: in case of a CAN bus with a 3312 single CAN device, sending a CAN frame may result in a huge number of CAN bus errors.</para> 3313 </listitem> 3314 </varlistentry> 3315 <varlistentry> 3316 <term><varname>ListenOnly=</varname></term> 3317 <listitem> 3318 <para>Takes a boolean. When <literal>yes</literal>, listen-only mode is enabled. When the 3319 interface is in listen-only mode, the interface neither transmit CAN frames nor send ACK 3320 bit. Listen-only mode is important to debug CAN networks without interfering with the 3321 communication or acknowledge the CAN frame. When unset, the kernel's default will be used. 3322 </para> 3323 </listitem> 3324 </varlistentry> 3325 <varlistentry> 3326 <term><varname>Loopback=</varname></term> 3327 <listitem> 3328 <para>Takes a boolean. When <literal>yes</literal>, loopback mode is enabled. When the 3329 loopback mode is enabled, the interface treats messages transmitted by itself as received 3330 messages. The loopback mode is important to debug CAN networks. When unset, the kernel's 3331 default will be used.</para> 3332 </listitem> 3333 </varlistentry> 3334 <varlistentry> 3335 <term><varname>OneShot=</varname></term> 3336 <listitem> 3337 <para>Takes a boolean. When <literal>yes</literal>, one-shot mode is enabled. When unset, 3338 the kernel's default will be used.</para> 3339 </listitem> 3340 </varlistentry> 3341 <varlistentry> 3342 <term><varname>PresumeAck=</varname></term> 3343 <listitem> 3344 <para>Takes a boolean. When <literal>yes</literal>, the interface will ignore missing CAN 3345 ACKs. When unset, the kernel's default will be used.</para> 3346 </listitem> 3347 </varlistentry> 3348 <varlistentry> 3349 <term><varname>ClassicDataLengthCode=</varname></term> 3350 <listitem> 3351 <para>Takes a boolean. When <literal>yes</literal>, the interface will handle the 4bit data 3352 length code (DLC). When unset, the kernel's default will be used.</para> 3353 </listitem> 3354 </varlistentry> 3355 </variablelist> 3356 </refsect1> 3357 3358 <refsect1> 3359 <title>[IPoIB] Section Options</title> 3360 <para>The [IPoIB] section manages the IP over Infiniband and accepts the following keys:</para> 3361 <variablelist class='network-directives'> 3362 <xi:include href="systemd.netdev.xml" xpointer="ipoib_mode" /> 3363 <xi:include href="systemd.netdev.xml" xpointer="ipoib_umcast" /> 3364 </variablelist> 3365 </refsect1> 3366 3367 <refsect1> 3368 <title>[QDisc] Section Options</title> 3369 <para>The [QDisc] section manages the traffic control queueing discipline (qdisc).</para> 3370 3371 <variablelist class='network-directives'> 3372 <varlistentry> 3373 <term><varname>Parent=</varname></term> 3374 <listitem> 3375 <para>Specifies the parent Queueing Discipline (qdisc). Takes one of <literal>clsact</literal> 3376 or <literal>ingress</literal>. This is mandatory.</para> 3377 </listitem> 3378 </varlistentry> 3379 3380 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3381 </variablelist> 3382 </refsect1> 3383 3384 <refsect1> 3385 <title>[NetworkEmulator] Section Options</title> 3386 <para>The [NetworkEmulator] section manages the queueing discipline (qdisc) of the network emulator. It 3387 can be used to configure the kernel packet scheduler and simulate packet delay and loss for UDP or TCP 3388 applications, or limit the bandwidth usage of a particular service to simulate internet connections. 3389 </para> 3390 3391 <variablelist class='network-directives'> 3392 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3393 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3394 3395 <varlistentry> 3396 <term><varname>DelaySec=</varname></term> 3397 <listitem> 3398 <para>Specifies the fixed amount of delay to be added to all packets going out of the 3399 interface. Defaults to unset.</para> 3400 </listitem> 3401 </varlistentry> 3402 3403 <varlistentry> 3404 <term><varname>DelayJitterSec=</varname></term> 3405 <listitem> 3406 <para>Specifies the chosen delay to be added to the packets outgoing to the network 3407 interface. Defaults to unset.</para> 3408 </listitem> 3409 </varlistentry> 3410 3411 <varlistentry> 3412 <term><varname>PacketLimit=</varname></term> 3413 <listitem> 3414 <para>Specifies the maximum number of packets the qdisc may hold queued at a time. 3415 An unsigned integer in the range 0…4294967294. Defaults to 1000.</para> 3416 </listitem> 3417 </varlistentry> 3418 3419 <varlistentry> 3420 <term><varname>LossRate=</varname></term> 3421 <listitem> 3422 <para>Specifies an independent loss probability to be added to the packets outgoing from the 3423 network interface. Takes a percentage value, suffixed with "%". Defaults to unset.</para> 3424 </listitem> 3425 </varlistentry> 3426 3427 <varlistentry> 3428 <term><varname>DuplicateRate=</varname></term> 3429 <listitem> 3430 <para>Specifies that the chosen percent of packets is duplicated before queuing them. 3431 Takes a percentage value, suffixed with "%". Defaults to unset.</para> 3432 </listitem> 3433 </varlistentry> 3434 </variablelist> 3435 </refsect1> 3436 3437 <refsect1> 3438 <title>[TokenBucketFilter] Section Options</title> 3439 <para>The [TokenBucketFilter] section manages the queueing discipline (qdisc) of token bucket filter 3440 (tbf).</para> 3441 3442 <variablelist class='network-directives'> 3443 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3444 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3445 3446 <varlistentry> 3447 <term><varname>LatencySec=</varname></term> 3448 <listitem> 3449 <para>Specifies the latency parameter, which specifies the maximum amount of time a 3450 packet can sit in the Token Bucket Filter (TBF). Defaults to unset.</para> 3451 </listitem> 3452 </varlistentry> 3453 3454 <varlistentry> 3455 <term><varname>LimitBytes=</varname></term> 3456 <listitem> 3457 <para>Takes the number of bytes that can be queued waiting for tokens to become available. 3458 When the size is suffixed with K, M, or G, it is parsed as Kilobytes, Megabytes, or Gigabytes, 3459 respectively, to the base of 1024. Defaults to unset.</para> 3460 </listitem> 3461 </varlistentry> 3462 3463 <varlistentry> 3464 <term><varname>BurstBytes=</varname></term> 3465 <listitem> 3466 <para>Specifies the size of the bucket. This is the maximum amount of bytes that tokens 3467 can be available for instantaneous transfer. When the size is suffixed with K, M, or G, it is 3468 parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to 3469 unset.</para> 3470 </listitem> 3471 </varlistentry> 3472 3473 <varlistentry> 3474 <term><varname>Rate=</varname></term> 3475 <listitem> 3476 <para>Specifies the device specific bandwidth. When suffixed with K, M, or G, the specified 3477 bandwidth is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 1000. 3478 Defaults to unset.</para> 3479 </listitem> 3480 </varlistentry> 3481 3482 <varlistentry> 3483 <term><varname>MPUBytes=</varname></term> 3484 <listitem> 3485 <para>The Minimum Packet Unit (MPU) determines the minimal token usage (specified in bytes) 3486 for a packet. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, 3487 Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to zero.</para> 3488 </listitem> 3489 </varlistentry> 3490 3491 <varlistentry> 3492 <term><varname>PeakRate=</varname></term> 3493 <listitem> 3494 <para>Takes the maximum depletion rate of the bucket. When suffixed with K, M, or G, the 3495 specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 3496 1000. Defaults to unset.</para> 3497 </listitem> 3498 </varlistentry> 3499 3500 <varlistentry> 3501 <term><varname>MTUBytes=</varname></term> 3502 <listitem> 3503 <para>Specifies the size of the peakrate bucket. When suffixed with K, M, or G, the specified 3504 size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. 3505 Defaults to unset.</para> 3506 </listitem> 3507 </varlistentry> 3508 </variablelist> 3509 </refsect1> 3510 3511 <refsect1> 3512 <title>[PIE] Section Options</title> 3513 <para>The [PIE] section manages the queueing discipline (qdisc) of Proportional Integral 3514 controller-Enhanced (PIE).</para> 3515 3516 <variablelist class='network-directives'> 3517 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3518 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3519 3520 <varlistentry> 3521 <term><varname>PacketLimit=</varname></term> 3522 <listitem> 3523 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, 3524 incoming packets are dropped. An unsigned integer in the range 1…4294967294. Defaults to unset and 3525 kernel's default is used.</para> 3526 </listitem> 3527 </varlistentry> 3528 </variablelist> 3529 </refsect1> 3530 3531 <refsect1> 3532 <title>[FlowQueuePIE] Section Options</title> 3533 <para>The <literal>[FlowQueuePIE]</literal> section manages the queueing discipline 3534 (qdisc) of Flow Queue Proportional Integral controller-Enhanced (fq_pie).</para> 3535 3536 <variablelist class='network-directives'> 3537 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3538 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3539 3540 <varlistentry> 3541 <term><varname>PacketLimit=</varname></term> 3542 <listitem> 3543 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, 3544 incoming packets are dropped. An unsigned integer ranges 1 to 4294967294. Defaults to unset and 3545 kernel's default is used.</para> 3546 </listitem> 3547 </varlistentry> 3548 </variablelist> 3549 </refsect1> 3550 3551 <refsect1> 3552 <title>[StochasticFairBlue] Section Options</title> 3553 <para>The [StochasticFairBlue] section manages the queueing discipline (qdisc) of stochastic fair blue 3554 (sfb).</para> 3555 3556 <variablelist class='network-directives'> 3557 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3558 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3559 3560 <varlistentry> 3561 <term><varname>PacketLimit=</varname></term> 3562 <listitem> 3563 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, 3564 incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and 3565 kernel's default is used.</para> 3566 </listitem> 3567 </varlistentry> 3568 </variablelist> 3569 </refsect1> 3570 3571 <refsect1> 3572 <title>[StochasticFairnessQueueing] Section Options</title> 3573 <para>The [StochasticFairnessQueueing] section manages the queueing discipline (qdisc) of stochastic 3574 fairness queueing (sfq).</para> 3575 3576 <variablelist class='network-directives'> 3577 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3578 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3579 3580 <varlistentry> 3581 <term><varname>PerturbPeriodSec=</varname></term> 3582 <listitem> 3583 <para>Specifies the interval in seconds for queue algorithm perturbation. Defaults to unset.</para> 3584 </listitem> 3585 </varlistentry> 3586 </variablelist> 3587 </refsect1> 3588 3589 <refsect1> 3590 <title>[BFIFO] Section Options</title> 3591 <para>The [BFIFO] section manages the queueing discipline (qdisc) of Byte limited Packet First In First 3592 Out (bfifo).</para> 3593 3594 <variablelist class='network-directives'> 3595 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3596 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3597 3598 <varlistentry> 3599 <term><varname>LimitBytes=</varname></term> 3600 <listitem> 3601 <para>Specifies the hard limit in bytes on the FIFO buffer size. The size limit prevents overflow 3602 in case the kernel is unable to dequeue packets as quickly as it receives them. When this limit is 3603 reached, incoming packets are dropped. When suffixed with K, M, or G, the specified size is parsed 3604 as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and 3605 kernel default is used.</para> 3606 </listitem> 3607 </varlistentry> 3608 </variablelist> 3609 </refsect1> 3610 3611 <refsect1> 3612 <title>[PFIFO] Section Options</title> 3613 <para>The [PFIFO] section manages the queueing discipline (qdisc) of Packet First In First Out 3614 (pfifo).</para> 3615 3616 <variablelist class='network-directives'> 3617 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3618 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3619 3620 <varlistentry> 3621 <term><varname>PacketLimit=</varname></term> 3622 <listitem> 3623 <para>Specifies the hard limit on the number of packets in the FIFO queue. The size limit prevents 3624 overflow in case the kernel is unable to dequeue packets as quickly as it receives them. When this 3625 limit is reached, incoming packets are dropped. An unsigned integer in the range 3626 0…4294967294. Defaults to unset and kernel's default is used.</para> 3627 </listitem> 3628 </varlistentry> 3629 </variablelist> 3630 </refsect1> 3631 3632 <refsect1> 3633 <title>[PFIFOHeadDrop] Section Options</title> 3634 <para>The [PFIFOHeadDrop] section manages the queueing discipline (qdisc) of Packet First In First Out 3635 Head Drop (pfifo_head_drop).</para> 3636 3637 <variablelist class='network-directives'> 3638 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3639 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3640 3641 <varlistentry> 3642 <term><varname>PacketLimit=</varname></term> 3643 <listitem> 3644 <para>As in [PFIFO] section.</para></listitem> 3645 </varlistentry> 3646 </variablelist> 3647 </refsect1> 3648 3649 <refsect1> 3650 <title>[PFIFOFast] Section Options</title> 3651 <para>The [PFIFOFast] section manages the queueing discipline (qdisc) of Packet First In First Out Fast 3652 (pfifo_fast).</para> 3653 3654 <variablelist class='network-directives'> 3655 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3656 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3657 </variablelist> 3658 </refsect1> 3659 3660 <refsect1> 3661 <title>[CAKE] Section Options</title> 3662 <para>The [CAKE] section manages the queueing discipline (qdisc) of Common Applications Kept Enhanced 3663 (CAKE).</para> 3664 3665 <variablelist class='network-directives'> 3666 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3667 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3668 3669 <varlistentry> 3670 <term><varname>Bandwidth=</varname></term> 3671 <listitem> 3672 <para>Specifies the shaper bandwidth. When suffixed with K, M, or G, the specified size is 3673 parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 1000. Defaults to 3674 unset and kernel's default is used.</para> 3675 </listitem> 3676 </varlistentry> 3677 3678 <varlistentry> 3679 <term><varname>AutoRateIngress=</varname></term> 3680 <listitem> 3681 <para>Takes a boolean value. Enables automatic capacity estimation based on traffic arriving 3682 at this qdisc. This is most likely to be useful with cellular links, which tend to change 3683 quality randomly. If this setting is enabled, the <varname>Bandwidth=</varname> setting is 3684 used as an initial estimate. Defaults to unset, and the kernel's default is used.</para> 3685 </listitem> 3686 </varlistentry> 3687 3688 <varlistentry> 3689 <term><varname>OverheadBytes=</varname></term> 3690 <listitem> 3691 <para>Specifies that bytes to be addeded to the size of each packet. Bytes may be negative. 3692 Takes an integer in the range -64…256. Defaults to unset and kernel's default is used. 3693 </para> 3694 </listitem> 3695 </varlistentry> 3696 3697 <varlistentry> 3698 <term><varname>MPUBytes=</varname></term> 3699 <listitem> 3700 <para>Rounds each packet (including overhead) up to the specified bytes. Takes an integer in 3701 the range 1…256. Defaults to unset and kernel's default is used.</para> 3702 </listitem> 3703 </varlistentry> 3704 3705 <varlistentry> 3706 <term><varname>CompensationMode=</varname></term> 3707 <listitem> 3708 <para>Takes one of <literal>none</literal>, <literal>atm</literal>, or <literal>ptm</literal>. 3709 Specifies the compensation mode for overhead calculation. When <literal>none</literal>, no 3710 compensation is taken into account. When <literal>atm</literal>, enables the compensation for 3711 ATM cell framing, which is normally found on ADSL links. When <literal>ptm</literal>, enables 3712 the compensation for PTM encoding, which is normally found on VDSL2 links and uses a 64b/65b 3713 encoding scheme. Defaults to unset and the kernel's default is used.</para> 3714 </listitem> 3715 </varlistentry> 3716 3717 <varlistentry> 3718 <term><varname>UseRawPacketSize=</varname></term> 3719 <listitem> 3720 <para>Takes a boolean value. When true, the packet size reported by the Linux kernel will be 3721 used, instead of the underlying IP packet size. Defaults to unset, and the kernel's default 3722 is used.</para> 3723 </listitem> 3724 </varlistentry> 3725 3726 <varlistentry> 3727 <term><varname>FlowIsolationMode=</varname></term> 3728 <listitem> 3729 <para>CAKE places packets from different flows into different queues, then packets from each 3730 queue are delivered fairly. This specifies whether the fairness is based on source address, 3731 destination address, individual flows, or any combination of those. The available values are: 3732 </para> 3733 3734 <variablelist> 3735 <varlistentry> 3736 <term><option>none</option></term> 3737 <listitem><para> 3738 The flow isolation is disabled, and all traffic passes through a single queue. 3739 </para></listitem> 3740 </varlistentry> 3741 <varlistentry> 3742 <term><option>src-host</option></term> 3743 <listitem><para> 3744 Flows are defined only by source address. Equivalent to the <literal>srchost</literal> 3745 option for <command>tc qdisc</command> command. See also 3746 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3747 </para></listitem> 3748 </varlistentry> 3749 <varlistentry> 3750 <term><option>dst-host</option></term> 3751 <listitem><para> 3752 Flows are defined only by destination address. Equivalent to the 3753 <literal>dsthost</literal> option for <command>tc qdisc</command> command. See also 3754 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3755 </para></listitem> 3756 </varlistentry> 3757 <varlistentry> 3758 <term><option>hosts</option></term> 3759 <listitem><para> 3760 Flows are defined by source-destination host pairs. Equivalent to the same option for 3761 <command>tc qdisc</command> command. See also 3762 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3763 </para></listitem> 3764 </varlistentry> 3765 <varlistentry> 3766 <term><option>flows</option></term> 3767 <listitem><para> 3768 Flows are defined by the entire 5-tuple of source address, destination address, 3769 transport protocol, source port and destination port. Equivalent to the same option for 3770 <command>tc qdisc</command> command. See also 3771 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3772 </para></listitem> 3773 </varlistentry> 3774 <varlistentry> 3775 <term><option>dual-src-host</option></term> 3776 <listitem><para> 3777 Flows are defined by the 5-tuple (see <literal>flows</literal> in the above), and 3778 fairness is applied first over source addresses, then over individual flows. Equivalent 3779 to the <literal>dual-srchost</literal> option for <command>tc qdisc</command> command. 3780 See also 3781 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3782 </para></listitem> 3783 </varlistentry> 3784 <varlistentry> 3785 <term><option>dual-dst-host</option></term> 3786 <listitem><para> 3787 Flows are defined by the 5-tuple (see <literal>flows</literal> in the above), and 3788 fairness is applied first over destination addresses, then over individual flows. 3789 Equivalent to the <literal>dual-dsthost</literal> option for 3790 <command>tc qdisc</command> command. See also 3791 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3792 </para></listitem> 3793 </varlistentry> 3794 <varlistentry> 3795 <term><option>triple</option></term> 3796 <listitem><para> 3797 Flows are defined by the 5-tuple (see <literal>flows</literal>), and fairness is 3798 applied over source and destination addresses, and also over individual flows. 3799 Equivalent to the <literal>triple-isolate</literal> option for 3800 <command>tc qdisc</command> command. See also 3801 <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. 3802 </para></listitem> 3803 </varlistentry> 3804 </variablelist> 3805 3806 <para>Defaults to unset and the kernel's default is used.</para> 3807 </listitem> 3808 </varlistentry> 3809 3810 <varlistentry> 3811 <term><varname>NAT=</varname></term> 3812 <listitem> 3813 <para>Takes a boolean value. When true, CAKE performs a NAT lookup before applying 3814 flow-isolation rules, to determine the true addresses and port numbers of the packet, to 3815 improve fairness between hosts inside the NAT. This has no practical effect when 3816 <varname>FlowIsolationMode=</varname> is <literal>none</literal> or <literal>flows</literal>, 3817 or if NAT is performed on a different host. Defaults to unset, and the kernel's default is 3818 used.</para> 3819 </listitem> 3820 </varlistentry> 3821 3822 <varlistentry> 3823 <term><varname>PriorityQueueingPreset=</varname></term> 3824 <listitem> 3825 <para>CAKE divides traffic into <literal>tins</literal>, and each tin has its own independent 3826 set of flow-isolation queues, bandwidth threshold, and priority. This specifies the preset of 3827 tin profiles. The available values are:</para> 3828 3829 <variablelist> 3830 <varlistentry> 3831 <term><option>besteffort</option></term> 3832 <listitem><para> 3833 Disables priority queueing by placing all traffic in one tin. 3834 </para></listitem> 3835 </varlistentry> 3836 <varlistentry> 3837 <term><option>precedence</option></term> 3838 <listitem><para> 3839 Enables priority queueing based on the legacy interpretation of TOS 3840 <literal>Precedence</literal> field. Use of this preset on the modern Internet is 3841 firmly discouraged. 3842 </para></listitem> 3843 </varlistentry> 3844 <varlistentry> 3845 <term><option>diffserv8</option></term> 3846 <listitem><para> 3847 Enables priority queueing based on the Differentiated Service 3848 (<literal>DiffServ</literal>) field with eight tins: Background Traffic, High 3849 Throughput, Best Effort, Video Streaming, Low Latency Transactions, Interactive Shell, 3850 Minimum Latency, and Network Control. 3851 </para></listitem> 3852 </varlistentry> 3853 <varlistentry> 3854 <term><option>diffserv4</option></term> 3855 <listitem><para> 3856 Enables priority queueing based on the Differentiated Service 3857 (<literal>DiffServ</literal>) field with four tins: Background Traffic, Best Effort, 3858 Streaming Media, and Latency Sensitive. 3859 </para></listitem> 3860 </varlistentry> 3861 <varlistentry> 3862 <term><option>diffserv3</option></term> 3863 <listitem><para> 3864 Enables priority queueing based on the Differentiated Service 3865 (<literal>DiffServ</literal>) field with three tins: Background Traffic, Best Effort, 3866 and Latency Sensitive. 3867 </para></listitem> 3868 </varlistentry> 3869 </variablelist> 3870 3871 <para>Defaults to unset, and the kernel's default is used.</para> 3872 </listitem> 3873 </varlistentry> 3874 3875 <varlistentry> 3876 <term><varname>FirewallMark=</varname></term> 3877 <listitem> 3878 <para>Takes an integer in the range 1…4294967295. When specified, firewall-mark-based 3879 overriding of CAKE's tin selection is enabled. Defaults to unset, and the kernel's default is 3880 used.</para> 3881 </listitem> 3882 </varlistentry> 3883 3884 <varlistentry> 3885 <term><varname>Wash=</varname></term> 3886 <listitem> 3887 <para>Takes a boolean value. When true, CAKE clears the DSCP fields, except for ECN bits, of 3888 any packet passing through CAKE. Defaults to unset, and the kernel's default is used.</para> 3889 </listitem> 3890 </varlistentry> 3891 3892 <varlistentry> 3893 <term><varname>SplitGSO=</varname></term> 3894 <listitem> 3895 <para>Takes a boolean value. When true, CAKE will split General Segmentation Offload (GSO) 3896 super-packets into their on-the-wire components and dequeue them individually. Defaults to 3897 unset, and the kernel's default is used.</para> 3898 </listitem> 3899 </varlistentry> 3900 3901 </variablelist> 3902 </refsect1> 3903 3904 <refsect1> 3905 <title>[ControlledDelay] Section Options</title> 3906 <para>The [ControlledDelay] section manages the queueing discipline (qdisc) of 3907 controlled delay (CoDel).</para> 3908 3909 <variablelist class='network-directives'> 3910 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3911 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3912 3913 <varlistentry> 3914 <term><varname>PacketLimit=</varname></term> 3915 <listitem> 3916 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, 3917 incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and 3918 kernel's default is used.</para> 3919 </listitem> 3920 </varlistentry> 3921 3922 <varlistentry> 3923 <term><varname>TargetSec=</varname></term> 3924 <listitem> 3925 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay. 3926 Defaults to unset and kernel's default is used.</para> 3927 </listitem> 3928 </varlistentry> 3929 3930 <varlistentry> 3931 <term><varname>IntervalSec=</varname></term> 3932 <listitem> 3933 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not 3934 become too stale. Defaults to unset and kernel's default is used.</para> 3935 </listitem> 3936 </varlistentry> 3937 3938 <varlistentry> 3939 <term><varname>ECN=</varname></term> 3940 <listitem> 3941 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to 3942 unset and kernel's default is used.</para> 3943 </listitem> 3944 </varlistentry> 3945 3946 <varlistentry> 3947 <term><varname>CEThresholdSec=</varname></term> 3948 <listitem> 3949 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN 3950 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> 3951 </listitem> 3952 </varlistentry> 3953 </variablelist> 3954 </refsect1> 3955 3956 <refsect1> 3957 <title>[DeficitRoundRobinScheduler] Section Options</title> 3958 <para>The [DeficitRoundRobinScheduler] section manages the queueing discipline (qdisc) of Deficit Round 3959 Robin Scheduler (DRR).</para> 3960 3961 <variablelist class='network-directives'> 3962 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3963 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3964 </variablelist> 3965 </refsect1> 3966 3967 <refsect1> 3968 <title>[DeficitRoundRobinSchedulerClass] Section Options</title> 3969 <para>The [DeficitRoundRobinSchedulerClass] section manages the traffic control class of Deficit Round 3970 Robin Scheduler (DRR).</para> 3971 3972 <variablelist class='network-directives'> 3973 <xi:include href="tc.xml" xpointer="tclass-parent" /> 3974 <xi:include href="tc.xml" xpointer="tclass-classid" /> 3975 3976 <varlistentry> 3977 <term><varname>QuantumBytes=</varname></term> 3978 <listitem> 3979 <para>Specifies the amount of bytes a flow is allowed to dequeue before the scheduler moves 3980 to the next class. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, 3981 Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to the MTU of the 3982 interface.</para> 3983 </listitem> 3984 </varlistentry> 3985 3986 </variablelist> 3987 </refsect1> 3988 3989 <refsect1> 3990 <title>[EnhancedTransmissionSelection] Section Options</title> 3991 <para>The [EnhancedTransmissionSelection] section manages the queueing discipline (qdisc) of Enhanced 3992 Transmission Selection (ETS).</para> 3993 3994 <variablelist class='network-directives'> 3995 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 3996 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 3997 3998 <varlistentry> 3999 <term><varname>Bands=</varname></term> 4000 <listitem> 4001 <para>Specifies the number of bands. An unsigned integer in the range 1…16. This value has to be at 4002 least large enough to cover the strict bands specified through the <varname>StrictBands=</varname> 4003 and bandwidth-sharing bands specified in <varname>QuantumBytes=</varname>.</para> 4004 </listitem> 4005 </varlistentry> 4006 4007 <varlistentry> 4008 <term><varname>StrictBands=</varname></term> 4009 <listitem> 4010 <para>Specifies the number of bands that should be created in strict mode. An unsigned integer in 4011 the range 1…16.</para> 4012 </listitem> 4013 </varlistentry> 4014 4015 <varlistentry> 4016 <term><varname>QuantumBytes=</varname></term> 4017 <listitem> 4018 <para>Specifies the white-space separated list of quantum used in band-sharing bands. When 4019 suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, 4020 respectively, to the base of 1024. This setting can be specified multiple times. If an empty 4021 string is assigned, then the all previous assignments are cleared.</para> 4022 </listitem> 4023 </varlistentry> 4024 4025 <varlistentry> 4026 <term><varname>PriorityMap=</varname></term> 4027 <listitem> 4028 <para>The priority map maps the priority of a packet to a band. The argument is a whitespace 4029 separated list of numbers. The first number indicates which band the packets with priority 0 should 4030 be put to, the second is for priority 1, and so on. There can be up to 16 numbers in the list. If 4031 there are fewer, the default band that traffic with one of the unmentioned priorities goes to is 4032 the last one. Each band number must be in the range 0…255. This setting can be specified multiple 4033 times. If an empty string is assigned, then the all previous assignments are cleared.</para> 4034 </listitem> 4035 </varlistentry> 4036 </variablelist> 4037 </refsect1> 4038 4039 <refsect1> 4040 <title>[GenericRandomEarlyDetection] Section Options</title> 4041 <para>The [GenericRandomEarlyDetection] section manages the queueing discipline (qdisc) of Generic Random 4042 Early Detection (GRED).</para> 4043 4044 <variablelist class='network-directives'> 4045 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4046 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4047 4048 <varlistentry> 4049 <term><varname>VirtualQueues=</varname></term> 4050 <listitem> 4051 <para>Specifies the number of virtual queues. Takes an integer in the range 1…16. Defaults to unset 4052 and kernel's default is used.</para> 4053 </listitem> 4054 </varlistentry> 4055 4056 <varlistentry> 4057 <term><varname>DefaultVirtualQueue=</varname></term> 4058 <listitem> 4059 <para>Specifies the number of default virtual queue. This must be less than <varname>VirtualQueue=</varname>. 4060 Defaults to unset and kernel's default is used.</para> 4061 </listitem> 4062 </varlistentry> 4063 4064 <varlistentry> 4065 <term><varname>GenericRIO=</varname></term> 4066 <listitem> 4067 <para>Takes a boolean. It turns on the RIO-like buffering scheme. Defaults to 4068 unset and kernel's default is used.</para> 4069 </listitem> 4070 </varlistentry> 4071 </variablelist> 4072 </refsect1> 4073 4074 <refsect1> 4075 <title>[FairQueueingControlledDelay] Section Options</title> 4076 <para>The [FairQueueingControlledDelay] section manages the queueing discipline (qdisc) of fair queuing 4077 controlled delay (FQ-CoDel).</para> 4078 4079 <variablelist class='network-directives'> 4080 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4081 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4082 4083 <varlistentry> 4084 <term><varname>PacketLimit=</varname></term> 4085 <listitem> 4086 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are 4087 dropped. Defaults to unset and kernel's default is used.</para> 4088 </listitem> 4089 </varlistentry> 4090 4091 <varlistentry> 4092 <term><varname>MemoryLimitBytes=</varname></term> 4093 <listitem> 4094 <para>Specifies the limit on the total number of bytes that can be queued in this FQ-CoDel instance. 4095 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, 4096 respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para> 4097 </listitem> 4098 </varlistentry> 4099 4100 <varlistentry> 4101 <term><varname>Flows=</varname></term> 4102 <listitem> 4103 <para>Specifies the number of flows into which the incoming packets are classified. 4104 Defaults to unset and kernel's default is used.</para> 4105 </listitem> 4106 </varlistentry> 4107 4108 <varlistentry> 4109 <term><varname>TargetSec=</varname></term> 4110 <listitem> 4111 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay. 4112 Defaults to unset and kernel's default is used.</para> 4113 </listitem> 4114 </varlistentry> 4115 4116 <varlistentry> 4117 <term><varname>IntervalSec=</varname></term> 4118 <listitem> 4119 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not 4120 become too stale. Defaults to unset and kernel's default is used.</para> 4121 </listitem> 4122 </varlistentry> 4123 4124 <varlistentry> 4125 <term><varname>QuantumBytes=</varname></term> 4126 <listitem> 4127 <para>Specifies the number of bytes used as the "deficit" in the fair queuing algorithm timespan. 4128 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, 4129 respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para> 4130 </listitem> 4131 </varlistentry> 4132 4133 <varlistentry> 4134 <term><varname>ECN=</varname></term> 4135 <listitem> 4136 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to 4137 unset and kernel's default is used.</para> 4138 </listitem> 4139 </varlistentry> 4140 4141 <varlistentry> 4142 <term><varname>CEThresholdSec=</varname></term> 4143 <listitem> 4144 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN 4145 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> 4146 </listitem> 4147 </varlistentry> 4148 </variablelist> 4149 </refsect1> 4150 4151 <refsect1> 4152 <title>[FairQueueing] Section Options</title> 4153 <para>The [FairQueueing] section manages the queueing discipline (qdisc) of fair queue traffic policing 4154 (FQ).</para> 4155 4156 <variablelist class='network-directives'> 4157 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4158 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4159 4160 <varlistentry> 4161 <term><varname>PacketLimit=</varname></term> 4162 <listitem> 4163 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are 4164 dropped. Defaults to unset and kernel's default is used.</para> 4165 </listitem> 4166 </varlistentry> 4167 4168 <varlistentry> 4169 <term><varname>FlowLimit=</varname></term> 4170 <listitem> 4171 <para>Specifies the hard limit on the maximum number of packets queued per flow. Defaults to 4172 unset and kernel's default is used.</para> 4173 </listitem> 4174 </varlistentry> 4175 4176 <varlistentry> 4177 <term><varname>QuantumBytes=</varname></term> 4178 <listitem> 4179 <para>Specifies the credit per dequeue RR round, i.e. the amount of bytes a flow is allowed 4180 to dequeue at once. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, 4181 Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and kernel's 4182 default is used.</para> 4183 </listitem> 4184 </varlistentry> 4185 4186 <varlistentry> 4187 <term><varname>InitialQuantumBytes=</varname></term> 4188 <listitem> 4189 <para>Specifies the initial sending rate credit, i.e. the amount of bytes a new flow is 4190 allowed to dequeue initially. When suffixed with K, M, or G, the specified size is parsed as 4191 Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and 4192 kernel's default is used.</para> 4193 </listitem> 4194 </varlistentry> 4195 4196 <varlistentry> 4197 <term><varname>MaximumRate=</varname></term> 4198 <listitem> 4199 <para>Specifies the maximum sending rate of a flow. When suffixed with K, M, or G, the 4200 specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 4201 1000. Defaults to unset and kernel's default is used.</para> 4202 </listitem> 4203 </varlistentry> 4204 4205 <varlistentry> 4206 <term><varname>Buckets=</varname></term> 4207 <listitem> 4208 <para>Specifies the size of the hash table used for flow lookups. Defaults to unset and 4209 kernel's default is used.</para> 4210 </listitem> 4211 </varlistentry> 4212 4213 <varlistentry> 4214 <term><varname>OrphanMask=</varname></term> 4215 <listitem> 4216 <para>Takes an unsigned integer. For packets not owned by a socket, fq is able to mask a part 4217 of hash and reduce number of buckets associated with the traffic. Defaults to unset and 4218 kernel's default is used.</para> 4219 </listitem> 4220 </varlistentry> 4221 4222 <varlistentry> 4223 <term><varname>Pacing=</varname></term> 4224 <listitem> 4225 <para>Takes a boolean, and enables or disables flow pacing. Defaults to unset and kernel's 4226 default is used.</para> 4227 </listitem> 4228 </varlistentry> 4229 4230 <varlistentry> 4231 <term><varname>CEThresholdSec=</varname></term> 4232 <listitem> 4233 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN 4234 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> 4235 </listitem> 4236 </varlistentry> 4237 </variablelist> 4238 </refsect1> 4239 4240 <refsect1> 4241 <title>[TrivialLinkEqualizer] Section Options</title> 4242 <para>The [TrivialLinkEqualizer] section manages the queueing discipline (qdisc) of trivial link 4243 equalizer (teql).</para> 4244 4245 <variablelist class='network-directives'> 4246 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4247 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4248 4249 <varlistentry> 4250 <term><varname>Id=</varname></term> 4251 <listitem> 4252 <para>Specifies the interface ID <literal>N</literal> of teql. Defaults to <literal>0</literal>. 4253 Note that when teql is used, currently, the module <constant>sch_teql</constant> with 4254 <constant>max_equalizers=N+1</constant> option must be loaded before 4255 <command>systemd-networkd</command> is started.</para> 4256 </listitem> 4257 </varlistentry> 4258 </variablelist> 4259 </refsect1> 4260 4261 <refsect1> 4262 <title>[HierarchyTokenBucket] Section Options</title> 4263 <para>The [HierarchyTokenBucket] section manages the queueing discipline (qdisc) of hierarchy token 4264 bucket (htb).</para> 4265 4266 <variablelist class='network-directives'> 4267 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4268 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4269 4270 <varlistentry> 4271 <term><varname>DefaultClass=</varname></term> 4272 <listitem> 4273 <para>Takes the minor id in hexadecimal of the default class. Unclassified traffic gets sent 4274 to the class. Defaults to unset.</para> 4275 </listitem> 4276 </varlistentry> 4277 4278 <varlistentry> 4279 <term><varname>RateToQuantum=</varname></term> 4280 <listitem> 4281 <para>Takes an unsigned integer. The DRR quantums are calculated by dividing the value 4282 configured in <varname>Rate=</varname> by <varname>RateToQuantum=</varname>.</para> 4283 </listitem> 4284 </varlistentry> 4285 </variablelist> 4286 </refsect1> 4287 4288 <refsect1> 4289 <title>[HierarchyTokenBucketClass] Section Options</title> 4290 <para>The [HierarchyTokenBucketClass] section manages the traffic control class of hierarchy token bucket 4291 (htb).</para> 4292 4293 <variablelist class='network-directives'> 4294 <xi:include href="tc.xml" xpointer="tclass-parent" /> 4295 <xi:include href="tc.xml" xpointer="tclass-classid" /> 4296 4297 <varlistentry> 4298 <term><varname>Priority=</varname></term> 4299 <listitem> 4300 <para>Specifies the priority of the class. In the round-robin process, classes with the lowest 4301 priority field are tried for packets first.</para> 4302 </listitem> 4303 </varlistentry> 4304 4305 <varlistentry> 4306 <term><varname>QuantumBytes=</varname></term> 4307 <listitem> 4308 <para>Specifies how many bytes to serve from leaf at once. When suffixed with K, M, or G, the 4309 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 4310 1024.</para> 4311 </listitem> 4312 </varlistentry> 4313 4314 <varlistentry> 4315 <term><varname>MTUBytes=</varname></term> 4316 <listitem> 4317 <para>Specifies the maximum packet size we create. When suffixed with K, M, or G, the specified 4318 size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024.</para> 4319 </listitem> 4320 </varlistentry> 4321 4322 <varlistentry> 4323 <term><varname>OverheadBytes=</varname></term> 4324 <listitem> 4325 <para>Takes an unsigned integer which specifies per-packet size overhead used in rate 4326 computations. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, 4327 Megabytes, or Gigabytes, respectively, to the base of 1024.</para> 4328 </listitem> 4329 </varlistentry> 4330 4331 <varlistentry> 4332 <term><varname>Rate=</varname></term> 4333 <listitem> 4334 <para>Specifies the maximum rate this class and all its children are guaranteed. When suffixed 4335 with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, 4336 to the base of 1000. This setting is mandatory.</para> 4337 </listitem> 4338 </varlistentry> 4339 4340 <varlistentry> 4341 <term><varname>CeilRate=</varname></term> 4342 <listitem> 4343 <para>Specifies the maximum rate at which a class can send, if its parent has bandwidth to spare. 4344 When suffixed with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits, 4345 respectively, to the base of 1000. When unset, the value specified with <varname>Rate=</varname> 4346 is used.</para> 4347 </listitem> 4348 </varlistentry> 4349 4350 <varlistentry> 4351 <term><varname>BufferBytes=</varname></term> 4352 <listitem> 4353 <para>Specifies the maximum bytes burst which can be accumulated during idle period. When suffixed 4354 with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, 4355 to the base of 1024.</para> 4356 </listitem> 4357 </varlistentry> 4358 4359 <varlistentry> 4360 <term><varname>CeilBufferBytes=</varname></term> 4361 <listitem> 4362 <para>Specifies the maximum bytes burst for ceil which can be accumulated during idle period. 4363 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, 4364 respectively, to the base of 1024.</para> 4365 </listitem> 4366 </varlistentry> 4367 </variablelist> 4368 </refsect1> 4369 4370 <refsect1> 4371 <title>[HeavyHitterFilter] Section Options</title> 4372 <para>The [HeavyHitterFilter] section manages the queueing discipline (qdisc) of Heavy Hitter Filter 4373 (hhf).</para> 4374 4375 <variablelist class='network-directives'> 4376 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4377 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4378 4379 <varlistentry> 4380 <term><varname>PacketLimit=</varname></term> 4381 <listitem> 4382 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, 4383 incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and 4384 kernel's default is used.</para> 4385 </listitem> 4386 </varlistentry> 4387 </variablelist> 4388 </refsect1> 4389 4390 <refsect1> 4391 <title>[QuickFairQueueing] Section Options</title> 4392 <para>The [QuickFairQueueing] section manages the queueing discipline (qdisc) of Quick Fair Queueing 4393 (QFQ).</para> 4394 4395 <variablelist class='network-directives'> 4396 <xi:include href="tc.xml" xpointer="qdisc-parent" /> 4397 <xi:include href="tc.xml" xpointer="qdisc-handle" /> 4398 </variablelist> 4399 </refsect1> 4400 4401 <refsect1> 4402 <title>[QuickFairQueueingClass] Section Options</title> 4403 <para>The [QuickFairQueueingClass] section manages the traffic control class of Quick Fair Queueing 4404 (qfq).</para> 4405 4406 <variablelist class='network-directives'> 4407 <xi:include href="tc.xml" xpointer="tclass-parent" /> 4408 <xi:include href="tc.xml" xpointer="tclass-classid" /> 4409 4410 <varlistentry> 4411 <term><varname>Weight=</varname></term> 4412 <listitem> 4413 <para>Specifies the weight of the class. Takes an integer in the range 1…1023. Defaults to 4414 unset in which case the kernel default is used.</para> 4415 </listitem> 4416 </varlistentry> 4417 4418 <varlistentry> 4419 <term><varname>MaxPacketBytes=</varname></term> 4420 <listitem> 4421 <para>Specifies the maximum packet size in bytes for the class. When suffixed with K, M, or G, the 4422 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 4423 1024. When unset, the kernel default is used.</para> 4424 </listitem> 4425 </varlistentry> 4426 </variablelist> 4427 </refsect1> 4428 4429 <refsect1> 4430 <title>[BridgeVLAN] Section Options</title> 4431 <para>The [BridgeVLAN] section manages the VLAN ID configuration of a bridge port and accepts the 4432 following keys. Specify several [BridgeVLAN] sections to configure several VLAN entries. The 4433 <varname>VLANFiltering=</varname> option has to be enabled, see the [Bridge] section in 4434 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> 4435 4436 <variablelist class='network-directives'> 4437 <varlistentry> 4438 <term><varname>VLAN=</varname></term> 4439 <listitem> 4440 <para>The VLAN ID allowed on the port. This can be either a single ID or a range M-N. Takes 4441 an integer in the range 1…4094.</para> 4442 </listitem> 4443 </varlistentry> 4444 <varlistentry> 4445 <term><varname>EgressUntagged=</varname></term> 4446 <listitem> 4447 <para>The VLAN ID specified here will be used to untag frames on egress. Configuring 4448 <varname>EgressUntagged=</varname> implicates the use of <varname>VLAN=</varname> above and will enable the 4449 VLAN ID for ingress as well. This can be either a single ID or a range M-N.</para> 4450 </listitem> 4451 </varlistentry> 4452 <varlistentry> 4453 <term><varname>PVID=</varname></term> 4454 <listitem> 4455 <para>The Port VLAN ID specified here is assigned to all untagged frames at ingress. 4456 <varname>PVID=</varname> can be used only once. Configuring <varname>PVID=</varname> implicates the use of 4457 <varname>VLAN=</varname> above and will enable the VLAN ID for ingress as well.</para> 4458 </listitem> 4459 </varlistentry> 4460 </variablelist> 4461 </refsect1> 4462 4463 <refsect1> 4464 <title>Examples</title> 4465 <example> 4466 <title>Static network configuration</title> 4467 4468 <programlisting># /etc/systemd/network/50-static.network 4469[Match] 4470Name=enp2s0 4471 4472[Network] 4473Address=192.168.0.15/24 4474Gateway=192.168.0.1</programlisting> 4475 4476 <para>This brings interface <literal>enp2s0</literal> up with a static address. The 4477 specified gateway will be used for a default route.</para> 4478 </example> 4479 4480 <example> 4481 <title>DHCP on ethernet links</title> 4482 4483 <programlisting># /etc/systemd/network/80-dhcp.network 4484[Match] 4485Name=en* 4486 4487[Network] 4488DHCP=yes</programlisting> 4489 4490 <para>This will enable DHCPv4 and DHCPv6 on all interfaces with names starting with 4491 <literal>en</literal> (i.e. ethernet interfaces).</para> 4492 </example> 4493 4494 <example> 4495 <title>IPv6 Prefix Delegation (DHCPv6 PD)</title> 4496 4497 <programlisting># /etc/systemd/network/55-dhcpv6-pd-upstream.network 4498[Match] 4499Name=enp1s0 4500 4501[Network] 4502DHCP=ipv6 4503 4504# The below setting is optional, to also assign an address in the delegated prefix 4505# to the upstream interface. If not necessary, then comment out the line below and 4506# the [DHCPPrefixDelegation] section. 4507DHCPPrefixDelegation=yes 4508 4509# If the upstream network provides Router Advertisement with Managed bit set, 4510# then comment out the line below and WithoutRA= setting in the [DHCPv6] section. 4511IPv6AcceptRA=no 4512 4513[DHCPv6] 4514WithoutRA=solicit 4515 4516[DHCPPrefixDelegation] 4517UplinkInterface=:self 4518SubnetId=0 4519Announce=no</programlisting> 4520 4521 <programlisting># /etc/systemd/network/55-dhcpv6-pd-downstream.network 4522[Match] 4523Name=enp2s0 4524 4525[Network] 4526DHCPPrefixDelegation=yes 4527IPv6SendRA=yes 4528 4529# It is expected that the host is acting as a router. So, usually it is not 4530# necessary to receive Router Advertisement from other hosts in the downstream network. 4531IPv6AcceptRA=no 4532 4533[DHCPPrefixDelegation] 4534UplinkInterface=enp1s0 4535SubnetId=1 4536Announce=yes</programlisting> 4537 4538 <para>This will enable DHCPv6-PD on the interface enp1s0 as an upstream interface where the 4539 DHCPv6 client is running and enp2s0 as a downstream interface where the prefix is delegated to. 4540 The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network. 4541 </para> 4542 </example> 4543 4544 <example> 4545 <title>IPv6 Prefix Delegation (DHCPv4 6RD)</title> 4546 4547 <programlisting># /etc/systemd/network/55-dhcpv4-6rd-upstream.network 4548[Match] 4549Name=enp1s0 4550 4551[Network] 4552DHCP=ipv4 4553 4554# When DHCPv4-6RD is used, the upstream network does not support IPv6. 4555# Hence, it is not necessary to wait for Router Advertisement, which is enabled by default. 4556IPv6AcceptRA=no 4557 4558[DHCPv4] 4559Use6RD=yes</programlisting> 4560 4561 <programlisting># /etc/systemd/network/55-dhcpv4-6rd-downstream.network 4562[Match] 4563Name=enp2s0 4564 4565[Network] 4566DHCPPrefixDelegation=yes 4567IPv6SendRA=yes 4568 4569# It is expected that the host is acting as a router. So, usually it is not 4570# necessary to receive Router Advertisement from other hosts in the downstream network. 4571IPv6AcceptRA=no 4572 4573[DHCPPrefixDelegation] 4574UplinkInterface=enp1s0 4575SubnetId=1 4576Announce=yes</programlisting> 4577 4578 <para>This will enable DHCPv4-6RD on the interface enp1s0 as an upstream interface where the 4579 DHCPv4 client is running and enp2s0 as a downstream interface where the prefix is delegated to. 4580 The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network. 4581 </para> 4582 </example> 4583 4584 <example> 4585 <title>A bridge with two enslaved links</title> 4586 4587 <programlisting># /etc/systemd/network/25-bridge-static.network 4588[Match] 4589Name=bridge0 4590 4591[Network] 4592Address=192.168.0.15/24 4593Gateway=192.168.0.1 4594DNS=192.168.0.1</programlisting> 4595 4596 <programlisting># /etc/systemd/network/25-bridge-slave-interface-1.network 4597[Match] 4598Name=enp2s0 4599 4600[Network] 4601Bridge=bridge0</programlisting> 4602 4603 <programlisting># /etc/systemd/network/25-bridge-slave-interface-2.network 4604[Match] 4605Name=wlp3s0 4606 4607[Network] 4608Bridge=bridge0</programlisting> 4609 4610 <para>This creates a bridge and attaches devices <literal>enp2s0</literal> and 4611 <literal>wlp3s0</literal> to it. The bridge will have the specified static address 4612 and network assigned, and a default route via the specified gateway will be 4613 added. The specified DNS server will be added to the global list of DNS resolvers. 4614 </para> 4615 </example> 4616 4617 <example> 4618 <title>Bridge port with VLAN forwarding</title> 4619 4620 <programlisting> 4621# /etc/systemd/network/25-bridge-slave-interface-1.network 4622[Match] 4623Name=enp2s0 4624 4625[Network] 4626Bridge=bridge0 4627 4628[BridgeVLAN] 4629VLAN=1-32 4630PVID=42 4631EgressUntagged=42 4632 4633[BridgeVLAN] 4634VLAN=100-200 4635 4636[BridgeVLAN] 4637EgressUntagged=300-400</programlisting> 4638 4639 <para>This overrides the configuration specified in the previous example for the 4640 interface <literal>enp2s0</literal>, and enables VLAN on that bridge port. VLAN IDs 4641 1-32, 42, 100-400 will be allowed. Packets tagged with VLAN IDs 42, 300-400 will be 4642 untagged when they leave on this interface. Untagged packets which arrive on this 4643 interface will be assigned VLAN ID 42.</para> 4644 </example> 4645 4646 <example> 4647 <title>Various tunnels</title> 4648 4649 <programlisting>/etc/systemd/network/25-tunnels.network 4650[Match] 4651Name=ens1 4652 4653[Network] 4654Tunnel=ipip-tun 4655Tunnel=sit-tun 4656Tunnel=gre-tun 4657Tunnel=vti-tun 4658 </programlisting> 4659 4660 <programlisting>/etc/systemd/network/25-tunnel-ipip.netdev 4661[NetDev] 4662Name=ipip-tun 4663Kind=ipip 4664 </programlisting> 4665 4666 <programlisting>/etc/systemd/network/25-tunnel-sit.netdev 4667[NetDev] 4668Name=sit-tun 4669Kind=sit 4670 </programlisting> 4671 4672 <programlisting>/etc/systemd/network/25-tunnel-gre.netdev 4673[NetDev] 4674Name=gre-tun 4675Kind=gre 4676 </programlisting> 4677 4678 <programlisting>/etc/systemd/network/25-tunnel-vti.netdev 4679[NetDev] 4680Name=vti-tun 4681Kind=vti 4682 </programlisting> 4683 4684 <para>This will bring interface <literal>ens1</literal> up and create an IPIP tunnel, 4685 a SIT tunnel, a GRE tunnel, and a VTI tunnel using it.</para> 4686 </example> 4687 4688 <example> 4689 <title>A bond device</title> 4690 4691 <programlisting># /etc/systemd/network/30-bond1.network 4692[Match] 4693Name=bond1 4694 4695[Network] 4696DHCP=ipv6 4697</programlisting> 4698 4699 <programlisting># /etc/systemd/network/30-bond1.netdev 4700[NetDev] 4701Name=bond1 4702Kind=bond 4703</programlisting> 4704 4705 <programlisting># /etc/systemd/network/30-bond1-dev1.network 4706[Match] 4707MACAddress=52:54:00:e9:64:41 4708 4709[Network] 4710Bond=bond1 4711</programlisting> 4712 4713 <programlisting># /etc/systemd/network/30-bond1-dev2.network 4714[Match] 4715MACAddress=52:54:00:e9:64:42 4716 4717[Network] 4718Bond=bond1 4719</programlisting> 4720 4721 <para>This will create a bond device <literal>bond1</literal> and enslave the two 4722 devices with MAC addresses 52:54:00:e9:64:41 and 52:54:00:e9:64:42 to it. IPv6 DHCP 4723 will be used to acquire an address.</para> 4724 </example> 4725 4726 <example> 4727 <title>Virtual Routing and Forwarding (VRF)</title> 4728 <para>Add the <literal>bond1</literal> interface to the VRF master interface 4729 <literal>vrf1</literal>. This will redirect routes generated on this interface to be 4730 within the routing table defined during VRF creation. For kernels before 4.8 traffic 4731 won't be redirected towards the VRFs routing table unless specific ip-rules are added. 4732 </para> 4733 <programlisting># /etc/systemd/network/25-vrf.network 4734[Match] 4735Name=bond1 4736 4737[Network] 4738VRF=vrf1 4739</programlisting> 4740 </example> 4741 4742 <example> 4743 <title>MacVTap</title> 4744 <para>This brings up a network interface <literal>macvtap-test</literal> 4745 and attaches it to <literal>enp0s25</literal>.</para> 4746 <programlisting># /usr/lib/systemd/network/25-macvtap.network 4747[Match] 4748Name=enp0s25 4749 4750[Network] 4751MACVTAP=macvtap-test 4752</programlisting> 4753 </example> 4754 4755 <example> 4756 <title>A Xfrm interface with physical underlying device.</title> 4757 4758 <programlisting># /etc/systemd/network/27-xfrm.netdev 4759[NetDev] 4760Name=xfrm0 4761Kind=xfrm 4762 4763[Xfrm] 4764InterfaceId=7</programlisting> 4765 4766 <programlisting># /etc/systemd/network/27-eth0.network 4767[Match] 4768Name=eth0 4769 4770[Network] 4771Xfrm=xfrm0</programlisting> 4772 4773 <para>This creates a <literal>xfrm0</literal> interface and binds it to the <literal>eth0</literal> device. 4774 This allows hardware based ipsec offloading to the <literal>eth0</literal> nic. 4775 If offloading is not needed, xfrm interfaces can be assigned to the <literal>lo</literal> device. 4776 </para> 4777 </example> 4778 </refsect1> 4779 4780 <refsect1> 4781 <title>See Also</title> 4782 <para> 4783 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, 4784 <citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, 4785 <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>, 4786 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>, 4787 <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, 4788 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> 4789 </para> 4790 </refsect1> 4791 4792</refentry> 4793