2 <!DOCTYPE refentry PUBLIC
"-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4 <!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
6 <refentry id=
"systemd.network" conditional='ENABLE_NETWORKD'
7 xmlns:
xi=
"http://www.w3.org/2001/XInclude">
10 <title>systemd.network
</title>
11 <productname>systemd
</productname>
15 <refentrytitle>systemd.network
</refentrytitle>
16 <manvolnum>5</manvolnum>
20 <refname>systemd.network
</refname>
21 <refpurpose>Network configuration
</refpurpose>
25 <para><filename><replaceable>network
</replaceable>.network
</filename></para>
29 <title>Description
</title>
31 <para>A plain ini-style text file that encodes network configuration for matching network
33 <citerefentry><refentrytitle>systemd-networkd
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
34 See
<citerefentry><refentrytitle>systemd.syntax
</refentrytitle><manvolnum>7</manvolnum></citerefentry>
35 for a general description of the syntax.
</para>
37 <para>The main network file must have the extension
<filename>.network
</filename>; other
38 extensions are ignored. Networks are applied to links whenever the links appear.
</para>
40 <para>The
<filename>.network
</filename> files are read from the files located in the system network
41 directories
<filename>/usr/lib/systemd/network
</filename> and
42 <filename>/usr/local/lib/systemd/network
</filename>, the volatile runtime network directory
43 <filename>/run/systemd/network
</filename> and the local administration network directory
44 <filename>/etc/systemd/network
</filename>. All configuration files are collectively sorted and
45 processed in lexical order, regardless of the directories in which they live. However, files with
46 identical filenames replace each other. Files in
<filename>/etc/
</filename> have the highest
47 priority, files in
<filename>/run/
</filename> take precedence over files with the same name under
48 <filename>/usr/
</filename>. This can be used to override a system-supplied configuration file with
49 a local file if needed. As a special case, an empty file (file size
0) or symlink with the same
50 name pointing to
<filename>/dev/null
</filename> disables the configuration file entirely (it is
53 <para>Along with the network file
<filename>foo.network
</filename>, a
"drop-in" directory
54 <filename>foo.network.d/
</filename> may exist. All files with the suffix
55 <literal>.conf
</literal> from this directory will be merged in the alphanumeric order and parsed
56 after the main file itself has been parsed. This is useful to alter or add configuration settings,
57 without having to modify the main configuration file. Each drop-in file must have appropriate
58 section headers.
</para>
60 <para>In addition to
<filename>/etc/systemd/network
</filename>, drop-in
<literal>.d
</literal>
61 directories can be placed in
<filename>/usr/lib/systemd/network
</filename> or
62 <filename>/run/systemd/network
</filename> directories. Drop-in files in
63 <filename>/etc/
</filename> take precedence over those in
<filename>/run/
</filename> which in turn
64 take precedence over those in
<filename>/usr/lib/
</filename>. Drop-in files under any of these
65 directories take precedence over the main network file wherever located.
</para>
69 <title>[Match] Section Options
</title>
71 <para>The network file contains a [Match] section, which determines if a given network file may
72 be applied to a given device; and a [Network] section specifying how the device should be
73 configured. The first (in lexical order) of the network files that matches a given device is
74 applied, all later files are ignored, even if they match as well.
</para>
76 <para>A network file is said to match a network interface if all matches specified by the [Match]
77 section are satisfied. When a network file does not contain valid settings in [Match] section, then
78 the file will match all interfaces and
<command>systemd-networkd
</command> warns about that. Hint:
79 to avoid the warning and to make it clear that all interfaces shall be matched, add the following:
80 <programlisting>Name=*
</programlisting> The following keys are accepted:
</para>
82 <variablelist class='network-directives'
>
83 <xi:include href=
"systemd.link.xml" xpointer=
"mac-address" />
84 <xi:include href=
"systemd.link.xml" xpointer=
"permanent-mac-address" />
85 <xi:include href=
"systemd.link.xml" xpointer=
"path" />
86 <xi:include href=
"systemd.link.xml" xpointer=
"driver" />
87 <xi:include href=
"systemd.link.xml" xpointer=
"type" />
88 <xi:include href=
"systemd.link.xml" xpointer=
"kind" />
89 <xi:include href=
"systemd.link.xml" xpointer=
"property" />
92 <term><varname>Name=
</varname></term>
94 <para>A whitespace-separated list of shell-style globs matching the device name, as exposed
95 by the udev property
<literal>INTERFACE
</literal>, or device's alternative names. If the
96 list is prefixed with a
"!", the test is inverted.
</para>
101 <term><varname>WLANInterfaceType=
</varname></term>
103 <para>A whitespace-separated list of wireless network type. Supported values are
104 <literal>ad-hoc
</literal>,
<literal>station
</literal>,
<literal>ap
</literal>,
105 <literal>ap-vlan
</literal>,
<literal>wds
</literal>,
<literal>monitor
</literal>,
106 <literal>mesh-point
</literal>,
<literal>p2p-client
</literal>,
<literal>p2p-go
</literal>,
107 <literal>p2p-device
</literal>,
<literal>ocb
</literal>, and
<literal>nan
</literal>. If the
108 list is prefixed with a
"!", the test is inverted.
</para>
113 <term><varname>SSID=
</varname></term>
115 <para>A whitespace-separated list of shell-style globs matching the SSID of the currently
116 connected wireless LAN. If the list is prefixed with a
"!", the test is inverted.
</para>
121 <term><varname>BSSID=
</varname></term>
123 <para>A whitespace-separated list of hardware address of the currently connected wireless
124 LAN. Use full colon-, hyphen- or dot-delimited hexadecimal. See the example in
125 <varname>MACAddress=
</varname>. This option may appear more than once, in which case the
126 lists are merged. If the empty string is assigned to this option, the list is reset.
</para>
130 <xi:include href=
"systemd.link.xml" xpointer=
"host" />
131 <xi:include href=
"systemd.link.xml" xpointer=
"virtualization" />
132 <xi:include href=
"systemd.link.xml" xpointer=
"kernel-command-line" />
133 <xi:include href=
"systemd.link.xml" xpointer=
"kernel-version" />
134 <xi:include href=
"systemd.link.xml" xpointer=
"architecture" />
135 <xi:include href=
"systemd.link.xml" xpointer=
"firmware" />
140 <title>[Link] Section Options
</title>
142 <para>The [Link] section accepts the following keys:
</para>
144 <variablelist class='network-directives'
>
146 <term><varname>MACAddress=
</varname></term>
148 <para>The hardware address to set for the device.
</para>
153 <term><varname>MTUBytes=
</varname></term>
155 <para>The maximum transmission unit in bytes to set for the device. The usual suffixes K, M,
156 G, are supported and are understood to the base of
1024.
</para>
157 <para>Note that if IPv6 is enabled on the interface, and the MTU is chosen below
1280 (the
158 minimum MTU for IPv6) it will automatically be increased to this value.
</para>
163 <term><varname>ARP=
</varname></term>
165 <para>Takes a boolean. If set to true, the ARP (low-level Address Resolution Protocol)
166 for this interface is enabled. When unset, the kernel's default will be used.
</para>
167 <para> For example, disabling ARP is useful when creating multiple MACVLAN or VLAN virtual
168 interfaces atop a single lower-level physical interface, which will then only serve as a
169 link/
"bridge" device aggregating traffic to the same physical link and not participate in
170 the network otherwise. Defaults to unset.
</para>
175 <term><varname>Multicast=
</varname></term>
177 <para>Takes a boolean. If set to true, the multicast flag on the device is enabled. Defaults
183 <term><varname>AllMulticast=
</varname></term>
185 <para>Takes a boolean. If set to true, the driver retrieves all multicast packets from the
186 network. This happens when multicast routing is enabled. Defaults to unset.
</para>
191 <term><varname>Promiscuous=
</varname></term>
193 <para>Takes a boolean. If set to true, promiscuous mode of the interface is enabled. Defaults
195 <para>If this is set to false for the underlying link of a
<literal>passthru
</literal> mode
196 MACVLAN/MACVTAP, the virtual interface will be created with the
<literal>nopromisc
</literal>
202 <term><varname>Unmanaged=
</varname></term>
204 <para>Takes a boolean. When
<literal>yes
</literal>, no attempts are made to bring up or
205 configure matching links, equivalent to when there are no matching network files. Defaults to
206 <literal>no
</literal>.
</para>
207 <para>This is useful for preventing later matching network files from interfering with
208 certain interfaces that are fully controlled by other applications.
</para>
213 <term><varname>Group=
</varname></term>
215 <para>Link groups are similar to port ranges found in managed switches. When network
216 interfaces are added to a numbered group, operations on all the interfaces from that group
217 can be performed at once. Takes an unsigned integer in the range
0…
2147483647. Defaults to
223 <term><varname>RequiredForOnline=
</varname></term>
225 <para>Takes a boolean or a minimum operational state and an optional maximum operational
227 <citerefentry><refentrytitle>networkctl
</refentrytitle><manvolnum>1</manvolnum></citerefentry>
228 for possible operational states. When
<literal>yes
</literal>, the network is deemed required
229 when determining whether the system is online (including when running
230 <command>systemd-networkd-wait-online
</command>). When
<literal>no
</literal>, the network is
231 ignored when determining the online state. When a minimum operational state and an optional
232 maximum operational state are set,
<literal>yes
</literal> is implied, and this controls the
233 minimum and maximum operational state required for the network interface to be considered
236 <para>Defaults to
<literal>yes
</literal> when
<varname>ActivationPolicy=
</varname> is not
237 set, or set to
<literal>up
</literal>,
<literal>always-up
</literal>, or
238 <literal>bound
</literal>. Defaults to
<literal>no
</literal> when
239 <varname>ActivationPolicy=
</varname> is set to
<literal>manual
</literal> or
240 <literal>down
</literal>. This is forced to
<literal>no
</literal> when
241 <varname>ActivationPolicy=
</varname> is set to
<literal>always-down
</literal>.
</para>
243 <para>The network will be brought up normally (as configured by
244 <varname>ActivationPolicy=
</varname>), but in the event that there is no address being
245 assigned by DHCP or the cable is not plugged in, the link will simply remain offline and be
246 skipped automatically by
<command>systemd-networkd-wait-online
</command> if
247 <literal>RequiredForOnline=no
</literal>.
</para>
252 <term><varname>RequiredFamilyForOnline=
</varname></term>
254 <para>Takes an address family. When specified, an IP address in the given family is deemed
255 required when determining whether the link is online (including when running
256 <command>systemd-networkd-wait-online
</command>). Takes one of
<literal>ipv4
</literal>,
257 <literal>ipv6
</literal>,
<literal>both
</literal>, or
<literal>any
</literal>. Defaults to
258 <literal>any
</literal>. Note that this option has no effect if
259 <literal>RequiredForOnline=no
</literal>, or if
<literal>RequiredForOnline=
</literal>
260 specifies a minimum operational state below
<literal>degraded
</literal>.
</para>
265 <term><varname>ActivationPolicy=
</varname></term>
267 <para>Specifies the policy for
<command>systemd-networkd
</command> managing the link
268 administrative state. Specifically, this controls how
<command>systemd-networkd
</command>
269 changes the network device's
<literal>IFF_UP
</literal> flag, which is sometimes
270 controlled by system administrators by running e.g.,
271 <command>ip link set dev eth0 up
</command> or
<command>ip link set dev eth0 down
</command>,
272 and can also be changed with
<command>networkctl up eth0
</command> or
273 <command>networkctl down eth0
</command>.
</para>
275 <para>Takes one of
<literal>up
</literal>,
<literal>always-up
</literal>,
276 <literal>manual
</literal>,
<literal>always-down
</literal>,
<literal>down
</literal>,
277 or
<literal>bound
</literal>. When
<literal>manual
</literal>,
278 <command>systemd-networkd
</command> will not change the link's admin state automatically;
279 the system administrator must bring the interface up or down manually, as desired. When
280 <literal>up
</literal> (the default) or
<literal>always-up
</literal>, or
281 <literal>down
</literal> or
<literal>always-down
</literal>,
282 <command>systemd-networkd
</command> will set the link up or down, respectively, when the
283 interface is (re)configured. When
<literal>always-up
</literal> or
284 <literal>always-down
</literal>,
<command>systemd-networkd
</command> will set the link up or
285 down, respectively, any time
<command>systemd-networkd
</command> detects a change in the
286 administrative state. When
<varname>BindCarrier=
</varname> is also set, this is automatically
287 set to
<literal>bound
</literal> and any other value is ignored.
</para>
289 <para>When the policy is set to
<literal>down
</literal> or
<literal>manual
</literal>, the
290 default value of
<varname>RequiredForOnline=
</varname> is
<literal>no
</literal>. When the
291 policy is set to
<literal>always-down
</literal>, the value of
292 <varname>RequiredForOnline=
</varname> forced to
<literal>no
</literal>.
</para>
294 <para>The administrative state is not the same as the carrier state, so using
295 <literal>always-up
</literal> does not mean the link will never lose carrier. The link carrier
296 depends on both the administrative state as well as the network device's physical connection.
297 However, to avoid reconfiguration failures, when using
<literal>always-up
</literal>,
298 <varname>IgnoreCarrierLoss=
</varname> is forced to true.
</para>
304 <xi:include href=
"systemd.link.xml" xpointer=
"sr-iov" />
307 <title>[Network] Section Options
</title>
309 <para>The [Network] section accepts the following keys:
</para>
311 <variablelist class='network-directives'
>
313 <term><varname>Description=
</varname></term>
315 <para>A description of the device. This is only used for presentation purposes.
</para>
320 <term><varname>DHCP=
</varname></term>
322 <para>Enables DHCPv4 and/or DHCPv6 client support. Accepts
<literal>yes
</literal>,
323 <literal>no
</literal>,
<literal>ipv4
</literal>, or
<literal>ipv6
</literal>. Defaults to
324 <literal>no
</literal>.
</para>
326 <para>Note that DHCPv6 will by default be triggered by Router Advertisement, if that is
327 enabled, regardless of this parameter. By enabling DHCPv6 support explicitly, the DHCPv6
328 client will be started regardless of the presence of routers on the link, or what flags the
329 routers pass. See
<literal>IPv6AcceptRA=
</literal>.
</para>
331 <para>Furthermore, note that by default the domain name specified through DHCP is not used
332 for name resolution. See option
<option>UseDomains=
</option> below.
</para>
334 <para>See the [DHCPv4] or [DHCPv6] sections below for further configuration options for the
335 DHCP client support.
</para>
340 <term><varname>DHCPServer=
</varname></term>
342 <para>Takes a boolean. If set to
<literal>yes
</literal>, DHCPv4 server will be started.
343 Defaults to
<literal>no
</literal>. Further settings for the DHCP server may be set in the
344 [DHCPServer] section described below.
</para>
349 <term><varname>LinkLocalAddressing=
</varname></term>
351 <para>Enables link-local address autoconfiguration. Accepts
<option>yes
</option>,
352 <option>no
</option>,
<option>ipv4
</option>, and
<option>ipv6
</option>. An IPv6 link-local
353 address is configured when
<option>yes
</option> or
<option>ipv6
</option>. An IPv4 link-local
354 address is configured when
<option>yes
</option> or
<option>ipv4
</option> and when DHCPv4
355 autoconfiguration has been unsuccessful for some time. (IPv4 link-local address
356 autoconfiguration will usually happen in parallel with repeated attempts to acquire a DHCPv4
359 <para>Defaults to
<option>no
</option> when
<varname>KeepMaster=
</varname> or
360 <varname>Bridge=
</varname> is set or when the specified
361 <varname>MACVLAN=
</varname>/
<varname>MACVTAP=
</varname> has
<varname>Mode=passthru
</varname>,
362 or
<option>ipv6
</option> otherwise.
</para>
367 <term><varname>IPv6LinkLocalAddressGenerationMode=
</varname></term>
369 <para>Specifies how IPv6 link local address is generated. Takes one of
370 <literal>eui64
</literal>,
<literal>none
</literal>,
<literal>stable-privacy
</literal> and
371 <literal>random
</literal>. When unset,
<literal>stable-privacy
</literal> is used if
372 <varname>IPv6StableSecretAddress=
</varname> is specified, and if not,
373 <literal>eui64
</literal> is used. Note that if
<varname>LinkLocalAddressing=
</varname> is
374 <literal>no
</literal> or
<literal>ipv4
</literal>, then
375 <varname>IPv6LinkLocalAddressGenerationMode=
</varname> will be ignored. Also, even if
376 <varname>LinkLocalAddressing=
</varname> is
<literal>yes
</literal> or
<literal>ipv6
</literal>,
377 setting
<varname>IPv6LinkLocalAddressGenerationMode=none
</varname>
378 disables to configure an IPv6 link-local address.
</para>
383 <term><varname>IPv6StableSecretAddress=
</varname></term>
385 <para>Takes an IPv6 address. The specified address will be used as a stable secret for
386 generating IPv6 link-local address. If this setting is specified, and
387 <varname>IPv6LinkLocalAddressGenerationMode=
</varname> is unset, then
388 <varname>IPv6LinkLocalAddressGenerationMode=stable-privacy
</varname> is implied.
389 If this setting is not specified, and
<literal>stable-privacy
</literal> is set to
390 <varname>IPv6LinkLocalAddressGenerationMode=
</varname>,
391 then a stable secret address will be generated from the local machine ID and the interface
397 <term><varname>IPv4LLRoute=
</varname></term>
399 <para>Takes a boolean. If set to true, sets up the route needed for non-IPv4LL hosts to
400 communicate with IPv4LL-only hosts. Defaults to false.
</para>
405 <term><varname>DefaultRouteOnDevice=
</varname></term>
407 <para>Takes a boolean. If set to true, sets up the default route bound to the interface.
408 Defaults to false. This is useful when creating routes on point-to-point interfaces. This is
409 equivalent to e.g. the following,
410 <programlisting>ip route add default dev veth99
</programlisting>
412 <programlisting>[Route]
413 Gateway=
0.0.0.0</programlisting></para>
414 <para>Currently, there are no way to specify e.g., the table for the route configured by this
415 setting. To configure the default route with such an additional property, please use the
417 <programlisting>[Route]
419 Table=
1234</programlisting></para>
424 <term><varname>LLMNR=
</varname></term>
426 <para>Takes a boolean or
<literal>resolve
</literal>. When true, enables
427 <ulink url=
"https://tools.ietf.org/html/rfc4795">Link-Local Multicast Name Resolution
</ulink>
428 on the link. When set to
<literal>resolve
</literal>, only resolution is enabled, but not host
429 registration and announcement. Defaults to true. This setting is read by
430 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
436 <term><varname>MulticastDNS=
</varname></term>
438 <para>Takes a boolean or
<literal>resolve
</literal>. When true, enables
439 <ulink url=
"https://tools.ietf.org/html/rfc6762">Multicast DNS
</ulink> support on the link.
440 When set to
<literal>resolve
</literal>, only resolution is enabled, but not host or service
441 registration and announcement. Defaults to false. This setting is read by
442 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
448 <term><varname>DNSOverTLS=
</varname></term>
450 <para>Takes a boolean or
<literal>opportunistic
</literal>. When true, enables
451 <ulink url=
"https://tools.ietf.org/html/rfc7858">DNS-over-TLS
</ulink> support on the link.
452 When set to
<literal>opportunistic
</literal>, compatibility with non-DNS-over-TLS servers is
453 increased, by automatically turning off DNS-over-TLS servers in this case. This option
454 defines a per-interface setting for
455 <citerefentry><refentrytitle>resolved.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s
456 global
<varname>DNSOverTLS=
</varname> option. Defaults to unset, and the global setting will
457 be used. This setting is read by
458 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
464 <term><varname>DNSSEC=
</varname></term>
466 <para>Takes a boolean or
<literal>allow-downgrade
</literal>. When true, enables
467 <ulink url=
"https://tools.ietf.org/html/rfc4033">DNSSEC
</ulink> DNS validation support on the
468 link. When set to
<literal>allow-downgrade
</literal>, compatibility with non-DNSSEC capable
469 networks is increased, by automatically turning off DNSSEC in this case. This option defines
470 a per-interface setting for
471 <citerefentry><refentrytitle>resolved.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s
472 global
<varname>DNSSEC=
</varname> option. Defaults to unset, and the global setting will be
473 used. This setting is read by
474 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
480 <term><varname>DNSSECNegativeTrustAnchors=
</varname></term>
482 <para>A space-separated list of DNSSEC negative trust anchor domains. If specified and DNSSEC
483 is enabled, look-ups done via the interface's DNS server will be subject to the list of
484 negative trust anchors, and not require authentication for the specified domains, or anything
485 below it. Use this to disable DNSSEC authentication for specific private domains, that cannot
486 be proven valid using the Internet DNS hierarchy. Defaults to the empty list. This setting is
488 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
494 <term><varname>LLDP=
</varname></term>
496 <para>Controls support for Ethernet LLDP packet reception. LLDP is a link-layer protocol
497 commonly implemented on professional routers and bridges which announces which physical port
498 a system is connected to, as well as other related data. Accepts a boolean or the special
499 value
<literal>routers-only
</literal>. When true, incoming LLDP packets are accepted and a
500 database of all LLDP neighbors maintained. If
<literal>routers-only
</literal> is set only
501 LLDP data of various types of routers is collected and LLDP data about other types of devices
502 ignored (such as stations, telephones and others). If false, LLDP reception is disabled.
503 Defaults to
<literal>routers-only
</literal>. Use
504 <citerefentry><refentrytitle>networkctl
</refentrytitle><manvolnum>1</manvolnum></citerefentry>
505 to query the collected neighbor data. LLDP is only available on Ethernet links. See
506 <varname>EmitLLDP=
</varname> below for enabling LLDP packet emission from the local system.
512 <term><varname>EmitLLDP=
</varname></term>
514 <para>Controls support for Ethernet LLDP packet emission. Accepts a boolean parameter or the
515 special values
<literal>nearest-bridge
</literal>,
<literal>non-tpmr-bridge
</literal> and
516 <literal>customer-bridge
</literal>. Defaults to false, which turns off LLDP packet emission.
517 If not false, a short LLDP packet with information about the local system is sent out in
518 regular intervals on the link. The LLDP packet will contain information about the local
519 hostname, the local machine ID (as stored in
520 <citerefentry><refentrytitle>machine-id
</refentrytitle><manvolnum>5</manvolnum></citerefentry>)
521 and the local interface name, as well as the pretty hostname of the system (as set in
522 <citerefentry><refentrytitle>machine-info
</refentrytitle><manvolnum>5</manvolnum></citerefentry>).
523 LLDP emission is only available on Ethernet links. Note that this setting passes data
524 suitable for identification of host to the network and should thus not be enabled on
525 untrusted networks, where such identification data should not be made available. Use this
526 option to permit other systems to identify on which interfaces they are connected to this
527 system. The three special values control propagation of the LLDP packets. The
528 <literal>nearest-bridge
</literal> setting permits propagation only to the nearest connected
529 bridge,
<literal>non-tpmr-bridge
</literal> permits propagation across Two-Port MAC Relays,
530 but not any other bridges, and
<literal>customer-bridge
</literal> permits propagation until
531 a customer bridge is reached. For details about these concepts, see
532 <ulink url=
"https://standards.ieee.org/findstds/standard/802.1AB-2016.html">IEEE
802.1AB-
2016</ulink>.
533 Note that configuring this setting to true is equivalent to
534 <literal>nearest-bridge
</literal>, the recommended and most restricted level of propagation.
535 See
<varname>LLDP=
</varname> above for an option to enable LLDP reception.
</para>
540 <term><varname>BindCarrier=
</varname></term>
542 <para>A link name or a list of link names. When set, controls the behavior of the current
543 link. When all links in the list are in an operational down state, the current link is
544 brought down. When at least one link has carrier, the current interface is brought up.
</para>
546 <para>This forces
<varname>ActivationPolicy=
</varname> to be set to
<literal>bound
</literal>.
552 <term><varname>Address=
</varname></term>
554 <para>A static IPv4 or IPv6 address and its prefix length, separated by a
555 <literal>/
</literal> character. Specify this key more than once to configure several
556 addresses. 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 containing an Address key (see below).
559 This option may be specified more than once.
</para>
561 <para>If the specified address is
<literal>0.0.0.0</literal> (for IPv4) or
562 <literal>::
</literal> (for IPv6), a new address range of the requested size is automatically
563 allocated from a system-wide pool of unused ranges. Note that the prefix length must be equal
564 or larger than
8 for IPv4, and
64 for IPv6. The allocated range is checked against all
565 current network interfaces and all known network configuration files to avoid address range
566 conflicts. The default system-wide pool consists of
192.168.0.0/
16,
172.16.0.0/
12 and
567 10.0.0.0/
8 for IPv4, and fd00::/
8 for IPv6. This functionality is useful to manage a large
568 number of dynamically created network interfaces with the same network configuration and
569 automatic address range assignment.
</para>
574 <term><varname>Gateway=
</varname></term>
576 <para>The gateway address, which must be in the format described in
577 <citerefentry project='man-pages'
><refentrytitle>inet_pton
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
578 This is a short-hand for a [Route] section only containing a
<varname>Gateway=
</varname> key.
579 This option may be specified more than once.
</para>
584 <term><varname>DNS=
</varname></term>
586 <para>A DNS server address, which must be in the format described in
587 <citerefentry project='man-pages'
><refentrytitle>inet_pton
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
588 This option may be specified more than once. Each address can optionally take a port number
589 separated with
<literal>:
</literal>, a network interface name or index separated with
590 <literal>%
</literal>, and a Server Name Indication (SNI) separated with
<literal>#
</literal>.
591 When IPv6 address is specified with a port number, then the address must be in the square
592 brackets. That is, the acceptable full formats are
593 <literal>111.222.333.444:
9953%ifname#example.com
</literal> for IPv4 and
594 <literal>[
1111:
2222::
3333]:
9953%ifname#example.com
</literal> for IPv6. If an empty string is
595 assigned, then the all previous assignments are cleared. This setting is read by
596 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
602 <term><varname>Domains=
</varname></term>
604 <para>A whitespace-separated list of domains which should be resolved using the DNS servers
605 on this link. Each item in the list should be a domain name, optionally prefixed with a tilde
606 (
<literal>~
</literal>). The domains with the prefix are called
"routing-only domains". The
607 domains without the prefix are called
"search domains" and are first used as search suffixes
608 for extending single-label hostnames (hostnames containing no dots) to become fully qualified
609 domain names (FQDNs). If a single-label hostname is resolved on this interface, each of the
610 specified search domains are appended to it in turn, converting it into a fully qualified
611 domain name, until one of them may be successfully resolved.
</para>
613 <para>Both
"search" and
"routing-only" domains are used for routing of DNS queries: look-ups
614 for hostnames ending in those domains (hence also single label names, if any
"search domains"
615 are listed), are routed to the DNS servers configured for this interface. The domain routing
616 logic is particularly useful on multi-homed hosts with DNS servers serving particular private
617 DNS zones on each interface.
</para>
619 <para>The
"routing-only" domain
<literal>~.
</literal> (the tilde indicating definition of a
620 routing domain, the dot referring to the DNS root domain which is the implied suffix of all
621 valid DNS names) has special effect. It causes all DNS traffic which does not match another
622 configured domain routing entry to be routed to DNS servers specified for this interface.
623 This setting is useful to prefer a certain set of DNS servers if a link on which they are
624 connected is available.
</para>
626 <para>This setting is read by
627 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
628 "Search domains" correspond to the
<varname>domain
</varname> and
<varname>search
</varname>
630 <citerefentry project='man-pages'
><refentrytitle>resolv.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
631 Domain name routing has no equivalent in the traditional glibc API, which has no concept of
632 domain name servers limited to a specific link.
</para>
637 <term><varname>DNSDefaultRoute=
</varname></term>
639 <para>Takes a boolean argument. If true, this link's configured DNS servers are used for
640 resolving domain names that do not match any link's configured
<varname>Domains=
</varname>
641 setting. If false, this link's configured DNS servers are never used for such domains, and
642 are exclusively used for resolving names that match at least one of the domains configured on
643 this link. If not specified defaults to an automatic mode: queries not matching any link's
644 configured domains will be routed to this link if it has no routing-only domains configured.
650 <term><varname>NTP=
</varname></term>
652 <para>An NTP server address (either an IP address, or a hostname). This option may be
653 specified more than once. This setting is read by
654 <citerefentry><refentrytitle>systemd-timesyncd.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
660 <term><varname>IPForward=
</varname></term>
662 <para>Configures IP packet forwarding for the system. If enabled, incoming packets on any
663 network interface will be forwarded to any other interfaces according to the routing table.
664 Takes a boolean, or the values
<literal>ipv4
</literal> or
<literal>ipv6
</literal>, which only
665 enable IP packet forwarding for the specified address family. This controls the
666 <filename>net.ipv4.ip_forward
</filename> and
<filename>net.ipv6.conf.all.forwarding
</filename>
667 sysctl options of the network interface (see
668 <ulink url=
"https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt
</ulink>
669 for details about sysctl options). Defaults to
<literal>no
</literal>.
</para>
671 <para>Note: this setting controls a global kernel option, and does so one way only: if a
672 network that has this setting enabled is set up the global setting is turned on. However,
673 it is never turned off again, even after all networks with this setting enabled are shut
676 <para>To allow IP packet forwarding only between specific network interfaces use a firewall.
682 <term><varname>IPMasquerade=
</varname></term>
684 <para>Configures IP masquerading for the network interface. If enabled, packets forwarded
685 from the network interface will be appear as coming from the local host. Takes one of
686 <literal>ipv4
</literal>,
<literal>ipv6
</literal>,
<literal>both
</literal>, or
687 <literal>no
</literal>. Defaults to
<literal>no
</literal>. If enabled, this automatically sets
688 <varname>IPForward=
</varname> to one of
<literal>ipv4
</literal>,
<literal>ipv6
</literal> or
689 <literal>yes
</literal>.
</para>
690 <para>Note. Any positive boolean values such as
<literal>yes
</literal> or
691 <literal>true
</literal> are now deprecated. Please use one of the values in the above.
</para>
696 <term><varname>IPv6PrivacyExtensions=
</varname></term>
698 <para>Configures use of stateless temporary addresses that change over time (see
699 <ulink url=
"https://tools.ietf.org/html/rfc4941">RFC
4941</ulink>,
700 Privacy Extensions for Stateless Address Autoconfiguration in IPv6). Takes a boolean or the
701 special values
<literal>prefer-public
</literal> and
<literal>kernel
</literal>. When true,
702 enables the privacy extensions and prefers temporary addresses over public addresses. When
703 <literal>prefer-public
</literal>, enables the privacy extensions, but prefers public
704 addresses over temporary addresses. When false, the privacy extensions remain disabled. When
705 <literal>kernel
</literal>, the kernel's default setting will be left in place. Defaults to
706 <literal>no
</literal>.
</para>
711 <term><varname>IPv6AcceptRA=
</varname></term>
713 <para>Takes a boolean. Controls IPv6 Router Advertisement (RA) reception support for the
714 interface. If true, RAs are accepted; if false, RAs are ignored. When RAs are accepted, they
715 may trigger the start of the DHCPv6 client if the relevant flags are set in the RA data, or
716 if no routers are found on the link. The default is to disable RA reception for bridge
717 devices or when IP forwarding is enabled, and to enable it otherwise. Cannot be enabled on
718 bond devices and when link local addressing is disabled.
</para>
720 <para>Further settings for the IPv6 RA support may be configured in the [IPv6AcceptRA]
721 section, see below.
</para>
724 <ulink url=
"https://www.kernel.org/doc/Documentation/networking/ip-sysctl.txt">ip-sysctl.txt
</ulink>
725 in the kernel documentation regarding
<literal>accept_ra
</literal>, but note that systemd's
726 setting of
<constant>1</constant> (i.e. true) corresponds to kernel's setting of
727 <constant>2</constant>.
</para>
729 <para>Note that kernel's implementation of the IPv6 RA protocol is always disabled,
730 regardless of this setting. If this option is enabled, a userspace implementation of the IPv6
731 RA protocol is used, and the kernel's own implementation remains disabled, since
732 <command>systemd-networkd
</command> needs to know all details supplied in the advertisements,
733 and these are not available from the kernel if the kernel's own implementation is used.
739 <term><varname>IPv6DuplicateAddressDetection=
</varname></term>
741 <para>Configures the amount of IPv6 Duplicate Address Detection (DAD) probes to send. When
742 unset, the kernel's default will be used.
</para>
747 <term><varname>IPv6HopLimit=
</varname></term>
749 <para>Configures IPv6 Hop Limit. For each router that forwards the packet, the hop limit is
750 decremented by
1. When the hop limit field reaches zero, the packet is discarded. When unset,
751 the kernel's default will be used.
</para>
756 <term><varname>IPv4AcceptLocal=
</varname></term>
758 <para>Takes a boolean. Accept packets with local source addresses. In combination with
759 suitable routing, this can be used to direct packets between two local interfaces over the
760 wire and have them accepted properly. When unset, the kernel's default will be used.
</para>
765 <term><varname>IPv4RouteLocalnet=
</varname></term>
767 <para>Takes a boolean. When true, the kernel does not consider loopback addresses as martian
768 source or destination while routing. This enables the use of
127.0.0.0/
8 for local routing
769 purposes. When unset, the kernel's default will be used.
</para>
774 <term><varname>IPv4ProxyARP=
</varname></term>
776 <para>Takes a boolean. Configures proxy ARP for IPv4. Proxy ARP is the technique in which one
777 host, usually a router, answers ARP requests intended for another machine. By
"faking" its
778 identity, the router accepts responsibility for routing packets to the
"real" destination.
779 See
<ulink url=
"https://tools.ietf.org/html/rfc1027">RFC
1027</ulink>. When unset, the
780 kernel's default will be used.
</para>
785 <term><varname>IPv6ProxyNDP=
</varname></term>
787 <para>Takes a boolean. Configures proxy NDP for IPv6. Proxy NDP (Neighbor Discovery Protocol)
788 is a technique for IPv6 to allow routing of addresses to a different destination when peers
789 expect them to be present on a certain physical link. In this case a router answers Neighbour
790 Advertisement messages intended for another machine by offering its own MAC address as
791 destination. Unlike proxy ARP for IPv4, it is not enabled globally, but will only send
792 Neighbour Advertisement messages for addresses in the IPv6 neighbor proxy table, which can
793 also be shown by
<command>ip -
6 neighbour show proxy
</command>. systemd-networkd will control
794 the per-interface `proxy_ndp` switch for each configured interface depending on this option.
795 When unset, the kernel's default will be used.
</para>
800 <term><varname>IPv6ProxyNDPAddress=
</varname></term>
802 <para>An IPv6 address, for which Neighbour Advertisement messages will be proxied. This
803 option may be specified more than once. systemd-networkd will add the
804 <varname>IPv6ProxyNDPAddress=
</varname> entries to the kernel's IPv6 neighbor proxy table.
805 This setting implies
<varname>IPv6ProxyNDP=yes
</varname> but has no effect if
806 <varname>IPv6ProxyNDP=
</varname> has been set to false. When unset, the kernel's default will
812 <term><varname>IPv6SendRA=
</varname></term>
814 <para>Whether to enable or disable Router Advertisement sending on a link. Takes a boolean
815 value. When enabled, prefixes configured in [IPv6Prefix] sections and routes configured in
816 the [IPv6RoutePrefix] sections are distributed as defined in the [IPv6SendRA] section. If
817 <varname>DHCPPrefixDelegation=
</varname> is enabled, then the delegated prefixes are also
818 distributed. See
<varname>DCHPPrefixDelegation=
</varname> setting and the [IPv6SendRA],
819 [IPv6Prefix], [IPv6RoutePrefix], and [DHCPPrefixDelegation] sections for more configuration
825 <term><varname>DHCPPrefixDelegation=
</varname></term>
827 <para>Takes a boolean value. When enabled, requests subnet prefixes on another link via the DHCPv6
828 protocol or via the
6RD option in the DHCPv4 protocol. An address within each delegated prefix will
829 be assigned, and the prefixes will be announced through IPv6 Router Advertisement if
830 <varname>IPv6SendRA=
</varname> is enabled. This behaviour can be configured in the
831 [DHCPPrefixDelegation] section. Defaults to disabled.
</para>
836 <term><varname>IPv6MTUBytes=
</varname></term>
838 <para>Configures IPv6 maximum transmission unit (MTU). An integer greater than or equal to
839 1280 bytes. When unset, the kernel's default will be used.
</para>
844 <term><varname>KeepMaster=
</varname></term>
846 <para>Takes a boolean value. When enabled, the current master interface index will not be
847 changed, and
<varname>BatmanAdvanced=
</varname>,
<varname>Bond=
</varname>,
848 <varname>Bridge=
</varname>, and
<varname>VRF=
</varname> settings are ignored. This may be
849 useful when a netdev with a master interface is created by another program, e.g.
850 <citerefentry><refentrytitle>systemd-nspawn
</refentrytitle><manvolnum>1</manvolnum></citerefentry>.
851 Defaults to false.
</para>
856 <term><varname>BatmanAdvanced=
</varname></term>
857 <term><varname>Bond=
</varname></term>
858 <term><varname>Bridge=
</varname></term>
859 <term><varname>VRF=
</varname></term>
861 <para>The name of the B.A.T.M.A.N. Advanced, bond, bridge, or VRF interface to add the link
863 <citerefentry><refentrytitle>systemd.netdev
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
869 <term><varname>IPoIB=
</varname></term>
870 <term><varname>IPVLAN=
</varname></term>
871 <term><varname>IPVTAP=
</varname></term>
872 <term><varname>MACsec=
</varname></term>
873 <term><varname>MACVLAN=
</varname></term>
874 <term><varname>MACVTAP=
</varname></term>
875 <term><varname>Tunnel=
</varname></term>
876 <term><varname>VLAN=
</varname></term>
877 <term><varname>VXLAN=
</varname></term>
878 <term><varname>Xfrm=
</varname></term>
880 <para>The name of an IPoIB, IPVLAN, IPVTAP, MACsec, MACVLAN, MACVTAP, tunnel, VLAN,
881 VXLAN, or Xfrm to be created on the link. See
882 <citerefentry><refentrytitle>systemd.netdev
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
883 This option may be specified more than once.
</para>
888 <term><varname>ActiveSlave=
</varname></term>
890 <para>Takes a boolean. Specifies the new active slave. The
<literal>ActiveSlave=
</literal>
891 option is only valid for following modes:
<literal>active-backup
</literal>,
892 <literal>balance-alb
</literal>, and
<literal>balance-tlb
</literal>. Defaults to false.
</para>
897 <term><varname>PrimarySlave=
</varname></term>
899 <para>Takes a boolean. Specifies which slave is the primary device. The specified device will
900 always be the active slave while it is available. Only when the primary is off-line will
901 alternate devices be used. This is useful when one slave is preferred over another, e.g.
902 when one slave has higher throughput than another. The
<literal>PrimarySlave=
</literal>
903 option is only valid for following modes:
<literal>active-backup
</literal>,
904 <literal>balance-alb
</literal>, and
<literal>balance-tlb
</literal>. Defaults to false.
</para>
909 <term><varname>ConfigureWithoutCarrier=
</varname></term>
911 <para>Takes a boolean. Allows networkd to configure a specific link even if it has no
912 carrier. Defaults to false. If enabled, and the
<varname>IgnoreCarrierLoss=
</varname> setting
913 is not explicitly set, then it is enabled as well.
</para>
918 <term><varname>IgnoreCarrierLoss=
</varname></term>
920 <para>Takes a boolean or a timespan. When true, networkd retains both the static and dynamic
921 configuration of the interface even if its carrier is lost. When a timespan is specified,
922 networkd waits for the specified timespan, and ignores the carrier loss if the link regain
923 its carrier within the timespan. Setting a finite timespan may be useful for a wireless
924 interface connecting to a network which has multiple access points with the same SSID, or an
925 interface which is reset on changing MTU. When unset, the value specified with
926 <varname>ConfigureWithoutCarrier=
</varname> is used.
</para>
928 <para>When
<varname>ActivationPolicy=
</varname> is set to
<literal>always-up
</literal>, this
929 is forced to
<literal>true
</literal>.
935 <term><varname>KeepConfiguration=
</varname></term>
937 <para>Takes a boolean or one of
<literal>static
</literal>,
<literal>dhcp-on-stop
</literal>,
938 <literal>dhcp
</literal>. When
<literal>static
</literal>,
<command>systemd-networkd
</command>
939 will not drop static addresses and routes on starting up process. When set to
940 <literal>dhcp-on-stop
</literal>,
<command>systemd-networkd
</command> will not drop addresses
941 and routes on stopping the daemon. When
<literal>dhcp
</literal>,
942 the addresses and routes provided by a DHCP server will never be dropped even if the DHCP
943 lease expires. This is contrary to the DHCP specification, but may be the best choice if,
944 e.g., the root filesystem relies on this connection. The setting
<literal>dhcp
</literal>
945 implies
<literal>dhcp-on-stop
</literal>, and
<literal>yes
</literal> implies
946 <literal>dhcp
</literal> and
<literal>static
</literal>. Defaults to
947 <literal>dhcp-on-stop
</literal> when
<command>systemd-networkd
</command> is running in
948 initrd,
<literal>yes
</literal> when the root filesystem is a network filesystem, and
949 <literal>no
</literal> otherwise.
</para>
956 <title>[Address] Section Options
</title>
958 <para>An [Address] section accepts the following keys. Specify several [Address] sections to
959 configure several addresses.
</para>
961 <variablelist class='network-directives'
>
963 <term><varname>Address=
</varname></term>
965 <para>As in the [Network] section. This setting is mandatory. Each [Address] section can
966 contain one
<varname>Address=
</varname> setting.
</para>
971 <term><varname>Peer=
</varname></term>
973 <para>The peer address in a point-to-point connection. Accepts the same format as the
974 <varname>Address=
</varname> setting.
</para>
979 <term><varname>Broadcast=
</varname></term>
981 <para>Takes an IPv4 address or boolean value. The address must be in the format described in
982 <citerefentry project='man-pages'
><refentrytitle>inet_pton
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
983 If set to true, then the IPv4 broadcast address will be derived from the
984 <varname>Address=
</varname> setting. If set to false, then the broadcast address will not be
985 set. Defaults to true, except for wireguard interfaces, where it default to false.
</para>
990 <term><varname>Label=
</varname></term>
992 <para>Specifies the label for the IPv4 address. The label must be a
7-bit ASCII string with
993 a length of
1…
15 characters. Defaults to unset.
</para>
998 <term><varname>PreferredLifetime=
</varname></term>
1000 <para>Allows the default
"preferred lifetime" of the address to be overridden. Only three
1001 settings are accepted:
<literal>forever
</literal>,
<literal>infinity
</literal>, which is the
1002 default and means that the address never expires, and
<literal>0</literal>, which means that
1003 the address is considered immediately
"expired" and will not be used, unless explicitly
1004 requested. A setting of
<option>PreferredLifetime=
0</option> is useful for addresses which
1005 are added to be used only by a specific application, which is then configured to use them
1011 <term><varname>Scope=
</varname></term>
1013 <para>The scope of the address, which can be
<literal>global
</literal> (valid everywhere on
1014 the network, even through a gateway),
<literal>link
</literal> (only valid on this device,
1015 will not traverse a gateway) or
<literal>host
</literal> (only valid within the device itself,
1016 e.g.
127.0.0.1) or an integer in the range
0…
255. Defaults to
<literal>global
</literal>.
1022 <term><varname>RouteMetric=
</varname></term>
1024 <para>The metric of the prefix route, which is pointing to the subnet of the configured IP
1025 address, taking the configured prefix length into account. Takes an unsigned integer in the
1026 range
0…
4294967295. When unset or set to
0, the kernel's default value is used. This
1027 setting will be ignored when
<varname>AddPrefixRoute=
</varname> is false.
</para>
1032 <term><varname>HomeAddress=
</varname></term>
1034 <para>Takes a boolean. Designates this address the
"home address" as defined in
1035 <ulink url=
"https://tools.ietf.org/html/rfc6275">RFC
6275</ulink>. Supported only on IPv6.
1036 Defaults to false.
</para>
1041 <term><varname>DuplicateAddressDetection=
</varname></term>
1043 <para>Takes one of
<literal>ipv4
</literal>,
<literal>ipv6
</literal>,
<literal>both
</literal>,
1044 or
<literal>none
</literal>. When
<literal>ipv4
</literal>, performs IPv4 Address Conflict
1045 Detection. See
<ulink url=
"https://tools.ietf.org/html/rfc5227">RFC
5227</ulink>.
1046 When
<literal>ipv6
</literal>, performs IPv6 Duplicate Address Detection. See
1047 <ulink url=
"https://tools.ietf.org/html/rfc4862">RFC
4862</ulink>. Defaults to
1048 <literal>ipv6
</literal>.
</para>
1053 <term><varname>ManageTemporaryAddress=
</varname></term>
1055 <para>Takes a boolean. If true the kernel manage temporary addresses created from this one as
1056 template on behalf of Privacy Extensions
1057 <ulink url=
"https://tools.ietf.org/html/rfc3041">RFC
3041</ulink>. For this to become active,
1058 the use_tempaddr sysctl setting has to be set to a value greater than zero. The given address
1059 needs to have a prefix length of
64. This flag allows using privacy extensions in a manually
1060 configured network, just like if stateless auto-configuration was active. Defaults to false.
1066 <term><varname>AddPrefixRoute=
</varname></term>
1068 <para>Takes a boolean. When true, the prefix route for the address is automatically added.
1069 Defaults to true.
</para>
1074 <term><varname>AutoJoin=
</varname></term>
1076 <para>Takes a boolean. Joining multicast group on ethernet level via
1077 <command>ip maddr
</command> command would not work if we have an Ethernet switch that does
1078 IGMP snooping since the switch would not replicate multicast packets on ports that did not
1079 have IGMP reports for the multicast addresses. Linux vxlan interfaces created via
1080 <command>ip link add vxlan
</command> or networkd's netdev kind vxlan have the group option
1081 that enables then to do the required join. By extending ip address command with option
1082 <literal>autojoin
</literal> we can get similar functionality for openvswitch (OVS) vxlan
1083 interfaces as well as other tunneling mechanisms that need to receive multicast traffic.
1084 Defaults to
<literal>no
</literal>.
</para>
1091 <title>[Neighbor] Section Options
</title>
1093 <para>A [Neighbor] section accepts the following keys. The neighbor section adds a permanent,
1094 static entry to the neighbor table (IPv6) or ARP table (IPv4) for the given hardware address on the
1095 links matched for the network. Specify several [Neighbor] sections to configure several static
1098 <variablelist class='network-directives'
>
1100 <term><varname>Address=
</varname></term>
1102 <para>The IP address of the neighbor.
</para>
1107 <term><varname>LinkLayerAddress=
</varname></term>
1109 <para>The link layer address (MAC address or IP address) of the neighbor.
</para>
1116 <title>[IPv6AddressLabel] Section Options
</title>
1118 <para>An [IPv6AddressLabel] section accepts the following keys. Specify several [IPv6AddressLabel]
1119 sections to configure several address labels. IPv6 address labels are used for address selection.
1120 See
<ulink url=
"https://tools.ietf.org/html/rfc3484">RFC
3484</ulink>. Precedence is managed by
1121 userspace, and only the label itself is stored in the kernel.
</para>
1123 <variablelist class='network-directives'
>
1125 <term><varname>Label=
</varname></term>
1127 <para>The label for the prefix, an unsigned integer in the range
0…
4294967294.
0xffffffff is
1128 reserved. This setting is mandatory.
</para>
1133 <term><varname>Prefix=
</varname></term>
1135 <para>IPv6 prefix is an address with a prefix length, separated by a slash
1136 <literal>/
</literal> character. This setting is mandatory.
</para>
1143 <title>[RoutingPolicyRule] Section Options
</title>
1145 <para>An [RoutingPolicyRule] section accepts the following settings. Specify several
1146 [RoutingPolicyRule] sections to configure several rules.
</para>
1148 <variablelist class='network-directives'
>
1150 <term><varname>TypeOfService=
</varname></term>
1152 <para>Takes a number between
0 and
255 that specifies the type of service to match.
</para>
1157 <term><varname>From=
</varname></term>
1159 <para>Specifies the source address prefix to match. Possibly followed by a slash and the
1160 prefix length.
</para>
1165 <term><varname>To=
</varname></term>
1167 <para>Specifies the destination address prefix to match. Possibly followed by a slash and the
1168 prefix length.
</para>
1173 <term><varname>FirewallMark=
</varname></term>
1175 <para>Specifies the iptables firewall mark value to match (a number in the range
1176 1…
4294967295). Optionally, the firewall mask (also a number between
1…
4294967295) can be
1177 suffixed with a slash (
<literal>/
</literal>), e.g.,
<literal>7/
255</literal>.
</para>
1182 <term><varname>Table=
</varname></term>
1184 <para>Specifies the routing table identifier to lookup if the rule selector matches. Takes
1185 one of predefined names
<literal>default
</literal>,
<literal>main
</literal>, and
1186 <literal>local
</literal>, and names defined in
<varname>RouteTable=
</varname> in
1187 <citerefentry><refentrytitle>networkd.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
1188 or a number between
1 and
4294967295. Defaults to
<literal>main
</literal>.
</para>
1193 <term><varname>Priority=
</varname></term>
1195 <para>Specifies the priority of this rule.
<varname>Priority=
</varname> is an integer in the
1196 range
0…
4294967295. Higher number means lower priority, and rules get processed in order of
1197 increasing number. Defaults to unset, and the kernel will pick a value dynamically.
</para>
1202 <term><varname>IncomingInterface=
</varname></term>
1204 <para>Specifies incoming device to match. If the interface is loopback, the rule only matches
1205 packets originating from this host.
</para>
1210 <term><varname>OutgoingInterface=
</varname></term>
1212 <para>Specifies the outgoing device to match. The outgoing interface is only available for
1213 packets originating from local sockets that are bound to a device.
</para>
1218 <term><varname>SourcePort=
</varname></term>
1220 <para>Specifies the source IP port or IP port range match in forwarding information base
1221 (FIB) rules. A port range is specified by the lower and upper port separated by a dash.
1222 Defaults to unset.
</para>
1227 <term><varname>DestinationPort=
</varname></term>
1229 <para>Specifies the destination IP port or IP port range match in forwarding information base
1230 (FIB) rules. A port range is specified by the lower and upper port separated by a dash.
1231 Defaults to unset.
</para>
1236 <term><varname>IPProtocol=
</varname></term>
1238 <para>Specifies the IP protocol to match in forwarding information base (FIB) rules. Takes IP
1239 protocol name such as
<literal>tcp
</literal>,
<literal>udp
</literal> or
1240 <literal>sctp
</literal>, or IP protocol number such as
<literal>6</literal> for
1241 <literal>tcp
</literal> or
<literal>17</literal> for
<literal>udp
</literal>. Defaults to unset.
1247 <term><varname>InvertRule=
</varname></term>
1249 <para>A boolean. Specifies whether the rule is to be inverted. Defaults to false.
</para>
1254 <term><varname>Family=
</varname></term>
1256 <para>Takes a special value
<literal>ipv4
</literal>,
<literal>ipv6
</literal>, or
1257 <literal>both
</literal>. By default, the address family is determined by the address
1258 specified in
<varname>To=
</varname> or
<varname>From=
</varname>. If neither
1259 <varname>To=
</varname> nor
<varname>From=
</varname> are specified, then defaults to
1260 <literal>ipv4
</literal>.
</para>
1265 <term><varname>User=
</varname></term>
1267 <para>Takes a username, a user ID, or a range of user IDs separated by a dash. Defaults to
1273 <term><varname>SuppressPrefixLength=
</varname></term>
1275 <para>Takes a number
<replaceable>N
</replaceable> in the range
0…
128 and rejects routing
1276 decisions that have a prefix length of
<replaceable>N
</replaceable> or less. Defaults to
1282 <term><varname>SuppressInterfaceGroup=
</varname></term>
1284 <para>Takes an integer in the range
0…
2147483647 and rejects routing decisions that have
1285 an interface with the same group id. It has the same meaning as
1286 <option>suppress_ifgroup
</option> in
<command>ip rule
</command>. Defaults to unset.
</para>
1291 <term><varname>Type=
</varname></term>
1293 <para>Specifies Routing Policy Database (RPDB) rule type. Takes one of
1294 <literal>blackhole
</literal>,
<literal>unreachable
</literal> or
<literal>prohibit
</literal>.
1302 <title>[NextHop] Section Options
</title>
1304 <para>The [NextHop] section is used to manipulate entries in the kernel's
"nexthop" tables. The
1305 [NextHop] section accepts the following settings. Specify several [NextHop] sections to configure
1306 several hops.
</para>
1308 <variablelist class='network-directives'
>
1310 <term><varname>Id=
</varname></term>
1312 <para>The id of the next hop. Takes an integer in the range
1…
4294967295. If unspecified,
1313 then automatically chosen by kernel.
</para>
1318 <term><varname>Gateway=
</varname></term>
1320 <para>As in the [Network] section.
</para>
1325 <term><varname>Family=
</varname></term>
1327 <para>Takes one of the special values
<literal>ipv4
</literal> or
<literal>ipv6
</literal>.
1328 By default, the family is determined by the address specified in
1329 <varname>Gateway=
</varname>. If
<varname>Gateway=
</varname> is not specified, then defaults
1330 to
<literal>ipv4
</literal>.
</para>
1335 <term><varname>OnLink=
</varname></term>
1337 <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is
1338 reachable directly by the current machine (i.e., attached to the local network), so that we
1339 can insert the nexthop in the kernel table without it being complained about. Defaults to
1340 <literal>no
</literal>.
</para>
1345 <term><varname>Blackhole=
</varname></term>
1347 <para>Takes a boolean. If enabled, packets to the corresponding routes are discarded
1348 silently, and
<varname>Gateway=
</varname> cannot be specified. Defaults to
1349 <literal>no
</literal>.
</para>
1354 <term><varname>Group=
</varname></term>
1356 <para>Takes a whitespace separated list of nexthop IDs. Each ID must be in the range
1357 1…
4294967295. Optionally, each nexthop ID can take a weight after a colon
1358 (
<literal><replaceable>id
</replaceable><optional>:
<replaceable>weight
</replaceable></optional></literal>).
1359 The weight must be in the range
1…
255. If the weight is not specified, then it is assumed
1360 that the weight is
1. This setting cannot be specified with
<varname>Gateway=
</varname>,
1361 <varname>Family=
</varname>,
<varname>Blackhole=
</varname>. This setting can be specified
1362 multiple times. If an empty string is assigned, then the all previous assignments are
1363 cleared. Defaults to unset.
</para>
1370 <title>[Route] Section Options
</title>
1372 <para>The [Route] section accepts the following settings. Specify several [Route] sections to
1373 configure several routes.
</para>
1375 <variablelist class='network-directives'
>
1377 <term><varname>Gateway=
</varname></term>
1379 <para>Takes the gateway address or the special values
<literal>_dhcp4
</literal> and
1380 <literal>_ipv6ra
</literal>. If
<literal>_dhcp4
</literal> or
<literal>_ipv6ra
</literal> is
1381 set, then the gateway address provided by DHCPv4 or IPv6 RA is used.
</para>
1386 <term><varname>GatewayOnLink=
</varname></term>
1388 <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is
1389 reachable directly by the current machine (i.e., attached to the local network), so that we
1390 can insert the route in the kernel table without it being complained about. Defaults to
1391 <literal>no
</literal>.
</para>
1396 <term><varname>Destination=
</varname></term>
1398 <para>The destination prefix of the route. Possibly followed by a slash and the prefix
1399 length. If omitted, a full-length host route is assumed.
</para>
1404 <term><varname>Source=
</varname></term>
1406 <para>The source prefix of the route. Possibly followed by a slash and the prefix length. If
1407 omitted, a full-length host route is assumed.
</para>
1412 <term><varname>Metric=
</varname></term>
1414 <para>The metric of the route. Takes an unsigned integer in the range
0…
4294967295. Defaults
1415 to unset, and the kernel's default will be used.
</para>
1420 <term><varname>IPv6Preference=
</varname></term>
1422 <para>Specifies the route preference as defined in
1423 <ulink url=
"https://tools.ietf.org/html/rfc4191">RFC
4191</ulink> for Router Discovery
1424 messages. Which can be one of
<literal>low
</literal> the route has a lowest priority,
1425 <literal>medium
</literal> the route has a default priority or
<literal>high
</literal> the
1426 route has a highest priority.
</para>
1431 <term><varname>Scope=
</varname></term>
1433 <para>The scope of the IPv4 route, which can be
<literal>global
</literal>,
1434 <literal>site
</literal>,
<literal>link
</literal>,
<literal>host
</literal>, or
1435 <literal>nowhere
</literal>:
</para>
1438 <para><literal>global
</literal> means the route can reach hosts more than one hop away.
1443 <para><literal>site
</literal> means an interior route in the local autonomous system.
1448 <para><literal>link
</literal> means the route can only reach hosts on the local network
1449 (one hop away).
</para>
1453 <para><literal>host
</literal> means the route will not leave the local machine (used for
1454 internal addresses like
127.0.0.1).
</para>
1458 <para><literal>nowhere
</literal> means the destination doesn't exist.
</para>
1462 <para>For IPv4 route, defaults to
<literal>host
</literal> if
<varname>Type=
</varname> is
1463 <literal>local
</literal> or
<literal>nat
</literal>, and
<literal>link
</literal> if
1464 <varname>Type=
</varname> is
<literal>broadcast
</literal>,
<literal>multicast
</literal>,
1465 <literal>anycast
</literal>, or direct
<literal>unicast
</literal> routes. In other cases,
1466 defaults to
<literal>global
</literal>. The value is not used for IPv6.
</para>
1471 <term><varname>PreferredSource=
</varname></term>
1473 <para>The preferred source address of the route. The address must be in the format described
1475 <citerefentry project='man-pages'
><refentrytitle>inet_pton
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
1481 <term><varname>Table=
</varname></term>
1483 <para>The table identifier for the route. Takes one of predefined names
1484 <literal>default
</literal>,
<literal>main
</literal>, and
<literal>local
</literal>, and names
1485 defined in
<varname>RouteTable=
</varname> in
1486 <citerefentry><refentrytitle>networkd.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
1487 or a number between
1 and
4294967295. The table can be retrieved using
1488 <command>ip route show table
<replaceable>num
</replaceable></command>. If unset and
1489 <varname>Type=
</varname> is
<literal>local
</literal>,
<literal>broadcast
</literal>,
1490 <literal>anycast
</literal>, or
<literal>nat
</literal>, then
<literal>local
</literal> is used.
1491 In other cases, defaults to
<literal>main
</literal>.
</para>
1496 <term><varname>Protocol=
</varname></term>
1498 <para>The protocol identifier for the route. Takes a number between
0 and
255 or the special
1499 values
<literal>kernel
</literal>,
<literal>boot
</literal>,
<literal>static
</literal>,
1500 <literal>ra
</literal> and
<literal>dhcp
</literal>. Defaults to
<literal>static
</literal>.
1506 <term><varname>Type=
</varname></term>
1508 <para>Specifies the type for the route. Takes one of
<literal>unicast
</literal>,
1509 <literal>local
</literal>,
<literal>broadcast
</literal>,
<literal>anycast
</literal>,
1510 <literal>multicast
</literal>,
<literal>blackhole
</literal>,
<literal>unreachable
</literal>,
1511 <literal>prohibit
</literal>,
<literal>throw
</literal>,
<literal>nat
</literal>, and
1512 <literal>xresolve
</literal>. If
<literal>unicast
</literal>, a regular route is defined, i.e.
1513 a route indicating the path to take to a destination network address. If
1514 <literal>blackhole
</literal>, packets to the defined route are discarded silently. If
1515 <literal>unreachable
</literal>, packets to the defined route are discarded and the ICMP
1516 message
"Host Unreachable" is generated. If
<literal>prohibit
</literal>, packets to the
1517 defined route are discarded and the ICMP message
"Communication Administratively Prohibited"
1518 is generated. If
<literal>throw
</literal>, route lookup in the current routing table will
1519 fail and the route selection process will return to Routing Policy Database (RPDB). Defaults
1520 to
<literal>unicast
</literal>.
</para>
1525 <term><varname>InitialCongestionWindow=
</varname></term>
1527 <para>The TCP initial congestion window is used during the start of a TCP connection.
1528 During the start of a TCP session, when a client requests a resource, the server's initial
1529 congestion window determines how many packets will be sent during the initial burst of data
1530 without waiting for acknowledgement. Takes a number between
1 and
1023. Note that
100 is
1531 considered an extremely large value for this option. When unset, the kernel's default
1532 (typically
10) will be used.
</para>
1537 <term><varname>InitialAdvertisedReceiveWindow=
</varname></term>
1539 <para>The TCP initial advertised receive window is the amount of receive data (in bytes)
1540 that can initially be buffered at one time on a connection. The sending host can send only
1541 that amount of data before waiting for an acknowledgment and window update from the
1542 receiving host. Takes a number between
1 and
1023. Note that
100 is considered an extremely
1543 large value for this option. When unset, the kernel's default will be used.
</para>
1548 <term><varname>QuickAck=
</varname></term>
1550 <para>Takes a boolean. When true enables TCP quick ack mode for the route. When unset, the
1551 kernel's default will be used.
</para>
1556 <term><varname>FastOpenNoCookie=
</varname></term>
1558 <para>Takes a boolean. When true enables TCP fastopen without a cookie on a per-route basis.
1559 When unset, the kernel's default will be used.
</para>
1564 <term><varname>TTLPropagate=
</varname></term>
1566 <para>Takes a boolean. When true enables TTL propagation at Label Switched Path (LSP) egress.
1567 When unset, the kernel's default will be used.
</para>
1572 <term><varname>MTUBytes=
</varname></term>
1574 <para>The maximum transmission unit in bytes to set for the route. The usual suffixes K, M,
1575 G, are supported and are understood to the base of
1024.
</para>
1580 <term><varname>TCPAdvertisedMaximumSegmentSize=
</varname></term>
1582 <para>Specifies the Path MSS (in bytes) hints given on TCP layer. The usual suffixes K, M, G,
1583 are supported and are understood to the base of
1024. An unsigned integer in the range
1584 1…
4294967294. When unset, the kernel's default will be used.
</para>
1589 <term><varname>MultiPathRoute=
<replaceable>address
</replaceable>[@
<replaceable>name
</replaceable>] [
<replaceable>weight
</replaceable>]
</varname></term>
1591 <para>Configures multipath route. Multipath routing is the technique of using multiple
1592 alternative paths through a network. Takes gateway address. Optionally, takes a network
1593 interface name or index separated with
<literal>@
</literal>, and a weight in
1.
.256 for this
1594 multipath route separated with whitespace. This setting can be specified multiple times. If
1595 an empty string is assigned, then the all previous assignments are cleared.
</para>
1600 <term><varname>NextHop=
</varname></term>
1602 <para>Specifies the nexthop id. Takes an unsigned integer in the range
1…
4294967295. If set,
1603 the corresponding [NextHop] section must be configured. Defaults to unset.
</para>
1610 <title>[DHCPv4] Section Options
</title>
1612 <para>The [DHCPv4] section configures the DHCPv4 client, if it is enabled with the
1613 <varname>DHCP=
</varname> setting described above:
</para>
1615 <variablelist class='network-directives'
>
1617 <!-- DHCP packet contents -->
1620 <term><varname>SendHostname=
</varname></term>
1622 <para>When true (the default), the machine's hostname (or the value specified with
1623 <varname>Hostname=
</varname>, described below) will be sent to the DHCP server. Note that the
1624 hostname must consist only of
7-bit ASCII lower-case characters and no spaces or dots, and be
1625 formatted as a valid DNS domain name. Otherwise, the hostname is not sent even if this option
1631 <term><varname>Hostname=
</varname></term>
1633 <para>Use this value for the hostname which is sent to the DHCP server, instead of machine's
1634 hostname. Note that the specified hostname must consist only of
7-bit ASCII lower-case
1635 characters and no spaces or dots, and be formatted as a valid DNS domain name.
</para>
1640 <term><varname>MUDURL=
</varname></term>
1642 <para>When configured, the specified Manufacturer Usage Description (MUD) URL will be sent
1643 to the DHCPv4 server. Takes a URL of length up to
255 characters. A superficial verification
1644 that the string is a valid URL will be performed. DHCPv4 clients are intended to have at most
1645 one MUD URL associated with them. See
1646 <ulink url=
"https://tools.ietf.org/html/rfc8520">RFC
8520</ulink>.
</para>
1648 <para>MUD is an embedded software standard defined by the IETF that allows IoT device makers
1649 to advertise device specifications, including the intended communication patterns for their
1650 device when it connects to the network. The network can then use this to author a
1651 context-specific access policy, so the device functions only within those parameters.
</para>
1656 <term><varname>ClientIdentifier=
</varname></term>
1658 <para>The DHCPv4 client identifier to use. Takes one of
<option>mac
</option>,
1659 <option>duid
</option> or
<option>duid-only
</option>. If set to
<option>mac
</option>, the
1660 MAC address of the link is used. If set to
<option>duid
</option>, an RFC4361-compliant Client
1661 ID, which is the combination of IAID and DUID (see below), is used. If set to
1662 <option>duid-only
</option>, only DUID is used, this may not be RFC compliant, but some setups
1663 may require to use this. Defaults to
<option>duid
</option>.
</para>
1668 <term><varname>VendorClassIdentifier=
</varname></term>
1670 <para>The vendor class identifier used to identify vendor type and configuration.
</para>
1675 <term><varname>UserClass=
</varname></term>
1677 <para>A DHCPv4 client can use UserClass option to identify the type or category of user or
1678 applications it represents. The information contained in this option is a string that
1679 represents the user class of which the client is a member. Each class sets an identifying
1680 string of information to be used by the DHCP service to classify clients. Takes a
1681 whitespace-separated list of strings.
</para>
1686 <term><varname>DUIDType=
</varname></term>
1688 <para>Override the global
<varname>DUIDType=
</varname> setting for this network. See
1689 <citerefentry><refentrytitle>networkd.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>
1690 for a description of possible values.
</para>
1695 <term><varname>DUIDRawData=
</varname></term>
1697 <para>Override the global
<varname>DUIDRawData=
</varname> setting for this network. See
1698 <citerefentry><refentrytitle>networkd.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>
1699 for a description of possible values.
</para>
1704 <term><varname>IAID=
</varname></term>
1706 <para>The DHCP Identity Association Identifier (IAID) for the interface, a
32-bit unsigned
1712 <term><varname>Anonymize=
</varname></term>
1714 <para>Takes a boolean. When true, the options sent to the DHCP server will follow the
1715 <ulink url=
"https://tools.ietf.org/html/rfc7844">RFC
7844</ulink> (Anonymity Profiles for
1716 DHCP Clients) to minimize disclosure of identifying information. Defaults to false.
</para>
1718 <para>This option should only be set to true when
<varname>MACAddressPolicy=
</varname> is set
1719 to
<option>random
</option> (see
1720 <citerefentry><refentrytitle>systemd.link
</refentrytitle><manvolnum>5</manvolnum></citerefentry>).
1723 <para>When true,
<varname>SendHostname=
</varname>,
<varname>ClientIdentifier=
</varname>,
1724 <varname>VendorClassIdentifier=
</varname>,
<varname>UserClass=
</varname>,
1725 <varname>RequestOptions=
</varname>,
<varname>SendOption=
</varname>,
1726 <varname>SendVendorOption=
</varname>, and
<varname>MUDURL=
</varname> are ignored.
</para>
1728 <para>With this option enabled DHCP requests will mimic those generated by Microsoft
1729 Windows, in order to reduce the ability to fingerprint and recognize installations. This
1730 means DHCP request sizes will grow and lease data will be more comprehensive than normally,
1731 though most of the requested data is not actually used.
</para>
1736 <term><varname>RequestOptions=
</varname></term>
1738 <para>Sets request options to be sent to the server in the DHCPv4 request options list. A
1739 whitespace-separated list of integers in the range
1…
254. Defaults to unset.
</para>
1744 <term><varname>SendOption=
</varname></term>
1746 <para>Send an arbitrary raw option in the DHCPv4 request. Takes a DHCP option number, data
1747 type and data separated with a colon
1748 (
<literal><replaceable>option
</replaceable>:
<replaceable>type
</replaceable>:
<replaceable>value
</replaceable></literal>).
1749 The option number must be an integer in the range
1…
254. The type takes one of
1750 <literal>uint8
</literal>,
<literal>uint16
</literal>,
<literal>uint32
</literal>,
1751 <literal>ipv4address
</literal>, or
<literal>string
</literal>. Special characters in the data
1752 string may be escaped using
1753 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
1754 escapes
</ulink>. This setting can be specified multiple times. If an empty string is
1755 specified, then all options specified earlier are cleared. Defaults to unset.
</para>
1760 <term><varname>SendVendorOption=
</varname></term>
1762 <para>Send an arbitrary vendor option in the DHCPv4 request. Takes a DHCP option number, data
1763 type and data separated with a colon
1764 (
<literal><replaceable>option
</replaceable>:
<replaceable>type
</replaceable>:
<replaceable>value
</replaceable></literal>).
1765 The option number must be an integer in the range
1…
254. The type takes one of
1766 <literal>uint8
</literal>,
<literal>uint16
</literal>,
<literal>uint32
</literal>,
1767 <literal>ipv4address
</literal>, or
<literal>string
</literal>. Special characters in the data
1768 string may be escaped using
1769 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
1770 escapes
</ulink>. This setting can be specified multiple times. If an empty string is specified,
1771 then all options specified earlier are cleared. Defaults to unset.
</para>
1776 <term><varname>IPServiceType=
</varname></term>
1778 <para>Takes one of the special values
<literal>none
</literal>,
<literal>CS6
</literal>, or
1779 <literal>CS4
</literal>. When
<literal>none
</literal> no IP service type is set to the packet
1780 sent from the DHCPv4 client. When
<literal>CS6
</literal> (network control) or
1781 <literal>CS4
</literal> (realtime), the corresponding service type will be set. Defaults to
1782 <literal>CS6
</literal>.
</para>
1786 <!-- How to use the DHCP lease -->
1789 <term><varname>Label=
</varname></term>
1791 <para>Specifies the label for the IPv4 address received from the DHCP server. The label must
1792 be a
7-bit ASCII string with a length of
1…
15 characters. Defaults to unset.
</para>
1797 <term><varname>UseDNS=
</varname></term>
1799 <para>When true (the default), the DNS servers received from the DHCP server will be used.
1802 <para>This corresponds to the
<option>nameserver
</option> option in
1803 <citerefentry project='man-pages'
><refentrytitle>resolv.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
1809 <term><varname>RoutesToDNS=
</varname></term>
1811 <para>When true, the routes to the DNS servers received from the DHCP server will be
1812 configured. When
<varname>UseDNS=
</varname> is disabled, this setting is ignored. Defaults to
1818 <term><varname>UseNTP=
</varname></term>
1820 <para>When true (the default), the NTP servers received from the DHCP server will be used by
1821 <filename>systemd-timesyncd.service
</filename>.
</para>
1826 <term><varname>RoutesToNTP=
</varname></term>
1828 <para>When true, the routes to the NTP servers received from the DHCP server will be
1829 configured. When
<varname>UseNTP=
</varname> is disabled, this setting is ignored. Defaults to
1835 <term><varname>UseSIP=
</varname></term>
1837 <para>When true (the default), the SIP servers received from the DHCP server will be collected
1838 and made available to client programs.
</para>
1843 <term><varname>UseMTU=
</varname></term>
1845 <para>When true, the interface maximum transmission unit from the DHCP server will be used on
1846 the current link. If
<varname>MTUBytes=
</varname> is set, then this setting is ignored.
1847 Defaults to false.
</para>
1849 <para>Note, some drivers will reset the interfaces if the MTU is changed. For such
1850 interfaces, please try to use
<varname>IgnoreCarrierLoss=
</varname> with a short timespan,
1851 e.g.
<literal>3 seconds
</literal>.
</para>
1856 <term><varname>UseHostname=
</varname></term>
1858 <para>When true (the default), the hostname received from the DHCP server will be set as the
1859 transient hostname of the system.
</para>
1864 <term><varname>UseDomains=
</varname></term>
1866 <para>Takes a boolean, or the special value
<option>route
</option>. When true, the domain
1867 name received from the DHCP server will be used as DNS search domain over this link, similar
1868 to the effect of the
<option>Domains=
</option> setting. If set to
<option>route
</option>, the
1869 domain name received from the DHCP server will be used for routing DNS queries only, but not
1870 for searching, similar to the effect of the
<option>Domains=
</option> setting when the
1871 argument is prefixed with
<literal>~
</literal>. Defaults to false.
</para>
1873 <para>It is recommended to enable this option only on trusted networks, as setting this
1874 affects resolution of all hostnames, in particular of single-label names. It is generally
1875 safer to use the supplied domain only as routing domain, rather than as search domain, in
1876 order to not have it affect local resolution of single-label names.
</para>
1878 <para>When set to true, this setting corresponds to the
<option>domain
</option> option in
1879 <citerefentry project='man-pages'
><refentrytitle>resolv.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
1885 <term><varname>UseRoutes=
</varname></term>
1887 <para>When true (the default), the static routes will be requested from the DHCP server and
1888 added to the routing table with a metric of
1024, and a scope of
<option>global
</option>,
1889 <option>link
</option> or
<option>host
</option>, depending on the route's destination and
1890 gateway. If the destination is on the local host, e.g.,
127.x.x.x, or the same as the link's
1891 own address, the scope will be set to
<option>host
</option>. Otherwise if the gateway is null
1892 (a direct route), a
<option>link
</option> scope will be used. For anything else, scope
1893 defaults to
<option>global
</option>.
</para>
1898 <term><varname>RouteMetric=
</varname></term>
1900 <para>Set the routing metric for routes specified by the DHCP server (including the prefix
1901 route added for the specified prefix). Takes an unsigned integer in the range
0…
4294967295.
1902 Defaults to
1024.
</para>
1907 <term><varname>RouteTable=
<replaceable>num
</replaceable></varname></term>
1909 <para>The table identifier for DHCP routes (a number between
1 and
4294967295, or
0 to
1910 unset). The table can be retrieved using
1911 <command>ip route show table
<replaceable>num
</replaceable></command>.
</para>
1913 <para>When used in combination with
<varname>VRF=
</varname>, the VRF's routing table is
1914 used when this parameter is not specified.
</para>
1919 <term><varname>RouteMTUBytes=
</varname></term>
1921 <para>Specifies the MTU for the DHCP routes. Please see the [Route] section for further
1927 <term><varname>UseGateway=
</varname></term>
1929 <para>When true, the gateway will be requested from the DHCP server and added to the routing
1930 table with a metric of
1024, and a scope of
<option>link
</option>. When unset, the value
1931 specified with
<varname>UseRoutes=
</varname> is used.
</para>
1936 <term><varname>UseTimezone=
</varname></term>
1937 <listitem><para>When true, the timezone received from the DHCP server will be set as timezone
1938 of the local system. Defaults to false.
</para></listitem>
1942 <term><varname>Use6RD=
</varname></term>
1944 <para>When true, subnets of the received IPv6 prefix are assigned to downstream interfaces
1945 which enables
<varname>DHCPPrefixDelegation=
</varname>. See also
1946 <varname>DHCPPrefixDelegation=
</varname> in the [Network] section, the [DHCPPrefixDelegation]
1947 section, and
<ulink url=
"https://tools.ietf.org/html/rfc5969">RFC
5969</ulink>. Defaults to
1953 <term><varname>FallbackLeaseLifetimeSec=
</varname></term>
1955 <para>Allows one to set DHCPv4 lease lifetime when DHCPv4 server does not send the lease
1956 lifetime. Takes one of
<literal>forever
</literal> or
<literal>infinity
</literal>. If
1957 specified, the acquired address never expires. Defaults to unset.
</para>
1961 <!-- How to communicate with the server -->
1964 <term><varname>RequestBroadcast=
</varname></term>
1966 <para>Request the server to use broadcast messages before the IP address has been configured.
1967 This is necessary for devices that cannot receive RAW packets, or that cannot receive packets
1968 at all before an IP address has been configured. On the other hand, this must not be enabled
1969 on networks where broadcasts are filtered out.
</para>
1974 <term><varname>MaxAttempts=
</varname></term>
1976 <para>Specifies how many times the DHCPv4 client configuration should be attempted. Takes a
1977 number or
<literal>infinity
</literal>. Defaults to
<literal>infinity
</literal>. Note that the
1978 time between retries is increased exponentially, up to approximately one per minute, so the
1979 network will not be overloaded even if this number is high. The default is suitable in most
1980 circumstances.
</para>
1985 <term><varname>ListenPort=
</varname></term>
1987 <para>Set the port from which the DHCP client packets originate.
</para>
1992 <term><varname>DenyList=
</varname></term>
1994 <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a
1995 prefix length after
<literal>/
</literal>. DHCP offers from servers in the list are rejected.
1996 Note that if
<varname>AllowList=
</varname> is configured then
<varname>DenyList=
</varname> is
2002 <term><varname>AllowList=
</varname></term>
2004 <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a
2005 prefix length after
<literal>/
</literal>. DHCP offers from servers in the list are accepted.
2011 <term><varname>SendRelease=
</varname></term>
2013 <para>When true, the DHCPv4 client sends a DHCP release packet when it stops. Defaults to
2019 <term><varname>SendDecline=
</varname></term>
2021 <para>A boolean. When true,
<command>systemd-networkd
</command> performs IPv4 Duplicate
2022 Address Detection to the acquired address by the DHCPv4 client. If duplicate is detected,
2023 the DHCPv4 client rejects the address by sending a
<constant>DHCPDECLINE
</constant> packet to
2024 the DHCP server, and tries to obtain an IP address again. See
2025 <ulink url=
"https://tools.ietf.org/html/rfc5227">RFC
5227</ulink>. Defaults to false.
</para>
2032 <title>[DHCPv6] Section Options
</title>
2034 <para>The [DHCPv6] section configures the DHCPv6 client, if it is enabled with the
2035 <varname>DHCP=
</varname> setting described above, or invoked by the IPv6 Router Advertisement:
2038 <variablelist class='network-directives'
>
2040 <!-- DHCP packet contents -->
2043 <term><varname>MUDURL=
</varname></term>
2044 <term><varname>IAID=
</varname></term>
2045 <term><varname>DUIDType=
</varname></term>
2046 <term><varname>DUIDRawData=
</varname></term>
2047 <term><varname>RequestOptions=
</varname></term>
2049 <para>As in the [DHCPv4] section.
</para>
2054 <term><varname>SendOption=
</varname></term>
2056 <para>As in the [DHCPv4] section, however because DHCPv6 uses
16-bit fields to store option
2057 numbers, the option number is an integer in the range
1…
65536.
</para>
2062 <term><varname>SendVendorOption=
</varname></term>
2064 <para>Send an arbitrary vendor option in the DHCPv6 request. Takes an enterprise identifier,
2065 DHCP option number, data type, and data separated with a colon
2066 (
<literal><replaceable>enterprise identifier
</replaceable>:
<replaceable>option
</replaceable>:
<replaceable>type
</replaceable>:
<replaceable>value
</replaceable></literal>).
2067 Enterprise identifier is an unsigned integer in the range
1…
4294967294. The option number
2068 must be an integer in the range
1…
254. Data type takes one of
<literal>uint8
</literal>,
2069 <literal>uint16
</literal>,
<literal>uint32
</literal>,
<literal>ipv4address
</literal>,
2070 <literal>ipv6address
</literal>, or
<literal>string
</literal>. Special characters in the data
2071 string may be escaped using
2072 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
2073 escapes
</ulink>. This setting can be specified multiple times. If an empty string is
2074 specified, then all options specified earlier are cleared. Defaults to unset.
</para>
2079 <term><varname>UserClass=
</varname></term>
2081 <para>A DHCPv6 client can use User Class option to identify the type or category of user or
2082 applications it represents. The information contained in this option is a string that
2083 represents the user class of which the client is a member. Each class sets an identifying
2084 string of information to be used by the DHCP service to classify clients. Special characters
2085 in the data string may be escaped using
2086 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
2087 escapes
</ulink>. This setting can be specified multiple times. If an empty string is
2088 specified, then all options specified earlier are cleared. Takes a whitespace-separated list
2089 of strings. Note that currently
<constant>NUL
</constant> bytes are not allowed.
</para>
2094 <term><varname>VendorClass=
</varname></term>
2096 <para>A DHCPv6 client can use VendorClass option to identify the vendor that manufactured the
2097 hardware on which the client is running. The information contained in the data area of this
2098 option is contained in one or more opaque fields that identify details of the hardware
2099 configuration. Takes a whitespace-separated list of strings.
</para>
2104 <term><varname>PrefixDelegationHint=
</varname></term>
2106 <para>Takes an IPv6 address with prefix length in the same format as the
2107 <varname>Address=
</varname> in the [Network] section. The DHCPv6 client will include a prefix
2108 hint in the DHCPv6 solicitation sent to the server. The prefix length must be in the range
2109 1…
128. Defaults to unset.
</para>
2113 <!-- How to use the DHCP lease -->
2116 <term><varname>UseAddress=
</varname></term>
2118 <para>When true (the default), the IP addresses provided by the DHCPv6 server will be
2124 <term><varname>UseDelegatedPrefix=
</varname></term>
2126 <para>When true (the default), the client will request the DHCPv6 server to delegate
2127 prefixes. If the server provides prefixes to be delegated, then subnets of the prefixes are
2128 assigned to the interfaces which enables
<varname>DHCPPrefixDelegation=
</varname>.
2129 See also the
<varname>DHCPPrefixDelegation=
</varname> setting in the [Network] section,
2130 settings in the [DHCPPrefixDelegation] section, and
2131 <ulink url=
"https://www.rfc-editor.org/rfc/rfc8415.html#section-6.3">RFC
8415</ulink>.
2137 <term><varname>UseDNS=
</varname></term>
2138 <term><varname>UseNTP=
</varname></term>
2139 <term><varname>UseHostname=
</varname></term>
2140 <term><varname>UseDomains=
</varname></term>
2142 <para>As in the [DHCPv4] section.
</para>
2146 <!-- How to communicate with the server -->
2149 <term><varname>WithoutRA=
</varname></term>
2151 <para>Allows DHCPv6 client to start without router advertisements's managed or other
2152 address configuration flag. Takes one of
<literal>no
</literal>,
<literal>solicit
</literal>
2153 or
<literal>information-request
</literal>. If this is not specified,
2154 <literal>solicit
</literal> is used when
<varname>DHCPPrefixDelegation=
</varname> is enabled
2155 and
<varname>UplinkInterface=:self
</varname> is specified in the [DHCPPrefixDelegation]
2156 section. Otherwise, defaults to
<literal>no
</literal>, and the DHCPv6 client will be started
2157 when an RA is received. See also the
<varname>DHCPv6Client=
</varname> setting in the
2158 [IPv6AcceptRA] section.
</para>
2165 <title>[DHCPPrefixDelegation] Section Options
</title>
2166 <para>The [DHCPPrefixDelegation] section configures subnet prefixes of the delegated prefixes
2167 acquired by a DHCPv6 client, or by a DHCPv4 client through the
6RD option on another interface.
2168 The settings in this section are used only when the
<varname>DHCPPrefixDelegation=
</varname>
2169 setting in the [Network] section is enabled.
</para>
2171 <variablelist class='network-directives'
>
2173 <term><varname>UplinkInterface=
</varname></term>
2175 <para>Specifies the name or the index of the uplink interface, or one of the special values
2176 <literal>:self
</literal> and
<literal>:auto
</literal>. When
<literal>:self
</literal>, the
2177 interface itself is considered the uplink interface, and
2178 <varname>WithoutRA=solicit
</varname> is implied if the setting is not explicitly specified.
2179 When
<literal>:auto
</literal>, the first link which acquired prefixes to be delegated from
2180 the DHCPv6 or DHCPv4 server is selected. Defaults to
<literal>:auto
</literal>.
</para>
2185 <term><varname>SubnetId=
</varname></term>
2187 <para>Configure a specific subnet ID on the interface from a (previously) received prefix
2188 delegation. You can either set
"auto" (the default) or a specific subnet ID (as defined in
2189 <ulink url=
"https://tools.ietf.org/html/rfc4291#section-2.5.4">RFC
4291</ulink>, section
2190 2.5.4), in which case the allowed value is hexadecimal, from
0 to
0x7fffffffffffffff
2196 <term><varname>Announce=
</varname></term>
2198 <para>Takes a boolean. When enabled, and
<varname>IPv6SendRA=
</varname> in [Network] section
2199 is enabled, the delegated prefixes are distributed through the IPv6 Router Advertisement.
2200 This setting will be ignored when the
<varname>DHCPPrefixDelegation=
</varname> setting is
2201 enabled on the upstream interface. Defaults to yes.
</para>
2206 <term><varname>Assign=
</varname></term>
2208 <para>Takes a boolean. Specifies whether to add an address from the delegated prefixes which
2209 are received from the WAN interface by the DHCPv6 Prefix Delegation. When true (on LAN
2210 interfce), the EUI-
64 algorithm will be used by default to form an interface identifier from
2211 the delegated prefixes. See also
<varname>Token=
</varname> setting below. Defaults to yes.
2217 <term><varname>Token=
</varname></term>
2219 <para>Specifies an optional address generation mode for assigning an address in each
2220 delegated prefix. This accepts the same syntax as
<varname>Token=
</varname> in the
2221 [IPv6AcceptRA] section. If
<varname>Assign=
</varname> is set to false, then this setting will
2222 be ignored. Defaults to unset, which means the EUI-
64 algorithm will be used.
</para>
2227 <term><varname>ManageTemporaryAddress=
</varname></term>
2229 <para>As in the [Address] section, but defaults to true.
</para>
2234 <term><varname>RouteMetric=
</varname></term>
2236 <para>The metric of the route to the delegated prefix subnet. Takes an unsigned integer in
2237 the range
0…
4294967295. When set to
0, the kernel's default value is used. Defaults to
256.
2245 <title>[IPv6AcceptRA] Section Options
</title>
2246 <para>The [IPv6AcceptRA] section configures the IPv6 Router Advertisement (RA) client, if it is enabled
2247 with the
<varname>IPv6AcceptRA=
</varname> setting described above:
</para>
2249 <variablelist class='network-directives'
>
2251 <term><varname>Token=
</varname></term>
2253 <para>Specifies an optional address generation mode for the Stateless Address
2254 Autoconfiguration (SLAAC). The following values are supported:
</para>
2258 <term><option>eui64
</option></term>
2261 The EUI-
64 algorithm will be used to generate an address for that prefix. Only
2262 supported by Ethernet or InfiniBand interfaces.
2267 <term><option>static:
<replaceable>ADDRESS
</replaceable></option></term>
2270 An IPv6 address must be specified after a colon (
<literal>:
</literal>), and the
2271 lower bits of the supplied address are combined with the upper bits of a prefix
2272 received in a Router Advertisement (RA) message to form a complete address. Note
2273 that if multiple prefixes are received in an RA message, or in multiple RA messages,
2274 addresses will be formed from each of them using the supplied address. This mode
2275 implements SLAAC but uses a static interface identifier instead of an identifier
2276 generated by using the EUI-
64 algorithm. Because the interface identifier is static,
2277 if Duplicate Address Detection detects that the computed address is a duplicate
2278 (in use by another node on the link), then this mode will fail to provide an address
2279 for that prefix. If an IPv6 address without mode is specified, then
2280 <literal>static
</literal> mode is assumed.
2285 <term><option>prefixstable[:
<replaceable>ADDRESS
</replaceable>][,
<replaceable>UUID
</replaceable>]
</option></term>
2288 The algorithm specified in
2289 <ulink url=
"https://tools.ietf.org/html/rfc7217">RFC
7217</ulink> will be used to
2290 generate interface identifiers. This mode can optionally take an IPv6 address
2291 separated with a colon (
<literal>:
</literal>). If an IPv6 address is specified,
2292 then an interface identifier is generated only when a prefix received in an RA
2293 message matches the supplied address.
2296 This mode can also optionally take a non-null UUID in the format which
2297 <function>sd_id128_from_string()
</function> accepts, e.g.
2298 <literal>86b123b969ba4b7eb8b3d8605123525a
</literal> or
2299 <literal>86b123b9-
69ba-
4b7e-b8b3-d8605123525a
</literal>. If a UUID is specified, the
2300 value is used as the secret key to generate interface identifiers. If not specified,
2301 then an application specific ID generated with the system's machine-ID will be used
2302 as the secret key. See
2303 <citerefentry><refentrytitle>sd-id128
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
2304 <citerefentry><refentrytitle>sd_id128_from_string
</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
2306 <citerefentry><refentrytitle>sd_id128_get_machine
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
2309 Note that the
<literal>prefixstable
</literal> algorithm uses both the interface
2310 name and MAC address as input to the hash to compute the interface identifier, so
2311 if either of those are changed the resulting interface identifier (and address)
2312 will be changed, even if the prefix received in the RA message has not been
2319 <para>If no address generation mode is specified (which is the default), or a received
2320 prefix does not match any of the addresses provided in
<literal>prefixstable
</literal>
2321 mode, then the EUI-
64 algorithm will be used for Ethernet or InfiniBand interfaces,
2322 otherwise
<literal>prefixstable
</literal> will be used to form an interface identifier for
2325 <para>This setting can be specified multiple times. If an empty string is assigned, then
2326 the all previous assignments are cleared.
</para>
2329 <programlisting>Token=eui64
2331 Token=static:::
1a:
2b:
3c:
4d
2333 Token=prefixstable:
2002:da8:
1::
</programlisting></para>
2338 <term><varname>UseDNS=
</varname></term>
2340 <para>When true (the default), the DNS servers received in the Router Advertisement will be used.
</para>
2342 <para>This corresponds to the
<option>nameserver
</option> option in
<citerefentry
2343 project='man-pages'
><refentrytitle>resolv.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
2348 <term><varname>UseDomains=
</varname></term>
2350 <para>Takes a boolean, or the special value
<literal>route
</literal>. When true, the domain name
2351 received via IPv6 Router Advertisement (RA) will be used as DNS search domain over this link, similar to
2352 the effect of the
<option>Domains=
</option> setting. If set to
<literal>route
</literal>, the domain name
2353 received via IPv6 RA will be used for routing DNS queries only, but not for searching, similar to the
2354 effect of the
<option>Domains=
</option> setting when the argument is prefixed with
2355 <literal>~
</literal>. Defaults to false.
</para>
2357 <para>It is recommended to enable this option only on trusted networks, as setting this affects resolution
2358 of all hostnames, in particular of single-label names. It is generally safer to use the supplied domain
2359 only as routing domain, rather than as search domain, in order to not have it affect local resolution of
2360 single-label names.
</para>
2362 <para>When set to true, this setting corresponds to the
<option>domain
</option> option in
<citerefentry
2363 project='man-pages'
><refentrytitle>resolv.conf
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
2368 <term><varname>RouteTable=
<replaceable>num
</replaceable></varname></term>
2370 <para>The table identifier for the routes received in the Router Advertisement
2371 (a number between
1 and
4294967295, or
0 to unset).
2372 The table can be retrieved using
<command>ip route show table
<replaceable>num
</replaceable></command>.
2378 <term><varname>RouteMetric=
</varname></term>
2380 <para>Set the routing metric for the routes received in the Router Advertisement. Takes an
2381 unsigned integer in the range
0…
4294967295. Defaults to
1024.
</para>
2386 <term><varname>UseMTU=
</varname></term>
2388 <para>Takes a boolean. When true, the MTU received in the Router Advertisement will be
2389 used. Defaults to true.
</para>
2394 <term><varname>UseGateway=
</varname></term>
2396 <para>When true (the default), the router address will be configured as the default gateway.
2402 <term><varname>UseRoutePrefix=
</varname></term>
2404 <para>When true (the default), the routes corresponding to the route prefixes received in
2405 the Router Advertisement will be configured.
</para>
2410 <term><varname>UseAutonomousPrefix=
</varname></term>
2412 <para>When true (the default), the autonomous prefix received in the Router Advertisement will be used and take
2413 precedence over any statically configured ones.
</para>
2418 <term><varname>UseOnLinkPrefix=
</varname></term>
2420 <para>When true (the default), the onlink prefix received in the Router Advertisement will be
2421 used and takes precedence over any statically configured ones.
</para>
2426 <term><varname>RouterDenyList=
</varname></term>
2428 <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally
2429 take a prefix length after
<literal>/
</literal>. Any information advertised by the listed
2430 router is ignored.
</para>
2435 <term><varname>RouterAllowList=
</varname></term>
2437 <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally
2438 take a prefix length after
<literal>/
</literal>. Only information advertised by the listed
2439 router is accepted. Note that if
<varname>RouterAllowList=
</varname> is configured then
2440 <varname>RouterDenyList=
</varname> is ignored.
</para>
2445 <term><varname>PrefixDenyList=
</varname></term>
2447 <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its
2448 prefix length after
<literal>/
</literal>. IPv6 prefixes supplied via router advertisements
2449 in the list are ignored.
</para>
2454 <term><varname>PrefixAllowList=
</varname></term>
2456 <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its
2457 prefix length after
<literal>/
</literal>. IPv6 prefixes supplied via router advertisements
2458 in the list are allowed. Note that if
<varname>PrefixAllowList=
</varname> is configured
2459 then
<varname>PrefixDenyList=
</varname> is ignored.
</para>
2464 <term><varname>RouteDenyList=
</varname></term>
2466 <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take
2467 its prefix length after
<literal>/
</literal>. IPv6 route prefixes supplied via router
2468 advertisements in the list are ignored.
</para>
2473 <term><varname>RouteAllowList=
</varname></term>
2475 <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take
2476 its prefix length after
<literal>/
</literal>. IPv6 route prefixes supplied via router
2477 advertisements in the list are allowed. Note that if
<varname>RouteAllowList=
</varname> is
2478 configured then
<varname>RouteDenyList=
</varname> is ignored.
</para>
2483 <term><varname>DHCPv6Client=
</varname></term>
2485 <para>Takes a boolean, or the special value
<literal>always
</literal>. When true, the
2486 DHCPv6 client will be started when the RA has the managed or other information flag. If set
2487 to
<literal>always
</literal>, the DHCPv6 client will be started in managed mode when an RA
2488 is received, even if neither managed nor other information flag is set in the RA. This will
2489 be ignored when
<varname>WithoutRA=
</varname> in the [DHCPv6] section is enabled, or
2490 <varname>UplinkInterface=:self
</varname> in the [DHCPPrefixDelegation] section is
2491 specified. Defaults to true.
</para>
2498 <title>[DHCPServer] Section Options
</title>
2499 <para>The [DHCPServer] section contains settings for the DHCP server, if enabled via the
2500 <varname>DHCPServer=
</varname> option described above:
</para>
2502 <variablelist class='network-directives'
>
2505 <term><varname>ServerAddress=
</varname></term>
2506 <listitem><para>Specifies server address for the DHCP server. Takes an IPv4 address with prefix
2507 length, for example
<literal>192.168.0.1/
24</literal>. This setting may be useful when the link on
2508 which the DHCP server is running has multiple static addresses. When unset, one of static addresses
2509 in the link will be automatically selected. Defaults to unset.
</para></listitem>
2513 <term><varname>PoolOffset=
</varname></term>
2514 <term><varname>PoolSize=
</varname></term>
2516 <listitem><para>Configures the pool of addresses to hand out. The pool
2517 is a contiguous sequence of IP addresses in the subnet configured for
2518 the server address, which does not include the subnet nor the broadcast
2519 address.
<varname>PoolOffset=
</varname> takes the offset of the pool
2520 from the start of subnet, or zero to use the default value.
2521 <varname>PoolSize=
</varname> takes the number of IP addresses in the
2522 pool or zero to use the default value. By default, the pool starts at
2523 the first address after the subnet address and takes up the rest of
2524 the subnet, excluding the broadcast address. If the pool includes
2525 the server address (the default), this is reserved and not handed
2526 out to clients.
</para></listitem>
2530 <term><varname>DefaultLeaseTimeSec=
</varname></term>
2531 <term><varname>MaxLeaseTimeSec=
</varname></term>
2533 <listitem><para>Control the default and maximum DHCP lease
2534 time to pass to clients. These settings take time values in seconds or
2535 another common time unit, depending on the suffix. The default
2536 lease time is used for clients that did not ask for a specific
2537 lease time. If a client asks for a lease time longer than the
2538 maximum lease time, it is automatically shortened to the
2539 specified time. The default lease time defaults to
1h, the
2540 maximum lease time to
12h. Shorter lease times are beneficial
2541 if the configuration data in DHCP leases changes frequently
2542 and clients shall learn the new settings with shorter
2543 latencies. Longer lease times reduce the generated DHCP
2544 network traffic.
</para></listitem>
2548 <term><varname>UplinkInterface=
</varname></term>
2549 <listitem><para>Specifies the name or the index of the uplink interface, or one of the special
2550 values
<literal>:none
</literal> and
<literal>:auto
</literal>. When emitting DNS, NTP, or SIP
2551 servers is enabled but no servers are specified, the servers configured in the uplink interface
2552 will be emitted. When
<literal>:auto
</literal>, the link which has a default gateway with the
2553 highest priority will be automatically selected. When
<literal>:none
</literal>, no uplink
2554 interface will be selected. Defaults to
<literal>:auto
</literal>.
</para></listitem>
2558 <term><varname>EmitDNS=
</varname></term>
2559 <term><varname>DNS=
</varname></term>
2561 <listitem><para><varname>EmitDNS=
</varname> takes a boolean. Configures whether the DHCP leases
2562 handed out to clients shall contain DNS server information. Defaults to
<literal>yes
</literal>.
2563 The DNS servers to pass to clients may be configured with the
<varname>DNS=
</varname> option,
2564 which takes a list of IPv4 addresses, or special value
<literal>_server_address
</literal> which
2565 will be converted to the address used by the DHCP server.
</para>
2567 <para>If the
<varname>EmitDNS=
</varname> option is enabled but no servers configured, the
2568 servers are automatically propagated from an
"uplink" interface that has appropriate servers
2569 set. The
"uplink" interface is determined by the default route of the system with the highest
2570 priority. Note that this information is acquired at the time the lease is handed out, and does
2571 not take uplink interfaces into account that acquire DNS server information at a later point.
2572 If no suitable uplink interface is found the DNS server data from
2573 <filename>/etc/resolv.conf
</filename> is used. Also, note that the leases are not refreshed if
2574 the uplink network configuration changes. To ensure clients regularly acquire the most current
2575 uplink DNS server information, it is thus advisable to shorten the DHCP lease time via
2576 <varname>MaxLeaseTimeSec=
</varname> described above.
</para>
2578 <para>This setting can be specified multiple times. If an empty string is specified, then all
2579 DNS servers specified earlier are cleared.
</para></listitem>
2583 <term><varname>EmitNTP=
</varname></term>
2584 <term><varname>NTP=
</varname></term>
2585 <term><varname>EmitSIP=
</varname></term>
2586 <term><varname>SIP=
</varname></term>
2587 <term><varname>EmitPOP3=
</varname></term>
2588 <term><varname>POP3=
</varname></term>
2589 <term><varname>EmitSMTP=
</varname></term>
2590 <term><varname>SMTP=
</varname></term>
2591 <term><varname>EmitLPR=
</varname></term>
2592 <term><varname>LPR=
</varname></term>
2594 <listitem><para>Similar to the
<varname>EmitDNS=
</varname> and
<varname>DNS=
</varname> settings
2595 described above, these settings configure whether and what server information for the indicate
2596 protocol shall be emitted as part of the DHCP lease. The same syntax, propagation semantics and
2597 defaults apply as for
<varname>EmitDNS=
</varname> and
<varname>DNS=
</varname>.
</para></listitem>
2601 <term><varname>EmitRouter=
</varname></term>
2602 <term><varname>Router=
</varname></term>
2604 <listitem><para>The
<varname>EmitRouter=
</varname> setting takes a boolean value, and configures
2605 whether the DHCP lease should contain the router option. The
<varname>Router=
</varname> setting
2606 takes an IPv4 address, and configures the router address to be emitted. When the
2607 <varname>Router=
</varname> setting is not specified, then the server address will be used for
2608 the router option. When the
<varname>EmitRouter=
</varname> setting is disabled, the
2609 <varname>Router=
</varname> setting will be ignored. The
<varname>EmitRouter=
</varname> setting
2610 defaults to true, and the
<varname>Router=
</varname> setting defaults to unset.
2615 <term><varname>EmitTimezone=
</varname></term>
2616 <term><varname>Timezone=
</varname></term>
2618 <listitem><para>Takes a boolean. Configures whether the DHCP leases handed out
2619 to clients shall contain timezone information. Defaults to
<literal>yes
</literal>. The
2620 <varname>Timezone=
</varname> setting takes a timezone string
2621 (such as
<literal>Europe/Berlin
</literal> or
2622 <literal>UTC
</literal>) to pass to clients. If no explicit
2623 timezone is set, the system timezone of the local host is
2624 propagated, as determined by the
2625 <filename>/etc/localtime
</filename> symlink.
</para></listitem>
2629 <term><varname>BootServerAddress=
</varname></term>
2632 <para>Takes an IPv4 address of the boot server used by e.g. PXE boot systems. When specified,
2633 the address is set to the
<literal>siaddr
</literal> field of the DHCP message header. See
2634 <ulink url=
"https://www.rfc-editor.org/rfc/rfc2131.html">RFC
2131</ulink> for more details.
2635 Defaults to unset.
</para>
2640 <term><varname>BootServerName=
</varname></term>
2643 <para>Takes a name of the boot server used by e.g. PXE boot systems. When specified, the
2644 server name is set to the DHCP option
66. See
2645 <ulink url=
"https://www.rfc-editor.org/rfc/rfc2132.html">RFC
2132</ulink> for more details.
2646 Defaults to unset.
</para>
2647 <para>Note that typically one of
2648 <varname>BootServerName=
</varname>/
<varname>BootServerAddress=
</varname> is sufficient to be
2649 set, but both can be set too, if desired.
</para>
2654 <term><varname>BootFilename=
</varname></term>
2657 <para>Takes a path or URL to a file loaded by e.g. a PXE boot loader. The specified path is
2658 set to the DHCP option
67. See
2659 <ulink url=
"https://www.rfc-editor.org/rfc/rfc2132.html">RFC
2132</ulink> for more details.
2660 Defaults to unset.
</para>
2665 <term><varname>SendOption=
</varname></term>
2667 <para>Send a raw option with value via DHCPv4 server. Takes a DHCP option number, data type
2668 and data (
<literal><replaceable>option
</replaceable>:
<replaceable>type
</replaceable>:
<replaceable>value
</replaceable></literal>).
2669 The option number is an integer in the range
1…
254. The type takes one of
<literal>uint8
</literal>,
2670 <literal>uint16
</literal>,
<literal>uint32
</literal>,
<literal>ipv4address
</literal>,
<literal>ipv6address
</literal>, or
2671 <literal>string
</literal>. Special characters in the data string may be escaped using
2672 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
2673 escapes
</ulink>. This setting can be specified multiple times. If an empty string is specified,
2674 then all options specified earlier are cleared. Defaults to unset.
</para>
2679 <term><varname>SendVendorOption=
</varname></term>
2681 <para>Send a vendor option with value via DHCPv4 server. Takes a DHCP option number, data type
2682 and data (
<literal><replaceable>option
</replaceable>:
<replaceable>type
</replaceable>:
<replaceable>value
</replaceable></literal>).
2683 The option number is an integer in the range
1…
254. The type takes one of
<literal>uint8
</literal>,
2684 <literal>uint16
</literal>,
<literal>uint32
</literal>,
<literal>ipv4address
</literal>, or
2685 <literal>string
</literal>. Special characters in the data string may be escaped using
2686 <ulink url=
"https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style
2687 escapes
</ulink>. This setting can be specified multiple times. If an empty string is specified,
2688 then all options specified earlier are cleared. Defaults to unset.
</para>
2692 <term><varname>BindToInterface=
</varname></term>
2694 <para>Takes a boolean value. When
<literal>yes
</literal>, DHCP server socket will be bound
2695 to its network interface and all socket communication will be restricted to this interface.
2696 Defaults to
<literal>yes
</literal>, except if
<varname>RelayTarget=
</varname> is used (see below),
2697 in which case it defaults to
<literal>no
</literal>.
</para>
2701 <term><varname>RelayTarget=
</varname></term>
2703 <para>Takes an IPv4 address, which must be in the format described in
2704 <citerefentry project='man-pages'
><refentrytitle>inet_pton
</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
2705 Turns this DHCP server into a DHCP relay agent. See
<ulink url=
"https://tools.ietf.org/html/rfc1542">RFC
1542</ulink>.
2706 The address is the address of DHCP server or another relay agent to forward DHCP messages to and from.
</para>
2710 <term><varname>RelayAgentCircuitId=
</varname></term>
2712 <para>Specifies value for Agent Circuit ID suboption of Relay Agent Information option.
2713 Takes a string, which must be in the format
<literal>string:
<replaceable>value
</replaceable></literal>,
2714 where
<literal><replaceable>value
</replaceable></literal> should be replaced with the value of the suboption.
2715 Defaults to unset (means no Agent Circuit ID suboption is generated).
2716 Ignored if
<varname>RelayTarget=
</varname> is not specified.
</para>
2720 <term><varname>RelayAgentRemoteId=
</varname></term>
2722 <para>Specifies value for Agent Remote ID suboption of Relay Agent Information option.
2723 Takes a string, which must be in the format
<literal>string:
<replaceable>value
</replaceable></literal>,
2724 where
<literal><replaceable>value
</replaceable></literal> should be replaced with the value of the suboption.
2725 Defaults to unset (means no Agent Remote ID suboption is generated).
2726 Ignored if
<varname>RelayTarget=
</varname> is not specified.
</para>
2734 <title>[DHCPServerStaticLease] Section Options
</title>
2735 <para>The
<literal>[DHCPServerStaticLease]
</literal> section configures a static DHCP lease to assign a
2736 fixed IPv4 address to a specific device based on its MAC address. This section can be specified multiple
2739 <variablelist class='network-directives'
>
2741 <term><varname>MACAddress=
</varname></term>
2743 <listitem><para>The hardware address of a device to match. This key is mandatory.
</para></listitem>
2747 <term><varname>Address=
</varname></term>
2749 <listitem><para>The IPv4 address that should be assigned to the device that was matched with
2750 <varname>MACAddress=
</varname>. This key is mandatory.
</para></listitem>
2756 <title>[IPv6SendRA] Section Options
</title>
2757 <para>The [IPv6SendRA] section contains settings for sending IPv6 Router Advertisements and whether
2758 to act as a router, if enabled via the
<varname>IPv6SendRA=
</varname> option described above. IPv6
2759 network prefixes or routes are defined with one or more [IPv6Prefix] or [IPv6RoutePrefix] sections.
2762 <variablelist class='network-directives'
>
2765 <term><varname>Managed=
</varname></term>
2766 <term><varname>OtherInformation=
</varname></term>
2768 <listitem><para>Takes a boolean. Controls whether a DHCPv6 server is used to acquire IPv6
2769 addresses on the network link when
<varname>Managed=
</varname>
2770 is set to
<literal>true
</literal> or if only additional network
2771 information can be obtained via DHCPv6 for the network link when
2772 <varname>OtherInformation=
</varname> is set to
2773 <literal>true
</literal>. Both settings default to
2774 <literal>false
</literal>, which means that a DHCPv6 server is not being
2775 used.
</para></listitem>
2779 <term><varname>RouterLifetimeSec=
</varname></term>
2781 <listitem><para>Takes a timespan. Configures the IPv6 router lifetime in seconds. The value must be
0
2782 seconds, or between
4 seconds and
9000 seconds. When set to
0, the host is not acting as a router.
2783 Defaults to
1800 seconds (
30 minutes).
</para>
2788 <term><varname>RouterPreference=
</varname></term>
2790 <listitem><para>Configures IPv6 router preference if
2791 <varname>RouterLifetimeSec=
</varname> is non-zero. Valid values are
2792 <literal>high
</literal>,
<literal>medium
</literal> and
2793 <literal>low
</literal>, with
<literal>normal
</literal> and
2794 <literal>default
</literal> added as synonyms for
2795 <literal>medium
</literal> just to make configuration easier. See
2796 <ulink url=
"https://tools.ietf.org/html/rfc4191">RFC
4191</ulink>
2797 for details. Defaults to
<literal>medium
</literal>.
</para></listitem>
2801 <term><varname>UplinkInterface=
</varname></term>
2802 <listitem><para>Specifies the name or the index of the uplink interface, or one of the special
2803 values
<literal>:none
</literal> and
<literal>:auto
</literal>. When emitting DNS servers or
2804 search domains is enabled but no servers are specified, the servers configured in the uplink
2805 interface will be emitted. When
<literal>:auto
</literal>, the value specified to the same
2806 setting in the [DHCPPrefixDelegation] section will be used if
2807 <varname>DHCPPrefixDelegation=
</varname> is enabled, otherwise the link which has a default
2808 gateway with the highest priority will be automatically selected. When
<literal>:none
</literal>,
2809 no uplink interface will be selected. Defaults to
<literal>:auto
</literal>.
</para></listitem>
2813 <term><varname>EmitDNS=
</varname></term>
2814 <term><varname>DNS=
</varname></term>
2816 <listitem><para><varname>DNS=
</varname> specifies a list of recursive DNS server IPv6 addresses
2817 that are distributed via Router Advertisement messages when
<varname>EmitDNS=
</varname> is true.
2818 <varname>DNS=
</varname> also takes special value
<literal>_link_local
</literal>; in that case
2819 the IPv6 link local address is distributed. If
<varname>DNS=
</varname> is empty, DNS servers are
2820 read from the [Network] section. If the [Network] section does not contain any DNS servers
2821 either, DNS servers from the uplink interface specified in
<varname>UplinkInterface=
</varname>
2822 will be used. When
<varname>EmitDNS=
</varname> is false, no DNS server information is sent in
2823 Router Advertisement messages.
<varname>EmitDNS=
</varname> defaults to true.
</para></listitem>
2827 <term><varname>EmitDomains=
</varname></term>
2828 <term><varname>Domains=
</varname></term>
2830 <listitem><para>A list of DNS search domains distributed via Router Advertisement messages when
2831 <varname>EmitDomains=
</varname> is true. If
<varname>Domains=
</varname> is empty, DNS search
2832 domains are read from the [Network] section. If the [Network] section does not contain any DNS
2833 search domains either, DNS search domains from the uplink interface specified in
2834 <varname>UplinkInterface=
</varname> will be used. When
<varname>EmitDomains=
</varname> is false,
2835 no DNS search domain information is sent in Router Advertisement messages.
2836 <varname>EmitDomains=
</varname> defaults to true.
</para></listitem>
2840 <term><varname>DNSLifetimeSec=
</varname></term>
2842 <listitem><para>Lifetime in seconds for the DNS server addresses listed in
2843 <varname>DNS=
</varname> and search domains listed in
<varname>Domains=
</varname>. Defaults to
2844 3600 seconds (one hour).
</para></listitem>
2851 <title>[IPv6Prefix] Section Options
</title>
2852 <para>One or more [IPv6Prefix] sections contain the IPv6 prefixes that are announced via Router
2853 Advertisements. See
<ulink url=
"https://tools.ietf.org/html/rfc4861">RFC
4861</ulink> for further
2856 <variablelist class='network-directives'
>
2859 <term><varname>AddressAutoconfiguration=
</varname></term>
2860 <term><varname>OnLink=
</varname></term>
2862 <listitem><para>Takes a boolean to specify whether IPv6 addresses can be
2863 autoconfigured with this prefix and whether the prefix can be used for
2864 onlink determination. Both settings default to
<literal>true
</literal>
2865 in order to ease configuration.
2870 <term><varname>Prefix=
</varname></term>
2872 <listitem><para>The IPv6 prefix that is to be distributed to hosts. Similarly to configuring static
2873 IPv6 addresses, the setting is configured as an IPv6 prefix and its prefix length, separated by a
2874 <literal>/
</literal> character. Use multiple [IPv6Prefix] sections to configure multiple IPv6
2875 prefixes since prefix lifetimes, address autoconfiguration and onlink status may differ from one
2876 prefix to another.
</para></listitem>
2880 <term><varname>PreferredLifetimeSec=
</varname></term>
2881 <term><varname>ValidLifetimeSec=
</varname></term>
2883 <listitem><para>Preferred and valid lifetimes for the prefix measured in seconds.
2884 <varname>PreferredLifetimeSec=
</varname> defaults to
1800 seconds (
30 minutes) and
2885 <varname>ValidLifetimeSec=
</varname> defaults to
3600 seconds (one hour).
</para></listitem>
2889 <term><varname>Assign=
</varname></term>
2890 <listitem><para>Takes a boolean. When true, adds an address from the prefix. Default to false.
2895 <term><varname>Token=
</varname></term>
2897 <para>Specifies an optional address generation mode for assigning an address in each
2898 prefix. This accepts the same syntax as
<varname>Token=
</varname> in the [IPv6AcceptRA]
2899 section. If
<varname>Assign=
</varname> is set to false, then this setting will be ignored.
2900 Defaults to unset, which means the EUI-
64 algorithm will be used.
</para>
2905 <term><varname>RouteMetric=
</varname></term>
2907 <para>The metric of the prefix route. Takes an unsigned integer in the range
0…
4294967295.
2908 When unset or set to
0, the kernel's default value is used. This setting is ignored when
2909 <varname>Assign=
</varname> is false.
</para>
2916 <title>[IPv6RoutePrefix] Section Options
</title>
2917 <para>One or more [IPv6RoutePrefix] sections contain the IPv6
2918 prefix routes that are announced via Router Advertisements. See
2919 <ulink url=
"https://tools.ietf.org/html/rfc4191">RFC
4191</ulink>
2920 for further details.
</para>
2922 <variablelist class='network-directives'
>
2925 <term><varname>Route=
</varname></term>
2927 <listitem><para>The IPv6 route that is to be distributed to hosts. Similarly to configuring static
2928 IPv6 routes, the setting is configured as an IPv6 prefix routes and its prefix route length,
2929 separated by a
<literal>/
</literal> character. Use multiple [IPv6PrefixRoutes] sections to configure
2930 multiple IPv6 prefix routes.
</para></listitem>
2934 <term><varname>LifetimeSec=
</varname></term>
2936 <listitem><para>Lifetime for the route prefix measured in seconds.
2937 <varname>LifetimeSec=
</varname> defaults to
3600 seconds (one hour).
</para></listitem>
2944 <title>[Bridge] Section Options
</title>
2945 <para>The [Bridge] section accepts the following keys:
</para>
2946 <variablelist class='network-directives'
>
2948 <term><varname>UnicastFlood=
</varname></term>
2950 <para>Takes a boolean. Controls whether the bridge should flood
2951 traffic for which an FDB entry is missing and the destination
2952 is unknown through this port. When unset, the kernel's default will be used.
2957 <term><varname>MulticastFlood=
</varname></term>
2959 <para>Takes a boolean. Controls whether the bridge should flood
2960 traffic for which an MDB entry is missing and the destination
2961 is unknown through this port. When unset, the kernel's default will be used.
2966 <term><varname>MulticastToUnicast=
</varname></term>
2968 <para>Takes a boolean. Multicast to unicast works on top of the multicast snooping feature of
2969 the bridge. Which means unicast copies are only delivered to hosts which are interested in it.
2970 When unset, the kernel's default will be used.
2975 <term><varname>NeighborSuppression=
</varname></term>
2977 <para>Takes a boolean. Configures whether ARP and ND neighbor suppression is enabled for
2978 this port. When unset, the kernel's default will be used.
2983 <term><varname>Learning=
</varname></term>
2985 <para>Takes a boolean. Configures whether MAC address learning is enabled for
2986 this port. When unset, the kernel's default will be used.
2991 <term><varname>HairPin=
</varname></term>
2993 <para>Takes a boolean. Configures whether traffic may be sent back out of the port on which it
2994 was received. When this flag is false, then the bridge will not forward traffic back out of the
2995 receiving port. When unset, the kernel's default will be used.
</para>
2999 <term><varname>Isolated=
</varname></term>
3001 <para>Takes a boolean. Configures whether this port is isolated or not. Within a bridge,
3002 isolated ports can only communicate with non-isolated ports. When set to true, this port can only
3003 communicate with other ports whose Isolated setting is false. When set to false, this port
3004 can communicate with any other ports. When unset, the kernel's default will be used.
</para>
3008 <term><varname>UseBPDU=
</varname></term>
3010 <para>Takes a boolean. Configures whether STP Bridge Protocol Data Units will be
3011 processed by the bridge port. When unset, the kernel's default will be used.
</para>
3015 <term><varname>FastLeave=
</varname></term>
3017 <para>Takes a boolean. This flag allows the bridge to immediately stop multicast
3018 traffic on a port that receives an IGMP Leave message. It is only used with
3019 IGMP snooping if enabled on the bridge. When unset, the kernel's default will be used.
</para>
3023 <term><varname>AllowPortToBeRoot=
</varname></term>
3025 <para>Takes a boolean. Configures whether a given port is allowed to
3026 become a root port. Only used when STP is enabled on the bridge.
3027 When unset, the kernel's default will be used.
</para>
3031 <term><varname>ProxyARP=
</varname></term>
3033 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port.
3034 When unset, the kernel's default will be used.
</para>
3038 <term><varname>ProxyARPWiFi=
</varname></term>
3040 <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port
3041 which meets extended requirements by IEEE
802.11 and Hotspot
2.0 specifications.
3042 When unset, the kernel's default will be used.
</para>
3046 <term><varname>MulticastRouter=
</varname></term>
3048 <para>Configures this port for having multicast routers attached. A port with a multicast
3049 router will receive all multicast traffic. Takes one of
<literal>no
</literal>
3050 to disable multicast routers on this port,
<literal>query
</literal> to let the system detect
3051 the presence of routers,
<literal>permanent
</literal> to permanently enable multicast traffic
3052 forwarding on this port, or
<literal>temporary
</literal> to enable multicast routers temporarily
3053 on this port, not depending on incoming queries. When unset, the kernel's default will be used.
</para>
3057 <term><varname>Cost=
</varname></term>
3059 <para>Sets the
"cost" of sending packets of this interface.
3060 Each port in a bridge may have a different speed and the cost
3061 is used to decide which link to use. Faster interfaces
3062 should have lower costs. It is an integer value between
1 and
3067 <term><varname>Priority=
</varname></term>
3069 <para>Sets the
"priority" of sending packets on this interface.
3070 Each port in a bridge may have a different priority which is used
3071 to decide which link to use. Lower value means higher priority.
3072 It is an integer value between
0 to
63. Networkd does not set any
3073 default, meaning the kernel default value of
32 is used.
</para>
3079 <title>[BridgeFDB] Section Options
</title>
3080 <para>The [BridgeFDB] section manages the forwarding database table of a port and accepts the following
3081 keys. Specify several [BridgeFDB] sections to configure several static MAC table entries.
</para>
3083 <variablelist class='network-directives'
>
3085 <term><varname>MACAddress=
</varname></term>
3087 <para>As in the [Network] section. This key is mandatory.
</para>
3091 <term><varname>Destination=
</varname></term>
3093 <para>Takes an IP address of the destination VXLAN tunnel endpoint.
</para>
3097 <term><varname>VLANId=
</varname></term>
3099 <para>The VLAN ID for the new static MAC table entry. If
3100 omitted, no VLAN ID information is appended to the new static MAC
3105 <term><varname>VNI=
</varname></term>
3107 <para>The VXLAN Network Identifier (or VXLAN Segment ID) to use to connect to
3108 the remote VXLAN tunnel endpoint. Takes a number in the range
1…
16777215.
3109 Defaults to unset.
</para>
3113 <term><varname>AssociatedWith=
</varname></term>
3115 <para>Specifies where the address is associated with. Takes one of
<literal>use
</literal>,
3116 <literal>self
</literal>,
<literal>master
</literal> or
<literal>router
</literal>.
3117 <literal>use
</literal> means the address is in use. User space can use this option to
3118 indicate to the kernel that the fdb entry is in use.
<literal>self
</literal> means
3119 the address is associated with the port drivers fdb. Usually hardware.
<literal>master
</literal>
3120 means the address is associated with master devices fdb.
<literal>router
</literal> means
3121 the destination address is associated with a router. Note that it's valid if the referenced
3122 device is a VXLAN type device and has route shortcircuit enabled. Defaults to
<literal>self
</literal>.
</para>
3126 <term><varname>OutgoingInterface=
</varname></term>
3128 <para>Specifies the name or index of the outgoing interface for the VXLAN device driver to
3129 reach the remote VXLAN tunnel endpoint. Defaults to unset.
</para>
3135 <title>[BridgeMDB] Section Options
</title>
3136 <para>The [BridgeMDB] section manages the multicast membership entries forwarding database table of a port and accepts the following
3137 keys. Specify several [BridgeMDB] sections to configure several permanent multicast membership entries.
</para>
3139 <variablelist class='network-directives'
>
3141 <term><varname>MulticastGroupAddress=
</varname></term>
3143 <para>Specifies the IPv4 or IPv6 multicast group address to add. This setting is mandatory.
</para>
3147 <term><varname>VLANId=
</varname></term>
3149 <para>The VLAN ID for the new entry. Valid ranges are
0 (no VLAN) to
4094. Optional, defaults to
0.
</para>
3156 <title>[LLDP] Section Options
</title>
3157 <para>The [LLDP] section manages the Link Layer Discovery Protocol (LLDP) and accepts the following
3159 <variablelist class='network-directives'
>
3161 <term><varname>MUDURL=
</varname></term>
3163 <para>When configured, the specified Manufacturer Usage Descriptions (MUD) URL will be sent in
3164 LLDP packets. The syntax and semantics are the same as for
<varname>MUDURL=
</varname> in the
3165 [DHCPv4] section described above.
</para>
3167 <para>The MUD URLs received via LLDP packets are saved and can be read using the
3168 <function>sd_lldp_neighbor_get_mud_url()
</function> function.
</para>
3175 <title>[CAN] Section Options
</title>
3176 <para>The [CAN] section manages the Controller Area Network (CAN bus) and accepts the
3177 following keys:
</para>
3178 <variablelist class='network-directives'
>
3180 <term><varname>BitRate=
</varname></term>
3182 <para>The bitrate of CAN device in bits per second. The usual SI prefixes (K, M) with the base of
1000 can
3183 be used here. Takes a number in the range
1…
4294967295.
</para>
3187 <term><varname>SamplePoint=
</varname></term>
3189 <para>Optional sample point in percent with one decimal (e.g.
<literal>75%
</literal>,
3190 <literal>87.5%
</literal>) or permille (e.g.
<literal>875‰
</literal>). This will be ignored when
3191 <varname>BitRate=
</varname> is unspecified.
</para>
3195 <term><varname>TimeQuantaNSec=
</varname></term>
3196 <term><varname>PropagationSegment=
</varname></term>
3197 <term><varname>PhaseBufferSegment1=
</varname></term>
3198 <term><varname>PhaseBufferSegment2=
</varname></term>
3199 <term><varname>SyncJumpWidth=
</varname></term>
3201 <para>Specifies the time quanta, propagation segment, phase buffer segment
1 and
2, and the
3202 synchronization jump width, which allow one to define the CAN bit-timing in a hardware
3203 independent format as proposed by the Bosch CAN
2.0 Specification.
3204 <varname>TimeQuantaNSec=
</varname> takes a timespan in nanoseconds.
3205 <varname>PropagationSegment=
</varname>,
<varname>PhaseBufferSegment1=
</varname>,
3206 <varname>PhaseBufferSegment2=
</varname>, and
<varname>SyncJumpWidth=
</varname> take number
3207 of time quantum specified in
<varname>TimeQuantaNSec=
</varname> and must be an unsigned
3208 integer in the range
0…
4294967295. These settings except for
3209 <varname>SyncJumpWidth=
</varname> will be ignored when
<varname>BitRate=
</varname> is
3214 <term><varname>DataBitRate=
</varname></term>
3215 <term><varname>DataSamplePoint=
</varname></term>
3217 <para>The bitrate and sample point for the data phase, if CAN-FD is used. These settings are
3218 analogous to the
<varname>BitRate=
</varname> and
<varname>SamplePoint=
</varname> keys.
</para>
3222 <term><varname>DataTimeQuantaNSec=
</varname></term>
3223 <term><varname>DataPropagationSegment=
</varname></term>
3224 <term><varname>DataPhaseBufferSegment1=
</varname></term>
3225 <term><varname>DataPhaseBufferSegment2=
</varname></term>
3226 <term><varname>DataSyncJumpWidth=
</varname></term>
3228 <para>Specifies the time quanta, propagation segment, phase buffer segment
1 and
2, and the
3229 synchronization jump width for the data phase, if CAN-FD is used. These settings are
3230 analogous to the
<varname>TimeQuantaNSec=
</varname> or related settings.
</para>
3234 <term><varname>FDMode=
</varname></term>
3236 <para>Takes a boolean. When
<literal>yes
</literal>, CAN-FD mode is enabled for the interface.
3237 Note, that a bitrate and optional sample point should also be set for the CAN-FD data phase using
3238 the
<varname>DataBitRate=
</varname> and
<varname>DataSamplePoint=
</varname> keys, or
3239 <varname>DataTimeQuanta=
</varname> and related settings.
</para>
3243 <term><varname>FDNonISO=
</varname></term>
3245 <para>Takes a boolean. When
<literal>yes
</literal>, non-ISO CAN-FD mode is enabled for the
3246 interface. When unset, the kernel's default will be used.
</para>
3250 <term><varname>RestartSec=
</varname></term>
3252 <para>Automatic restart delay time. If set to a non-zero value, a restart of the CAN controller will be
3253 triggered automatically in case of a bus-off condition after the specified delay time. Subsecond delays can
3254 be specified using decimals (e.g.
<literal>0.1s
</literal>) or a
<literal>ms
</literal> or
3255 <literal>us
</literal> postfix. Using
<literal>infinity
</literal> or
<literal>0</literal> will turn the
3256 automatic restart off. By default automatic restart is disabled.
</para>
3260 <term><varname>Termination=
</varname></term>
3262 <para>Takes a boolean or a termination resistor value in ohm in the range
0…
65535. When
3263 <literal>yes
</literal>, the termination resistor is set to
120 ohm. When
3264 <literal>no
</literal> or
<literal>0</literal> is set, the termination resistor is disabled.
3265 When unset, the kernel's default will be used.
</para>
3269 <term><varname>TripleSampling=
</varname></term>
3271 <para>Takes a boolean. When
<literal>yes
</literal>, three samples (instead of one) are used to determine
3272 the value of a received bit by majority rule. When unset, the kernel's default will be used.
</para>
3276 <term><varname>BusErrorReporting=
</varname></term>
3278 <para>Takes a boolean. When
<literal>yes
</literal>, reporting of CAN bus errors is activated
3279 (those include single bit, frame format, and bit stuffing errors, unable to send dominant bit,
3280 unable to send recessive bit, bus overload, active error announcement, error occurred on
3281 transmission). When unset, the kernel's default will be used. Note: in case of a CAN bus with a
3282 single CAN device, sending a CAN frame may result in a huge number of CAN bus errors.
</para>
3286 <term><varname>ListenOnly=
</varname></term>
3288 <para>Takes a boolean. When
<literal>yes
</literal>, listen-only mode is enabled. When the
3289 interface is in listen-only mode, the interface neither transmit CAN frames nor send ACK
3290 bit. Listen-only mode is important to debug CAN networks without interfering with the
3291 communication or acknowledge the CAN frame. When unset, the kernel's default will be used.
3296 <term><varname>Loopback=
</varname></term>
3298 <para>Takes a boolean. When
<literal>yes
</literal>, loopback mode is enabled. When the
3299 loopback mode is enabled, the interface treats messages transmitted by itself as received
3300 messages. The loopback mode is important to debug CAN networks. When unset, the kernel's
3301 default will be used.
</para>
3305 <term><varname>OneShot=
</varname></term>
3307 <para>Takes a boolean. When
<literal>yes
</literal>, one-shot mode is enabled. When unset,
3308 the kernel's default will be used.
</para>
3312 <term><varname>PresumeAck=
</varname></term>
3314 <para>Takes a boolean. When
<literal>yes
</literal>, the interface will ignore missing CAN
3315 ACKs. When unset, the kernel's default will be used.
</para>
3319 <term><varname>ClassicDataLengthCode=
</varname></term>
3321 <para>Takes a boolean. When
<literal>yes
</literal>, the interface will handle the
4bit data
3322 length code (DLC). When unset, the kernel's default will be used.
</para>
3329 <title>[IPoIB] Section Options
</title>
3330 <para>The [IPoIB] section manages the IP over Infiniband and accepts the following keys:
</para>
3331 <variablelist class='network-directives'
>
3332 <xi:include href=
"systemd.netdev.xml" xpointer=
"ipoib_mode" />
3333 <xi:include href=
"systemd.netdev.xml" xpointer=
"ipoib_umcast" />
3338 <title>[QDisc] Section Options
</title>
3339 <para>The [QDisc] section manages the traffic control queueing discipline (qdisc).
</para>
3341 <variablelist class='network-directives'
>
3343 <term><varname>Parent=
</varname></term>
3345 <para>Specifies the parent Queueing Discipline (qdisc). Takes one of
<literal>clsact
</literal>
3346 or
<literal>ingress
</literal>. This is mandatory.
</para>
3350 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3355 <title>[NetworkEmulator] Section Options
</title>
3356 <para>The [NetworkEmulator] section manages the queueing discipline (qdisc) of the network emulator. It
3357 can be used to configure the kernel packet scheduler and simulate packet delay and loss for UDP or TCP
3358 applications, or limit the bandwidth usage of a particular service to simulate internet connections.
3361 <variablelist class='network-directives'
>
3362 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3363 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3366 <term><varname>DelaySec=
</varname></term>
3368 <para>Specifies the fixed amount of delay to be added to all packets going out of the
3369 interface. Defaults to unset.
</para>
3374 <term><varname>DelayJitterSec=
</varname></term>
3376 <para>Specifies the chosen delay to be added to the packets outgoing to the network
3377 interface. Defaults to unset.
</para>
3382 <term><varname>PacketLimit=
</varname></term>
3384 <para>Specifies the maximum number of packets the qdisc may hold queued at a time.
3385 An unsigned integer in the range
0…
4294967294. Defaults to
1000.
</para>
3390 <term><varname>LossRate=
</varname></term>
3392 <para>Specifies an independent loss probability to be added to the packets outgoing from the
3393 network interface. Takes a percentage value, suffixed with
"%". Defaults to unset.
</para>
3398 <term><varname>DuplicateRate=
</varname></term>
3400 <para>Specifies that the chosen percent of packets is duplicated before queuing them.
3401 Takes a percentage value, suffixed with
"%". Defaults to unset.
</para>
3408 <title>[TokenBucketFilter] Section Options
</title>
3409 <para>The [TokenBucketFilter] section manages the queueing discipline (qdisc) of token bucket filter
3412 <variablelist class='network-directives'
>
3413 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3414 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3417 <term><varname>LatencySec=
</varname></term>
3419 <para>Specifies the latency parameter, which specifies the maximum amount of time a
3420 packet can sit in the Token Bucket Filter (TBF). Defaults to unset.
</para>
3425 <term><varname>LimitBytes=
</varname></term>
3427 <para>Takes the number of bytes that can be queued waiting for tokens to become available.
3428 When the size is suffixed with K, M, or G, it is parsed as Kilobytes, Megabytes, or Gigabytes,
3429 respectively, to the base of
1024. Defaults to unset.
</para>
3434 <term><varname>BurstBytes=
</varname></term>
3436 <para>Specifies the size of the bucket. This is the maximum amount of bytes that tokens
3437 can be available for instantaneous transfer. When the size is suffixed with K, M, or G, it is
3438 parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to
3444 <term><varname>Rate=
</varname></term>
3446 <para>Specifies the device specific bandwidth. When suffixed with K, M, or G, the specified
3447 bandwidth is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of
1000.
3448 Defaults to unset.
</para>
3453 <term><varname>MPUBytes=
</varname></term>
3455 <para>The Minimum Packet Unit (MPU) determines the minimal token usage (specified in bytes)
3456 for a packet. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
3457 Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to zero.
</para>
3462 <term><varname>PeakRate=
</varname></term>
3464 <para>Takes the maximum depletion rate of the bucket. When suffixed with K, M, or G, the
3465 specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of
3466 1000. Defaults to unset.
</para>
3471 <term><varname>MTUBytes=
</varname></term>
3473 <para>Specifies the size of the peakrate bucket. When suffixed with K, M, or G, the specified
3474 size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
1024.
3475 Defaults to unset.
</para>
3482 <title>[PIE] Section Options
</title>
3483 <para>The [PIE] section manages the queueing discipline (qdisc) of Proportional Integral
3484 controller-Enhanced (PIE).
</para>
3486 <variablelist class='network-directives'
>
3487 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3488 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3491 <term><varname>PacketLimit=
</varname></term>
3493 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached,
3494 incoming packets are dropped. An unsigned integer in the range
1…
4294967294. Defaults to unset and
3495 kernel's default is used.
</para>
3502 <title>[FlowQueuePIE] Section Options
</title>
3503 <para>The
<literal>[FlowQueuePIE]
</literal> section manages the queueing discipline
3504 (qdisc) of Flow Queue Proportional Integral controller-Enhanced (fq_pie).
</para>
3506 <variablelist class='network-directives'
>
3507 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3508 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3511 <term><varname>PacketLimit=
</varname></term>
3513 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached,
3514 incoming packets are dropped. An unsigned integer ranges
1 to
4294967294. Defaults to unset and
3515 kernel's default is used.
</para>
3522 <title>[StochasticFairBlue] Section Options
</title>
3523 <para>The [StochasticFairBlue] section manages the queueing discipline (qdisc) of stochastic fair blue
3526 <variablelist class='network-directives'
>
3527 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3528 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3531 <term><varname>PacketLimit=
</varname></term>
3533 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached,
3534 incoming packets are dropped. An unsigned integer in the range
0…
4294967294. Defaults to unset and
3535 kernel's default is used.
</para>
3542 <title>[StochasticFairnessQueueing] Section Options
</title>
3543 <para>The [StochasticFairnessQueueing] section manages the queueing discipline (qdisc) of stochastic
3544 fairness queueing (sfq).
</para>
3546 <variablelist class='network-directives'
>
3547 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3548 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3551 <term><varname>PerturbPeriodSec=
</varname></term>
3553 <para>Specifies the interval in seconds for queue algorithm perturbation. Defaults to unset.
</para>
3560 <title>[BFIFO] Section Options
</title>
3561 <para>The [BFIFO] section manages the queueing discipline (qdisc) of Byte limited Packet First In First
3564 <variablelist class='network-directives'
>
3565 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3566 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3569 <term><varname>LimitBytes=
</varname></term>
3571 <para>Specifies the hard limit in bytes on the FIFO buffer size. The size limit prevents overflow
3572 in case the kernel is unable to dequeue packets as quickly as it receives them. When this limit is
3573 reached, incoming packets are dropped. When suffixed with K, M, or G, the specified size is parsed
3574 as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to unset and
3575 kernel default is used.
</para>
3582 <title>[PFIFO] Section Options
</title>
3583 <para>The [PFIFO] section manages the queueing discipline (qdisc) of Packet First In First Out
3586 <variablelist class='network-directives'
>
3587 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3588 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3591 <term><varname>PacketLimit=
</varname></term>
3593 <para>Specifies the hard limit on the number of packets in the FIFO queue. The size limit prevents
3594 overflow in case the kernel is unable to dequeue packets as quickly as it receives them. When this
3595 limit is reached, incoming packets are dropped. An unsigned integer in the range
3596 0…
4294967294. Defaults to unset and kernel's default is used.
</para>
3603 <title>[PFIFOHeadDrop] Section Options
</title>
3604 <para>The [PFIFOHeadDrop] section manages the queueing discipline (qdisc) of Packet First In First Out
3605 Head Drop (pfifo_head_drop).
</para>
3607 <variablelist class='network-directives'
>
3608 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3609 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3612 <term><varname>PacketLimit=
</varname></term>
3614 <para>As in [PFIFO] section.
</para></listitem>
3620 <title>[PFIFOFast] Section Options
</title>
3621 <para>The [PFIFOFast] section manages the queueing discipline (qdisc) of Packet First In First Out Fast
3622 (pfifo_fast).
</para>
3624 <variablelist class='network-directives'
>
3625 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3626 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3631 <title>[CAKE] Section Options
</title>
3632 <para>The [CAKE] section manages the queueing discipline (qdisc) of Common Applications Kept Enhanced
3635 <variablelist class='network-directives'
>
3636 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3637 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3640 <term><varname>Bandwidth=
</varname></term>
3642 <para>Specifies the shaper bandwidth. When suffixed with K, M, or G, the specified size is
3643 parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of
1000. Defaults to
3644 unset and kernel's default is used.
</para>
3649 <term><varname>AutoRateIngress=
</varname></term>
3651 <para>Takes a boolean value. Enables automatic capacity estimation based on traffic arriving
3652 at this qdisc. This is most likely to be useful with cellular links, which tend to change
3653 quality randomly. If this setting is enabled, the
<varname>Bandwidth=
</varname> setting is
3654 used as an initial estimate. Defaults to unset, and the kernel's default is used.
</para>
3659 <term><varname>OverheadBytes=
</varname></term>
3661 <para>Specifies that bytes to be addeded to the size of each packet. Bytes may be negative.
3662 Takes an integer in the range -
64…
256. Defaults to unset and kernel's default is used.
3668 <term><varname>MPUBytes=
</varname></term>
3670 <para>Rounds each packet (including overhead) up to the specified bytes. Takes an integer in
3671 the range
1…
256. Defaults to unset and kernel's default is used.
</para>
3676 <term><varname>CompensationMode=
</varname></term>
3678 <para>Takes one of
<literal>none
</literal>,
<literal>atm
</literal>, or
<literal>ptm
</literal>.
3679 Specifies the compensation mode for overhead calculation. When
<literal>none
</literal>, no
3680 compensation is taken into account. When
<literal>atm
</literal>, enables the compensation for
3681 ATM cell framing, which is normally found on ADSL links. When
<literal>ptm
</literal>, enables
3682 the compensation for PTM encoding, which is normally found on VDSL2 links and uses a
64b/
65b
3683 encoding scheme. Defaults to unset and the kernel's default is used.
</para>
3688 <term><varname>UseRawPacketSize=
</varname></term>
3690 <para>Takes a boolean value. When true, the packet size reported by the Linux kernel will be
3691 used, instead of the underlying IP packet size. Defaults to unset, and the kernel's default
3697 <term><varname>FlowIsolationMode=
</varname></term>
3699 <para>CAKE places packets from different flows into different queues, then packets from each
3700 queue are delivered fairly. This specifies whether the fairness is based on source address,
3701 destination address, individual flows, or any combination of those. The available values are:
3706 <term><option>none
</option></term>
3708 The flow isolation is disabled, and all traffic passes through a single queue.
3712 <term><option>src-host
</option></term>
3714 Flows are defined only by source address. Equivalent to the
<literal>srchost
</literal>
3715 option for
<command>tc qdisc
</command> command. See also
3716 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3720 <term><option>dst-host
</option></term>
3722 Flows are defined only by destination address. Equivalent to the
3723 <literal>dsthost
</literal> option for
<command>tc qdisc
</command> command. See also
3724 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3728 <term><option>hosts
</option></term>
3730 Flows are defined by source-destination host pairs. Equivalent to the same option for
3731 <command>tc qdisc
</command> command. See also
3732 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3736 <term><option>flows
</option></term>
3738 Flows are defined by the entire
5-tuple of source address, destination address,
3739 transport protocol, source port and destination port. Equivalent to the same option for
3740 <command>tc qdisc
</command> command. See also
3741 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3745 <term><option>dual-src-host
</option></term>
3747 Flows are defined by the
5-tuple (see
<literal>flows
</literal> in the above), and
3748 fairness is applied first over source addresses, then over individual flows. Equivalent
3749 to the
<literal>dual-srchost
</literal> option for
<command>tc qdisc
</command> command.
3751 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3755 <term><option>dual-dst-host
</option></term>
3757 Flows are defined by the
5-tuple (see
<literal>flows
</literal> in the above), and
3758 fairness is applied first over destination addresses, then over individual flows.
3759 Equivalent to the
<literal>dual-dsthost
</literal> option for
3760 <command>tc qdisc
</command> command. See also
3761 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3765 <term><option>triple
</option></term>
3767 Flows are defined by the
5-tuple (see
<literal>flows
</literal>), and fairness is
3768 applied over source and destination addresses, and also over individual flows.
3769 Equivalent to the
<literal>triple-isolate
</literal> option for
3770 <command>tc qdisc
</command> command. See also
3771 <citerefentry project='man-pages'
><refentrytitle>tc-cake
</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
3776 <para>Defaults to unset and the kernel's default is used.
</para>
3781 <term><varname>NAT=
</varname></term>
3783 <para>Takes a boolean value. When true, CAKE performs a NAT lookup before applying
3784 flow-isolation rules, to determine the true addresses and port numbers of the packet, to
3785 improve fairness between hosts inside the NAT. This has no practical effect when
3786 <varname>FlowIsolationMode=
</varname> is
<literal>none
</literal> or
<literal>flows
</literal>,
3787 or if NAT is performed on a different host. Defaults to unset, and the kernel's default is
3793 <term><varname>PriorityQueueingPreset=
</varname></term>
3795 <para>CAKE divides traffic into
<literal>tins
</literal>, and each tin has its own independent
3796 set of flow-isolation queues, bandwidth threshold, and priority. This specifies the preset of
3797 tin profiles. The available values are:
</para>
3801 <term><option>besteffort
</option></term>
3803 Disables priority queueing by placing all traffic in one tin.
3807 <term><option>precedence
</option></term>
3809 Enables priority queueing based on the legacy interpretation of TOS
3810 <literal>Precedence
</literal> field. Use of this preset on the modern Internet is
3815 <term><option>diffserv8
</option></term>
3817 Enables priority queueing based on the Differentiated Service
3818 (
<literal>DiffServ
</literal>) field with eight tins: Background Traffic, High
3819 Throughput, Best Effort, Video Streaming, Low Latency Transactions, Interactive Shell,
3820 Minimum Latency, and Network Control.
3824 <term><option>diffserv4
</option></term>
3826 Enables priority queueing based on the Differentiated Service
3827 (
<literal>DiffServ
</literal>) field with four tins: Background Traffic, Best Effort,
3828 Streaming Media, and Latency Sensitive.
3832 <term><option>diffserv3
</option></term>
3834 Enables priority queueing based on the Differentiated Service
3835 (
<literal>DiffServ
</literal>) field with three tins: Background Traffic, Best Effort,
3836 and Latency Sensitive.
3841 <para>Defaults to unset, and the kernel's default is used.
</para>
3846 <term><varname>FirewallMark=
</varname></term>
3848 <para>Takes an integer in the range
1…
4294967295. When specified, firewall-mark-based
3849 overriding of CAKE's tin selection is enabled. Defaults to unset, and the kernel's default is
3855 <term><varname>Wash=
</varname></term>
3857 <para>Takes a boolean value. When true, CAKE clears the DSCP fields, except for ECN bits, of
3858 any packet passing through CAKE. Defaults to unset, and the kernel's default is used.
</para>
3863 <term><varname>SplitGSO=
</varname></term>
3865 <para>Takes a boolean value. When true, CAKE will split General Segmentation Offload (GSO)
3866 super-packets into their on-the-wire components and dequeue them individually. Defaults to
3867 unset, and the kernel's default is used.
</para>
3875 <title>[ControlledDelay] Section Options
</title>
3876 <para>The [ControlledDelay] section manages the queueing discipline (qdisc) of
3877 controlled delay (CoDel).
</para>
3879 <variablelist class='network-directives'
>
3880 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3881 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3884 <term><varname>PacketLimit=
</varname></term>
3886 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached,
3887 incoming packets are dropped. An unsigned integer in the range
0…
4294967294. Defaults to unset and
3888 kernel's default is used.
</para>
3893 <term><varname>TargetSec=
</varname></term>
3895 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay.
3896 Defaults to unset and kernel's default is used.
</para>
3901 <term><varname>IntervalSec=
</varname></term>
3903 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not
3904 become too stale. Defaults to unset and kernel's default is used.
</para>
3909 <term><varname>ECN=
</varname></term>
3911 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to
3912 unset and kernel's default is used.
</para>
3917 <term><varname>CEThresholdSec=
</varname></term>
3919 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
3920 Congestion Experienced (CE). Defaults to unset and kernel's default is used.
</para>
3927 <title>[DeficitRoundRobinScheduler] Section Options
</title>
3928 <para>The [DeficitRoundRobinScheduler] section manages the queueing discipline (qdisc) of Deficit Round
3929 Robin Scheduler (DRR).
</para>
3931 <variablelist class='network-directives'
>
3932 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3933 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3938 <title>[DeficitRoundRobinSchedulerClass] Section Options
</title>
3939 <para>The [DeficitRoundRobinSchedulerClass] section manages the traffic control class of Deficit Round
3940 Robin Scheduler (DRR).
</para>
3942 <variablelist class='network-directives'
>
3943 <xi:include href=
"tc.xml" xpointer=
"tclass-parent" />
3944 <xi:include href=
"tc.xml" xpointer=
"tclass-classid" />
3947 <term><varname>QuantumBytes=
</varname></term>
3949 <para>Specifies the amount of bytes a flow is allowed to dequeue before the scheduler moves
3950 to the next class. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
3951 Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to the MTU of the
3960 <title>[EnhancedTransmissionSelection] Section Options
</title>
3961 <para>The [EnhancedTransmissionSelection] section manages the queueing discipline (qdisc) of Enhanced
3962 Transmission Selection (ETS).
</para>
3964 <variablelist class='network-directives'
>
3965 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
3966 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
3969 <term><varname>Bands=
</varname></term>
3971 <para>Specifies the number of bands. An unsigned integer in the range
1…
16. This value has to be at
3972 least large enough to cover the strict bands specified through the
<varname>StrictBands=
</varname>
3973 and bandwidth-sharing bands specified in
<varname>QuantumBytes=
</varname>.
</para>
3978 <term><varname>StrictBands=
</varname></term>
3980 <para>Specifies the number of bands that should be created in strict mode. An unsigned integer in
3981 the range
1…
16.
</para>
3986 <term><varname>QuantumBytes=
</varname></term>
3988 <para>Specifies the white-space separated list of quantum used in band-sharing bands. When
3989 suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
3990 respectively, to the base of
1024. This setting can be specified multiple times. If an empty
3991 string is assigned, then the all previous assignments are cleared.
</para>
3996 <term><varname>PriorityMap=
</varname></term>
3998 <para>The priority map maps the priority of a packet to a band. The argument is a whitespace
3999 separated list of numbers. The first number indicates which band the packets with priority
0 should
4000 be put to, the second is for priority
1, and so on. There can be up to
16 numbers in the list. If
4001 there are fewer, the default band that traffic with one of the unmentioned priorities goes to is
4002 the last one. Each band number must be in the range
0…
255. This setting can be specified multiple
4003 times. If an empty string is assigned, then the all previous assignments are cleared.
</para>
4010 <title>[GenericRandomEarlyDetection] Section Options
</title>
4011 <para>The [GenericRandomEarlyDetection] section manages the queueing discipline (qdisc) of Generic Random
4012 Early Detection (GRED).
</para>
4014 <variablelist class='network-directives'
>
4015 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4016 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4019 <term><varname>VirtualQueues=
</varname></term>
4021 <para>Specifies the number of virtual queues. Takes an integer in the range
1…
16. Defaults to unset
4022 and kernel's default is used.
</para>
4027 <term><varname>DefaultVirtualQueue=
</varname></term>
4029 <para>Specifies the number of default virtual queue. This must be less than
<varname>VirtualQueue=
</varname>.
4030 Defaults to unset and kernel's default is used.
</para>
4035 <term><varname>GenericRIO=
</varname></term>
4037 <para>Takes a boolean. It turns on the RIO-like buffering scheme. Defaults to
4038 unset and kernel's default is used.
</para>
4045 <title>[FairQueueingControlledDelay] Section Options
</title>
4046 <para>The [FairQueueingControlledDelay] section manages the queueing discipline (qdisc) of fair queuing
4047 controlled delay (FQ-CoDel).
</para>
4049 <variablelist class='network-directives'
>
4050 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4051 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4054 <term><varname>PacketLimit=
</varname></term>
4056 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are
4057 dropped. Defaults to unset and kernel's default is used.
</para>
4062 <term><varname>MemoryLimitBytes=
</varname></term>
4064 <para>Specifies the limit on the total number of bytes that can be queued in this FQ-CoDel instance.
4065 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
4066 respectively, to the base of
1024. Defaults to unset and kernel's default is used.
</para>
4071 <term><varname>Flows=
</varname></term>
4073 <para>Specifies the number of flows into which the incoming packets are classified.
4074 Defaults to unset and kernel's default is used.
</para>
4079 <term><varname>TargetSec=
</varname></term>
4081 <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay.
4082 Defaults to unset and kernel's default is used.
</para>
4087 <term><varname>IntervalSec=
</varname></term>
4089 <para>Takes a timespan. This is used to ensure that the measured minimum delay does not
4090 become too stale. Defaults to unset and kernel's default is used.
</para>
4095 <term><varname>QuantumBytes=
</varname></term>
4097 <para>Specifies the number of bytes used as the
"deficit" in the fair queuing algorithm timespan.
4098 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
4099 respectively, to the base of
1024. Defaults to unset and kernel's default is used.
</para>
4104 <term><varname>ECN=
</varname></term>
4106 <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to
4107 unset and kernel's default is used.
</para>
4112 <term><varname>CEThresholdSec=
</varname></term>
4114 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
4115 Congestion Experienced (CE). Defaults to unset and kernel's default is used.
</para>
4122 <title>[FairQueueing] Section Options
</title>
4123 <para>The [FairQueueing] section manages the queueing discipline (qdisc) of fair queue traffic policing
4126 <variablelist class='network-directives'
>
4127 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4128 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4131 <term><varname>PacketLimit=
</varname></term>
4133 <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are
4134 dropped. Defaults to unset and kernel's default is used.
</para>
4139 <term><varname>FlowLimit=
</varname></term>
4141 <para>Specifies the hard limit on the maximum number of packets queued per flow. Defaults to
4142 unset and kernel's default is used.
</para>
4147 <term><varname>QuantumBytes=
</varname></term>
4149 <para>Specifies the credit per dequeue RR round, i.e. the amount of bytes a flow is allowed
4150 to dequeue at once. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
4151 Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to unset and kernel's
4152 default is used.
</para>
4157 <term><varname>InitialQuantumBytes=
</varname></term>
4159 <para>Specifies the initial sending rate credit, i.e. the amount of bytes a new flow is
4160 allowed to dequeue initially. When suffixed with K, M, or G, the specified size is parsed as
4161 Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
1024. Defaults to unset and
4162 kernel's default is used.
</para>
4167 <term><varname>MaximumRate=
</varname></term>
4169 <para>Specifies the maximum sending rate of a flow. When suffixed with K, M, or G, the
4170 specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of
4171 1000. Defaults to unset and kernel's default is used.
</para>
4176 <term><varname>Buckets=
</varname></term>
4178 <para>Specifies the size of the hash table used for flow lookups. Defaults to unset and
4179 kernel's default is used.
</para>
4184 <term><varname>OrphanMask=
</varname></term>
4186 <para>Takes an unsigned integer. For packets not owned by a socket, fq is able to mask a part
4187 of hash and reduce number of buckets associated with the traffic. Defaults to unset and
4188 kernel's default is used.
</para>
4193 <term><varname>Pacing=
</varname></term>
4195 <para>Takes a boolean, and enables or disables flow pacing. Defaults to unset and kernel's
4196 default is used.
</para>
4201 <term><varname>CEThresholdSec=
</varname></term>
4203 <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN
4204 Congestion Experienced (CE). Defaults to unset and kernel's default is used.
</para>
4211 <title>[TrivialLinkEqualizer] Section Options
</title>
4212 <para>The [TrivialLinkEqualizer] section manages the queueing discipline (qdisc) of trivial link
4213 equalizer (teql).
</para>
4215 <variablelist class='network-directives'
>
4216 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4217 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4220 <term><varname>Id=
</varname></term>
4222 <para>Specifies the interface ID
<literal>N
</literal> of teql. Defaults to
<literal>0</literal>.
4223 Note that when teql is used, currently, the module
<constant>sch_teql
</constant> with
4224 <constant>max_equalizers=N+
1</constant> option must be loaded before
4225 <command>systemd-networkd
</command> is started.
</para>
4232 <title>[HierarchyTokenBucket] Section Options
</title>
4233 <para>The [HierarchyTokenBucket] section manages the queueing discipline (qdisc) of hierarchy token
4234 bucket (htb).
</para>
4236 <variablelist class='network-directives'
>
4237 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4238 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4241 <term><varname>DefaultClass=
</varname></term>
4243 <para>Takes the minor id in hexadecimal of the default class. Unclassified traffic gets sent
4244 to the class. Defaults to unset.
</para>
4249 <term><varname>RateToQuantum=
</varname></term>
4251 <para>Takes an unsigned integer. The DRR quantums are calculated by dividing the value
4252 configured in
<varname>Rate=
</varname> by
<varname>RateToQuantum=
</varname>.
</para>
4259 <title>[HierarchyTokenBucketClass] Section Options
</title>
4260 <para>The [HierarchyTokenBucketClass] section manages the traffic control class of hierarchy token bucket
4263 <variablelist class='network-directives'
>
4264 <xi:include href=
"tc.xml" xpointer=
"tclass-parent" />
4265 <xi:include href=
"tc.xml" xpointer=
"tclass-classid" />
4268 <term><varname>Priority=
</varname></term>
4270 <para>Specifies the priority of the class. In the round-robin process, classes with the lowest
4271 priority field are tried for packets first.
</para>
4276 <term><varname>QuantumBytes=
</varname></term>
4278 <para>Specifies how many bytes to serve from leaf at once. When suffixed with K, M, or G, the
4279 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
4285 <term><varname>MTUBytes=
</varname></term>
4287 <para>Specifies the maximum packet size we create. When suffixed with K, M, or G, the specified
4288 size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
1024.
</para>
4293 <term><varname>OverheadBytes=
</varname></term>
4295 <para>Takes an unsigned integer which specifies per-packet size overhead used in rate
4296 computations. When suffixed with K, M, or G, the specified size is parsed as Kilobytes,
4297 Megabytes, or Gigabytes, respectively, to the base of
1024.
</para>
4302 <term><varname>Rate=
</varname></term>
4304 <para>Specifies the maximum rate this class and all its children are guaranteed. When suffixed
4305 with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits, respectively,
4306 to the base of
1000. This setting is mandatory.
</para>
4311 <term><varname>CeilRate=
</varname></term>
4313 <para>Specifies the maximum rate at which a class can send, if its parent has bandwidth to spare.
4314 When suffixed with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits,
4315 respectively, to the base of
1000. When unset, the value specified with
<varname>Rate=
</varname>
4321 <term><varname>BufferBytes=
</varname></term>
4323 <para>Specifies the maximum bytes burst which can be accumulated during idle period. When suffixed
4324 with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively,
4325 to the base of
1024.
</para>
4330 <term><varname>CeilBufferBytes=
</varname></term>
4332 <para>Specifies the maximum bytes burst for ceil which can be accumulated during idle period.
4333 When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes,
4334 respectively, to the base of
1024.
</para>
4341 <title>[HeavyHitterFilter] Section Options
</title>
4342 <para>The [HeavyHitterFilter] section manages the queueing discipline (qdisc) of Heavy Hitter Filter
4345 <variablelist class='network-directives'
>
4346 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4347 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4350 <term><varname>PacketLimit=
</varname></term>
4352 <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached,
4353 incoming packets are dropped. An unsigned integer in the range
0…
4294967294. Defaults to unset and
4354 kernel's default is used.
</para>
4361 <title>[QuickFairQueueing] Section Options
</title>
4362 <para>The [QuickFairQueueing] section manages the queueing discipline (qdisc) of Quick Fair Queueing
4365 <variablelist class='network-directives'
>
4366 <xi:include href=
"tc.xml" xpointer=
"qdisc-parent" />
4367 <xi:include href=
"tc.xml" xpointer=
"qdisc-handle" />
4372 <title>[QuickFairQueueingClass] Section Options
</title>
4373 <para>The [QuickFairQueueingClass] section manages the traffic control class of Quick Fair Queueing
4376 <variablelist class='network-directives'
>
4377 <xi:include href=
"tc.xml" xpointer=
"tclass-parent" />
4378 <xi:include href=
"tc.xml" xpointer=
"tclass-classid" />
4381 <term><varname>Weight=
</varname></term>
4383 <para>Specifies the weight of the class. Takes an integer in the range
1…
1023. Defaults to
4384 unset in which case the kernel default is used.
</para>
4389 <term><varname>MaxPacketBytes=
</varname></term>
4391 <para>Specifies the maximum packet size in bytes for the class. When suffixed with K, M, or G, the
4392 specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of
4393 1024. When unset, the kernel default is used.
</para>
4400 <title>[BridgeVLAN] Section Options
</title>
4401 <para>The [BridgeVLAN] section manages the VLAN ID configuration of a bridge port and accepts the
4402 following keys. Specify several [BridgeVLAN] sections to configure several VLAN entries. The
4403 <varname>VLANFiltering=
</varname> option has to be enabled, see the [Bridge] section in
4404 <citerefentry><refentrytitle>systemd.netdev
</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
4406 <variablelist class='network-directives'
>
4408 <term><varname>VLAN=
</varname></term>
4410 <para>The VLAN ID allowed on the port. This can be either a single ID or a range M-N. Takes
4411 an integer in the range
1…
4094.
</para>
4415 <term><varname>EgressUntagged=
</varname></term>
4417 <para>The VLAN ID specified here will be used to untag frames on egress. Configuring
4418 <varname>EgressUntagged=
</varname> implicates the use of
<varname>VLAN=
</varname> above and will enable the
4419 VLAN ID for ingress as well. This can be either a single ID or a range M-N.
</para>
4423 <term><varname>PVID=
</varname></term>
4425 <para>The Port VLAN ID specified here is assigned to all untagged frames at ingress.
4426 <varname>PVID=
</varname> can be used only once. Configuring
<varname>PVID=
</varname> implicates the use of
4427 <varname>VLAN=
</varname> above and will enable the VLAN ID for ingress as well.
</para>
4434 <title>Examples
</title>
4436 <title>Static network configuration
</title>
4438 <programlisting># /etc/systemd/network/
50-static.network
4443 Address=
192.168.0.15/
24
4444 Gateway=
192.168.0.1</programlisting>
4446 <para>This brings interface
<literal>enp2s0
</literal> up with a static address. The
4447 specified gateway will be used for a default route.
</para>
4451 <title>DHCP on ethernet links
</title>
4453 <programlisting># /etc/systemd/network/
80-dhcp.network
4458 DHCP=yes
</programlisting>
4460 <para>This will enable DHCPv4 and DHCPv6 on all interfaces with names starting with
4461 <literal>en
</literal> (i.e. ethernet interfaces).
</para>
4465 <title>IPv6 Prefix Delegation (DHCPv6 PD)
</title>
4467 <programlisting># /etc/systemd/network/
55-dhcpv6-pd-upstream.network
4474 # The below setting is optional, to also assign an address in the delegated prefix
4475 # to the upstream interface. If not necessary, then comment out the line below and
4476 # the [DHCPPrefixDelegation] section.
4477 DHCPPrefixDelegation=yes
4479 # If the upstream network provides Router Advertisement with Managed bit set,
4480 # then comment out the line below and WithoutRA= setting in the [DHCPv6] section.
4486 [DHCPPrefixDelegation]
4487 UplinkInterface=:self
4489 Announce=no
</programlisting>
4491 <programlisting># /etc/systemd/network/
55-dhcpv6-pd-downstream.network
4496 DHCPPrefixDelegation=yes
4499 # It is expected that the host is acting as a router. So, usually it is not
4500 # necessary to receive Router Advertisement from other hosts in the downstream network.
4503 [DHCPPrefixDelegation]
4504 UplinkInterface=enp1s0
4506 Announce=yes
</programlisting>
4508 <para>This will enable DHCPv6-PD on the interface enp1s0 as an upstream interface where the
4509 DHCPv6 client is running and enp2s0 as a downstream interface where the prefix is delegated to.
4510 The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network.
4515 <title>IPv6 Prefix Delegation (DHCPv4
6RD)
</title>
4517 <programlisting># /etc/systemd/network/
55-dhcpv4-
6rd-upstream.network
4524 # When DHCPv4-
6RD is used, the upstream network does not support IPv6.
4525 # Hence, it is not necessary to wait for Router Advertisement, which is enabled by default.
4529 Use6RD=yes
</programlisting>
4531 <programlisting># /etc/systemd/network/
55-dhcpv4-
6rd-downstream.network
4536 DHCPPrefixDelegation=yes
4539 # It is expected that the host is acting as a router. So, usually it is not
4540 # necessary to receive Router Advertisement from other hosts in the downstream network.
4543 [DHCPPrefixDelegation]
4544 UplinkInterface=enp1s0
4546 Announce=yes
</programlisting>
4548 <para>This will enable DHCPv4-
6RD on the interface enp1s0 as an upstream interface where the
4549 DHCPv4 client is running and enp2s0 as a downstream interface where the prefix is delegated to.
4550 The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network.
4555 <title>A bridge with two enslaved links
</title>
4557 <programlisting># /etc/systemd/network/
25-bridge-static.network
4562 Address=
192.168.0.15/
24
4564 DNS=
192.168.0.1</programlisting>
4566 <programlisting># /etc/systemd/network/
25-bridge-slave-interface-
1.network
4571 Bridge=bridge0
</programlisting>
4573 <programlisting># /etc/systemd/network/
25-bridge-slave-interface-
2.network
4578 Bridge=bridge0
</programlisting>
4580 <para>This creates a bridge and attaches devices
<literal>enp2s0
</literal> and
4581 <literal>wlp3s0
</literal> to it. The bridge will have the specified static address
4582 and network assigned, and a default route via the specified gateway will be
4583 added. The specified DNS server will be added to the global list of DNS resolvers.
4588 <title>Bridge port with VLAN forwarding
</title>
4591 # /etc/systemd/network/
25-bridge-slave-interface-
1.network
4607 EgressUntagged=
300-
400</programlisting>
4609 <para>This overrides the configuration specified in the previous example for the
4610 interface
<literal>enp2s0
</literal>, and enables VLAN on that bridge port. VLAN IDs
4611 1-
32,
42,
100-
400 will be allowed. Packets tagged with VLAN IDs
42,
300-
400 will be
4612 untagged when they leave on this interface. Untagged packets which arrive on this
4613 interface will be assigned VLAN ID
42.
</para>
4617 <title>Various tunnels
</title>
4619 <programlisting>/etc/systemd/network/
25-tunnels.network
4630 <programlisting>/etc/systemd/network/
25-tunnel-ipip.netdev
4636 <programlisting>/etc/systemd/network/
25-tunnel-sit.netdev
4642 <programlisting>/etc/systemd/network/
25-tunnel-gre.netdev
4648 <programlisting>/etc/systemd/network/
25-tunnel-vti.netdev
4654 <para>This will bring interface
<literal>ens1
</literal> up and create an IPIP tunnel,
4655 a SIT tunnel, a GRE tunnel, and a VTI tunnel using it.
</para>
4659 <title>A bond device
</title>
4661 <programlisting># /etc/systemd/network/
30-bond1.network
4669 <programlisting># /etc/systemd/network/
30-bond1.netdev
4675 <programlisting># /etc/systemd/network/
30-bond1-dev1.network
4677 MACAddress=
52:
54:
00:e9:
64:
41
4683 <programlisting># /etc/systemd/network/
30-bond1-dev2.network
4685 MACAddress=
52:
54:
00:e9:
64:
42
4691 <para>This will create a bond device
<literal>bond1
</literal> and enslave the two
4692 devices with MAC addresses
52:
54:
00:e9:
64:
41 and
52:
54:
00:e9:
64:
42 to it. IPv6 DHCP
4693 will be used to acquire an address.
</para>
4697 <title>Virtual Routing and Forwarding (VRF)
</title>
4698 <para>Add the
<literal>bond1
</literal> interface to the VRF master interface
4699 <literal>vrf1
</literal>. This will redirect routes generated on this interface to be
4700 within the routing table defined during VRF creation. For kernels before
4.8 traffic
4701 won't be redirected towards the VRFs routing table unless specific ip-rules are added.
4703 <programlisting># /etc/systemd/network/
25-vrf.network
4713 <title>MacVTap
</title>
4714 <para>This brings up a network interface
<literal>macvtap-test
</literal>
4715 and attaches it to
<literal>enp0s25
</literal>.
</para>
4716 <programlisting># /usr/lib/systemd/network/
25-macvtap.network
4721 MACVTAP=macvtap-test
4726 <title>A Xfrm interface with physical underlying device.
</title>
4728 <programlisting># /etc/systemd/network/
27-xfrm.netdev
4734 InterfaceId=
7</programlisting>
4736 <programlisting># /etc/systemd/network/
27-eth0.network
4741 Xfrm=xfrm0
</programlisting>
4743 <para>This creates a
<literal>xfrm0
</literal> interface and binds it to the
<literal>eth0
</literal> device.
4744 This allows hardware based ipsec offloading to the
<literal>eth0
</literal> nic.
4745 If offloading is not needed, xfrm interfaces can be assigned to the
<literal>lo
</literal> device.
4751 <title>See Also
</title>
4753 <citerefentry><refentrytitle>systemd
</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
4754 <citerefentry><refentrytitle>systemd-networkd.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
4755 <citerefentry><refentrytitle>systemd.link
</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
4756 <citerefentry><refentrytitle>systemd.netdev
</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
4757 <citerefentry><refentrytitle>systemd-resolved.service
</refentrytitle><manvolnum>8</manvolnum></citerefentry>