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