]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/systemd.network.xml
Merge pull request #14448 from yuwata/network-permanent-mac-address
[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+ -->
5
6 <refentry id="systemd.network" conditional='ENABLE_NETWORKD'>
7
8 <refentryinfo>
9 <title>systemd.network</title>
10 <productname>systemd</productname>
11 </refentryinfo>
12
13 <refmeta>
14 <refentrytitle>systemd.network</refentrytitle>
15 <manvolnum>5</manvolnum>
16 </refmeta>
17
18 <refnamediv>
19 <refname>systemd.network</refname>
20 <refpurpose>Network configuration</refpurpose>
21 </refnamediv>
22
23 <refsynopsisdiv>
24 <para><filename><replaceable>network</replaceable>.network</filename></para>
25 </refsynopsisdiv>
26
27 <refsect1>
28 <title>Description</title>
29
30 <para>Network setup is performed by
31 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
32 </para>
33
34 <para>The main network file must have the extension <filename>.network</filename>; other
35 extensions are ignored. Networks are applied to links whenever the links appear.</para>
36
37 <para>The <filename>.network</filename> files are read from the files located in the system network
38 directories <filename>/usr/lib/systemd/network</filename> and
39 <filename>/usr/local/lib/systemd/network</filename>, the volatile runtime network directory
40 <filename>/run/systemd/network</filename> and the local administration network directory
41 <filename>/etc/systemd/network</filename>. All configuration files are collectively sorted and processed
42 in lexical order, regardless of the directories in which they live. However, files with identical
43 filenames replace each other. Files in <filename>/etc</filename> have the highest priority, files in
44 <filename>/run</filename> take precedence over files with the same name under
45 <filename>/usr</filename>. This can be used to override a system-supplied configuration file with a local
46 file if needed. As a special case, an empty file (file size 0) or symlink with the same name pointing to
47 <filename>/dev/null</filename> disables the configuration file entirely (it is "masked").</para>
48
49 <para>Along with the network file <filename>foo.network</filename>, a "drop-in" directory
50 <filename>foo.network.d/</filename> may exist. All files with the suffix
51 <literal>.conf</literal> from this directory will be parsed after the file itself is
52 parsed. This is useful to alter or add configuration settings, without having to modify the main
53 configuration file. Each drop-in file must have appropriate section headers.</para>
54
55 <para>In addition to <filename>/etc/systemd/network</filename>, drop-in <literal>.d</literal>
56 directories can be placed in <filename>/usr/lib/systemd/network</filename> or
57 <filename>/run/systemd/network</filename> directories. Drop-in files in
58 <filename>/etc</filename> take precedence over those in <filename>/run</filename> which in turn
59 take precedence over those in <filename>/usr/lib</filename>. Drop-in files under any of these
60 directories take precedence over the main network file wherever located.</para>
61
62 <para>Note that an interface without any static IPv6 addresses configured, and neither DHCPv6
63 nor IPv6LL enabled, shall be considered to have no IPv6 support. IPv6 will be automatically
64 disabled for that interface by writing "1" to
65 <filename>/proc/sys/net/ipv6/conf/<replaceable>ifname</replaceable>/disable_ipv6</filename>.
66 </para>
67 </refsect1>
68
69 <refsect1>
70 <title>[Match] Section Options</title>
71
72 <para>The network file contains a <literal>[Match]</literal>
73 section, which determines if a given network file may be applied
74 to a given device; and a <literal>[Network]</literal> section
75 specifying how the device should be configured. The first (in
76 lexical order) of the network files that matches a given device
77 is applied, all later files are ignored, even if they match as
78 well.</para>
79
80 <para>A network file is said to match a network interface if all matches specified by the
81 <literal>[Match]</literal> section are satisfied. When a network file does not contain valid
82 settings in <literal>[Match]</literal> section, then the file will match all interfaces and
83 <command>systemd-networkd</command> warns about that. Hint: to avoid the warning and to make it
84 clear that all interfaces shall be matched, add the following:
85 <programlisting>Name=*</programlisting>
86 The following keys are accepted:</para>
87
88 <variablelist class='network-directives'>
89 <varlistentry>
90 <term><varname>MACAddress=</varname></term>
91 <listitem>
92 <para>A whitespace-separated list of hardware addresses. Use full colon-, hyphen- or dot-delimited hexadecimal. See the example below.
93 This option may appear more than once, in which case the lists are merged. If the empty string is assigned to this option, the list
94 of hardware addresses defined prior to this is reset.</para>
95
96 <para>Example:
97 <programlisting>MACAddress=01:23:45:67:89:ab 00-11-22-33-44-55 AABB.CCDD.EEFF</programlisting></para>
98 </listitem>
99 </varlistentry>
100 <varlistentry>
101 <term><varname>PermanentMACAddress=</varname></term>
102 <listitem>
103 <para>A whitespace-separated list of hardware's permanent addresses. While
104 <varname>MACAddress=</varname> matches the device's current MAC address, this matches the
105 device's permanent MAC address, which may be different from the current one. Use full
106 colon-, hyphen- or dot-delimited hexadecimal. This option may appear more than once, in
107 which case the lists are merged. If the empty string is assigned to this option, the list
108 of hardware addresses defined prior to this is reset.</para>
109 </listitem>
110 </varlistentry>
111 <varlistentry>
112 <term><varname>Path=</varname></term>
113 <listitem>
114 <para>A whitespace-separated list of shell-style globs
115 matching the persistent path, as exposed by the udev
116 property <literal>ID_PATH</literal>. If the list is
117 prefixed with a "!", the test is inverted; i.e. it is
118 true when <literal>ID_PATH</literal> does not match any
119 item in the list.</para>
120 </listitem>
121 </varlistentry>
122 <varlistentry>
123 <term><varname>Driver=</varname></term>
124 <listitem>
125 <para>A whitespace-separated list of shell-style globs
126 matching the driver currently bound to the device, as
127 exposed by the udev property <literal>ID_NET_DRIVER</literal>
128 of its parent device, or if that is not set the driver
129 as exposed by <literal>ethtool -i</literal> of the
130 device itself. If the list is prefixed with a "!", the
131 test is inverted.</para>
132 </listitem>
133 </varlistentry>
134 <varlistentry>
135 <term><varname>Type=</varname></term>
136 <listitem>
137 <para>A whitespace-separated list of shell-style globs
138 matching the device type, as exposed by the udev property
139 <literal>DEVTYPE</literal>. If the list is prefixed with
140 a "!", the test is inverted.</para>
141 </listitem>
142 </varlistentry>
143 <varlistentry>
144 <term><varname>Name=</varname></term>
145 <listitem>
146 <para>A whitespace-separated list of shell-style globs matching the device name, as exposed
147 by the udev property <literal>INTERFACE</literal>, or device's alternative names. If the
148 list is prefixed with a "!", the test is inverted.</para>
149 </listitem>
150 </varlistentry>
151 <varlistentry>
152 <term><varname>Property=</varname></term>
153 <listitem>
154 <para>A whitespace-separated list of udev property name with its value after a equal
155 (<literal>=</literal>). If multiple properties are specified, the test results are ANDed.
156 If the list is prefixed with a "!", the test is inverted. If a value contains white
157 spaces, then please quote whole key and value pair. If a value contains quotation, then
158 please escape the quotation with <literal>\</literal>.</para>
159
160 <para>Example: if a .network file has the following:
161 <programlisting>Property=ID_MODEL_ID=9999 "ID_VENDOR_FROM_DATABASE=vendor name" "KEY=with \"quotation\""</programlisting>
162 then, the .network file matches only when an interface has all the above three properties.
163 </para>
164 </listitem>
165 </varlistentry>
166 <varlistentry>
167 <term><varname>WLANInterfaceType=</varname></term>
168 <listitem>
169 <para>A whitespace-separated list of wireless network type. Supported values are
170 <literal>ad-hoc</literal>, <literal>station</literal>, <literal>ap</literal>,
171 <literal>ap-vlan</literal>, <literal>wds</literal>, <literal>monitor</literal>,
172 <literal>mesh-point</literal>, <literal>p2p-client</literal>, <literal>p2p-go</literal>,
173 <literal>p2p-device</literal>, <literal>ocb</literal>, and <literal>nan</literal>. If the
174 list is prefixed with a "!", the test is inverted.
175 </para>
176 </listitem>
177 </varlistentry>
178 <varlistentry>
179 <term><varname>SSID=</varname></term>
180 <listitem>
181 <para>A whitespace-separated list of shell-style globs matching the SSID of the currently
182 connected wireless LAN. If the list is prefixed with a "!", the test is inverted.
183 </para>
184 </listitem>
185 </varlistentry>
186 <varlistentry>
187 <term><varname>BSSID=</varname></term>
188 <listitem>
189 <para>A whitespace-separated list of hardware address of the currently connected wireless
190 LAN. Use full colon-, hyphen- or dot-delimited hexadecimal. See the example in
191 <varname>MACAddress=</varname>. This option may appear more than one, in which case the
192 lists are merged. If the empty string is assigned to this option, the list of BSSID defined
193 prior to this is reset.</para>
194 </listitem>
195 </varlistentry>
196 <varlistentry>
197 <term><varname>Host=</varname></term>
198 <listitem>
199 <para>Matches against the hostname or machine ID of the host. See
200 <literal>ConditionHost=</literal> in
201 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
202 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
203 If an empty string is assigned, then previously assigned value is cleared.
204 </para>
205 </listitem>
206 </varlistentry>
207 <varlistentry>
208 <term><varname>Virtualization=</varname></term>
209 <listitem>
210 <para>Checks whether the system is executed in a virtualized environment and optionally test
211 whether it is a specific implementation. See <literal>ConditionVirtualization=</literal> in
212 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
213 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
214 If an empty string is assigned, then previously assigned value is cleared.
215 </para>
216 </listitem>
217 </varlistentry>
218 <varlistentry>
219 <term><varname>KernelCommandLine=</varname></term>
220 <listitem>
221 <para>Checks whether a specific kernel command line option is set. See
222 <literal>ConditionKernelCommandLine=</literal> in
223 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
224 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
225 If an empty string is assigned, then previously assigned value is cleared.
226 </para>
227 </listitem>
228 </varlistentry>
229 <varlistentry>
230 <term><varname>KernelVersion=</varname></term>
231 <listitem>
232 <para>Checks whether the kernel version (as reported by <command>uname -r</command>) matches a
233 certain expression. See <literal>ConditionKernelVersion=</literal> in
234 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
235 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
236 If an empty string is assigned, then previously assigned value is cleared.
237 </para>
238 </listitem>
239 </varlistentry>
240 <varlistentry>
241 <term><varname>Architecture=</varname></term>
242 <listitem>
243 <para>Checks whether the system is running on a specific architecture. See
244 <literal>ConditionArchitecture=</literal> in
245 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
246 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
247 If an empty string is assigned, then previously assigned value is cleared.
248 </para>
249 </listitem>
250 </varlistentry>
251 </variablelist>
252
253 </refsect1>
254
255 <refsect1>
256 <title>[Link] Section Options</title>
257
258 <para> The <literal>[Link]</literal> section accepts the following keys:</para>
259
260 <variablelist class='network-directives'>
261 <varlistentry>
262 <term><varname>MACAddress=</varname></term>
263 <listitem>
264 <para>The hardware address to set for the device.</para>
265 </listitem>
266 </varlistentry>
267 <varlistentry>
268 <term><varname>MTUBytes=</varname></term>
269 <listitem>
270 <para>The maximum transmission unit in bytes to set for the
271 device. The usual suffixes K, M, G, are supported and are
272 understood to the base of 1024.</para>
273 <para>Note that if IPv6 is enabled on the interface, and the MTU is chosen
274 below 1280 (the minimum MTU for IPv6) it will automatically be increased to this value.</para>
275 </listitem>
276 </varlistentry>
277 <varlistentry>
278 <term><varname>ARP=</varname></term>
279 <listitem>
280 <para>Takes a boolean. If set to true, the ARP (low-level Address Resolution Protocol)
281 for this interface is enabled. When unset, the kernel's default will be used.</para>
282 <para> For example, disabling ARP is useful when creating multiple MACVLAN or VLAN virtual
283 interfaces atop a single lower-level physical interface, which will then only serve as a
284 link/"bridge" device aggregating traffic to the same physical link and not participate in
285 the network otherwise.</para>
286 </listitem>
287 </varlistentry>
288 <varlistentry>
289 <term><varname>Multicast=</varname></term>
290 <listitem>
291 <para>Takes a boolean. If set to true, the multicast flag on the device is enabled.</para>
292 </listitem>
293 </varlistentry>
294 <varlistentry>
295 <term><varname>AllMulticast=</varname></term>
296 <listitem>
297 <para>Takes a boolean. If set to true, the driver retrieves all multicast packets from the network.
298 This happens when multicast routing is enabled.</para>
299 </listitem>
300 </varlistentry>
301 <varlistentry>
302 <term><varname>Unmanaged=</varname></term>
303 <listitem>
304 <para>Takes a boolean. When <literal>yes</literal>, no attempts are
305 made to bring up or configure matching links, equivalent to
306 when there are no matching network files. Defaults to
307 <literal>no</literal>.</para>
308 <para>This is useful for preventing later matching network
309 files from interfering with certain interfaces that are fully
310 controlled by other applications.</para>
311 </listitem>
312 </varlistentry>
313 <varlistentry>
314 <term><varname>RequiredForOnline=</varname></term>
315 <listitem>
316 <para>Takes a boolean or operational state. Please see
317 <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry>
318 for possible operational states. When <literal>yes</literal>, the network is deemed required when
319 determining whether the system is online when running
320 <command>systemd-networkd-wait-online</command>. When <literal>no</literal>, the network is ignored
321 when checking for online state. When an operational state is set, <literal>yes</literal> is implied,
322 and this controls the operational state required for the network interface to be considered online.
323 Defaults to <literal>yes</literal>.</para>
324
325 <para>The network will be brought up normally in all cases, but in
326 the event that there is no address being assigned by DHCP or the
327 cable is not plugged in, the link will simply remain offline and be
328 skipped automatically by <command>systemd-networkd-wait-online</command>
329 if <literal>RequiredForOnline=no</literal>.</para>
330 </listitem>
331 </varlistentry>
332 </variablelist>
333 </refsect1>
334
335 <refsect1>
336 <title>[Network] Section Options</title>
337
338 <para>The <literal>[Network]</literal> section accepts the following keys:</para>
339
340 <variablelist class='network-directives'>
341 <varlistentry>
342 <term><varname>Description=</varname></term>
343 <listitem>
344 <para>A description of the device. This is only used for
345 presentation purposes.</para>
346 </listitem>
347 </varlistentry>
348 <varlistentry>
349 <term><varname>DHCP=</varname></term>
350 <listitem>
351 <para>Enables DHCPv4 and/or DHCPv6 client support. Accepts
352 <literal>yes</literal>, <literal>no</literal>,
353 <literal>ipv4</literal>, or <literal>ipv6</literal>. Defaults
354 to <literal>no</literal>.</para>
355
356 <para>Note that DHCPv6 will by default be triggered by Router
357 Advertisement, if that is enabled, regardless of this parameter.
358 By enabling DHCPv6 support explicitly, the DHCPv6 client will
359 be started regardless of the presence of routers on the link,
360 or what flags the routers pass. See
361 <literal>IPv6AcceptRA=</literal>.</para>
362
363 <para>Furthermore, note that by default the domain name
364 specified through DHCP is not used for name resolution.
365 See option <option>UseDomains=</option> below.</para>
366
367 <para>See the <literal>[DHCPv4]</literal> or <literal>[DHCPv6]</literal> section below for
368 further configuration options for the DHCP client support.</para>
369 </listitem>
370 </varlistentry>
371 <varlistentry>
372 <term><varname>DHCPServer=</varname></term>
373 <listitem>
374 <para>Takes a boolean. If set to <literal>yes</literal>, DHCPv4 server will be started. Defaults
375 to <literal>no</literal>. Further settings for the DHCP
376 server may be set in the <literal>[DHCPServer]</literal>
377 section described below.</para>
378 </listitem>
379 </varlistentry>
380 <varlistentry>
381 <term><varname>LinkLocalAddressing=</varname></term>
382 <listitem>
383 <para>Enables link-local address autoconfiguration. Accepts <literal>yes</literal>,
384 <literal>no</literal>, <literal>ipv4</literal>, <literal>ipv6</literal>,
385 <literal>fallback</literal>, or <literal>ipv4-fallback</literal>. If
386 <literal>fallback</literal> or <literal>ipv4-fallback</literal> is specified, then an IPv4
387 link-local address is configured only when DHCPv4 fails. If <literal>fallback</literal>,
388 an IPv6 link-local address is always configured, and if <literal>ipv4-fallback</literal>,
389 the address is not configured. Note that, the fallback mechanism works only when DHCPv4
390 client is enabled, that is, it requires <literal>DHCP=yes</literal> or
391 <literal>DHCP=ipv4</literal>. If <varname>Bridge=</varname> is set, defaults to
392 <literal>no</literal>, and if not, defaults to <literal>ipv6</literal>.
393 </para>
394 </listitem>
395 </varlistentry>
396 <varlistentry>
397 <term><varname>IPv4LLRoute=</varname></term>
398 <listitem>
399 <para>Takes a boolean. If set to true, sets up the route needed for
400 non-IPv4LL hosts to communicate with IPv4LL-only hosts. Defaults
401 to false.
402 </para>
403 </listitem>
404 </varlistentry>
405 <varlistentry>
406 <term><varname>DefaultRouteOnDevice=</varname></term>
407 <listitem>
408 <para>Takes a boolean. If set to true, sets up the default route bound to the interface.
409 Defaults to false. This is useful when creating routes on point-to-point interfaces.
410 This is equivalent to e.g. the following.
411 <programlisting>ip route add default dev veth99</programlisting></para>
412 </listitem>
413 </varlistentry>
414 <varlistentry>
415 <term><varname>IPv6Token=</varname></term>
416 <listitem>
417 <para>An IPv6 address with the top 64 bits unset. When set, indicates the
418 64-bit interface part of SLAAC IPv6 addresses for this link. Note that
419 the token is only ever used for SLAAC, and not for DHCPv6 addresses, even
420 in the case DHCP is requested by router advertisement. By default, the
421 token is autogenerated.</para>
422 </listitem>
423 </varlistentry>
424 <varlistentry>
425 <term><varname>LLMNR=</varname></term>
426 <listitem>
427 <para>Takes a boolean or <literal>resolve</literal>. When true,
428 enables <ulink
429 url="https://tools.ietf.org/html/rfc4795">Link-Local
430 Multicast Name Resolution</ulink> on the link. When set to
431 <literal>resolve</literal>, only resolution is enabled,
432 but not host registration and announcement. Defaults to
433 true. This setting is read by
434 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
435 </listitem>
436 </varlistentry>
437 <varlistentry>
438 <term><varname>MulticastDNS=</varname></term>
439 <listitem>
440 <para>Takes a boolean or <literal>resolve</literal>. When true,
441 enables <ulink
442 url="https://tools.ietf.org/html/rfc6762">Multicast
443 DNS</ulink> support on the link. When set to
444 <literal>resolve</literal>, only resolution is enabled,
445 but not host or service registration and
446 announcement. Defaults to false. This setting is read by
447 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
448 </listitem>
449 </varlistentry>
450 <varlistentry>
451 <term><varname>DNSOverTLS=</varname></term>
452 <listitem>
453 <para>Takes a boolean or <literal>opportunistic</literal>.
454 When true, enables
455 <ulink
456 url="https://tools.ietf.org/html/rfc7858">DNS-over-TLS</ulink>
457 support on the link.
458 When set to <literal>opportunistic</literal>, compatibility with
459 non-DNS-over-TLS servers is increased, by automatically
460 turning off DNS-over-TLS servers in this case.
461 This option defines a per-interface setting for
462 <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s
463 global <varname>DNSOverTLS=</varname> option. Defaults to
464 false. This setting is read by
465 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
466 </listitem>
467 </varlistentry>
468 <varlistentry>
469 <term><varname>DNSSEC=</varname></term>
470 <listitem>
471 <para>Takes a boolean. or
472 <literal>allow-downgrade</literal>. When true, enables
473 <ulink
474 url="https://tools.ietf.org/html/rfc4033">DNSSEC</ulink>
475 DNS validation support on the link. When set to
476 <literal>allow-downgrade</literal>, compatibility with
477 non-DNSSEC capable networks is increased, by automatically
478 turning off DNSSEC in this case. This option defines a
479 per-interface setting for
480 <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s
481 global <varname>DNSSEC=</varname> option. Defaults to
482 false. This setting is read by
483 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
484 </listitem>
485 </varlistentry>
486 <varlistentry>
487 <term><varname>DNSSECNegativeTrustAnchors=</varname></term>
488 <listitem><para>A space-separated list of DNSSEC negative
489 trust anchor domains. If specified and DNSSEC is enabled,
490 look-ups done via the interface's DNS server will be subject
491 to the list of negative trust anchors, and not require
492 authentication for the specified domains, or anything below
493 it. Use this to disable DNSSEC authentication for specific
494 private domains, that cannot be proven valid using the
495 Internet DNS hierarchy. Defaults to the empty list. This
496 setting is read by
497 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
498 </listitem>
499 </varlistentry>
500 <varlistentry>
501 <term><varname>LLDP=</varname></term>
502 <listitem>
503 <para>Controls support for Ethernet LLDP packet reception. LLDP is a link-layer protocol commonly
504 implemented on professional routers and bridges which announces which physical port a system is connected
505 to, as well as other related data. Accepts a boolean or the special value
506 <literal>routers-only</literal>. When true, incoming LLDP packets are accepted and a database of all LLDP
507 neighbors maintained. If <literal>routers-only</literal> is set only LLDP data of various types of routers
508 is collected and LLDP data about other types of devices ignored (such as stations, telephones and
509 others). If false, LLDP reception is disabled. Defaults to <literal>routers-only</literal>. Use
510 <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> to query the
511 collected neighbor data. LLDP is only available on Ethernet links. See <varname>EmitLLDP=</varname> below
512 for enabling LLDP packet emission from the local system.
513 </para>
514 </listitem>
515 </varlistentry>
516 <varlistentry>
517 <term><varname>EmitLLDP=</varname></term>
518 <listitem>
519 <para>Controls support for Ethernet LLDP packet emission. Accepts a boolean parameter or the special values
520 <literal>nearest-bridge</literal>, <literal>non-tpmr-bridge</literal> and
521 <literal>customer-bridge</literal>. Defaults to false, which turns off LLDP packet emission. If not false,
522 a short LLDP packet with information about the local system is sent out in regular intervals on the
523 link. The LLDP packet will contain information about the local host name, the local machine ID (as stored
524 in <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>) and the
525 local interface name, as well as the pretty hostname of the system (as set in
526 <citerefentry><refentrytitle>machine-info</refentrytitle><manvolnum>5</manvolnum></citerefentry>). LLDP
527 emission is only available on Ethernet links. Note that this setting passes data suitable for
528 identification of host to the network and should thus not be enabled on untrusted networks, where such
529 identification data should not be made available. Use this option to permit other systems to identify on
530 which interfaces they are connected to this system. The three special values control propagation of the
531 LLDP packets. The <literal>nearest-bridge</literal> setting permits propagation only to the nearest
532 connected bridge, <literal>non-tpmr-bridge</literal> permits propagation across Two-Port MAC Relays, but
533 not any other bridges, and <literal>customer-bridge</literal> permits propagation until a customer bridge
534 is reached. For details about these concepts, see <ulink
535 url="https://standards.ieee.org/findstds/standard/802.1AB-2016.html">IEEE 802.1AB-2016</ulink>. Note that
536 configuring this setting to true is equivalent to <literal>nearest-bridge</literal>, the recommended and
537 most restricted level of propagation. See <varname>LLDP=</varname> above for an option to enable LLDP
538 reception.</para>
539 </listitem>
540 </varlistentry>
541 <varlistentry>
542 <term><varname>BindCarrier=</varname></term>
543 <listitem>
544 <para>A link name or a list of link names. When set, controls the behavior of the current
545 link. When all links in the list are in an operational down state, the current link is brought
546 down. When at least one link has carrier, the current interface is brought up.
547 </para>
548 </listitem>
549 </varlistentry>
550 <varlistentry>
551 <term><varname>Address=</varname></term>
552 <listitem>
553 <para>A static IPv4 or IPv6 address and its prefix length,
554 separated by a <literal>/</literal> character. Specify
555 this key more than once to configure several addresses.
556 The format of the address must be as described in
557 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
558 This is a short-hand for an [Address] section only
559 containing an Address key (see below). This option may be
560 specified more than once.
561 </para>
562
563 <para>If the specified address is <literal>0.0.0.0</literal> (for IPv4) or <literal>::</literal>
564 (for IPv6), a new address range of the requested size is automatically allocated from a
565 system-wide pool of unused ranges. Note that the prefix length must be equal or larger than 8 for
566 IPv4, and 64 for IPv6. The allocated range is checked against all current network interfaces and
567 all known network configuration files to avoid address range conflicts. The default system-wide
568 pool consists of 192.168.0.0/16, 172.16.0.0/12 and 10.0.0.0/8 for IPv4, and fd00::/8 for IPv6.
569 This functionality is useful to manage a large number of dynamically created network interfaces
570 with the same network configuration and automatic address range assignment.</para>
571
572 </listitem>
573 </varlistentry>
574 <varlistentry>
575 <term><varname>Gateway=</varname></term>
576 <listitem>
577 <para>The gateway address, which must be in the format
578 described in
579 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
580 This is a short-hand for a [Route] section only containing
581 a Gateway key. This option may be specified more than
582 once.</para>
583 </listitem>
584 </varlistentry>
585 <varlistentry>
586 <term><varname>DNS=</varname></term>
587 <listitem>
588 <para>A DNS server address, which must be in the format
589 described in
590 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
591 This option may be specified more than once. This setting is read by
592 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
593 </listitem>
594 </varlistentry>
595 <varlistentry>
596 <term><varname>Domains=</varname></term>
597 <listitem>
598 <para>A list of domains which should be resolved using the DNS servers on this link. Each item in the list
599 should be a domain name, optionally prefixed with a tilde (<literal>~</literal>). The domains with the
600 prefix are called "routing-only domains". The domains without the prefix are called "search domains" and
601 are first used as search suffixes for extending single-label host names (host names containing no dots) to
602 become fully qualified domain names (FQDNs). If a single-label host name is resolved on this interface,
603 each of the specified search domains are appended to it in turn, converting it into a fully qualified
604 domain name, until one of them may be successfully resolved.</para>
605
606 <para>Both "search" and "routing-only" domains are used for routing of DNS queries: look-ups for host names
607 ending in those domains (hence also single label names, if any "search domains" are listed), are routed to
608 the DNS servers configured for this interface. The domain routing logic is particularly useful on
609 multi-homed hosts with DNS servers serving particular private DNS zones on each interface.</para>
610
611 <para>The "routing-only" domain <literal>~.</literal> (the tilde indicating definition of a routing domain,
612 the dot referring to the DNS root domain which is the implied suffix of all valid DNS names) has special
613 effect. It causes all DNS traffic which does not match another configured domain routing entry to be routed
614 to DNS servers specified for this interface. This setting is useful to prefer a certain set of DNS servers
615 if a link on which they are connected is available.</para>
616
617 <para>This setting is read by
618 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
619 "Search domains" correspond to the <varname>domain</varname> and <varname>search</varname> entries in
620 <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
621 Domain name routing has no equivalent in the traditional glibc API, which has no concept of domain
622 name servers limited to a specific link.</para>
623 </listitem>
624 </varlistentry>
625 <varlistentry>
626 <term><varname>DNSDefaultRoute=</varname></term>
627 <listitem>
628 <para>Takes a boolean argument. If true, this link's configured DNS servers are used for resolving domain
629 names that do not match any link's configured <varname>Domains=</varname> setting. If false, this link's
630 configured DNS servers are never used for such domains, and are exclusively used for resolving names that
631 match at least one of the domains configured on this link. If not specified defaults to an automatic mode:
632 queries not matching any link's configured domains will be routed to this link if it has no routing-only
633 domains configured.</para>
634 </listitem>
635 </varlistentry>
636 <varlistentry>
637 <term><varname>NTP=</varname></term>
638 <listitem>
639 <para>An NTP server address. This option may be specified more than once. This setting is read by
640 <citerefentry><refentrytitle>systemd-timesyncd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
641 </listitem>
642 </varlistentry>
643 <varlistentry>
644 <term><varname>IPForward=</varname></term>
645 <listitem><para>Configures IP packet forwarding for the
646 system. If enabled, incoming packets on any network
647 interface will be forwarded to any other interfaces
648 according to the routing table. Takes a boolean,
649 or the values <literal>ipv4</literal> or
650 <literal>ipv6</literal>, which only enable IP packet
651 forwarding for the specified address family. This controls
652 the <filename>net.ipv4.ip_forward</filename> and
653 <filename>net.ipv6.conf.all.forwarding</filename> sysctl
654 options of the network interface (see <ulink
655 url="https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt</ulink>
656 for details about sysctl options). Defaults to
657 <literal>no</literal>.</para>
658
659 <para>Note: this setting controls a global kernel option,
660 and does so one way only: if a network that has this setting
661 enabled is set up the global setting is turned on. However,
662 it is never turned off again, even after all networks with
663 this setting enabled are shut down again.</para>
664
665 <para>To allow IP packet forwarding only between specific
666 network interfaces use a firewall.</para>
667 </listitem>
668 </varlistentry>
669 <varlistentry>
670 <term><varname>IPMasquerade=</varname></term>
671 <listitem><para>Configures IP masquerading for the network
672 interface. If enabled, packets forwarded from the network
673 interface will be appear as coming from the local host.
674 Takes a boolean argument. Implies
675 <varname>IPForward=ipv4</varname>. Defaults to
676 <literal>no</literal>.</para></listitem>
677 </varlistentry>
678 <varlistentry>
679 <term><varname>IPv6PrivacyExtensions=</varname></term>
680 <listitem><para>Configures use of stateless temporary
681 addresses that change over time (see <ulink
682 url="https://tools.ietf.org/html/rfc4941">RFC 4941</ulink>,
683 Privacy Extensions for Stateless Address Autoconfiguration
684 in IPv6). Takes a boolean or the special values
685 <literal>prefer-public</literal> and
686 <literal>kernel</literal>. When true, enables the privacy
687 extensions and prefers temporary addresses over public
688 addresses. When <literal>prefer-public</literal>, enables the
689 privacy extensions, but prefers public addresses over
690 temporary addresses. When false, the privacy extensions
691 remain disabled. When <literal>kernel</literal>, the kernel's
692 default setting will be left in place. Defaults to
693 <literal>no</literal>.</para></listitem>
694 </varlistentry>
695 <varlistentry>
696 <term><varname>IPv6AcceptRA=</varname></term>
697 <listitem><para>Takes a boolean. Controls IPv6 Router Advertisement (RA) reception support
698 for the interface. If true, RAs are accepted; if false, RAs are ignored, independently of the
699 local forwarding state. When RAs are accepted, they may trigger the start of the DHCPv6
700 client if the relevant flags are set in the RA data, or if no routers are found on the link.</para>
701
702 <para>Further settings for the IPv6 RA support may be configured in the
703 <literal>[IPv6AcceptRA]</literal> section, see below.</para>
704
705 <para>Also see <ulink
706 url="https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt</ulink> in the kernel
707 documentation regarding <literal>accept_ra</literal>, but note that systemd's setting of
708 <constant>1</constant> (i.e. true) corresponds to kernel's setting of <constant>2</constant>.</para>
709
710 <para>Note that kernel's implementation of the IPv6 RA protocol is always disabled,
711 regardless of this setting. If this option is enabled, a userspace implementation of the IPv6
712 RA protocol is used, and the kernel's own implementation remains disabled, since
713 <command>systemd-networkd</command> needs to know all details supplied in the advertisements,
714 and these are not available from the kernel if the kernel's own implementation is used.</para>
715 </listitem>
716 </varlistentry>
717 <varlistentry>
718 <term><varname>IPv6DuplicateAddressDetection=</varname></term>
719 <listitem><para>Configures the amount of IPv6 Duplicate
720 Address Detection (DAD) probes to send. When unset, the kernel's default will be used.
721 </para></listitem>
722 </varlistentry>
723 <varlistentry>
724 <term><varname>IPv6HopLimit=</varname></term>
725 <listitem><para>Configures IPv6 Hop Limit. For each router that
726 forwards the packet, the hop limit is decremented by 1. When the
727 hop limit field reaches zero, the packet is discarded.
728 When unset, the kernel's default will be used.
729 </para></listitem>
730 </varlistentry>
731 <varlistentry>
732 <term><varname>IPv4ProxyARP=</varname></term>
733 <listitem><para>Takes a boolean. Configures proxy ARP for IPv4. Proxy ARP is the technique in which one host,
734 usually a router, answers ARP requests intended for another machine. By "faking" its identity,
735 the router accepts responsibility for routing packets to the "real" destination. (see <ulink
736 url="https://tools.ietf.org/html/rfc1027">RFC 1027</ulink>.
737 When unset, the kernel's default will be used.
738 </para></listitem>
739 </varlistentry>
740 <varlistentry>
741 <term><varname>IPv6ProxyNDP=</varname></term>
742 <listitem><para>Takes a boolean. Configures proxy NDP for IPv6. Proxy NDP (Neighbor Discovery
743 Protocol) is a technique for IPv6 to allow routing of addresses to a different
744 destination when peers expect them to be present on a certain physical link.
745 In this case a router answers Neighbour Advertisement messages intended for
746 another machine by offering its own MAC address as destination.
747 Unlike proxy ARP for IPv4, it is not enabled globally, but will only send Neighbour
748 Advertisement messages for addresses in the IPv6 neighbor proxy table,
749 which can also be shown by <command>ip -6 neighbour show proxy</command>.
750 systemd-networkd will control the per-interface `proxy_ndp` switch for each configured
751 interface depending on this option.
752 When unset, the kernel's default will be used.
753 </para></listitem>
754 </varlistentry>
755 <varlistentry>
756 <term><varname>IPv6ProxyNDPAddress=</varname></term>
757 <listitem><para>An IPv6 address, for which Neighbour Advertisement messages will be
758 proxied. This option may be specified more than once. systemd-networkd will add the
759 <option>IPv6ProxyNDPAddress=</option> entries to the kernel's IPv6 neighbor proxy table.
760 This option implies <option>IPv6ProxyNDP=yes</option> but has no effect if
761 <option>IPv6ProxyNDP</option> has been set to false. When unset, the kernel's default will be used.
762 </para></listitem>
763 </varlistentry>
764 <varlistentry>
765 <term><varname>IPv6PrefixDelegation=</varname></term>
766 <listitem><para>Whether to enable or disable Router Advertisement sending on a link.
767 Allowed values are <literal>static</literal> which distributes prefixes as defined in
768 the <literal>[IPv6PrefixDelegation]</literal> and any <literal>[IPv6Prefix]</literal>
769 sections, <literal>dhcpv6</literal> which requests prefixes using a DHCPv6 client
770 configured for another link and any values configured in the
771 <literal>[IPv6PrefixDelegation]</literal> section while ignoring all static prefix
772 configuration sections, <literal>yes</literal> which uses both static configuration
773 and DHCPv6, and <literal>false</literal> which turns off IPv6 prefix delegation
774 altogether. Defaults to <literal>false</literal>. See the
775 <literal>[IPv6PrefixDelegation]</literal> and the <literal>[IPv6Prefix]</literal>
776 sections for more configuration options.
777 </para></listitem>
778 </varlistentry>
779 <varlistentry>
780 <term><varname>IPv6MTUBytes=</varname></term>
781 <listitem><para>Configures IPv6 maximum transmission unit (MTU).
782 An integer greater than or equal to 1280 bytes. When unset, the kernel's default will be used.
783 </para></listitem>
784 </varlistentry>
785 <varlistentry>
786 <term><varname>Bridge=</varname></term>
787 <listitem>
788 <para>The name of the bridge to add the link to. See
789 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
790 </para>
791 </listitem>
792 </varlistentry>
793 <varlistentry>
794 <term><varname>Bond=</varname></term>
795 <listitem>
796 <para>The name of the bond to add the link to. See
797 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
798 </para>
799 </listitem>
800 </varlistentry>
801 <varlistentry>
802 <term><varname>VRF=</varname></term>
803 <listitem>
804 <para>The name of the VRF to add the link to. See
805 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
806 </para>
807 </listitem>
808 </varlistentry>
809 <varlistentry>
810 <term><varname>VLAN=</varname></term>
811 <listitem>
812 <para>The name of a VLAN to create on the link. See
813 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
814 This option may be specified more than once.</para>
815 </listitem>
816 </varlistentry>
817 <varlistentry>
818 <term><varname>IPVLAN=</varname></term>
819 <listitem>
820 <para>The name of a IPVLAN to create on the link. See
821 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
822 This option may be specified more than once.</para>
823 </listitem>
824 </varlistentry>
825 <varlistentry>
826 <term><varname>MACVLAN=</varname></term>
827 <listitem>
828 <para>The name of a MACVLAN to create on the link. See
829 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
830 This option may be specified more than once.</para>
831 </listitem>
832 </varlistentry>
833 <varlistentry>
834 <term><varname>VXLAN=</varname></term>
835 <listitem>
836 <para>The name of a VXLAN to create on the link. See
837 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
838 This option may be specified more than once.</para>
839 </listitem>
840 </varlistentry>
841 <varlistentry>
842 <term><varname>Tunnel=</varname></term>
843 <listitem>
844 <para>The name of a Tunnel to create on the link. See
845 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
846 This option may be specified more than once.</para>
847 </listitem>
848 </varlistentry>
849 <varlistentry>
850 <term><varname>MACsec=</varname></term>
851 <listitem>
852 <para>The name of a MACsec device to create on the link. See
853 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
854 This option may be specified more than once.</para>
855 </listitem>
856 </varlistentry>
857 <varlistentry>
858 <term><varname>ActiveSlave=</varname></term>
859 <listitem>
860 <para>Takes a boolean. Specifies the new active slave. The <literal>ActiveSlave=</literal>
861 option is only valid for following modes:
862 <literal>active-backup</literal>,
863 <literal>balance-alb</literal> and
864 <literal>balance-tlb</literal>. Defaults to false.
865 </para>
866 </listitem>
867 </varlistentry>
868 <varlistentry>
869 <term><varname>PrimarySlave=</varname></term>
870 <listitem>
871 <para>Takes a boolean. Specifies which slave is the primary device. The specified
872 device will always be the active slave while it is available. Only when the
873 primary is off-line will alternate devices be used. This is useful when
874 one slave is preferred over another, e.g. when one slave has higher throughput
875 than another. The <literal>PrimarySlave=</literal> option is only valid for
876 following modes:
877 <literal>active-backup</literal>,
878 <literal>balance-alb</literal> and
879 <literal>balance-tlb</literal>. Defaults to false.
880 </para>
881 </listitem>
882 </varlistentry>
883 <varlistentry>
884 <term><varname>ConfigureWithoutCarrier=</varname></term>
885 <listitem>
886 <para>Takes a boolean. Allows networkd to configure a specific link even if it has no carrier.
887 Defaults to false.
888 </para>
889 </listitem>
890 </varlistentry>
891 <varlistentry>
892 <term><varname>IgnoreCarrierLoss=</varname></term>
893 <listitem>
894 <para>A boolean. Allows networkd to retain both the static and dynamic configuration of the
895 interface even if its carrier is lost. Defaults to false.
896 </para>
897 </listitem>
898 </varlistentry>
899 <varlistentry>
900 <term><varname>Xfrm=</varname></term>
901 <listitem>
902 <para>The name of the xfrm to create on the link. See
903 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
904 This option may be specified more than once.</para>
905 </listitem>
906 </varlistentry>
907 <varlistentry>
908 <term><varname>KeepConfiguration=</varname></term>
909 <listitem>
910 <para>Takes a boolean or one of <literal>static</literal>, <literal>dhcp-on-stop</literal>,
911 <literal>dhcp</literal>. When <literal>static</literal>, <command>systemd-networkd</command>
912 will not drop static addresses and routes on starting up process. When set to
913 <literal>dhcp-on-stop</literal>, <command>systemd-networkd</command> will not drop addresses
914 and routes on stopping the daemon. When <literal>dhcp</literal>,
915 the addresses and routes provided by a DHCP server will never be dropped even if the DHCP
916 lease expires. This is contrary to the DHCP specification, but may be the best choice if,
917 e.g., the root filesystem relies on this connection. The setting <literal>dhcp</literal>
918 implies <literal>dhcp-on-stop</literal>, and <literal>yes</literal> implies
919 <literal>dhcp</literal> and <literal>static</literal>. Defaults to <literal>no</literal>.
920 </para>
921 </listitem>
922 </varlistentry>
923
924 </variablelist>
925
926 </refsect1>
927
928 <refsect1>
929 <title>[Address] Section Options</title>
930
931 <para>An <literal>[Address]</literal> section accepts the
932 following keys. Specify several <literal>[Address]</literal>
933 sections to configure several addresses.</para>
934
935 <variablelist class='network-directives'>
936 <varlistentry>
937 <term><varname>Address=</varname></term>
938 <listitem>
939 <para>As in the <literal>[Network]</literal> section. This key is mandatory. Each
940 <literal>[Address]</literal> section can contain one <varname>Address=</varname> setting.</para>
941 </listitem>
942 </varlistentry>
943 <varlistentry>
944 <term><varname>Peer=</varname></term>
945 <listitem>
946 <para>The peer address in a point-to-point connection.
947 Accepts the same format as the <varname>Address=</varname>
948 key.</para>
949 </listitem>
950 </varlistentry>
951 <varlistentry>
952 <term><varname>Broadcast=</varname></term>
953 <listitem>
954 <para>The broadcast address, which must be in the format
955 described in
956 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
957 This key only applies to IPv4 addresses. If it is not
958 given, it is derived from the <varname>Address=</varname>
959 key.</para>
960 </listitem>
961 </varlistentry>
962 <varlistentry>
963 <term><varname>Label=</varname></term>
964 <listitem>
965 <para>An address label.</para>
966 </listitem>
967 </varlistentry>
968 <varlistentry>
969 <term><varname>PreferredLifetime=</varname></term>
970 <listitem>
971 <para>Allows the default "preferred lifetime" of the address to be overridden.
972 Only three settings are accepted: <literal>forever</literal> or <literal>infinity</literal>
973 which is the default and means that the address never expires, and <literal>0</literal> which means
974 that the address is considered immediately "expired" and will not be used,
975 unless explicitly requested. A setting of PreferredLifetime=0 is useful for
976 addresses which are added to be used only by a specific application,
977 which is then configured to use them explicitly.</para>
978 </listitem>
979 </varlistentry>
980 <varlistentry>
981 <term><varname>Scope=</varname></term>
982 <listitem>
983 <para>The scope of the address, which can be <literal>global</literal>,
984 <literal>link</literal> or <literal>host</literal> or an unsigned integer ranges 0 to 255.
985 Defaults to <literal>global</literal>.</para>
986 </listitem>
987 </varlistentry>
988 <varlistentry>
989 <term><varname>HomeAddress=</varname></term>
990 <listitem>
991 <para>Takes a boolean. Designates this address the "home address" as defined in
992 <ulink url="https://tools.ietf.org/html/rfc6275">RFC 6275</ulink>.
993 Supported only on IPv6. Defaults to false.</para>
994 </listitem>
995 </varlistentry>
996 <varlistentry>
997 <term><varname>DuplicateAddressDetection=</varname></term>
998 <listitem>
999 <para>Takes one of <literal>ipv4</literal>, <literal>ipv6</literal>,
1000 <literal>both</literal>, <literal>none</literal>. When <literal>ipv4</literal>,
1001 performs IPv4 Duplicate Address Detection. See
1002 <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5224</ulink>.
1003 When <literal>ipv6</literal>, performs IPv6 Duplicate Address Detection. See
1004 <ulink url="https://tools.ietf.org/html/rfc4862">RFC 4862</ulink>.
1005 Defaults to <literal>ipv6</literal>.</para>
1006 </listitem>
1007 </varlistentry>
1008 <varlistentry>
1009 <term><varname>ManageTemporaryAddress=</varname></term>
1010 <listitem>
1011 <para>Takes a boolean. If true the kernel manage temporary addresses created
1012 from this one as template on behalf of Privacy Extensions
1013 <ulink url="https://tools.ietf.org/html/rfc3041">RFC 3041</ulink>. For this to become
1014 active, the use_tempaddr sysctl setting has to be set to a value greater than zero.
1015 The given address needs to have a prefix length of 64. This flag allows using privacy
1016 extensions in a manually configured network, just like if stateless auto-configuration
1017 was active. Defaults to false. </para>
1018 </listitem>
1019 </varlistentry>
1020 <varlistentry>
1021 <term><varname>AddPrefixRoute=</varname></term>
1022 <listitem>
1023 <para>Takes a boolean. When true, the prefix route for the address is automatically added.
1024 Defaults to true.</para>
1025 </listitem>
1026 </varlistentry>
1027 <varlistentry>
1028 <term><varname>AutoJoin=</varname></term>
1029 <listitem>
1030 <para>Takes a boolean. Joining multicast group on ethernet level via
1031 <command>ip maddr</command> command would not work if we have an Ethernet switch that does
1032 IGMP snooping since the switch would not replicate multicast packets on ports that did not
1033 have IGMP reports for the multicast addresses. Linux vxlan interfaces created via
1034 <command>ip link add vxlan</command> or networkd's netdev kind vxlan have the group option
1035 that enables then to do the required join. By extending ip address command with option
1036 <literal>autojoin</literal> we can get similar functionality for openvswitch (OVS) vxlan
1037 interfaces as well as other tunneling mechanisms that need to receive multicast traffic.
1038 Defaults to <literal>no</literal>.</para>
1039 </listitem>
1040 </varlistentry>
1041 </variablelist>
1042 </refsect1>
1043
1044 <refsect1>
1045 <title>[Neighbor] Section Options</title>
1046 <para>A <literal>[Neighbor]</literal> section accepts the
1047 following keys. The neighbor section adds a permanent, static
1048 entry to the neighbor table (IPv6) or ARP table (IPv4) for
1049 the given hardware address on the links matched for the network.
1050 Specify several <literal>[Neighbor]</literal> sections to configure
1051 several static neighbors.</para>
1052
1053 <variablelist class='network-directives'>
1054 <varlistentry>
1055 <term><varname>Address=</varname></term>
1056 <listitem>
1057 <para>The IP address of the neighbor.</para>
1058 </listitem>
1059 </varlistentry>
1060 <varlistentry>
1061 <term><varname>LinkLayerAddress=</varname></term>
1062 <listitem>
1063 <para>The link layer address (MAC address or IP address) of the neighbor.</para>
1064 </listitem>
1065 </varlistentry>
1066 </variablelist>
1067 </refsect1>
1068
1069 <refsect1>
1070 <title>[IPv6AddressLabel] Section Options</title>
1071
1072 <para>An <literal>[IPv6AddressLabel]</literal> section accepts the
1073 following keys. Specify several <literal>[IPv6AddressLabel]</literal>
1074 sections to configure several address labels. IPv6 address labels are
1075 used for address selection. See <ulink url="https://tools.ietf.org/html/rfc3484">RFC 3484</ulink>.
1076 Precedence is managed by userspace, and only the label itself is stored in the kernel</para>
1077
1078 <variablelist class='network-directives'>
1079 <varlistentry>
1080 <term><varname>Label=</varname></term>
1081 <listitem>
1082 <para> The label for the prefix (an unsigned integer) ranges 0 to 4294967294.
1083 0xffffffff is reserved. This key is mandatory.</para>
1084 </listitem>
1085 </varlistentry>
1086 <varlistentry>
1087 <term><varname>Prefix=</varname></term>
1088 <listitem>
1089 <para>IPv6 prefix is an address with a prefix length, separated by a slash <literal>/</literal> character.
1090 This key is mandatory. </para>
1091 </listitem>
1092 </varlistentry>
1093 </variablelist>
1094 </refsect1>
1095
1096 <refsect1>
1097 <title>[RoutingPolicyRule] Section Options</title>
1098
1099 <para>An <literal>[RoutingPolicyRule]</literal> section accepts the
1100 following keys. Specify several <literal>[RoutingPolicyRule]</literal>
1101 sections to configure several rules.</para>
1102
1103 <variablelist class='network-directives'>
1104 <varlistentry>
1105 <term><varname>TypeOfService=</varname></term>
1106 <listitem>
1107 <para>Specifies the type of service to match a number between 0 to 255.</para>
1108 </listitem>
1109 </varlistentry>
1110 <varlistentry>
1111 <term><varname>From=</varname></term>
1112 <listitem>
1113 <para>Specifies the source address prefix to match. Possibly followed by a slash and the prefix length.</para>
1114 </listitem>
1115 </varlistentry>
1116 <varlistentry>
1117 <term><varname>To=</varname></term>
1118 <listitem>
1119 <para>Specifies the destination address prefix to match. Possibly followed by a slash and the prefix length.</para>
1120 </listitem>
1121 </varlistentry>
1122 <varlistentry>
1123 <term><varname>FirewallMark=</varname></term>
1124 <listitem>
1125 <para>Specifies the iptables firewall mark value to match (a number between 1 and 4294967295).</para>
1126 </listitem>
1127 </varlistentry>
1128 <varlistentry>
1129 <term><varname>Table=</varname></term>
1130 <listitem>
1131 <para>Specifies the routing table identifier to lookup if the rule selector matches. Takes
1132 one of <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>,
1133 or a number between 1 and 4294967295. Defaults to <literal>main</literal>.</para>
1134 </listitem>
1135 </varlistentry>
1136 <varlistentry>
1137 <term><varname>Priority=</varname></term>
1138 <listitem>
1139 <para>Specifies the priority of this rule. <varname>Priority=</varname> is an unsigned
1140 integer. Higher number means lower priority, and rules get processed in order of increasing number.</para>
1141 </listitem>
1142 </varlistentry>
1143 <varlistentry>
1144 <term><varname>IncomingInterface=</varname></term>
1145 <listitem>
1146 <para>Specifies incoming device to match. If the interface is loopback, the rule only matches packets originating from this host.</para>
1147 </listitem>
1148 </varlistentry>
1149 <varlistentry>
1150 <term><varname>OutgoingInterface=</varname></term>
1151 <listitem>
1152 <para>Specifies the outgoing device to match. The outgoing interface is only available for packets originating from local sockets that are bound to a device.</para>
1153 </listitem>
1154 </varlistentry>
1155 <varlistentry>
1156 <term><varname>SourcePort=</varname></term>
1157 <listitem>
1158 <para>Specifies the source IP port or IP port range match in forwarding information base (FIB) rules.
1159 A port range is specified by the lower and upper port separated by a dash. Defaults to unset.</para>
1160 </listitem>
1161 </varlistentry>
1162 <varlistentry>
1163 <term><varname>DestinationPort=</varname></term>
1164 <listitem>
1165 <para>Specifies the destination IP port or IP port range match in forwarding information base (FIB) rules.
1166 A port range is specified by the lower and upper port separated by a dash. Defaults to unset.</para>
1167 </listitem>
1168 </varlistentry>
1169 <varlistentry>
1170 <term><varname>IPProtocol=</varname></term>
1171 <listitem>
1172 <para>Specifies the IP protocol to match in forwarding information base (FIB) rules. Takes IP protocol name such as <literal>tcp</literal>,
1173 <literal>udp</literal> or <literal>sctp</literal>, or IP protocol number such as <literal>6</literal> for <literal>tcp</literal> or
1174 <literal>17</literal> for <literal>udp</literal>.
1175 Defaults to unset.</para>
1176 </listitem>
1177 </varlistentry>
1178 <varlistentry>
1179 <term><varname>InvertRule=</varname></term>
1180 <listitem>
1181 <para>A boolean. Specifies whether the rule to be inverted. Defaults to false.</para>
1182 </listitem>
1183 </varlistentry>
1184 <varlistentry>
1185 <term><varname>Family=</varname></term>
1186 <listitem>
1187 <para>Takes a special value <literal>ipv4</literal>, <literal>ipv6</literal>, or
1188 <literal>both</literal>. By default, the address family is determined by the address
1189 specified in <varname>To=</varname> or <varname>From=</varname>. If neither
1190 <varname>To=</varname> nor <varname>From=</varname> are specified, then defaults to
1191 <literal>ipv4</literal>.</para>
1192 </listitem>
1193 </varlistentry>
1194 </variablelist>
1195 </refsect1>
1196
1197 <refsect1>
1198 <title>[NextHop] Section Options</title>
1199 <para>The <literal>[NextHop]</literal> section accepts the
1200 following keys. Specify several <literal>[NextHop]</literal>
1201 sections to configure several nexthop. Nexthop is used to manipulate entries in the kernel's nexthop
1202 tables.</para>
1203
1204 <variablelist class='network-directives'>
1205 <varlistentry>
1206 <term><varname>Gateway=</varname></term>
1207 <listitem>
1208 <para>As in the <literal>[Network]</literal> section. This is mandatory.</para>
1209 </listitem>
1210 </varlistentry>
1211 <varlistentry>
1212 <term><varname>Id=</varname></term>
1213 <listitem>
1214 <para>The id of the nexthop (an unsigned integer). If unspecified or '0' then automatically chosen by kernel.</para>
1215 </listitem>
1216 </varlistentry>
1217 </variablelist>
1218 </refsect1>
1219
1220 <refsect1>
1221 <title>[Route] Section Options</title>
1222 <para>The <literal>[Route]</literal> section accepts the
1223 following keys. Specify several <literal>[Route]</literal>
1224 sections to configure several routes.</para>
1225
1226 <variablelist class='network-directives'>
1227 <varlistentry>
1228 <term><varname>Gateway=</varname></term>
1229 <listitem>
1230 <para>Takes the gateway address or special value <literal>dhcp</literal>. If
1231 <literal>dhcp</literal>, then the gateway address provided by DHCP (or in the IPv6 case,
1232 provided by IPv6 RA) is used.</para>
1233 </listitem>
1234 </varlistentry>
1235 <varlistentry>
1236 <term><varname>GatewayOnLink=</varname></term>
1237 <listitem>
1238 <para>Takes a boolean. If set to true, the kernel does not have
1239 to check if the gateway is reachable directly by the current machine (i.e., the kernel does
1240 not need to check if the gateway is attached to the local network), so that we can insert the
1241 route in the kernel table without it being complained about. Defaults to <literal>no</literal>.
1242 </para>
1243 </listitem>
1244 </varlistentry>
1245 <varlistentry>
1246 <term><varname>Destination=</varname></term>
1247 <listitem>
1248 <para>The destination prefix of the route. Possibly
1249 followed by a slash and the prefix length. If omitted, a
1250 full-length host route is assumed.</para>
1251 </listitem>
1252 </varlistentry>
1253 <varlistentry>
1254 <term><varname>Source=</varname></term>
1255 <listitem>
1256 <para>The source prefix of the route. Possibly followed by
1257 a slash and the prefix length. If omitted, a full-length
1258 host route is assumed.</para>
1259 </listitem>
1260 </varlistentry>
1261 <varlistentry>
1262 <term><varname>Metric=</varname></term>
1263 <listitem>
1264 <para>The metric of the route (an unsigned integer).</para>
1265 </listitem>
1266 </varlistentry>
1267 <varlistentry>
1268 <term><varname>IPv6Preference=</varname></term>
1269 <listitem>
1270 <para>Specifies the route preference as defined in <ulink
1271 url="https://tools.ietf.org/html/rfc4191">RFC4191</ulink> for Router Discovery messages.
1272 Which can be one of <literal>low</literal> the route has a lowest priority,
1273 <literal>medium</literal> the route has a default priority or
1274 <literal>high</literal> the route has a highest priority.</para>
1275 </listitem>
1276 </varlistentry>
1277 <varlistentry>
1278 <term><varname>Scope=</varname></term>
1279 <listitem>
1280 <para>The scope of the route, which can be <literal>global</literal>, <literal>site</literal>,
1281 <literal>link</literal>, <literal>host</literal>, or <literal>nowhere</literal>. For IPv4 route,
1282 defaults to <literal>host</literal> if <varname>Type=</varname> is <literal>local</literal>
1283 or <literal>nat</literal>, and <literal>link</literal> if <varname>Type=</varname> is
1284 <literal>broadcast</literal>, <literal>multicast</literal>, or <literal>anycast</literal>.
1285 In other cases, defaults to <literal>global</literal>.</para>
1286 </listitem>
1287 </varlistentry>
1288 <varlistentry>
1289 <term><varname>PreferredSource=</varname></term>
1290 <listitem>
1291 <para>The preferred source address of the route. The address
1292 must be in the format described in
1293 <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>.</para>
1294 </listitem>
1295 </varlistentry>
1296 <varlistentry>
1297 <term><varname>Table=</varname></term>
1298 <listitem>
1299 <para>The table identifier for the route. Takes <literal>default</literal>,
1300 <literal>main</literal>, <literal>local</literal> or a number between 1 and 4294967295.
1301 The table can be retrieved using <command>ip route show table <replaceable>num</replaceable></command>.
1302 If unset and <varname>Type=</varname> is <literal>local</literal>, <literal>broadcast</literal>,
1303 <literal>anycast</literal>, or <literal>nat</literal>, then <literal>local</literal> is used.
1304 In other cases, defaults to <literal>main</literal>.
1305 </para>
1306 </listitem>
1307 </varlistentry>
1308 <varlistentry>
1309 <term><varname>Protocol=</varname></term>
1310 <listitem>
1311 <para>The protocol identifier for the route. Takes a number between 0 and 255 or the special values
1312 <literal>kernel</literal>, <literal>boot</literal>, <literal>static</literal>,
1313 <literal>ra</literal> and <literal>dhcp</literal>. Defaults to <literal>static</literal>.
1314 </para>
1315 </listitem>
1316 </varlistentry>
1317 <varlistentry>
1318 <term><varname>Type=</varname></term>
1319 <listitem>
1320 <para>Specifies the type for the route. Takes one of <literal>unicast</literal>,
1321 <literal>local</literal>, <literal>broadcast</literal>, <literal>anycast</literal>,
1322 <literal>multicast</literal>, <literal>blackhole</literal>, <literal>unreachable</literal>,
1323 <literal>prohibit</literal>, <literal>throw</literal>, <literal>nat</literal>, and
1324 <literal>xresolve</literal>. If <literal>unicast</literal>, a regular route is defined, i.e. a
1325 route indicating the path to take to a destination network address. If <literal>blackhole</literal>, packets
1326 to the defined route are discarded silently. If <literal>unreachable</literal>, packets to the defined route
1327 are discarded and the ICMP message "Host Unreachable" is generated. If <literal>prohibit</literal>, packets
1328 to the defined route are discarded and the ICMP message "Communication Administratively Prohibited" is
1329 generated. If <literal>throw</literal>, route lookup in the current routing table will fail and the route
1330 selection process will return to Routing Policy Database (RPDB). Defaults to <literal>unicast</literal>.
1331 </para>
1332 </listitem>
1333 </varlistentry>
1334 <varlistentry>
1335 <term><varname>InitialCongestionWindow=</varname></term>
1336 <listitem>
1337 <para>The TCP initial congestion window is used during the start of a TCP connection. During the start of a TCP
1338 session, when a client requests a resource, the server's initial congestion window determines how many data bytes
1339 will be sent during the initial burst of data. Takes a size in bytes between 1 and 4294967295 (2^32 - 1). The usual
1340 suffixes K, M, G are supported and are understood to the base of 1024. When unset, the kernel's default will be used.
1341 </para>
1342 </listitem>
1343 </varlistentry>
1344 <varlistentry>
1345 <term><varname>InitialAdvertisedReceiveWindow=</varname></term>
1346 <listitem>
1347 <para>The TCP initial advertised receive window is the amount of receive data (in bytes) that can initially be buffered at one time
1348 on a connection. The sending host can send only that amount of data before waiting for an acknowledgment and window update
1349 from the receiving host. Takes a size in bytes between 1 and 4294967295 (2^32 - 1). The usual suffixes K, M, G are supported
1350 and are understood to the base of 1024. When unset, the kernel's default will be used.
1351 </para>
1352 </listitem>
1353 </varlistentry>
1354 <varlistentry>
1355 <term><varname>QuickAck=</varname></term>
1356 <listitem>
1357 <para>Takes a boolean. When true enables TCP quick ack mode for the route. When unset, the kernel's default will be used.
1358 </para>
1359 </listitem>
1360 </varlistentry>
1361 <varlistentry>
1362 <term><varname>FastOpenNoCookie=</varname></term>
1363 <listitem>
1364 <para>Takes a boolean. When true enables TCP fastopen without a cookie on a per-route basis.
1365 When unset, the kernel's default will be used.
1366 </para>
1367 </listitem>
1368 </varlistentry>
1369 <varlistentry>
1370 <term><varname>TTLPropagate=</varname></term>
1371 <listitem>
1372 <para>Takes a boolean. When true enables TTL propagation at Label Switched Path (LSP) egress.
1373 When unset, the kernel's default will be used.
1374 </para>
1375 </listitem>
1376 </varlistentry>
1377 <varlistentry>
1378 <term><varname>MTUBytes=</varname></term>
1379 <listitem>
1380 <para>The maximum transmission unit in bytes to set for the
1381 route. The usual suffixes K, M, G, are supported and are
1382 understood to the base of 1024.</para>
1383 <para>Note that if IPv6 is enabled on the interface, and the MTU is chosen
1384 below 1280 (the minimum MTU for IPv6) it will automatically be increased to this value.</para>
1385 </listitem>
1386 </varlistentry>
1387 <varlistentry>
1388 <term><varname>IPServiceType=</varname></term>
1389 <listitem>
1390 <para>Takes string; <literal>CS6</literal> or <literal>CS4</literal>. Used to set IP
1391 service type to CS6 (network control) or CS4 (Realtime). Defaults to CS6.</para>
1392 </listitem>
1393 </varlistentry>
1394 <varlistentry>
1395 <term><varname>MultiPathRoute=<replaceable>address</replaceable>[@<replaceable>name</replaceable>] [<replaceable>weight</replaceable>]</varname></term>
1396 <listitem>
1397 <para>Configures multipath route. Multipath routing is the technique of using multiple
1398 alternative paths through a network. Takes gateway address. Optionally, takes a network
1399 interface name or index separated with <literal>@</literal>, and a weight in 1..256 for
1400 this multipath route separated with whitespace. This setting can be specified multiple
1401 times. If an empty string is assigned, then the all previous assignments are cleared.</para>
1402 </listitem>
1403 </varlistentry>
1404 </variablelist>
1405 </refsect1>
1406
1407 <refsect1>
1408 <title>[DHCPv4] Section Options</title>
1409 <para>The <literal>[DHCPv4]</literal> section configures the
1410 DHCPv4 client, if it is enabled with the
1411 <varname>DHCP=</varname> setting described above:</para>
1412
1413 <variablelist class='network-directives'>
1414 <varlistentry>
1415 <term><varname>UseDNS=</varname></term>
1416 <listitem>
1417 <para>When true (the default), the DNS servers received
1418 from the DHCP server will be used and take precedence over
1419 any statically configured ones.</para>
1420
1421 <para>This corresponds to the <option>nameserver</option>
1422 option in <citerefentry
1423 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
1424 </listitem>
1425 </varlistentry>
1426 <varlistentry>
1427 <term><varname>RoutesToDNS=</varname></term>
1428 <listitem>
1429 <para>When true, the routes to the DNS servers received from the DHCP server will be
1430 configured. When <varname>UseDNS=</varname> is disabled, this setting is ignored.
1431 Defaults to false.</para>
1432 </listitem>
1433 </varlistentry>
1434 <varlistentry>
1435 <term><varname>UseNTP=</varname></term>
1436 <listitem>
1437 <para>When true (the default), the NTP servers received
1438 from the DHCP server will be used by systemd-timesyncd
1439 and take precedence over any statically configured ones.</para>
1440 </listitem>
1441 </varlistentry>
1442 <varlistentry>
1443 <term><varname>UseSIP=</varname></term>
1444 <listitem>
1445 <para>When true (the default), the SIP servers received
1446 from the DHCP server will be saved at the state files and can be
1447 read via <function>sd_network_link_get_sip_servers()</function> function.</para>
1448 </listitem>
1449 </varlistentry>
1450 <varlistentry>
1451 <term><varname>UseMTU=</varname></term>
1452 <listitem>
1453 <para>When true, the interface maximum transmission unit
1454 from the DHCP server will be used on the current link.
1455 If <varname>MTUBytes=</varname> is set, then this setting is ignored.
1456 Defaults to false.</para>
1457 </listitem>
1458 </varlistentry>
1459 <varlistentry>
1460 <term><varname>Anonymize=</varname></term>
1461 <listitem>
1462 <para>Takes a boolean. When true, the options sent to the DHCP server will
1463 follow the <ulink url="https://tools.ietf.org/html/rfc7844">RFC 7844</ulink>
1464 (Anonymity Profiles for DHCP Clients) to minimize disclosure of identifying information.
1465 Defaults to false.</para>
1466
1467 <para>This option should only be set to true when
1468 <varname>MACAddressPolicy=</varname> is set to <literal>random</literal>
1469 (see <citerefentry
1470 project='man-pages'><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>).</para>
1471
1472 <para>Note that this configuration will overwrite others.
1473 In concrete, the following variables will be ignored:
1474 <varname>SendHostname=</varname>, <varname>ClientIdentifier=</varname>,
1475 <varname>UseRoutes=</varname>, <varname>SendHostname=</varname>,
1476 <varname>UseMTU=</varname>, <varname>VendorClassIdentifier=</varname>,
1477 <varname>UseTimezone=</varname>.</para>
1478
1479 <para>With this option enabled DHCP requests will mimic those generated by Microsoft Windows, in
1480 order to reduce the ability to fingerprint and recognize installations. This means DHCP request
1481 sizes will grow and lease data will be more comprehensive than normally, though most of the
1482 requested data is not actually used.</para>
1483 </listitem>
1484 </varlistentry>
1485 <varlistentry>
1486 <term><varname>SendHostname=</varname></term>
1487 <listitem>
1488 <para>When true (the default), the machine's hostname will be sent to the DHCP server.
1489 Note that the machine's hostname must consist only of 7-bit ASCII lower-case characters and
1490 no spaces or dots, and be formatted as a valid DNS domain name. Otherwise, the hostname is not
1491 sent even if this is set to true.</para>
1492 </listitem>
1493 </varlistentry>
1494 <varlistentry>
1495 <term><varname>UseHostname=</varname></term>
1496 <listitem>
1497 <para>When true (the default), the hostname received from
1498 the DHCP server will be set as the transient hostname of the system.
1499 </para>
1500 </listitem>
1501 </varlistentry>
1502 <varlistentry>
1503 <term><varname>Hostname=</varname></term>
1504 <listitem>
1505 <para>Use this value for the hostname which is sent to the DHCP server, instead of machine's hostname.
1506 Note that the specified hostname must consist only of 7-bit ASCII lower-case characters and
1507 no spaces or dots, and be formatted as a valid DNS domain name.</para>
1508 </listitem>
1509 </varlistentry>
1510 <varlistentry>
1511 <term><varname>UseDomains=</varname></term>
1512 <listitem>
1513 <para>Takes a boolean, or the special value <literal>route</literal>. When true, the domain name
1514 received from the DHCP server will be used as DNS search domain over this link, similar to the effect of
1515 the <option>Domains=</option> setting. If set to <literal>route</literal>, the domain name received from
1516 the DHCP server will be used for routing DNS queries only, but not for searching, similar to the effect of
1517 the <option>Domains=</option> setting when the argument is prefixed with <literal>~</literal>. Defaults to
1518 false.</para>
1519
1520 <para>It is recommended to enable this option only on trusted networks, as setting this affects resolution
1521 of all host names, in particular of single-label names. It is generally safer to use the supplied domain
1522 only as routing domain, rather than as search domain, in order to not have it affect local resolution of
1523 single-label names.</para>
1524
1525 <para>When set to true, this setting corresponds to the <option>domain</option> option in <citerefentry
1526 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
1527 </listitem>
1528 </varlistentry>
1529 <varlistentry>
1530 <term><varname>UseRoutes=</varname></term>
1531 <listitem>
1532 <para>When true (the default), the static routes will be requested from the DHCP server and added to the
1533 routing table with a metric of 1024, and a scope of "global", "link" or "host", depending on the route's
1534 destination and gateway. If the destination is on the local host, e.g., 127.x.x.x, or the same as the
1535 link's own address, the scope will be set to "host". Otherwise if the gateway is null (a direct route), a
1536 "link" scope will be used. For anything else, scope defaults to "global".</para>
1537 </listitem>
1538 </varlistentry>
1539
1540 <varlistentry>
1541 <term><varname>UseTimezone=</varname></term>
1542
1543 <listitem><para>When true, the timezone received from the
1544 DHCP server will be set as timezone of the local
1545 system. Defaults to <literal>no</literal>.</para></listitem>
1546 </varlistentry>
1547
1548 <varlistentry>
1549 <term><varname>ClientIdentifier=</varname></term>
1550 <listitem>
1551 <para>The DHCPv4 client identifier to use. Takes one of <literal>mac</literal>, <literal>duid</literal> or <literal>duid-only</literal>.
1552 If set to <literal>mac</literal>, the MAC address of the link is used.
1553 If set to <literal>duid</literal>, an RFC4361-compliant Client ID, which is the combination of IAID and DUID (see below), is used.
1554 If set to <literal>duid-only</literal>, only DUID is used, this may not be RFC compliant, but some setups may require to use this.
1555 Defaults to <literal>duid</literal>.</para>
1556 </listitem>
1557 </varlistentry>
1558
1559 <varlistentry>
1560 <term><varname>VendorClassIdentifier=</varname></term>
1561 <listitem>
1562 <para>The vendor class identifier used to identify vendor
1563 type and configuration.</para>
1564 </listitem>
1565 </varlistentry>
1566
1567 <varlistentry>
1568 <term><varname>UserClass=</varname></term>
1569 <listitem>
1570 <para>A DHCPv4 client can use UserClass option to identify the type or category of user or applications
1571 it represents. The information contained in this option is a string that represents the user class of which
1572 the client is a member. Each class sets an identifying string of information to be used by the DHCP
1573 service to classify clients. Takes a whitespace-separated list of strings.</para>
1574 </listitem>
1575 </varlistentry>
1576
1577 <varlistentry>
1578 <term><varname>MaxAttempts=</varname></term>
1579 <listitem>
1580 <para>Specifies how many times the DHCPv4 client configuration should be attempted. Takes a
1581 number or <literal>infinity</literal>. Defaults to <literal>infinity</literal>.
1582 Note that the time between retries is increased exponentially, so the network will not be
1583 overloaded even if this number is high.</para>
1584 </listitem>
1585 </varlistentry>
1586
1587 <varlistentry>
1588 <term><varname>DUIDType=</varname></term>
1589 <listitem>
1590 <para>Override the global <varname>DUIDType</varname> setting for this network. See
1591 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
1592 for a description of possible values.</para>
1593 </listitem>
1594 </varlistentry>
1595
1596 <varlistentry>
1597 <term><varname>DUIDRawData=</varname></term>
1598 <listitem>
1599 <para>Override the global <varname>DUIDRawData</varname> setting for this network. See
1600 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>
1601 for a description of possible values.</para>
1602 </listitem>
1603 </varlistentry>
1604
1605 <varlistentry>
1606 <term><varname>IAID=</varname></term>
1607 <listitem>
1608 <para>The DHCP Identity Association Identifier (IAID) for the interface, a 32-bit unsigned integer.</para>
1609 </listitem>
1610 </varlistentry>
1611
1612 <varlistentry>
1613 <term><varname>RequestBroadcast=</varname></term>
1614 <listitem>
1615 <para>Request the server to use broadcast messages before
1616 the IP address has been configured. This is necessary for
1617 devices that cannot receive RAW packets, or that cannot
1618 receive packets at all before an IP address has been
1619 configured. On the other hand, this must not be enabled on
1620 networks where broadcasts are filtered out.</para>
1621 </listitem>
1622 </varlistentry>
1623
1624 <varlistentry>
1625 <term><varname>RouteMetric=</varname></term>
1626 <listitem>
1627 <para>Set the routing metric for routes specified by the
1628 DHCP server.</para>
1629 </listitem>
1630 </varlistentry>
1631
1632 <varlistentry>
1633 <term><varname>RouteTable=<replaceable>num</replaceable></varname></term>
1634 <listitem>
1635 <para>The table identifier for DHCP routes (a number between 1 and 4294967295, or 0 to unset).
1636 The table can be retrieved using <command>ip route show table <replaceable>num</replaceable></command>.
1637 </para>
1638 <para>When used in combination with <varname>VRF=</varname> the
1639 VRF's routing table is used unless this parameter is specified.
1640 </para>
1641 </listitem>
1642 </varlistentry>
1643
1644 <varlistentry>
1645 <term><varname>RouteMTUBytes=</varname></term>
1646 <listitem>
1647 <para>Specifies the MTU for the DHCP routes. Please see the [Route] section for further details.</para>
1648 </listitem>
1649 </varlistentry>
1650
1651 <varlistentry>
1652 <term><varname>ListenPort=</varname></term>
1653 <listitem>
1654 <para>Allow setting custom port for the DHCP client to listen on.</para>
1655 </listitem>
1656 </varlistentry>
1657
1658 <varlistentry>
1659 <term><varname>SendRelease=</varname></term>
1660 <listitem>
1661 <para>When true, the DHCPv4 client sends a DHCP release packet when it stops.
1662 Defaults to true.</para>
1663 </listitem>
1664 </varlistentry>
1665
1666 <varlistentry>
1667 <term><varname>SendDecline=</varname></term>
1668 <listitem>
1669 <para>A boolen. When <literal>true</literal>, DHCPv4 clients receives IP address from DHCP server.
1670 After new IP is received, DHCPv4 performs IPv4 Duplicate Address Detection. If duplicate use of IP is detected
1671 the DHCPv4 client rejects the IP by sending a DHCPDECLINE packet DHCP clients try to obtain an IP address again.
1672 See <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5224</ulink>.
1673 Defaults to <literal>unset</literal>.</para>
1674 </listitem>
1675 </varlistentry>
1676
1677 <varlistentry>
1678 <term><varname>BlackList=</varname></term>
1679 <listitem>
1680 <para>A whitespace-separated list of IPv4 addresses. DHCP offers from servers in the list are rejected.</para>
1681 </listitem>
1682 </varlistentry>
1683
1684 <varlistentry>
1685 <term><varname>RequestOptions=</varname></term>
1686 <listitem>
1687 <para>A whitespace-separated list of integers in the range 1–254.</para>
1688 </listitem>
1689 </varlistentry>
1690
1691 <varlistentry>
1692 <term><varname>SendOption=</varname></term>
1693 <listitem>
1694 <para>Send an arbitrary option in the DHCPv4 request. Takes a DHCP option number, data type
1695 and data separated with a colon
1696 (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>).
1697 The option number must be an integer in the range 1..254. The type takes one of <literal>uint8</literal>,
1698 <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, or
1699 <literal>string</literal>. Special characters in the data string may be escaped using
1700 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
1701 escapes</ulink>. This setting can be specified multiple times. If an empty string is specified,
1702 then all options specified earlier are cleared. Defaults to unset.</para>
1703 </listitem>
1704 </varlistentry>
1705 </variablelist>
1706 </refsect1>
1707
1708 <refsect1>
1709 <title>[DHCPv6] Section Options</title>
1710 <para>The <literal>[DHCPv6]</literal> section configures the DHCPv6 client, if it is enabled with the
1711 <varname>DHCP=</varname> setting described above, or invoked by the IPv6 Router Advertisement:</para>
1712
1713 <variablelist class='network-directives'>
1714 <varlistentry>
1715 <term><varname>UseDNS=</varname></term>
1716 <term><varname>UseNTP=</varname></term>
1717 <listitem>
1718 <para>As in the <literal>[DHCPv4]</literal> section.</para>
1719 </listitem>
1720 </varlistentry>
1721
1722 <varlistentry>
1723 <term><varname>RapidCommit=</varname></term>
1724 <listitem>
1725 <para>Takes a boolean. The DHCPv6 client can obtain configuration parameters from a DHCPv6 server through
1726 a rapid two-message exchange (solicit and reply). When the rapid commit option is enabled by both
1727 the DHCPv6 client and the DHCPv6 server, the two-message exchange is used, rather than the default
1728 four-method exchange (solicit, advertise, request, and reply). The two-message exchange provides
1729 faster client configuration and is beneficial in environments in which networks are under a heavy load.
1730 See <ulink url="https://tools.ietf.org/html/rfc3315#section-17.2.1">RFC 3315</ulink> for details.
1731 Defaults to true.</para>
1732 </listitem>
1733 </varlistentry>
1734
1735 <varlistentry>
1736 <term><varname>ForceDHCPv6PDOtherInformation=</varname></term>
1737 <listitem>
1738 <para>Takes a boolean that enforces DHCPv6 stateful mode when the 'Other information' bit is set in
1739 Router Advertisement messages. By default setting only the 'O' bit in Router Advertisements
1740 makes DHCPv6 request network information in a stateless manner using a two-message Information
1741 Request and Information Reply message exchange.
1742 <ulink url="https://tools.ietf.org/html/rfc7084">RFC 7084</ulink>, requirement WPD-4, updates
1743 this behavior for a Customer Edge router so that stateful DHCPv6 Prefix Delegation is also
1744 requested when only the 'O' bit is set in Router Advertisements. This option enables such a CE
1745 behavior as it is impossible to automatically distinguish the intention of the 'O' bit otherwise.
1746 By default this option is set to 'false', enable it if no prefixes are delegated when the device
1747 should be acting as a CE router.</para>
1748 </listitem>
1749 </varlistentry>
1750
1751 <varlistentry>
1752 <term><varname>PrefixDelegationHint=</varname></term>
1753 <listitem>
1754 <para>Takes an IPv6 address with prefix length as <varname>Address=</varname> in
1755 the "[Network]" section. Specifies the DHCPv6 client for the requesting router to include
1756 a prefix-hint in the DHCPv6 solicitation. Prefix ranges 1-128. Defaults to unset.</para>
1757 </listitem>
1758 </varlistentry>
1759 </variablelist>
1760 </refsect1>
1761
1762 <refsect1>
1763 <title>[IPv6AcceptRA] Section Options</title>
1764 <para>The <literal>[IPv6AcceptRA]</literal> section configures the IPv6 Router Advertisement
1765 (RA) client, if it is enabled with the <varname>IPv6AcceptRA=</varname> setting described
1766 above:</para>
1767
1768 <variablelist class='network-directives'>
1769 <varlistentry>
1770 <term><varname>UseDNS=</varname></term>
1771 <listitem>
1772 <para>When true (the default), the DNS servers received in the Router Advertisement will be used and take
1773 precedence over any statically configured ones.</para>
1774
1775 <para>This corresponds to the <option>nameserver</option> option in <citerefentry
1776 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
1777 </listitem>
1778 </varlistentry>
1779
1780 <varlistentry>
1781 <term><varname>UseDomains=</varname></term>
1782 <listitem>
1783 <para>Takes a boolean, or the special value <literal>route</literal>. When true, the domain name
1784 received via IPv6 Router Advertisement (RA) will be used as DNS search domain over this link, similar to
1785 the effect of the <option>Domains=</option> setting. If set to <literal>route</literal>, the domain name
1786 received via IPv6 RA will be used for routing DNS queries only, but not for searching, similar to the
1787 effect of the <option>Domains=</option> setting when the argument is prefixed with
1788 <literal>~</literal>. Defaults to false.</para>
1789
1790 <para>It is recommended to enable this option only on trusted networks, as setting this affects resolution
1791 of all host names, in particular of single-label names. It is generally safer to use the supplied domain
1792 only as routing domain, rather than as search domain, in order to not have it affect local resolution of
1793 single-label names.</para>
1794
1795 <para>When set to true, this setting corresponds to the <option>domain</option> option in <citerefentry
1796 project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
1797 </listitem>
1798 </varlistentry>
1799
1800 <varlistentry>
1801 <term><varname>RouteTable=<replaceable>num</replaceable></varname></term>
1802 <listitem>
1803 <para>The table identifier for the routes received in the Router Advertisement
1804 (a number between 1 and 4294967295, or 0 to unset).
1805 The table can be retrieved using <command>ip route show table <replaceable>num</replaceable></command>.
1806 </para>
1807 </listitem>
1808 </varlistentry>
1809
1810 <varlistentry>
1811 <term><varname>UseAutonomousPrefix=</varname></term>
1812 <listitem>
1813 <para>When true (the default), the autonomous prefix received in the Router Advertisement will be used and take
1814 precedence over any statically configured ones.</para>
1815 </listitem>
1816 </varlistentry>
1817
1818 <varlistentry>
1819 <term><varname>UseOnLinkPrefix=</varname></term>
1820 <listitem>
1821 <para>When true (the default), the onlink prefix received in the Router Advertisement will be used and take
1822 precedence over any statically configured ones.</para>
1823 </listitem>
1824 </varlistentry>
1825
1826 <varlistentry>
1827 <term><varname>BlackList=</varname></term>
1828 <listitem>
1829 <para>A whitespace-separated list of IPv6 prefixes. IPv6 prefixes supplied via router advertisements in the list are ignored.</para>
1830 </listitem>
1831 </varlistentry>
1832
1833 </variablelist>
1834 </refsect1>
1835
1836 <refsect1>
1837 <title>[DHCPServer] Section Options</title>
1838 <para>The <literal>[DHCPServer]</literal> section contains
1839 settings for the DHCP server, if enabled via the
1840 <varname>DHCPServer=</varname> option described above:</para>
1841
1842 <variablelist class='network-directives'>
1843
1844 <varlistentry>
1845 <term><varname>PoolOffset=</varname></term>
1846 <term><varname>PoolSize=</varname></term>
1847
1848 <listitem><para>Configures the pool of addresses to hand out. The pool
1849 is a contiguous sequence of IP addresses in the subnet configured for
1850 the server address, which does not include the subnet nor the broadcast
1851 address. <varname>PoolOffset=</varname> takes the offset of the pool
1852 from the start of subnet, or zero to use the default value.
1853 <varname>PoolSize=</varname> takes the number of IP addresses in the
1854 pool or zero to use the default value. By default, the pool starts at
1855 the first address after the subnet address and takes up the rest of
1856 the subnet, excluding the broadcast address. If the pool includes
1857 the server address (the default), this is reserved and not handed
1858 out to clients.</para></listitem>
1859 </varlistentry>
1860
1861 <varlistentry>
1862 <term><varname>DefaultLeaseTimeSec=</varname></term>
1863 <term><varname>MaxLeaseTimeSec=</varname></term>
1864
1865 <listitem><para>Control the default and maximum DHCP lease
1866 time to pass to clients. These settings take time values in seconds or
1867 another common time unit, depending on the suffix. The default
1868 lease time is used for clients that did not ask for a specific
1869 lease time. If a client asks for a lease time longer than the
1870 maximum lease time, it is automatically shortened to the
1871 specified time. The default lease time defaults to 1h, the
1872 maximum lease time to 12h. Shorter lease times are beneficial
1873 if the configuration data in DHCP leases changes frequently
1874 and clients shall learn the new settings with shorter
1875 latencies. Longer lease times reduce the generated DHCP
1876 network traffic.</para></listitem>
1877 </varlistentry>
1878
1879 <varlistentry>
1880 <term><varname>EmitDNS=</varname></term>
1881 <term><varname>DNS=</varname></term>
1882
1883 <listitem><para>Takes a boolean. Configures whether the DHCP leases handed out
1884 to clients shall contain DNS server information. Defaults to <literal>yes</literal>.
1885 The DNS servers to pass to clients may be configured with the
1886 <varname>DNS=</varname> option, which takes a list of IPv4
1887 addresses. If the <varname>EmitDNS=</varname> option is
1888 enabled but no servers configured, the servers are
1889 automatically propagated from an "uplink" interface that has
1890 appropriate servers set. The "uplink" interface is determined
1891 by the default route of the system with the highest
1892 priority. Note that this information is acquired at the time
1893 the lease is handed out, and does not take uplink interfaces
1894 into account that acquire DNS or NTP server information at a
1895 later point. DNS server propagation does not take
1896 <filename>/etc/resolv.conf</filename> into account. Also, note
1897 that the leases are not refreshed if the uplink network
1898 configuration changes. To ensure clients regularly acquire the
1899 most current uplink DNS server information, it is thus
1900 advisable to shorten the DHCP lease time via
1901 <varname>MaxLeaseTimeSec=</varname> described
1902 above.</para></listitem>
1903 </varlistentry>
1904
1905 <varlistentry>
1906 <term><varname>EmitNTP=</varname></term>
1907 <term><varname>NTP=</varname></term>
1908
1909 <listitem><para>Similar to the <varname>EmitDNS=</varname> and
1910 <varname>DNS=</varname> settings described above, these
1911 settings configure whether and what NTP server information
1912 shall be emitted as part of the DHCP lease. The same syntax,
1913 propagation semantics and defaults apply as for
1914 <varname>EmitDNS=</varname> and
1915 <varname>DNS=</varname>.</para></listitem>
1916 </varlistentry>
1917
1918 <varlistentry>
1919 <term><varname>EmitSIP=</varname></term>
1920 <term><varname>SIP=</varname></term>
1921
1922 <listitem><para>Similar to the <varname>EmitDNS=</varname> and
1923 <varname>DNS=</varname> settings described above, these
1924 settings configure whether and what SIP server information
1925 shall be emitted as part of the DHCP lease. The same syntax,
1926 propagation semantics and defaults apply as for
1927 <varname>EmitDNS=</varname> and
1928 <varname>DNS=</varname>.</para></listitem>
1929 </varlistentry>
1930
1931 <varlistentry>
1932 <term><varname>EmitRouter=</varname></term>
1933
1934 <listitem><para>Similar to the <varname>EmitDNS=</varname>
1935 setting described above, this setting configures whether the
1936 DHCP lease should contain the router option. The same syntax,
1937 propagation semantics and defaults apply as for
1938 <varname>EmitDNS=</varname>.</para></listitem>
1939 </varlistentry>
1940
1941 <varlistentry>
1942 <term><varname>EmitTimezone=</varname></term>
1943 <term><varname>Timezone=</varname></term>
1944
1945 <listitem><para>Takes a boolean. Configures whether the DHCP leases handed out
1946 to clients shall contain timezone information. Defaults to <literal>yes</literal>. The
1947 <varname>Timezone=</varname> setting takes a timezone string
1948 (such as <literal>Europe/Berlin</literal> or
1949 <literal>UTC</literal>) to pass to clients. If no explicit
1950 timezone is set, the system timezone of the local host is
1951 propagated, as determined by the
1952 <filename>/etc/localtime</filename> symlink.</para></listitem>
1953 </varlistentry>
1954
1955 <varlistentry>
1956 <term><varname>SendOption=</varname></term>
1957 <listitem>
1958 <para>Send a raw option with value via DHCPv4 server. Takes a DHCP option number, data type
1959 and data (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>).
1960 The option number is an integer in the range 1..254. The type takes one of <literal>uint8</literal>,
1961 <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, or
1962 <literal>string</literal>. Special characters in the data string may be escaped using
1963 <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
1964 escapes</ulink>. This setting can be specified multiple times. If an empty string is specified,
1965 then all options specified earlier are cleared. Defaults to unset.</para>
1966 </listitem>
1967 </varlistentry>
1968
1969 </variablelist>
1970 </refsect1>
1971
1972 <refsect1>
1973 <title>[IPv6PrefixDelegation] Section Options</title>
1974 <para>The <literal>[IPv6PrefixDelegation]</literal> section contains
1975 settings for sending IPv6 Router Advertisements and whether to act as
1976 a router, if enabled via the <varname>IPv6PrefixDelegation=</varname>
1977 option described above. IPv6 network prefixes are defined with one or
1978 more <literal>[IPv6Prefix]</literal> sections.</para>
1979
1980 <variablelist class='network-directives'>
1981
1982 <varlistentry>
1983 <term><varname>Managed=</varname></term>
1984 <term><varname>OtherInformation=</varname></term>
1985
1986 <listitem><para>Takes a boolean. Controls whether a DHCPv6 server is used to acquire IPv6
1987 addresses on the network link when <varname>Managed=</varname>
1988 is set to <literal>true</literal> or if only additional network
1989 information can be obtained via DHCPv6 for the network link when
1990 <varname>OtherInformation=</varname> is set to
1991 <literal>true</literal>. Both settings default to
1992 <literal>false</literal>, which means that a DHCPv6 server is not being
1993 used.</para></listitem>
1994 </varlistentry>
1995
1996 <varlistentry>
1997 <term><varname>RouterLifetimeSec=</varname></term>
1998
1999 <listitem><para>Takes a timespan. Configures the IPv6 router lifetime in seconds. If set,
2000 this host also announces itself in Router Advertisements as an IPv6
2001 router for the network link. When unset, the host is not acting as a router.</para>
2002 </listitem>
2003 </varlistentry>
2004
2005 <varlistentry>
2006 <term><varname>RouterPreference=</varname></term>
2007
2008 <listitem><para>Configures IPv6 router preference if
2009 <varname>RouterLifetimeSec=</varname> is non-zero. Valid values are
2010 <literal>high</literal>, <literal>medium</literal> and
2011 <literal>low</literal>, with <literal>normal</literal> and
2012 <literal>default</literal> added as synonyms for
2013 <literal>medium</literal> just to make configuration easier. See
2014 <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink>
2015 for details. Defaults to <literal>medium</literal>.</para></listitem>
2016 </varlistentry>
2017
2018 <varlistentry>
2019 <term><varname>EmitDNS=</varname></term>
2020 <term><varname>DNS=</varname></term>
2021
2022 <listitem><para><varname>DNS=</varname> specifies a list of recursive
2023 DNS server IPv6 addresses that distributed via Router Advertisement
2024 messages when <varname>EmitDNS=</varname> is true. If <varname>DNS=
2025 </varname> is empty, DNS servers are read from the
2026 <literal>[Network]</literal> section. If the
2027 <literal>[Network]</literal> section does not contain any DNS servers
2028 either, DNS servers from the uplink with the highest priority default
2029 route are used. When <varname>EmitDNS=</varname> is false, no DNS server
2030 information is sent in Router Advertisement messages.
2031 <varname>EmitDNS=</varname> defaults to true.
2032 </para></listitem>
2033 </varlistentry>
2034
2035 <varlistentry>
2036 <term><varname>EmitDomains=</varname></term>
2037 <term><varname>Domains=</varname></term>
2038
2039 <listitem><para>A list of DNS search domains distributed via Router
2040 Advertisement messages when <varname>EmitDomains=</varname> is true. If
2041 <varname>Domains=</varname> is empty, DNS search domains are read from the
2042 <literal>[Network]</literal> section. If the <literal>[Network]</literal>
2043 section does not contain any DNS search domains either, DNS search
2044 domains from the uplink with the highest priority default route are
2045 used. When <varname>EmitDomains=</varname> is false, no DNS search domain
2046 information is sent in Router Advertisement messages.
2047 <varname>EmitDomains=</varname> defaults to true.
2048 </para></listitem>
2049 </varlistentry>
2050
2051 <varlistentry>
2052 <term><varname>DNSLifetimeSec=</varname></term>
2053
2054 <listitem><para>Lifetime in seconds for the DNS server addresses listed
2055 in <varname>DNS=</varname> and search domains listed in
2056 <varname>Domains=</varname>.</para></listitem>
2057 </varlistentry>
2058
2059 </variablelist>
2060 </refsect1>
2061
2062 <refsect1>
2063 <title>[IPv6Prefix] Section Options</title>
2064 <para>One or more <literal>[IPv6Prefix]</literal> sections contain the IPv6
2065 prefixes that are announced via Router Advertisements. See
2066 <ulink url="https://tools.ietf.org/html/rfc4861">RFC 4861</ulink>
2067 for further details.</para>
2068
2069 <variablelist class='network-directives'>
2070
2071 <varlistentry>
2072 <term><varname>AddressAutoconfiguration=</varname></term>
2073 <term><varname>OnLink=</varname></term>
2074
2075 <listitem><para>Takes a boolean to specify whether IPv6 addresses can be
2076 autoconfigured with this prefix and whether the prefix can be used for
2077 onlink determination. Both settings default to <literal>true</literal>
2078 in order to ease configuration.
2079 </para></listitem>
2080 </varlistentry>
2081
2082 <varlistentry>
2083 <term><varname>Prefix=</varname></term>
2084
2085 <listitem><para>The IPv6 prefix that is to be distributed to hosts.
2086 Similarly to configuring static IPv6 addresses, the setting is
2087 configured as an IPv6 prefix and its prefix length, separated by a
2088 <literal>/</literal> character. Use multiple
2089 <literal>[IPv6Prefix]</literal> sections to configure multiple IPv6
2090 prefixes since prefix lifetimes, address autoconfiguration and onlink
2091 status may differ from one prefix to another.</para></listitem>
2092 </varlistentry>
2093
2094 <varlistentry>
2095 <term><varname>PreferredLifetimeSec=</varname></term>
2096 <term><varname>ValidLifetimeSec=</varname></term>
2097
2098 <listitem><para>Preferred and valid lifetimes for the prefix measured in
2099 seconds. <varname>PreferredLifetimeSec=</varname> defaults to 604800
2100 seconds (one week) and <varname>ValidLifetimeSec=</varname> defaults
2101 to 2592000 seconds (30 days).</para></listitem>
2102 </varlistentry>
2103
2104 </variablelist>
2105 </refsect1>
2106
2107 <refsect1>
2108 <title>[IPv6RoutePrefix] Section Options</title>
2109 <para>One or more <literal>[IPv6RoutePrefix]</literal> sections contain the IPv6
2110 prefix routes that are announced via Router Advertisements. See
2111 <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink>
2112 for further details.</para>
2113
2114 <variablelist class='network-directives'>
2115
2116 <varlistentry>
2117 <term><varname>Route=</varname></term>
2118
2119 <listitem><para>The IPv6 route that is to be distributed to hosts.
2120 Similarly to configuring static IPv6 routes, the setting is
2121 configured as an IPv6 prefix routes and its prefix route length,
2122 separated by a<literal>/</literal> character. Use multiple
2123 <literal>[IPv6PrefixRoutes]</literal> sections to configure multiple IPv6
2124 prefix routes.</para></listitem>
2125 </varlistentry>
2126
2127 <varlistentry>
2128 <term><varname>LifetimeSec=</varname></term>
2129
2130 <listitem><para>Lifetime for the route prefix measured in
2131 seconds. <varname>LifetimeSec=</varname> defaults to 604800 seconds (one week).
2132 </para></listitem>
2133 </varlistentry>
2134
2135 </variablelist>
2136 </refsect1>
2137
2138 <refsect1>
2139 <title>[Bridge] Section Options</title>
2140 <para>The <literal>[Bridge]</literal> section accepts the
2141 following keys.</para>
2142 <variablelist class='network-directives'>
2143 <varlistentry>
2144 <term><varname>UnicastFlood=</varname></term>
2145 <listitem>
2146 <para>Takes a boolean. Controls whether the bridge should flood
2147 traffic for which an FDB entry is missing and the destination
2148 is unknown through this port. When unset, the kernel's default will be used.
2149 </para>
2150 </listitem>
2151 </varlistentry>
2152 <varlistentry>
2153 <term><varname>MulticastFlood=</varname></term>
2154 <listitem>
2155 <para>Takes a boolean. Controls whether the bridge should flood
2156 traffic for which an MDB entry is missing and the destination
2157 is unknown through this port. When unset, the kernel's default will be used.
2158 </para>
2159 </listitem>
2160 </varlistentry>
2161 <varlistentry>
2162 <term><varname>MulticastToUnicast=</varname></term>
2163 <listitem>
2164 <para>Takes a boolean. Multicast to unicast works on top of the multicast snooping feature of
2165 the bridge. Which means unicast copies are only delivered to hosts which are interested in it.
2166 When unset, the kernel's default will be used.
2167 </para>
2168 </listitem>
2169 </varlistentry>
2170 <varlistentry>
2171 <term><varname>NeighborSuppression=</varname></term>
2172 <listitem>
2173 <para>Takes a boolean. Configures whether ARP and ND neighbor suppression is enabled for
2174 this port. When unset, the kernel's default will be used.
2175 </para>
2176 </listitem>
2177 </varlistentry>
2178 <varlistentry>
2179 <term><varname>Learning=</varname></term>
2180 <listitem>
2181 <para>Takes a boolean. Configures whether MAC address learning is enabled for
2182 this port. When unset, the kernel's default will be used.
2183 </para>
2184 </listitem>
2185 </varlistentry>
2186 <varlistentry>
2187 <term><varname>HairPin=</varname></term>
2188 <listitem>
2189 <para>Takes a boolean. Configures whether traffic may be sent back
2190 out of the port on which it was received. When this flag is false, and the bridge
2191 will not forward traffic back out of the receiving port.
2192 When unset, the kernel's default will be used.</para>
2193 </listitem>
2194 </varlistentry>
2195 <varlistentry>
2196 <term><varname>UseBPDU=</varname></term>
2197 <listitem>
2198 <para>Takes a boolean. Configures whether STP Bridge Protocol Data Units will be
2199 processed by the bridge port. When unset, the kernel's default will be used.</para>
2200 </listitem>
2201 </varlistentry>
2202 <varlistentry>
2203 <term><varname>FastLeave=</varname></term>
2204 <listitem>
2205 <para>Takes a boolean. This flag allows the bridge to immediately stop multicast
2206 traffic on a port that receives an IGMP Leave message. It is only used with
2207 IGMP snooping if enabled on the bridge. When unset, the kernel's default will be used.</para>
2208 </listitem>
2209 </varlistentry>
2210 <varlistentry>
2211 <term><varname>AllowPortToBeRoot=</varname></term>
2212 <listitem>
2213 <para>Takes a boolean. Configures whether a given port is allowed to
2214 become a root port. Only used when STP is enabled on the bridge.
2215 When unset, the kernel's default will be used.</para>
2216 </listitem>
2217 </varlistentry>
2218 <varlistentry>
2219 <term><varname>ProxyARP=</varname></term>
2220 <listitem>
2221 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port.
2222 When unset, the kernel's default will be used.</para>
2223 </listitem>
2224 </varlistentry>
2225 <varlistentry>
2226 <term><varname>ProxyARPWiFi=</varname></term>
2227 <listitem>
2228 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port
2229 which meets extended requirements by IEEE 802.11 and Hotspot 2.0 specifications.
2230 When unset, the kernel's default will be used.</para>
2231 </listitem>
2232 </varlistentry>
2233 <varlistentry>
2234 <term><varname>MulticastRouter=</varname></term>
2235 <listitem>
2236 <para>Configures this port for having multicast routers attached. A port with a multicast
2237 router will receive all multicast traffic. Takes one of <literal>no</literal>
2238 to disable multicast routers on this port, <literal>query</literal> to let the system detect
2239 the presence of routers, <literal>permanent</literal> to permanently enable multicast traffic
2240 forwarding on this port, or <literal>temporary</literal> to enable multicast routers temporarily
2241 on this port, not depending on incoming queries. When unset, the kernel's default will be used.</para>
2242 </listitem>
2243 </varlistentry>
2244 <varlistentry>
2245 <term><varname>Cost=</varname></term>
2246 <listitem>
2247 <para>Sets the "cost" of sending packets of this interface.
2248 Each port in a bridge may have a different speed and the cost
2249 is used to decide which link to use. Faster interfaces
2250 should have lower costs. It is an integer value between 1 and
2251 65535.</para>
2252 </listitem>
2253 </varlistentry>
2254 <varlistentry>
2255 <term><varname>Priority=</varname></term>
2256 <listitem>
2257 <para>Sets the "priority" of sending packets on this interface.
2258 Each port in a bridge may have a different priority which is used
2259 to decide which link to use. Lower value means higher priority.
2260 It is an integer value between 0 to 63. Networkd does not set any
2261 default, meaning the kernel default value of 32 is used.</para>
2262 </listitem>
2263 </varlistentry>
2264 </variablelist>
2265 </refsect1>
2266 <refsect1>
2267 <title>[BridgeFDB] Section Options</title>
2268 <para>The <literal>[BridgeFDB]</literal> section manages the
2269 forwarding database table of a port and accepts the following
2270 keys. Specify several <literal>[BridgeFDB]</literal> sections to
2271 configure several static MAC table entries.</para>
2272
2273 <variablelist class='network-directives'>
2274 <varlistentry>
2275 <term><varname>MACAddress=</varname></term>
2276 <listitem>
2277 <para>As in the <literal>[Network]</literal> section. This
2278 key is mandatory.</para>
2279 </listitem>
2280 </varlistentry>
2281 <varlistentry>
2282 <term><varname>Destination=</varname></term>
2283 <listitem>
2284 <para>Takes an IP address of the destination VXLAN tunnel endpoint.</para>
2285 </listitem>
2286 </varlistentry>
2287 <varlistentry>
2288 <term><varname>VLANId=</varname></term>
2289 <listitem>
2290 <para>The VLAN ID for the new static MAC table entry. If
2291 omitted, no VLAN ID information is appended to the new static MAC
2292 table entry.</para>
2293 </listitem>
2294 </varlistentry>
2295 <varlistentry>
2296 <term><varname>VNI=</varname></term>
2297 <listitem>
2298 <para>The VXLAN Network Identifier (or VXLAN Segment ID) to use to connect to
2299 the remote VXLAN tunnel endpoint. Takes a number in the range 1-16777215.
2300 Defaults to unset.</para>
2301 </listitem>
2302 </varlistentry>
2303 <varlistentry>
2304 <term><varname>AssociatedWith=</varname></term>
2305 <listitem>
2306 <para>Specifies where the address is associated with. Takes one of <literal>use</literal>,
2307 <literal>self</literal>, <literal>master</literal> or <literal>router</literal>.
2308 <literal>use</literal> means the address is in use. User space can use this option to
2309 indicate to the kernel that the fdb entry is in use. <literal>self</literal> means
2310 the address is associated with the port drivers fdb. Usually hardware. <literal>master</literal>
2311 means the address is associated with master devices fdb. <literal>router</literal> means
2312 the destination address is associated with a router. Note that it's valid if the referenced
2313 device is a VXLAN type device and has route shortcircuit enabled. Defaults to <literal>self</literal>.</para>
2314 </listitem>
2315 </varlistentry>
2316 </variablelist>
2317 </refsect1>
2318
2319 <refsect1>
2320 <title>[CAN] Section Options</title>
2321 <para>The <literal>[CAN]</literal> section manages the Controller Area Network (CAN bus) and accepts the
2322 following keys.</para>
2323 <variablelist class='network-directives'>
2324 <varlistentry>
2325 <term><varname>BitRate=</varname></term>
2326 <listitem>
2327 <para>The bitrate of CAN device in bits per second. The usual SI prefixes (K, M) with the base of 1000 can
2328 be used here.</para>
2329 </listitem>
2330 </varlistentry>
2331 <varlistentry>
2332 <term><varname>SamplePoint=</varname></term>
2333 <listitem>
2334 <para>Optional sample point in percent with one decimal (e.g. <literal>75%</literal>,
2335 <literal>87.5%</literal>) or permille (e.g. <literal>875‰</literal>).</para>
2336 </listitem>
2337 </varlistentry>
2338 <varlistentry>
2339 <term><varname>RestartSec=</varname></term>
2340 <listitem>
2341 <para>Automatic restart delay time. If set to a non-zero value, a restart of the CAN controller will be
2342 triggered automatically in case of a bus-off condition after the specified delay time. Subsecond delays can
2343 be specified using decimals (e.g. <literal>0.1s</literal>) or a <literal>ms</literal> or
2344 <literal>us</literal> postfix. Using <literal>infinity</literal> or <literal>0</literal> will turn the
2345 automatic restart off. By default automatic restart is disabled.</para>
2346 </listitem>
2347 </varlistentry>
2348 <varlistentry>
2349 <term><varname>TripleSampling=</varname></term>
2350 <listitem>
2351 <para>Takes a boolean. When <literal>yes</literal>, three samples (instead of one) are used to determine
2352 the value of a received bit by majority rule. When unset, the kernel's default will be used.</para>
2353 </listitem>
2354 </varlistentry>
2355 </variablelist>
2356 </refsect1>
2357
2358 <refsect1>
2359 <title>[TrafficControlQueueingDiscipline] Section Options</title>
2360 <para>The <literal>[TrafficControlQueueingDiscipline]</literal> section manages the Traffic control. It can be used
2361 to configure the kernel packet scheduler and simulate packet delay and loss for UDP or TCP applications,
2362 or limit the bandwidth usage of a particular service to simulate internet connections.</para>
2363
2364 <variablelist class='network-directives'>
2365 <varlistentry>
2366 <term><varname>Parent=</varname></term>
2367 <listitem>
2368 <para>Specifies the parent Queueing Discipline (qdisc). Takes one of <literal>root</literal>,
2369 <literal>clsact</literal> or <literal>ingress</literal>. Defaults to <literal>root</literal>.</para>
2370 </listitem>
2371 </varlistentry>
2372
2373 <varlistentry>
2374 <term><varname>NetworkEmulatorDelaySec=</varname></term>
2375 <listitem>
2376 <para>Specifies the fixed amount of delay to be added to all packets going out of the
2377 interface. Defaults to unset.</para>
2378 </listitem>
2379 </varlistentry>
2380
2381 <varlistentry>
2382 <term><varname>NetworkEmulatorDelayJitterSec=</varname></term>
2383 <listitem>
2384 <para>Specifies the chosen delay to be added to the packets outgoing to the network
2385 interface. Defaults to unset.</para>
2386 </listitem>
2387 </varlistentry>
2388
2389 <varlistentry>
2390 <term><varname>NetworkEmulatorPacketLimit=</varname></term>
2391 <listitem>
2392 <para>Specifies the maximum number of packets the qdisc may hold queued at a time.
2393 An unsigned integer ranges 0 to 4294967294. Defaults to 1000.</para>
2394 </listitem>
2395 </varlistentry>
2396
2397 <varlistentry>
2398 <term><varname>NetworkEmulatorLossRate=</varname></term>
2399 <listitem>
2400 <para>Specifies an independent loss probability to be added to the packets outgoing from the
2401 network interface. Takes a percentage value, suffixed with "%". Defaults to unset.</para>
2402 </listitem>
2403 </varlistentry>
2404
2405 <varlistentry>
2406 <term><varname>NetworkEmulatorDuplicateRate=</varname></term>
2407 <listitem>
2408 <para>Specifies that the chosen percent of packets is duplicated before queuing them.
2409 Takes a percentage value, suffixed with "%". Defaults to unset.</para>
2410 </listitem>
2411 </varlistentry>
2412
2413 <varlistentry>
2414 <term><varname>TokenBufferFilterLatencySec=</varname></term>
2415 <listitem>
2416 <para>Specifies the latency parameter, which specifies the maximum amount of time a
2417 packet can sit in the Token Buffer Filter (TBF). Defaults to unset.</para>
2418 </listitem>
2419 </varlistentry>
2420
2421 <varlistentry>
2422 <term><varname>TokenBufferFilterLimitSize=</varname></term>
2423 <listitem>
2424 <para>Takes the number of bytes that can be queued waiting for tokens to become available.
2425 When the size is suffixed with K, M, or G, it is parsed as Kilobytes, Megabytes, or Gigabytes,
2426 respectively, to the base of 1000. Defaults to unset.</para>
2427 </listitem>
2428 </varlistentry>
2429
2430 <varlistentry>
2431 <term><varname>TokenBufferFilterBurst=</varname></term>
2432 <listitem>
2433 <para>Specifies the size of the bucket. This is the maximum amount of bytes that tokens
2434 can be available for instantaneous transfer. When the size is suffixed with K, M, or G, it is
2435 parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1000. Defaults to
2436 unset.</para>
2437 </listitem>
2438 </varlistentry>
2439
2440 <varlistentry>
2441 <term><varname>TokenBufferFilterRate=</varname></term>
2442 <listitem>
2443 <para>Specifies the device specific bandwidth. When suffixed with K, M, or G, the specified
2444 bandwidth is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1000.
2445 Defaults to unset.</para>
2446 </listitem>
2447 </varlistentry>
2448
2449 <varlistentry>
2450 <term><varname>TokenBufferFilterMPUBytes=</varname></term>
2451 <listitem>
2452 <para>The Minimum Packet Unit (MPU) determines the minimal token usage (specified in bytes)
2453 for a packet. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
2454 Megabytes, or Gigabytes, respectively, to the base of 1000. Defaults to zero.</para>
2455 </listitem>
2456 </varlistentry>
2457
2458 <varlistentry>
2459 <term><varname>TokenBufferFilterPeakRate=</varname></term>
2460 <listitem>
2461 <para>Takes the maximum depletion rate of the bucket. When suffixed with K, M, or G, the
2462 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
2463 1000. Defaults to unset.</para>
2464 </listitem>
2465 </varlistentry>
2466
2467 <varlistentry>
2468 <term><varname>TokenBufferFilterMTUBytes=</varname></term>
2469 <listitem>
2470 <para>Specifies the size of the peakrate bucket. When suffixed with K, M, or G, the specified
2471 size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1000.
2472 Defaults to unset.</para>
2473 </listitem>
2474 </varlistentry>
2475
2476 <varlistentry>
2477 <term><varname>StochasticFairnessQueueingPerturbPeriodSec=</varname></term>
2478 <listitem>
2479 <para>Specifies the interval in seconds for queue algorithm perturbation. Defaults to unset.</para>
2480 </listitem>
2481 </varlistentry>
2482
2483 <varlistentry>
2484 <term><varname>ControlledDelayPacketLimit=</varname></term>
2485 <listitem>
2486 <para>Specifies the hard lmit on the queue size in number of packets. When this limit is reached, incoming packets are
2487 dropped. An unsigned integer ranges 0 to 4294967294. Defaults to unset and kernel's default is used.</para>
2488 </listitem>
2489 </varlistentry>
2490
2491 <varlistentry>
2492 <term><varname>ControlledDelayTargetSec=</varname></term>
2493 <listitem>
2494 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay.
2495 Defaults to unset and kernel's default is used.</para>
2496 </listitem>
2497 </varlistentry>
2498
2499 <varlistentry>
2500 <term><varname>ControlledDelayIntervalSec=</varname></term>
2501 <listitem>
2502 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not
2503 become too stale. Defaults to unset and kernel's default is used.</para>
2504 </listitem>
2505 </varlistentry>
2506
2507 <varlistentry>
2508 <term><varname>ControlledDelayECN=</varname></term>
2509 <listitem>
2510 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to
2511 unset and kernel's default is used.</para>
2512 </listitem>
2513 </varlistentry>
2514
2515 <varlistentry>
2516 <term><varname>ControlledDelayCEThresholdSec=</varname></term>
2517 <listitem>
2518 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
2519 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para>
2520 </listitem>
2521 </varlistentry>
2522
2523 <varlistentry>
2524 <term><varname>FairQueuingControlledDelayPacketLimit=</varname></term>
2525 <listitem>
2526 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are
2527 dropped. Defaults to unset and kernel's default is used.</para>
2528 </listitem>
2529 </varlistentry>
2530
2531 <varlistentry>
2532 <term><varname>FairQueuingControlledDelayMemoryLimit=</varname></term>
2533 <listitem>
2534 <para>Specifies the limit on the total number of bytes that can be queued in this FQ-CoDel instance.
2535 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
2536 respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para>
2537 </listitem>
2538 </varlistentry>
2539
2540 <varlistentry>
2541 <term><varname>FairQueuingControlledDelayFlows=</varname></term>
2542 <listitem>
2543 <para>Specifies the number of flows into which the incoming packets are classified.
2544 Defaults to unset and kernel's default is used.</para>
2545 </listitem>
2546 </varlistentry>
2547
2548 <varlistentry>
2549 <term><varname>FairQueuingControlledDelayTargetSec=</varname></term>
2550 <listitem>
2551 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay.
2552 Defaults to unset and kernel's default is used.</para>
2553 </listitem>
2554 </varlistentry>
2555
2556 <varlistentry>
2557 <term><varname>FairQueuingControlledDelayIntervalSec=</varname></term>
2558 <listitem>
2559 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not
2560 become too stale. Defaults to unset and kernel's default is used.</para>
2561 </listitem>
2562 </varlistentry>
2563
2564 <varlistentry>
2565 <term><varname>FairQueuingControlledDelayQuantum=</varname></term>
2566 <listitem>
2567 <para>Specifies the number of bytes used as 'deficit' in the fair queuing algorithmtimespan.
2568 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
2569 respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para>
2570 </listitem>
2571 </varlistentry>
2572
2573 <varlistentry>
2574 <term><varname>FairQueuingControlledDelayECN=</varname></term>
2575 <listitem>
2576 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to
2577 unset and kernel's default is used.</para>
2578 </listitem>
2579 </varlistentry>
2580
2581 <varlistentry>
2582 <term><varname>FairQueuingControlledDelayCEThresholdSec=</varname></term>
2583 <listitem>
2584 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
2585 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para>
2586 </listitem>
2587 </varlistentry>
2588
2589 <varlistentry>
2590 <term><varname>FairQueueTrafficPolicingPacketLimit=</varname></term>
2591 <listitem>
2592 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are
2593 dropped. Defaults to unset and kernel's default is used.</para>
2594 </listitem>
2595 </varlistentry>
2596
2597 <varlistentry>
2598 <term><varname>FairQueueTrafficPolicingFlowLimit=</varname></term>
2599 <listitem>
2600 <para>Specifies the hard limit on the maximum number of packets queued per flow. Defaults to
2601 unset and kernel's default is used.</para>
2602 </listitem>
2603 </varlistentry>
2604
2605 <varlistentry>
2606 <term><varname>FairQueueTrafficPolicingQuantum=</varname></term>
2607 <listitem>
2608 <para>Specifies the credit per dequeue RR round, i.e. the amount of bytes a flow is allowed
2609 to dequeue at once. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
2610 Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and kernel's
2611 default is used.</para>
2612 </listitem>
2613 </varlistentry>
2614
2615 <varlistentry>
2616 <term><varname>FairQueueTrafficPolicingInitialQuantum=</varname></term>
2617 <listitem>
2618 <para>Specifies the initial sending rate credit, i.e. the amount of bytes a new flow is
2619 allowed to dequeue initially. When suffixed with K, M, or G, the specified size is parsed as
2620 Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and
2621 kernel's default is used.</para>
2622 </listitem>
2623 </varlistentry>
2624
2625 <varlistentry>
2626 <term><varname>FairQueueTrafficPolicingMaximumRate=</varname></term>
2627 <listitem>
2628 <para>Specifies the maximum sending rate of a flow. When suffixed with K, M, or G, the
2629 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
2630 1000. Defaults to unset and kernel's default is used.</para>
2631 </listitem>
2632 </varlistentry>
2633
2634 <varlistentry>
2635 <term><varname>FairQueueTrafficPolicingBuckets=</varname></term>
2636 <listitem>
2637 <para>Specifies the size of the hash table used for flow lookups. Defaults to unset and
2638 kernel's default is used.</para>
2639 </listitem>
2640 </varlistentry>
2641
2642 <varlistentry>
2643 <term><varname>FairQueueTrafficPolicingOrphanMask=</varname></term>
2644 <listitem>
2645 <para>Takes an unsigned integer. For packets not owned by a socket, fq is able to mask a part
2646 of hash and reduce number of buckets associated with the traffic. Defaults to unset and
2647 kernel's default is used.</para>
2648 </listitem>
2649 </varlistentry>
2650
2651 <varlistentry>
2652 <term><varname>FairQueueTrafficPolicingPacing=</varname></term>
2653 <listitem>
2654 <para>Takes a boolean, and enables or disables flow pacing. Defaults to unset and kernel's
2655 default is used.</para>
2656 </listitem>
2657 </varlistentry>
2658
2659 <varlistentry>
2660 <term><varname>FairQueueTrafficPolicingCEThresholdSec=</varname></term>
2661 <listitem>
2662 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
2663 Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para>
2664 </listitem>
2665 </varlistentry>
2666
2667 </variablelist>
2668 </refsect1>
2669
2670 <refsect1>
2671 <title>[BridgeVLAN] Section Options</title>
2672 <para>The <literal>[BridgeVLAN]</literal> section manages the VLAN ID configuration of a bridge port and accepts
2673 the following keys. Specify several <literal>[BridgeVLAN]</literal> sections to configure several VLAN entries.
2674 The <varname>VLANFiltering=</varname> option has to be enabled, see <literal>[Bridge]</literal> section in
2675 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para>
2676
2677 <variablelist class='network-directives'>
2678 <varlistentry>
2679 <term><varname>VLAN=</varname></term>
2680 <listitem>
2681 <para>The VLAN ID allowed on the port. This can be either a single ID or a range M-N. VLAN IDs are valid
2682 from 1 to 4094.</para>
2683 </listitem>
2684 </varlistentry>
2685 <varlistentry>
2686 <term><varname>EgressUntagged=</varname></term>
2687 <listitem>
2688 <para>The VLAN ID specified here will be used to untag frames on egress. Configuring
2689 <varname>EgressUntagged=</varname> implicates the use of <varname>VLAN=</varname> above and will enable the
2690 VLAN ID for ingress as well. This can be either a single ID or a range M-N.</para>
2691 </listitem>
2692 </varlistentry>
2693 <varlistentry>
2694 <term><varname>PVID=</varname></term>
2695 <listitem>
2696 <para>The Port VLAN ID specified here is assigned to all untagged frames at ingress.
2697 <varname>PVID=</varname> can be used only once. Configuring <varname>PVID=</varname> implicates the use of
2698 <varname>VLAN=</varname> above and will enable the VLAN ID for ingress as well.</para>
2699 </listitem>
2700 </varlistentry>
2701 </variablelist>
2702 </refsect1>
2703
2704 <refsect1>
2705 <title>Examples</title>
2706 <example>
2707 <title>Static network configuration</title>
2708
2709 <programlisting># /etc/systemd/network/50-static.network
2710 [Match]
2711 Name=enp2s0
2712
2713 [Network]
2714 Address=192.168.0.15/24
2715 Gateway=192.168.0.1</programlisting>
2716
2717 <para>This brings interface <literal>enp2s0</literal> up with a static address. The
2718 specified gateway will be used for a default route.</para>
2719 </example>
2720
2721 <example>
2722 <title>DHCP on ethernet links</title>
2723
2724 <programlisting># /etc/systemd/network/80-dhcp.network
2725 [Match]
2726 Name=en*
2727
2728 [Network]
2729 DHCP=yes</programlisting>
2730
2731 <para>This will enable DHCPv4 and DHCPv6 on all interfaces with names starting with
2732 <literal>en</literal> (i.e. ethernet interfaces).</para>
2733 </example>
2734
2735 <example>
2736 <title>IPv6 Prefix Delegation</title>
2737
2738 <programlisting># /etc/systemd/network/55-ipv6-pd-upstream.network
2739 [Match]
2740 Name=enp1s0
2741
2742 [Network]
2743 DHCP=ipv6</programlisting>
2744
2745 <programlisting># /etc/systemd/network/56-ipv6-pd-downstream.network
2746 [Match]
2747 Name=enp2s0
2748
2749 [Network]
2750 IPv6PrefixDelegation=dhcpv6</programlisting>
2751
2752 <para>This will enable IPv6 PD on the interface enp1s0 as an upstream interface where the
2753 DHCPv6 client is running and enp2s0 as a downstream interface where the prefix is delegated to.</para>
2754 </example>
2755
2756 <example>
2757 <title>A bridge with two enslaved links</title>
2758
2759 <programlisting># /etc/systemd/network/25-bridge-static.network
2760 [Match]
2761 Name=bridge0
2762
2763 [Network]
2764 Address=192.168.0.15/24
2765 Gateway=192.168.0.1
2766 DNS=192.168.0.1</programlisting>
2767
2768 <programlisting># /etc/systemd/network/25-bridge-slave-interface-1.network
2769 [Match]
2770 Name=enp2s0
2771
2772 [Network]
2773 Bridge=bridge0</programlisting>
2774
2775 <programlisting># /etc/systemd/network/25-bridge-slave-interface-2.network
2776 [Match]
2777 Name=wlp3s0
2778
2779 [Network]
2780 Bridge=bridge0</programlisting>
2781
2782 <para>This creates a bridge and attaches devices <literal>enp2s0</literal> and
2783 <literal>wlp3s0</literal> to it. The bridge will have the specified static address
2784 and network assigned, and a default route via the specified gateway will be
2785 added. The specified DNS server will be added to the global list of DNS resolvers.
2786 </para>
2787 </example>
2788
2789 <example>
2790 <title></title>
2791
2792 <programlisting>
2793 # /etc/systemd/network/20-bridge-slave-interface-vlan.network
2794 [Match]
2795 Name=enp2s0
2796
2797 [Network]
2798 Bridge=bridge0
2799
2800 [BridgeVLAN]
2801 VLAN=1-32
2802 PVID=42
2803 EgressUntagged=42
2804
2805 [BridgeVLAN]
2806 VLAN=100-200
2807
2808 [BridgeVLAN]
2809 EgressUntagged=300-400</programlisting>
2810
2811 <para>This overrides the configuration specified in the previous example for the
2812 interface <literal>enp2s0</literal>, and enables VLAN on that bridge port. VLAN IDs
2813 1-32, 42, 100-400 will be allowed. Packets tagged with VLAN IDs 42, 300-400 will be
2814 untagged when they leave on this interface. Untagged packets which arrive on this
2815 interface will be assigned VLAN ID 42.</para>
2816 </example>
2817
2818 <example>
2819 <title>Various tunnels</title>
2820
2821 <programlisting>/etc/systemd/network/25-tunnels.network
2822 [Match]
2823 Name=ens1
2824
2825 [Network]
2826 Tunnel=ipip-tun
2827 Tunnel=sit-tun
2828 Tunnel=gre-tun
2829 Tunnel=vti-tun
2830 </programlisting>
2831
2832 <programlisting>/etc/systemd/network/25-tunnel-ipip.netdev
2833 [NetDev]
2834 Name=ipip-tun
2835 Kind=ipip
2836 </programlisting>
2837
2838 <programlisting>/etc/systemd/network/25-tunnel-sit.netdev
2839 [NetDev]
2840 Name=sit-tun
2841 Kind=sit
2842 </programlisting>
2843
2844 <programlisting>/etc/systemd/network/25-tunnel-gre.netdev
2845 [NetDev]
2846 Name=gre-tun
2847 Kind=gre
2848 </programlisting>
2849
2850 <programlisting>/etc/systemd/network/25-tunnel-vti.netdev
2851 [NetDev]
2852 Name=vti-tun
2853 Kind=vti
2854 </programlisting>
2855
2856 <para>This will bring interface <literal>ens1</literal> up and create an IPIP tunnel,
2857 a SIT tunnel, a GRE tunnel, and a VTI tunnel using it.</para>
2858 </example>
2859
2860 <example>
2861 <title>A bond device</title>
2862
2863 <programlisting># /etc/systemd/network/30-bond1.network
2864 [Match]
2865 Name=bond1
2866
2867 [Network]
2868 DHCP=ipv6
2869 </programlisting>
2870
2871 <programlisting># /etc/systemd/network/30-bond1.netdev
2872 [NetDev]
2873 Name=bond1
2874 Kind=bond
2875 </programlisting>
2876
2877 <programlisting># /etc/systemd/network/30-bond1-dev1.network
2878 [Match]
2879 MACAddress=52:54:00:e9:64:41
2880
2881 [Network]
2882 Bond=bond1
2883 </programlisting>
2884
2885 <programlisting># /etc/systemd/network/30-bond1-dev2.network
2886 [Match]
2887 MACAddress=52:54:00:e9:64:42
2888
2889 [Network]
2890 Bond=bond1
2891 </programlisting>
2892
2893 <para>This will create a bond device <literal>bond1</literal> and enslave the two
2894 devices with MAC addresses 52:54:00:e9:64:41 and 52:54:00:e9:64:42 to it. IPv6 DHCP
2895 will be used to acquire an address.</para>
2896 </example>
2897
2898 <example>
2899 <title>Virtual Routing and Forwarding (VRF)</title>
2900 <para>Add the <literal>bond1</literal> interface to the VRF master interface
2901 <literal>vrf1</literal>. This will redirect routes generated on this interface to be
2902 within the routing table defined during VRF creation. For kernels before 4.8 traffic
2903 won't be redirected towards the VRFs routing table unless specific ip-rules are added.
2904 </para>
2905 <programlisting># /etc/systemd/network/25-vrf.network
2906 [Match]
2907 Name=bond1
2908
2909 [Network]
2910 VRF=vrf1
2911 </programlisting>
2912 </example>
2913
2914 <example>
2915 <title>MacVTap</title>
2916 <para>This brings up a network interface <literal>macvtap-test</literal>
2917 and attaches it to <literal>enp0s25</literal>.</para>
2918 <programlisting># /usr/lib/systemd/network/25-macvtap.network
2919 [Match]
2920 Name=enp0s25
2921
2922 [Network]
2923 MACVTAP=macvtap-test
2924 </programlisting>
2925 </example>
2926
2927 <example>
2928 <title>A Xfrm interface with physical underlying device.</title>
2929
2930 <programlisting># /etc/systemd/network/27-xfrm.netdev
2931 [NetDev]
2932 Name=xfrm0
2933
2934 [Xfrm]
2935 InterfaceId=7</programlisting>
2936
2937 <programlisting># /etc/systemd/network/27-eth0.network
2938 [Match]
2939 Name=eth0
2940
2941 [Network]
2942 Xfrm=xfrm0</programlisting>
2943
2944 <para>This creates a <literal>xfrm0</literal> interface and binds it to the <literal>eth0</literal> device.
2945 This allows hardware based ipsec offloading to the <literal>eth0</literal> nic.
2946 If offloading is not needed, xfrm interfaces can be assigned to the <literal>lo</literal> device.
2947 </para>
2948 </example>
2949 </refsect1>
2950
2951 <refsect1>
2952 <title>See Also</title>
2953 <para>
2954 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
2955 <citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
2956 <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2957 <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2958 <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
2959 </para>
2960 </refsect1>
2961
2962 </refentry>