]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/systemd.netdev.xml
Merge pull request #24570 from topimiettinen/nft-sets-v2
[thirdparty/systemd.git] / man / systemd.netdev.xml
1 <?xml version='1.0'?> <!--*-nxml-*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4 <!-- SPDX-License-Identifier: LGPL-2.1-or-later -->
5
6 <refentry id="systemd.netdev" conditional='ENABLE_NETWORKD'
7 xmlns:xi="http://www.w3.org/2001/XInclude">
8
9 <refentryinfo>
10 <title>systemd.network</title>
11 <productname>systemd</productname>
12 </refentryinfo>
13
14 <refmeta>
15 <refentrytitle>systemd.netdev</refentrytitle>
16 <manvolnum>5</manvolnum>
17 </refmeta>
18
19 <refnamediv>
20 <refname>systemd.netdev</refname>
21 <refpurpose>Virtual Network Device configuration</refpurpose>
22 </refnamediv>
23
24 <refsynopsisdiv>
25 <para><filename><replaceable>netdev</replaceable>.netdev</filename></para>
26 </refsynopsisdiv>
27
28 <refsect1>
29 <title>Description</title>
30
31 <para>A plain ini-style text file that encodes configuration about a virtual network device, used by
32 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
33 See <citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>7</manvolnum></citerefentry>
34 for a general description of the syntax.</para>
35
36 <para>The main Virtual Network Device file must have the extension <filename>.netdev</filename>;
37 other extensions are ignored. Virtual network devices are created as soon as networkd is
38 started. If a netdev with the specified name already exists, networkd will use that as-is rather
39 than create its own. Note that the settings of the pre-existing netdev will not be changed by
40 networkd.</para>
41
42 <para>The <filename>.netdev</filename> files are read from the files located in the system network
43 directory <filename>/usr/lib/systemd/network</filename> and
44 <filename>/usr/local/lib/systemd/network</filename>, the volatile runtime network directory
45 <filename>/run/systemd/network</filename> and the local administration network directory
46 <filename>/etc/systemd/network</filename>. All configuration files are collectively sorted and
47 processed in alphanumeric order, regardless of the directories in which they live. However, files
48 with identical filenames replace each other. It is recommended that each filename is prefixed with
49 a number (e.g. <filename>10-vlan.netdev</filename>). Otherwise, <filename>.netdev</filename> files
50 generated by
51 <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
52 may take precedence over user configured files. Files in <filename>/etc/</filename> have the
53 highest priority, files in <filename>/run/</filename> take precedence over files with the same name
54 in <filename>/usr/lib/</filename>. This can be used to override a system-supplied configuration
55 file with a local file if needed. As a special case, an empty file (file size 0) or symlink with
56 the same name pointing to <filename>/dev/null</filename> disables the configuration file entirely
57 (it is "masked").</para>
58
59 <para>Along with the netdev file <filename>foo.netdev</filename>, a "drop-in" directory
60 <filename>foo.netdev.d/</filename> may exist. All files with the suffix <literal>.conf</literal>
61 from this directory will be merged in the alphanumeric order and parsed after the main file itself
62 has been parsed. This is useful to alter or add configuration settings, without having to modify
63 the main configuration file. Each drop-in file must have appropriate section headers.</para>
64
65 <para>In addition to <filename>/etc/systemd/network</filename>, drop-in <literal>.d</literal>
66 directories can be placed in <filename>/usr/lib/systemd/network</filename> or
67 <filename>/run/systemd/network</filename> directories. Drop-in files in
68 <filename>/etc/</filename> take precedence over those in <filename>/run/</filename> which in turn
69 take precedence over those in <filename>/usr/lib/</filename>. Drop-in files under any of these
70 directories take precedence over the main netdev file wherever located. (Of course, since
71 <filename>/run/</filename> is temporary and <filename>/usr/lib/</filename> is for vendors, it is
72 unlikely drop-ins should be used in either of those places.)</para>
73 </refsect1>
74
75 <refsect1>
76 <title>Supported netdev kinds</title>
77
78 <para>The following kinds of virtual network devices may be
79 configured in <filename>.netdev</filename> files:</para>
80
81 <table>
82 <title>Supported kinds of virtual network devices</title>
83
84 <tgroup cols='2'>
85 <colspec colname='kind' />
86 <colspec colname='explanation' />
87 <thead><row>
88 <entry>Kind</entry>
89 <entry>Description</entry>
90 </row></thead>
91 <tbody>
92 <row><entry><varname>bond</varname></entry>
93 <entry>A bond device is an aggregation of all its slave devices. See <ulink url="https://docs.kernel.org/networking/bonding.html">Linux Ethernet Bonding Driver HOWTO</ulink> for details.</entry></row>
94
95 <row><entry><varname>bridge</varname></entry>
96 <entry>A bridge device is a software switch, and each of its slave devices and the bridge itself are ports of the switch.</entry></row>
97
98 <row><entry><varname>dummy</varname></entry>
99 <entry>A dummy device drops all packets sent to it.</entry></row>
100
101 <row><entry><varname>gre</varname></entry>
102 <entry>A Level 3 GRE tunnel over IPv4. See <ulink url="https://tools.ietf.org/html/rfc2784">RFC 2784</ulink> for details. Name <literal>gre0</literal> should not be used, as the kernel creates a device with this name when the corresponding kernel module is loaded.</entry></row>
103
104 <row><entry><varname>gretap</varname></entry>
105 <entry>A Level 2 GRE tunnel over IPv4. Name <literal>gretap0</literal> should not be used, as the kernel creates a device with this name when the corresponding kernel module is loaded.</entry></row>
106
107 <row><entry><varname>erspan</varname></entry>
108 <entry>ERSPAN mirrors traffic on one or more source ports and delivers the mirrored traffic to one or more destination ports on another switch. The traffic is encapsulated in generic routing encapsulation (GRE) and is therefore routable across a layer 3 network between the source switch and the destination switch. Name <literal>erspan0</literal> should not be used, as the kernel creates a device with this name when the corresponding kernel module is loaded.</entry></row>
109
110 <row><entry><varname>ip6gre</varname></entry>
111 <entry>A Level 3 GRE tunnel over IPv6.</entry></row>
112
113 <row><entry><varname>ip6tnl</varname></entry>
114 <entry>An IPv4 or IPv6 tunnel over IPv6</entry></row>
115
116 <row><entry><varname>ip6gretap</varname></entry>
117 <entry>A Level 2 GRE tunnel over IPv6.</entry></row>
118
119 <row><entry><varname>ipip</varname></entry>
120 <entry>An IPv4 over IPv4 tunnel.</entry></row>
121
122 <row><entry><varname>ipvlan</varname></entry>
123 <entry>An IPVLAN device is a stacked device which receives packets from its underlying device based on IP address filtering.</entry></row>
124
125 <row><entry><varname>ipvtap</varname></entry>
126 <entry>An IPVTAP device is a stacked device which receives packets from its underlying device based on IP address filtering and can be accessed using the tap user space interface.</entry></row>
127
128 <row><entry><varname>macvlan</varname></entry>
129 <entry>A macvlan device is a stacked device which receives packets from its underlying device based on MAC address filtering.</entry></row>
130
131 <row><entry><varname>macvtap</varname></entry>
132 <entry>A macvtap device is a stacked device which receives packets from its underlying device based on MAC address filtering.</entry></row>
133
134 <row><entry><varname>sit</varname></entry>
135 <entry>An IPv6 over IPv4 tunnel.</entry></row>
136
137 <row><entry><varname>tap</varname></entry>
138 <entry>A persistent Level 2 tunnel between a network device and a device node.</entry></row>
139
140 <row><entry><varname>tun</varname></entry>
141 <entry>A persistent Level 3 tunnel between a network device and a device node.</entry></row>
142
143 <row><entry><varname>veth</varname></entry>
144 <entry>An Ethernet tunnel between a pair of network devices.</entry></row>
145
146 <row><entry><varname>vlan</varname></entry>
147 <entry>A VLAN is a stacked device which receives packets from its underlying device based on VLAN tagging. See <ulink url="http://www.ieee802.org/1/pages/802.1Q.html">IEEE 802.1Q</ulink> for details.</entry></row>
148
149 <row><entry><varname>vti</varname></entry>
150 <entry>An IPv4 over IPSec tunnel.</entry></row>
151
152 <row><entry><varname>vti6</varname></entry>
153 <entry>An IPv6 over IPSec tunnel.</entry></row>
154
155 <row><entry><varname>vxlan</varname></entry>
156 <entry>A virtual extensible LAN (vxlan), for connecting Cloud computing deployments.</entry></row>
157
158 <row><entry><varname>geneve</varname></entry>
159 <entry>A GEneric NEtwork Virtualization Encapsulation (GENEVE) netdev driver.</entry></row>
160
161 <row><entry><varname>l2tp</varname></entry>
162 <entry>A Layer 2 Tunneling Protocol (L2TP) is a tunneling protocol used to support virtual private networks (VPNs) or as part of the delivery of services by ISPs. It does not provide any encryption or confidentiality by itself</entry></row>
163
164 <row><entry><varname>macsec</varname></entry>
165 <entry>Media Access Control Security (MACsec) is an 802.1AE IEEE industry-standard security technology that provides secure communication for all traffic on Ethernet links. MACsec provides point-to-point security on Ethernet links between directly connected nodes and is capable of identifying and preventing most security threats.</entry></row>
166
167 <row><entry><varname>vrf</varname></entry>
168 <entry>A Virtual Routing and Forwarding (<ulink url="https://docs.kernel.org/networking/vrf.html">VRF</ulink>) interface to create separate routing and forwarding domains.</entry></row>
169
170 <row><entry><varname>vcan</varname></entry>
171 <entry>The virtual CAN driver (vcan). Similar to the network loopback devices, vcan offers a virtual local CAN interface.</entry></row>
172
173 <row><entry><varname>vxcan</varname></entry>
174 <entry>The virtual CAN tunnel driver (vxcan). Similar to the virtual ethernet driver veth, vxcan implements a local CAN traffic tunnel between two virtual CAN network devices. When creating a vxcan, two vxcan devices are created as pair. When one end receives the packet it appears on its pair and vice versa. The vxcan can be used for cross namespace communication.
175 </entry></row>
176
177 <row><entry><varname>wireguard</varname></entry>
178 <entry>WireGuard Secure Network Tunnel.</entry></row>
179
180 <row><entry><varname>nlmon</varname></entry>
181 <entry>A Netlink monitor device. Use an nlmon device when you want to monitor system Netlink messages.</entry></row>
182
183 <row><entry><varname>fou</varname></entry>
184 <entry>Foo-over-UDP tunneling.</entry></row>
185
186 <row><entry><varname>xfrm</varname></entry>
187 <entry>A virtual tunnel interface like vti/vti6 but with several advantages.</entry></row>
188
189 <row><entry><varname>ifb</varname></entry>
190 <entry>The Intermediate Functional Block (ifb) pseudo network interface acts as a QoS concentrator for multiple different sources of traffic.</entry></row>
191
192 <row><entry><varname>bareudp</varname></entry>
193 <entry>Bare UDP tunnels provide a generic L3 encapsulation support for tunnelling different L3 protocols like MPLS, IP etc. inside of a UDP tunnel.</entry></row>
194
195 <row><entry><varname>batadv</varname></entry>
196 <entry><ulink url="https://www.open-mesh.org/projects/open-mesh/wiki">B.A.T.M.A.N. Advanced</ulink> is a routing protocol for multi-hop mobile ad-hoc networks which operates on layer 2.</entry></row>
197
198 <row><entry><varname>ipoib</varname></entry>
199 <entry>An IP over Infiniband subinterface.</entry></row>
200
201 <row><entry><varname>wlan</varname></entry>
202 <entry>A virtual wireless network (WLAN) interface.</entry></row>
203 </tbody>
204 </tgroup>
205 </table>
206
207 </refsect1>
208
209 <refsect1>
210 <title>[Match] Section Options</title>
211
212 <para>A virtual network device is only created if the [Match] section matches the current
213 environment, or if the section is empty. The following keys are accepted:</para>
214
215 <variablelist class='network-directives'>
216 <xi:include href="systemd.link.xml" xpointer="host" />
217 <xi:include href="systemd.link.xml" xpointer="virtualization" />
218 <xi:include href="systemd.link.xml" xpointer="kernel-command-line" />
219 <xi:include href="systemd.link.xml" xpointer="kernel-version" />
220 <xi:include href="systemd.link.xml" xpointer="credential" />
221 <xi:include href="systemd.link.xml" xpointer="architecture" />
222 <xi:include href="systemd.link.xml" xpointer="firmware" />
223 </variablelist>
224 </refsect1>
225
226 <refsect1>
227 <title>[NetDev] Section Options</title>
228
229 <para>The [NetDev] section accepts the
230 following keys:</para>
231
232 <variablelist class='network-directives'>
233 <varlistentry>
234 <term><varname>Description=</varname></term>
235 <listitem>
236 <para>A free-form description of the netdev.</para>
237
238 <xi:include href="version-info.xml" xpointer="v215"/>
239 </listitem>
240 </varlistentry>
241 <varlistentry>
242 <term><varname>Name=</varname></term>
243 <listitem>
244 <para>The interface name used when creating the netdev.
245 This setting is compulsory.</para>
246 </listitem>
247 </varlistentry>
248 <varlistentry>
249 <term><varname>Kind=</varname></term>
250 <listitem>
251 <para>The netdev kind. This setting is compulsory. See the
252 <literal>Supported netdev kinds</literal> section for the
253 valid keys.</para>
254 </listitem>
255 </varlistentry>
256 <varlistentry>
257 <term><varname>MTUBytes=</varname></term>
258 <listitem>
259 <para>The maximum transmission unit in bytes to set for the device. The usual suffixes K, M, G
260 are supported and are understood to the base of 1024. For <literal>tun</literal> or
261 <literal>tap</literal> devices, <varname>MTUBytes=</varname> setting is not currently supported in
262 [NetDev] section. Please specify it in [Link] section of
263 corresponding
264 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
265 files.</para>
266
267 <xi:include href="version-info.xml" xpointer="v215"/>
268 </listitem>
269 </varlistentry>
270 <varlistentry>
271 <term><varname>MACAddress=</varname></term>
272 <listitem>
273 <para>Specifies the MAC address to use for the device, or takes the special value
274 <literal>none</literal>. When <literal>none</literal>, <command>systemd-networkd</command>
275 does not request the MAC address for the device, and the kernel will assign a random MAC
276 address. For <literal>tun</literal>, <literal>tap</literal>, or <literal>l2tp</literal>
277 devices, the <varname>MACAddress=</varname> setting in the [NetDev] section is not
278 supported and will be ignored. Please specify it in the [Link] section of the corresponding
279 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
280 file. If this option is not set, <literal>vlan</literal> device inherits the MAC address of
281 the master interface. For other kind of netdevs, if this option is not set, then the MAC
282 address is generated based on the interface name and the
283 <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
284 </para>
285 <para>Note, even if <literal>none</literal> is specified, <command>systemd-udevd</command>
286 will assign the persistent MAC address for the device, as <filename>99-default.link</filename>
287 has <varname>MACAddressPolicy=persistent</varname>. So, it is also necessary to create a
288 custom .link file for the device, if the MAC address assignment is not desired.</para>
289
290 <xi:include href="version-info.xml" xpointer="v215"/>
291 </listitem>
292 </varlistentry>
293 </variablelist>
294 </refsect1>
295
296 <refsect1>
297 <title>[Bridge] Section Options</title>
298
299 <para>The [Bridge] section only applies for
300 netdevs of kind <literal>bridge</literal>, and accepts the
301 following keys:</para>
302
303 <variablelist class='network-directives'>
304 <varlistentry>
305 <term><varname>HelloTimeSec=</varname></term>
306 <listitem>
307 <para>HelloTimeSec specifies the number of seconds between two hello packets
308 sent out by the root bridge and the designated bridges. Hello packets are
309 used to communicate information about the topology throughout the entire
310 bridged local area network.</para>
311
312 <xi:include href="version-info.xml" xpointer="v227"/>
313 </listitem>
314 </varlistentry>
315 <varlistentry>
316 <term><varname>MaxAgeSec=</varname></term>
317 <listitem>
318 <para>MaxAgeSec specifies the number of seconds of maximum message age.
319 If the last seen (received) hello packet is more than this number of
320 seconds old, the bridge in question will start the takeover procedure
321 in attempt to become the Root Bridge itself.</para>
322
323 <xi:include href="version-info.xml" xpointer="v227"/>
324 </listitem>
325 </varlistentry>
326 <varlistentry>
327 <term><varname>ForwardDelaySec=</varname></term>
328 <listitem>
329 <para>ForwardDelaySec specifies the number of seconds spent in each
330 of the Listening and Learning states before the Forwarding state is entered.</para>
331
332 <xi:include href="version-info.xml" xpointer="v227"/>
333 </listitem>
334 </varlistentry>
335 <varlistentry>
336 <term><varname>AgeingTimeSec=</varname></term>
337 <listitem>
338 <para>This specifies the number of seconds a MAC Address will be kept in
339 the forwarding database after having a packet received from this MAC Address.</para>
340
341 <xi:include href="version-info.xml" xpointer="v232"/>
342 </listitem>
343 </varlistentry>
344 <varlistentry>
345 <term><varname>Priority=</varname></term>
346 <listitem>
347 <para>The priority of the bridge. An integer between 0 and 65535. A lower value
348 means higher priority. The bridge having the lowest priority will be elected as root bridge.</para>
349
350 <xi:include href="version-info.xml" xpointer="v232"/>
351 </listitem>
352 </varlistentry>
353 <varlistentry>
354 <term><varname>GroupForwardMask=</varname></term>
355 <listitem>
356 <para>A 16-bit bitmask represented as an integer which allows forwarding of link
357 local frames with 802.1D reserved addresses (01:80:C2:00:00:0X). A logical AND
358 is performed between the specified bitmask and the exponentiation of 2^X, the
359 lower nibble of the last octet of the MAC address. For example, a value of 8
360 would allow forwarding of frames addressed to 01:80:C2:00:00:03 (802.1X PAE).</para>
361
362 <xi:include href="version-info.xml" xpointer="v235"/>
363 </listitem>
364 </varlistentry>
365 <varlistentry>
366 <term><varname>DefaultPVID=</varname></term>
367 <listitem>
368 <para>This specifies the default port VLAN ID of a newly attached bridge port.
369 Set this to an integer in the range 1…4094 or <literal>none</literal> to disable the PVID.</para>
370
371 <xi:include href="version-info.xml" xpointer="v232"/>
372 </listitem>
373 </varlistentry>
374 <varlistentry>
375 <term><varname>MulticastQuerier=</varname></term>
376 <listitem>
377 <para>Takes a boolean. This setting controls the IFLA_BR_MCAST_QUERIER option in the kernel.
378 If enabled, the kernel will send general ICMP queries from a zero source address.
379 This feature should allow faster convergence on startup, but it causes some
380 multicast-aware switches to misbehave and disrupt forwarding of multicast packets.
381 When unset, the kernel's default will be used.
382 </para>
383
384 <xi:include href="version-info.xml" xpointer="v230"/>
385 </listitem>
386 </varlistentry>
387 <varlistentry>
388 <term><varname>MulticastSnooping=</varname></term>
389 <listitem>
390 <para>Takes a boolean. This setting controls the IFLA_BR_MCAST_SNOOPING option in the kernel.
391 If enabled, IGMP snooping monitors the Internet Group Management Protocol (IGMP) traffic
392 between hosts and multicast routers. When unset, the kernel's default will be used.
393 </para>
394
395 <xi:include href="version-info.xml" xpointer="v230"/>
396 </listitem>
397 </varlistentry>
398 <varlistentry>
399 <term><varname>VLANFiltering=</varname></term>
400 <listitem>
401 <para>Takes a boolean. This setting controls the IFLA_BR_VLAN_FILTERING option in the kernel.
402 If enabled, the bridge will be started in VLAN-filtering mode. When unset, the kernel's default will be used.
403 </para>
404
405 <xi:include href="version-info.xml" xpointer="v231"/>
406 </listitem>
407 </varlistentry>
408 <varlistentry>
409 <term><varname>VLANProtocol=</varname></term>
410 <listitem>
411 <para>Allows setting the protocol used for VLAN filtering. Takes
412 <option>802.1q</option> or,
413 <option>802.1ad</option>, and defaults to unset and kernel's default is used.
414 </para>
415
416 <xi:include href="version-info.xml" xpointer="v246"/>
417 </listitem>
418 </varlistentry>
419 <varlistentry>
420 <term><varname>STP=</varname></term>
421 <listitem>
422 <para>Takes a boolean. This enables the bridge's Spanning Tree Protocol (STP).
423 When unset, the kernel's default will be used.
424 </para>
425
426 <xi:include href="version-info.xml" xpointer="v232"/>
427 </listitem>
428 </varlistentry>
429 <varlistentry>
430 <term><varname>MulticastIGMPVersion=</varname></term>
431 <listitem>
432 <para>Allows changing bridge's multicast Internet Group Management Protocol (IGMP) version.
433 Takes an integer 2 or 3. When unset, the kernel's default will be used.
434 </para>
435
436 <xi:include href="version-info.xml" xpointer="v243"/>
437 </listitem>
438 </varlistentry>
439 </variablelist>
440 </refsect1>
441
442 <refsect1>
443 <title>[VLAN] Section Options</title>
444
445 <para>The [VLAN] section only applies for
446 netdevs of kind <literal>vlan</literal>, and accepts the
447 following key:</para>
448
449 <variablelist class='network-directives'>
450 <varlistentry>
451 <term><varname>Id=</varname></term>
452 <listitem>
453 <para>The VLAN ID to use. An integer in the range 0…4094.
454 This setting is compulsory.</para>
455 </listitem>
456 </varlistentry>
457 <varlistentry>
458 <term><varname>Protocol=</varname></term>
459 <listitem>
460 <para>Allows setting the protocol used for the VLAN interface. Takes <literal>802.1q</literal> or,
461 <literal>802.1ad</literal>, and defaults to unset and kernel's default is used.</para>
462
463 <xi:include href="version-info.xml" xpointer="v248"/>
464 </listitem>
465 </varlistentry>
466 <varlistentry>
467 <term><varname>GVRP=</varname></term>
468 <listitem>
469 <para>Takes a boolean. The Generic VLAN Registration Protocol (GVRP) is a protocol that
470 allows automatic learning of VLANs on a network.
471 When unset, the kernel's default will be used.
472 </para>
473
474 <xi:include href="version-info.xml" xpointer="v234"/>
475 </listitem>
476 </varlistentry>
477 <varlistentry>
478 <term><varname>MVRP=</varname></term>
479 <listitem>
480 <para>Takes a boolean. Multiple VLAN Registration Protocol (MVRP) formerly known as GARP VLAN
481 Registration Protocol (GVRP) is a standards-based Layer 2 network protocol,
482 for automatic configuration of VLAN information on switches. It was defined
483 in the 802.1ak amendment to 802.1Q-2005. When unset, the kernel's default will be used.
484 </para>
485
486 <xi:include href="version-info.xml" xpointer="v234"/>
487 </listitem>
488 </varlistentry>
489 <varlistentry>
490 <term><varname>LooseBinding=</varname></term>
491 <listitem>
492 <para>Takes a boolean. The VLAN loose binding mode, in which only the operational state is passed
493 from the parent to the associated VLANs, but the VLAN device state is not changed.
494 When unset, the kernel's default will be used.</para>
495
496 <xi:include href="version-info.xml" xpointer="v234"/>
497 </listitem>
498 </varlistentry>
499 <varlistentry>
500 <term><varname>ReorderHeader=</varname></term>
501 <listitem>
502 <para>Takes a boolean. When enabled, the VLAN reorder header is used and VLAN interfaces behave
503 like physical interfaces. When unset, the kernel's default will be used.</para>
504
505 <xi:include href="version-info.xml" xpointer="v234"/>
506 </listitem>
507 </varlistentry>
508 <varlistentry>
509 <term><varname>EgressQOSMaps=</varname></term>
510 <term><varname>IngressQOSMaps=</varname></term>
511 <listitem>
512 <para>Defines a mapping of Linux internal packet priority (<constant>SO_PRIORITY</constant>)
513 to VLAN header PCP field for outgoing and incoming frames, respectively. Takes a
514 whitespace-separated list of integer pairs, where each integer must be in the range
515 1…4294967294, in the format <literal>from</literal>-<literal>to</literal>, e.g.,
516 <literal>21-7 45-5</literal>. Note that <literal>from</literal> must be greater than or equal
517 to <literal>to</literal>. When unset, the kernel's default will be used.</para>
518 </listitem>
519 </varlistentry>
520 </variablelist>
521 </refsect1>
522
523 <refsect1>
524 <title>[MACVLAN] Section Options</title>
525
526 <para>The [MACVLAN] section only applies for
527 netdevs of kind <literal>macvlan</literal>, and accepts the
528 following key:</para>
529
530 <variablelist class='network-directives'>
531 <varlistentry>
532 <term><varname>Mode=</varname></term>
533 <listitem>
534 <para>The MACVLAN mode to use. The supported options are
535 <literal>private</literal>,
536 <literal>vepa</literal>,
537 <literal>bridge</literal>,
538 <literal>passthru</literal>, and
539 <literal>source</literal>.
540 </para>
541 </listitem>
542 </varlistentry>
543 <varlistentry>
544 <term><varname>SourceMACAddress=</varname></term>
545 <listitem>
546 <para>A whitespace-separated list of remote hardware addresses allowed on the MACVLAN. This
547 option only has an effect in source mode. Use full colon-, hyphen- or dot-delimited
548 hexadecimal. This option may appear more than once, in which case the lists are merged. If
549 the empty string is assigned to this option, the list of hardware addresses defined prior
550 to this is reset. Defaults to unset.</para>
551
552 <xi:include href="version-info.xml" xpointer="v246"/>
553 </listitem>
554 </varlistentry>
555 <varlistentry>
556 <term><varname>BroadcastMulticastQueueLength=</varname></term>
557 <listitem>
558 <para>Specifies the length of the receive queue for broadcast/multicast packets. An unsigned
559 integer in the range 0…4294967294. Defaults to unset.</para>
560
561 <xi:include href="version-info.xml" xpointer="v248"/>
562 </listitem>
563 </varlistentry>
564 </variablelist>
565 </refsect1>
566
567 <refsect1>
568 <title>[MACVTAP] Section Options</title>
569
570 <para>The [MACVTAP] section applies for netdevs of kind <literal>macvtap</literal> and accepts the same
571 keys as [MACVLAN].</para>
572 </refsect1>
573
574 <refsect1>
575 <title>[IPVLAN] Section Options</title>
576
577 <para>The [IPVLAN] section only applies for
578 netdevs of kind <literal>ipvlan</literal>, and accepts the
579 following key:</para>
580
581 <variablelist class='network-directives'>
582 <varlistentry>
583 <term><varname>Mode=</varname></term>
584 <listitem>
585 <para>The IPVLAN mode to use. The supported options are
586 <literal>L2</literal>,<literal>L3</literal> and <literal>L3S</literal>.
587 </para>
588
589 <xi:include href="version-info.xml" xpointer="v219"/>
590 </listitem>
591 </varlistentry>
592 <varlistentry>
593 <term><varname>Flags=</varname></term>
594 <listitem>
595 <para>The IPVLAN flags to use. The supported options are
596 <literal>bridge</literal>,<literal>private</literal> and <literal>vepa</literal>.
597 </para>
598
599 <xi:include href="version-info.xml" xpointer="v237"/>
600 </listitem>
601 </varlistentry>
602 </variablelist>
603 </refsect1>
604
605 <refsect1>
606 <title>[IPVTAP] Section Options</title>
607
608 <para>The [IPVTAP] section only applies for netdevs of kind <literal>ipvtap</literal> and accepts the
609 same keys as [IPVLAN].</para>
610 </refsect1>
611
612 <refsect1>
613 <title>[VXLAN] Section Options</title>
614
615 <para>The [VXLAN] section only applies for
616 netdevs of kind <literal>vxlan</literal>, and accepts the
617 following keys:</para>
618
619 <variablelist class='network-directives'>
620 <varlistentry>
621 <term><varname>VNI=</varname></term>
622 <listitem>
623 <para>The VXLAN Network Identifier (or VXLAN Segment ID). Takes a number in the range 1…16777215.</para>
624
625 <xi:include href="version-info.xml" xpointer="v243"/>
626 </listitem>
627 </varlistentry>
628 <varlistentry>
629 <term><varname>Remote=</varname></term>
630 <listitem>
631 <para>Configures destination IP address.</para>
632
633 <xi:include href="version-info.xml" xpointer="v233"/>
634 </listitem>
635 </varlistentry>
636 <varlistentry>
637 <term><varname>Local=</varname></term>
638 <listitem>
639 <para>Configures local IP address. It must be an address on the underlying interface of the
640 VXLAN interface, or one of the special values <literal>ipv4_link_local</literal>,
641 <literal>ipv6_link_local</literal>, <literal>dhcp4</literal>, <literal>dhcp6</literal>, and
642 <literal>slaac</literal>. If one of the special values is specified, an address which matches
643 the corresponding type on the underlying interface will be used. Defaults to unset.</para>
644
645 <xi:include href="version-info.xml" xpointer="v233"/>
646 </listitem>
647 </varlistentry>
648 <varlistentry>
649 <term><varname>Group=</varname></term>
650 <listitem>
651 <para>Configures VXLAN multicast group IP address. All members of a VXLAN must use the same
652 multicast group address.</para>
653
654 <xi:include href="version-info.xml" xpointer="v243"/>
655 </listitem>
656 </varlistentry>
657 <varlistentry>
658 <term><varname>TOS=</varname></term>
659 <listitem>
660 <para>The Type Of Service byte value for a vxlan interface.</para>
661
662 <xi:include href="version-info.xml" xpointer="v215"/>
663 </listitem>
664 </varlistentry>
665 <varlistentry>
666 <term><varname>TTL=</varname></term>
667 <listitem>
668 <para>A fixed Time To Live N on Virtual eXtensible Local Area Network packets.
669 Takes <literal>inherit</literal> or a number in the range 0…255. 0 is a special
670 value meaning inherit the inner protocol's TTL value. <literal>inherit</literal>
671 means that it will inherit the outer protocol's TTL value.</para>
672
673 <xi:include href="version-info.xml" xpointer="v215"/>
674 </listitem>
675 </varlistentry>
676 <varlistentry>
677 <term><varname>MacLearning=</varname></term>
678 <listitem>
679 <para>Takes a boolean. When true, enables dynamic MAC learning
680 to discover remote MAC addresses.</para>
681
682 <xi:include href="version-info.xml" xpointer="v215"/>
683 </listitem>
684 </varlistentry>
685 <varlistentry>
686 <term><varname>FDBAgeingSec=</varname></term>
687 <listitem>
688 <para>The lifetime of Forwarding Database entry learnt by
689 the kernel, in seconds.</para>
690
691 <xi:include href="version-info.xml" xpointer="v218"/>
692 </listitem>
693 </varlistentry>
694 <varlistentry>
695 <term><varname>MaximumFDBEntries=</varname></term>
696 <listitem>
697 <para>Configures maximum number of FDB entries.</para>
698
699 <xi:include href="version-info.xml" xpointer="v228"/>
700 </listitem>
701 </varlistentry>
702 <varlistentry>
703 <term><varname>ReduceARPProxy=</varname></term>
704 <listitem>
705 <para>Takes a boolean. When true, bridge-connected VXLAN tunnel
706 endpoint answers ARP requests from the local bridge on behalf
707 of remote Distributed Overlay Virtual Ethernet
708 <ulink url="https://en.wikipedia.org/wiki/Distributed_Overlay_Virtual_Ethernet">
709 (DOVE)</ulink> clients. Defaults to false.</para>
710
711 <xi:include href="version-info.xml" xpointer="v233"/>
712 </listitem>
713 </varlistentry>
714 <varlistentry>
715 <term><varname>L2MissNotification=</varname></term>
716 <listitem>
717 <para>Takes a boolean. When true, enables netlink LLADDR miss
718 notifications.</para>
719
720 <xi:include href="version-info.xml" xpointer="v218"/>
721 </listitem>
722 </varlistentry>
723 <varlistentry>
724 <term><varname>L3MissNotification=</varname></term>
725 <listitem>
726 <para>Takes a boolean. When true, enables netlink IP address miss notifications.</para>
727
728 <xi:include href="version-info.xml" xpointer="v218"/>
729 </listitem>
730 </varlistentry>
731 <varlistentry>
732 <term><varname>RouteShortCircuit=</varname></term>
733 <listitem>
734 <para>Takes a boolean. When true, route short circuiting is turned
735 on.</para>
736
737 <xi:include href="version-info.xml" xpointer="v218"/>
738 </listitem>
739 </varlistentry>
740 <varlistentry>
741 <term><varname>UDPChecksum=</varname></term>
742 <listitem>
743 <para>Takes a boolean. When true, transmitting UDP checksums when doing VXLAN/IPv4 is turned on.</para>
744
745 <xi:include href="version-info.xml" xpointer="v232"/>
746 </listitem>
747 </varlistentry>
748 <varlistentry>
749 <term><varname>UDP6ZeroChecksumTx=</varname></term>
750 <listitem>
751 <para>Takes a boolean. When true, sending zero checksums in VXLAN/IPv6 is turned on.</para>
752
753 <xi:include href="version-info.xml" xpointer="v220"/>
754 </listitem>
755 </varlistentry>
756 <varlistentry>
757 <term><varname>UDP6ZeroChecksumRx=</varname></term>
758 <listitem>
759 <para>Takes a boolean. When true, receiving zero checksums in VXLAN/IPv6 is turned on.</para>
760
761 <xi:include href="version-info.xml" xpointer="v232"/>
762 </listitem>
763 </varlistentry>
764 <varlistentry>
765 <term><varname>RemoteChecksumTx=</varname></term>
766 <listitem>
767 <para>Takes a boolean. When true, remote transmit checksum offload of VXLAN is turned on.</para>
768
769 <xi:include href="version-info.xml" xpointer="v232"/>
770 </listitem>
771 </varlistentry>
772 <varlistentry>
773 <term><varname>RemoteChecksumRx=</varname></term>
774 <listitem>
775 <para>Takes a boolean. When true, remote receive checksum offload in VXLAN is turned on.</para>
776
777 <xi:include href="version-info.xml" xpointer="v232"/>
778 </listitem>
779 </varlistentry>
780 <varlistentry>
781 <term><varname>GroupPolicyExtension=</varname></term>
782 <listitem>
783 <para>Takes a boolean. When true, it enables Group Policy VXLAN extension security label mechanism
784 across network peers based on VXLAN. For details about the Group Policy VXLAN, see the
785 <ulink url="https://tools.ietf.org/html/draft-smith-vxlan-group-policy">
786 VXLAN Group Policy </ulink> document. Defaults to false.</para>
787
788 <xi:include href="version-info.xml" xpointer="v224"/>
789 </listitem>
790 </varlistentry>
791 <varlistentry>
792 <term><varname>GenericProtocolExtension=</varname></term>
793 <listitem>
794 <para>Takes a boolean. When true, Generic Protocol Extension extends the existing VXLAN protocol
795 to provide protocol typing, OAM, and versioning capabilities. For details about the VXLAN GPE
796 Header, see the <ulink url="https://tools.ietf.org/html/draft-ietf-nvo3-vxlan-gpe-07">
797 Generic Protocol Extension for VXLAN </ulink> document. If destination port is not specified and
798 Generic Protocol Extension is set then default port of 4790 is used. Defaults to false.</para>
799
800 <xi:include href="version-info.xml" xpointer="v243"/>
801 </listitem>
802 </varlistentry>
803 <varlistentry>
804 <term><varname>DestinationPort=</varname></term>
805 <listitem>
806 <para>Configures the default destination UDP port. If the destination port is not specified then
807 Linux kernel default will be used. Set to 4789 to get the IANA assigned value.</para>
808
809 <xi:include href="version-info.xml" xpointer="v229"/>
810 </listitem>
811 </varlistentry>
812 <varlistentry>
813 <term><varname>PortRange=</varname></term>
814 <listitem>
815 <para>Configures the source port range for the VXLAN. The kernel assigns the source UDP port based
816 on the flow to help the receiver to do load balancing. When this option is not set, the normal
817 range of local UDP ports is used.</para>
818
819 <xi:include href="version-info.xml" xpointer="v229"/>
820 </listitem>
821 </varlistentry>
822 <varlistentry>
823 <term><varname>FlowLabel=</varname></term>
824 <listitem>
825 <para>Specifies the flow label to use in outgoing packets.
826 The valid range is 0-1048575.
827 </para>
828
829 <xi:include href="version-info.xml" xpointer="v234"/>
830 </listitem>
831 </varlistentry>
832 <varlistentry>
833 <term><varname>IPDoNotFragment=</varname></term>
834 <listitem>
835 <para>Allows setting the IPv4 Do not Fragment (DF) bit in outgoing packets, or to inherit its
836 value from the IPv4 inner header. Takes a boolean value, or <literal>inherit</literal>. Set
837 to <literal>inherit</literal> if the encapsulated protocol is IPv6. When unset, the kernel's
838 default will be used.</para>
839
840 <xi:include href="version-info.xml" xpointer="v243"/>
841 </listitem>
842 </varlistentry>
843 <varlistentry>
844 <term><varname>Independent=</varname></term>
845 <listitem>
846 <para>Takes a boolean. When true, the vxlan interface is created without any underlying network
847 interface. Defaults to false, which means that a .network file that requests this VXLAN interface
848 using <varname>VXLAN=</varname> is required for the VXLAN to be created.</para>
849 </listitem>
850 </varlistentry>
851 </variablelist>
852 </refsect1>
853
854 <refsect1>
855 <title>[GENEVE] Section Options</title>
856
857 <para>The [GENEVE] section only applies for
858 netdevs of kind <literal>geneve</literal>, and accepts the
859 following keys:</para>
860
861 <variablelist class='network-directives'>
862 <varlistentry>
863 <term><varname>Id=</varname></term>
864 <listitem>
865 <para>Specifies the Virtual Network Identifier (VNI) to use, a number between 0 and 16777215. This
866 field is mandatory.</para>
867 </listitem>
868 </varlistentry>
869 <varlistentry>
870 <term><varname>Remote=</varname></term>
871 <listitem>
872 <para>Specifies the unicast destination IP address to use in outgoing packets.</para>
873
874 <xi:include href="version-info.xml" xpointer="v234"/>
875 </listitem>
876 </varlistentry>
877 <varlistentry>
878 <term><varname>TOS=</varname></term>
879 <listitem>
880 <para>Specifies the TOS value to use in outgoing packets. Takes a number between 1 and 255.</para>
881
882 <xi:include href="version-info.xml" xpointer="v234"/>
883 </listitem>
884 </varlistentry>
885 <varlistentry>
886 <term><varname>TTL=</varname></term>
887 <listitem>
888 <para>Accepts the same values as in the [VXLAN] section, except that when unset
889 or set to 0, the kernel's default will be used, meaning that packet TTL will be set from
890 <filename>/proc/sys/net/ipv4/ip_default_ttl</filename>.</para>
891
892 <xi:include href="version-info.xml" xpointer="v234"/>
893 </listitem>
894 </varlistentry>
895 <varlistentry>
896 <term><varname>UDPChecksum=</varname></term>
897 <listitem>
898 <para>Takes a boolean. When true, specifies that UDP checksum is calculated for transmitted packets
899 over IPv4.</para>
900
901 <xi:include href="version-info.xml" xpointer="v234"/>
902 </listitem>
903 </varlistentry>
904 <varlistentry>
905 <term><varname>UDP6ZeroChecksumTx=</varname></term>
906 <listitem>
907 <para>Takes a boolean. When true, skip UDP checksum calculation for transmitted packets over IPv6.</para>
908
909 <xi:include href="version-info.xml" xpointer="v234"/>
910 </listitem>
911 </varlistentry>
912 <varlistentry>
913 <term><varname>UDP6ZeroChecksumRx=</varname></term>
914 <listitem>
915 <para>Takes a boolean. When true, allows incoming UDP packets over IPv6 with zero checksum field.</para>
916
917 <xi:include href="version-info.xml" xpointer="v234"/>
918 </listitem>
919 </varlistentry>
920 <varlistentry>
921 <term><varname>DestinationPort=</varname></term>
922 <listitem>
923 <para>Specifies destination port. Defaults to 6081. If not set or assigned the empty string, the default
924 port of 6081 is used.</para>
925
926 <xi:include href="version-info.xml" xpointer="v234"/>
927 </listitem>
928 </varlistentry>
929 <varlistentry>
930 <term><varname>FlowLabel=</varname></term>
931 <listitem>
932 <para>Specifies the flow label to use in outgoing packets.</para>
933
934 <xi:include href="version-info.xml" xpointer="v234"/>
935 </listitem>
936 </varlistentry>
937 <varlistentry>
938 <term><varname>IPDoNotFragment=</varname></term>
939 <listitem>
940 <para>Accepts the same key as in [VXLAN] section.</para>
941
942 <xi:include href="version-info.xml" xpointer="v243"/>
943 </listitem>
944 </varlistentry>
945 <varlistentry>
946 <term><varname>InheritInnerProtocol=</varname></term>
947 <listitem>
948 <para>Takes a boolean. When true, inner Layer 3 protocol is set as Protocol Type in the GENEVE
949 header instead of Ethernet. Defaults to false.</para>
950
951 <xi:include href="version-info.xml" xpointer="v254"/>
952 </listitem>
953 </varlistentry>
954 </variablelist>
955 </refsect1>
956
957 <refsect1>
958 <title>[BareUDP] Section Options</title>
959
960 <para>The [BareUDP] section only applies for
961 netdevs of kind <literal>bareudp</literal>, and accepts the
962 following keys:</para>
963
964 <variablelist class='network-directives'>
965 <varlistentry>
966 <term><varname>DestinationPort=</varname></term>
967 <listitem>
968 <para>Specifies the destination UDP port (in range 1…65535). This is mandatory.</para>
969
970 <xi:include href="version-info.xml" xpointer="v247"/>
971 </listitem>
972 </varlistentry>
973
974 <varlistentry>
975 <term><varname>EtherType=</varname></term>
976 <listitem>
977 <para>Specifies the L3 protocol. Takes one of <literal>ipv4</literal>, <literal>ipv6</literal>, <literal>mpls-uc</literal>
978 or <literal>mpls-mc</literal>. This is mandatory.</para>
979
980 <xi:include href="version-info.xml" xpointer="v247"/>
981 </listitem>
982 </varlistentry>
983 </variablelist>
984 </refsect1>
985
986 <refsect1>
987 <title>[L2TP] Section Options</title>
988
989 <para>The [L2TP] section only applies for
990 netdevs of kind <literal>l2tp</literal>, and accepts the
991 following keys:</para>
992
993 <variablelist class='network-directives'>
994 <varlistentry>
995 <term><varname>TunnelId=</varname></term>
996 <listitem>
997 <para>Specifies the tunnel identifier. Takes an number in the range 1…4294967295. The value used
998 must match the <literal>PeerTunnelId=</literal> value being used at the peer. This setting is
999 compulsory.</para>
1000
1001 <xi:include href="version-info.xml" xpointer="v242"/>
1002 </listitem>
1003 </varlistentry>
1004 <varlistentry>
1005 <term><varname>PeerTunnelId=</varname></term>
1006 <listitem>
1007 <para>Specifies the peer tunnel id. Takes a number in the range 1…4294967295. The value used must
1008 match the <literal>TunnelId=</literal> value being used at the peer. This setting is compulsory.
1009 </para>
1010
1011 <xi:include href="version-info.xml" xpointer="v242"/>
1012 </listitem>
1013 </varlistentry>
1014 <varlistentry>
1015 <term><varname>Remote=</varname></term>
1016 <listitem>
1017 <para>Specifies the IP address of the remote peer. This setting is compulsory.</para>
1018
1019 <xi:include href="version-info.xml" xpointer="v242"/>
1020 </listitem>
1021 </varlistentry>
1022 <varlistentry>
1023 <term><varname>Local=</varname></term>
1024 <listitem>
1025 <para>Specifies the IP address of a local interface. Takes an IP address, or the special
1026 values <literal>auto</literal>, <literal>static</literal>, or <literal>dynamic</literal>.
1027 Optionally a name of a local interface can be specified after <literal>@</literal>, e.g.
1028 <literal>192.168.0.1@eth0</literal> or <literal>auto@eth0</literal>. When an address is
1029 specified, then a local or specified interface must have the address, and the remote address
1030 must be accessible through the local address. If <literal>auto</literal>, then one of the
1031 addresses on a local or specified interface which is accessible to the remote address will be
1032 used. Similarly, if <literal>static</literal> or <literal>dynamic</literal> is set, then one
1033 of the static or dynamic addresses will be used. Defaults to <literal>auto</literal>.</para>
1034
1035 <xi:include href="version-info.xml" xpointer="v242"/>
1036 </listitem>
1037 </varlistentry>
1038 <varlistentry>
1039 <term><varname>EncapsulationType=</varname></term>
1040 <listitem>
1041 <para>Specifies the encapsulation type of the tunnel. Takes one of <literal>udp</literal> or
1042 <literal>ip</literal>.</para>
1043
1044 <xi:include href="version-info.xml" xpointer="v242"/>
1045 </listitem>
1046 </varlistentry>
1047 <varlistentry>
1048 <term><varname>UDPSourcePort=</varname></term>
1049 <listitem>
1050 <para>Specifies the UDP source port to be used for the tunnel. When UDP encapsulation is selected
1051 it's mandatory. Ignored when IP encapsulation is selected.</para>
1052
1053 <xi:include href="version-info.xml" xpointer="v242"/>
1054 </listitem>
1055 </varlistentry>
1056 <varlistentry>
1057 <term><varname>UDPDestinationPort=</varname></term>
1058 <listitem>
1059 <para>Specifies destination port. When UDP encapsulation is selected it's mandatory. Ignored when IP
1060 encapsulation is selected.</para>
1061
1062 <xi:include href="version-info.xml" xpointer="v245"/>
1063 </listitem>
1064 </varlistentry>
1065 <varlistentry>
1066 <term><varname>UDPChecksum=</varname></term>
1067 <listitem>
1068 <para>Takes a boolean. When true, specifies that UDP checksum is calculated for transmitted packets
1069 over IPv4.</para>
1070
1071 <xi:include href="version-info.xml" xpointer="v242"/>
1072 </listitem>
1073 </varlistentry>
1074 <varlistentry>
1075 <term><varname>UDP6ZeroChecksumTx=</varname></term>
1076 <listitem>
1077 <para>Takes a boolean. When true, skip UDP checksum calculation for transmitted packets over IPv6.</para>
1078
1079 <xi:include href="version-info.xml" xpointer="v242"/>
1080 </listitem>
1081 </varlistentry>
1082 <varlistentry>
1083 <term><varname>UDP6ZeroChecksumRx=</varname></term>
1084 <listitem>
1085 <para>Takes a boolean. When true, allows incoming UDP packets over IPv6 with zero checksum field.</para>
1086
1087 <xi:include href="version-info.xml" xpointer="v242"/>
1088 </listitem>
1089 </varlistentry>
1090 </variablelist>
1091 </refsect1>
1092
1093 <refsect1>
1094 <title>[L2TPSession] Section Options</title>
1095
1096 <para>The [L2TPSession] section only applies for
1097 netdevs of kind <literal>l2tp</literal>, and accepts the
1098 following keys:</para>
1099 <variablelist class='network-directives'>
1100 <varlistentry>
1101 <term><varname>Name=</varname></term>
1102 <listitem>
1103 <para>Specifies the name of the session. This setting is compulsory.</para>
1104
1105 <xi:include href="version-info.xml" xpointer="v242"/>
1106 </listitem>
1107 </varlistentry>
1108 <varlistentry>
1109 <term><varname>SessionId=</varname></term>
1110 <listitem>
1111 <para>Specifies the session identifier. Takes an number in the range 1…4294967295. The value used
1112 must match the <literal>SessionId=</literal> value being used at the peer. This setting is
1113 compulsory.</para>
1114
1115 <xi:include href="version-info.xml" xpointer="v242"/>
1116 </listitem>
1117 </varlistentry>
1118 <varlistentry>
1119 <term><varname>PeerSessionId=</varname></term>
1120 <listitem>
1121 <para>Specifies the peer session identifier. Takes an number in the range 1…4294967295.
1122 The value used must match the <literal>PeerSessionId=</literal> value being used at the peer.
1123 This setting is compulsory.</para>
1124
1125 <xi:include href="version-info.xml" xpointer="v242"/>
1126 </listitem>
1127 </varlistentry>
1128 <varlistentry>
1129 <term><varname>Layer2SpecificHeader=</varname></term>
1130 <listitem>
1131 <para>Specifies layer2specific header type of the session. One of <literal>none</literal> or <literal>default</literal>. Defaults to <literal>default</literal>.</para>
1132
1133 <xi:include href="version-info.xml" xpointer="v242"/>
1134 </listitem>
1135 </varlistentry>
1136 </variablelist>
1137 </refsect1>
1138
1139 <refsect1>
1140 <title>[MACsec] Section Options</title>
1141
1142 <para>The [MACsec] section only applies for network devices of kind
1143 <literal>macsec</literal>, and accepts the following keys:</para>
1144
1145 <variablelist class='network-directives'>
1146 <varlistentry>
1147 <term><varname>Port=</varname></term>
1148 <listitem>
1149 <para>Specifies the port to be used for the MACsec transmit channel. The port is used to make
1150 secure channel identifier (SCI). Takes a value between 1 and 65535. Defaults to unset.
1151 </para>
1152
1153 <xi:include href="version-info.xml" xpointer="v243"/>
1154 </listitem>
1155 </varlistentry>
1156 <varlistentry>
1157 <term><varname>Encrypt=</varname></term>
1158 <listitem>
1159 <para>Takes a boolean. When true, enable encryption. Defaults to unset.</para>
1160
1161 <xi:include href="version-info.xml" xpointer="v243"/>
1162 </listitem>
1163 </varlistentry>
1164 </variablelist>
1165 </refsect1>
1166
1167 <refsect1>
1168 <title>[MACsecReceiveChannel] Section Options</title>
1169 <para>The [MACsecReceiveChannel] section only applies for network devices of
1170 kind <literal>macsec</literal>, and accepts the following keys:</para>
1171
1172 <variablelist class='network-directives'>
1173 <varlistentry>
1174 <term><varname>Port=</varname></term>
1175 <listitem>
1176 <para>Specifies the port to be used for the MACsec receive channel. The port is used to make
1177 secure channel identifier (SCI). Takes a value between 1 and 65535. This option is
1178 compulsory, and is not set by default.</para>
1179
1180 <xi:include href="version-info.xml" xpointer="v243"/>
1181 </listitem>
1182 </varlistentry>
1183 <varlistentry>
1184 <term><varname>MACAddress=</varname></term>
1185 <listitem>
1186 <para>Specifies the MAC address to be used for the MACsec receive channel. The MAC address
1187 used to make secure channel identifier (SCI). This setting is compulsory, and is not set by
1188 default.</para>
1189
1190 <xi:include href="version-info.xml" xpointer="v243"/>
1191 </listitem>
1192 </varlistentry>
1193 </variablelist>
1194 </refsect1>
1195
1196 <refsect1>
1197 <title>[MACsecTransmitAssociation] Section Options</title>
1198
1199 <para>The [MACsecTransmitAssociation] section only applies for network devices
1200 of kind <literal>macsec</literal>, and accepts the following keys:</para>
1201
1202 <variablelist class='network-directives'>
1203 <varlistentry>
1204 <term><varname>PacketNumber=</varname></term>
1205 <listitem>
1206 <para>Specifies the packet number to be used for replay protection and the construction of
1207 the initialization vector (along with the secure channel identifier [SCI]). Takes a value
1208 between 1-4,294,967,295. Defaults to unset.
1209 </para>
1210
1211 <xi:include href="version-info.xml" xpointer="v243"/>
1212 </listitem>
1213 </varlistentry>
1214 <varlistentry>
1215 <term><varname>KeyId=</varname></term>
1216 <listitem>
1217 <para>Specifies the identification for the key. Takes a number between 0-255. This option
1218 is compulsory, and is not set by default.</para>
1219
1220 <xi:include href="version-info.xml" xpointer="v243"/>
1221 </listitem>
1222 </varlistentry>
1223 <varlistentry>
1224 <term><varname>Key=</varname></term>
1225 <listitem>
1226 <para>Specifies the encryption key used in the transmission channel. The same key must be
1227 configured on the peer’s matching receive channel. This setting is compulsory, and is not set
1228 by default. Takes a 128-bit key encoded in a hexadecimal string, for example
1229 <literal>dffafc8d7b9a43d5b9a3dfbbf6a30c16</literal>.</para>
1230
1231 <xi:include href="version-info.xml" xpointer="v243"/>
1232 </listitem>
1233 </varlistentry>
1234 <varlistentry>
1235 <term><varname>KeyFile=</varname></term>
1236 <listitem>
1237 <para>Takes an absolute path to a file which contains a 128-bit key encoded in a hexadecimal string,
1238 which will be used in the transmission channel. When this option is specified,
1239 <varname>Key=</varname> is ignored. Note that the file must be readable by the user
1240 <literal>systemd-network</literal>, so it should be, e.g., owned by
1241 <literal>root:systemd-network</literal> with a <literal>0640</literal> file mode. If the path
1242 refers to an <constant>AF_UNIX</constant> stream socket in the file system a connection is made to
1243 it and the key read from it.</para>
1244
1245 <xi:include href="version-info.xml" xpointer="v243"/>
1246 </listitem>
1247 </varlistentry>
1248 <varlistentry>
1249 <term><varname>Activate=</varname></term>
1250 <listitem>
1251 <para>Takes a boolean. If enabled, then the security association is activated. Defaults to
1252 unset.</para>
1253
1254 <xi:include href="version-info.xml" xpointer="v243"/>
1255 </listitem>
1256 </varlistentry>
1257 <varlistentry>
1258 <term><varname>UseForEncoding=</varname></term>
1259 <listitem>
1260 <para>Takes a boolean. If enabled, then the security association is used for encoding. Only
1261 one [MACsecTransmitAssociation] section can enable this option. When enabled,
1262 <varname>Activate=yes</varname> is implied. Defaults to unset.</para>
1263
1264 <xi:include href="version-info.xml" xpointer="v243"/>
1265 </listitem>
1266 </varlistentry>
1267 </variablelist>
1268 </refsect1>
1269
1270 <refsect1>
1271 <title>[MACsecReceiveAssociation] Section Options</title>
1272
1273 <para>The [MACsecReceiveAssociation] section only applies for
1274 network devices of kind <literal>macsec</literal>, and accepts the
1275 following keys:</para>
1276
1277 <variablelist class='network-directives'>
1278 <varlistentry>
1279 <term><varname>Port=</varname></term>
1280 <listitem>
1281 <para>Accepts the same key as in [MACsecReceiveChannel] section.</para>
1282
1283 <xi:include href="version-info.xml" xpointer="v243"/>
1284 </listitem>
1285 </varlistentry>
1286 <varlistentry>
1287 <term><varname>MACAddress=</varname></term>
1288 <listitem>
1289 <para>Accepts the same key as in [MACsecReceiveChannel] section.</para>
1290
1291 <xi:include href="version-info.xml" xpointer="v243"/>
1292 </listitem>
1293 </varlistentry>
1294 <varlistentry>
1295 <term><varname>PacketNumber=</varname></term>
1296 <listitem>
1297 <para>Accepts the same key as in [MACsecTransmitAssociation] section.</para>
1298
1299 <xi:include href="version-info.xml" xpointer="v243"/>
1300 </listitem>
1301 </varlistentry>
1302 <varlistentry>
1303 <term><varname>KeyId=</varname></term>
1304 <listitem>
1305 <para>Accepts the same key as in [MACsecTransmitAssociation] section.</para>
1306
1307 <xi:include href="version-info.xml" xpointer="v243"/>
1308 </listitem>
1309 </varlistentry>
1310 <varlistentry>
1311 <term><varname>Key=</varname></term>
1312 <listitem>
1313 <para>Accepts the same key as in [MACsecTransmitAssociation] section.</para>
1314
1315 <xi:include href="version-info.xml" xpointer="v243"/>
1316 </listitem>
1317 </varlistentry>
1318 <varlistentry>
1319 <term><varname>KeyFile=</varname></term>
1320 <listitem>
1321 <para>Accepts the same key as in [MACsecTransmitAssociation] section.</para>
1322
1323 <xi:include href="version-info.xml" xpointer="v243"/>
1324 </listitem>
1325 </varlistentry>
1326 <varlistentry>
1327 <term><varname>Activate=</varname></term>
1328 <listitem>
1329 <para>Accepts the same key as in [MACsecTransmitAssociation] section.</para>
1330
1331 <xi:include href="version-info.xml" xpointer="v243"/>
1332 </listitem>
1333 </varlistentry>
1334 </variablelist>
1335 </refsect1>
1336
1337 <refsect1>
1338 <title>[Tunnel] Section Options</title>
1339
1340 <para>The [Tunnel] section only applies for
1341 netdevs of kind
1342 <literal>ipip</literal>,
1343 <literal>sit</literal>,
1344 <literal>gre</literal>,
1345 <literal>gretap</literal>,
1346 <literal>ip6gre</literal>,
1347 <literal>ip6gretap</literal>,
1348 <literal>vti</literal>,
1349 <literal>vti6</literal>,
1350 <literal>ip6tnl</literal>, and
1351 <literal>erspan</literal> and accepts
1352 the following keys:</para>
1353
1354 <variablelist class='network-directives'>
1355 <varlistentry>
1356 <term><varname>External=</varname></term>
1357 <listitem>
1358 <para>Takes a boolean value. When true, then the tunnel is externally controlled, which is
1359 also known as collect metadata mode, and most settings below like <varname>Local=</varname>
1360 or <varname>Remote=</varname> are ignored. This implies <varname>Independent=</varname>.
1361 Defaults to false.</para>
1362
1363 <xi:include href="version-info.xml" xpointer="v251"/>
1364 </listitem>
1365 </varlistentry>
1366 <varlistentry>
1367 <term><varname>Local=</varname></term>
1368 <listitem>
1369 <para>A static local address for tunneled packets. It must be an address on another interface
1370 of this host, or one of the special values <literal>any</literal>,
1371 <literal>ipv4_link_local</literal>, <literal>ipv6_link_local</literal>,
1372 <literal>dhcp4</literal>, <literal>dhcp6</literal>, and <literal>slaac</literal>. If one
1373 of the special values except for <literal>any</literal> is specified, an address which
1374 matches the corresponding type on the underlying interface will be used. Defaults to
1375 <literal>any</literal>.</para>
1376
1377 <xi:include href="version-info.xml" xpointer="v215"/>
1378 </listitem>
1379 </varlistentry>
1380 <varlistentry>
1381 <term><varname>Remote=</varname></term>
1382 <listitem>
1383 <para>The remote endpoint of the tunnel. Takes an IP address or the special value
1384 <literal>any</literal>.</para>
1385
1386 <xi:include href="version-info.xml" xpointer="v215"/>
1387 </listitem>
1388 </varlistentry>
1389 <varlistentry>
1390 <term><varname>TOS=</varname></term>
1391 <listitem>
1392 <para>The Type Of Service byte value for a tunnel interface.
1393 For details about the TOS, see the
1394 <ulink url="http://tools.ietf.org/html/rfc1349"> Type of
1395 Service in the Internet Protocol Suite </ulink> document.
1396 </para>
1397
1398 <xi:include href="version-info.xml" xpointer="v215"/>
1399 </listitem>
1400 </varlistentry>
1401 <varlistentry>
1402 <term><varname>TTL=</varname></term>
1403 <listitem>
1404 <para>A fixed Time To Live N on tunneled packets. N is a
1405 number in the range 1…255. 0 is a special value meaning that
1406 packets inherit the TTL value. The default value for IPv4
1407 tunnels is 0 (inherit). The default value for IPv6 tunnels is
1408 64.</para>
1409
1410 <xi:include href="version-info.xml" xpointer="v215"/>
1411 </listitem>
1412 </varlistentry>
1413 <varlistentry>
1414 <term><varname>DiscoverPathMTU=</varname></term>
1415 <listitem>
1416 <para>Takes a boolean. When true, enables Path MTU Discovery on
1417 the tunnel.
1418 When <varname>IgnoreDontFragment=</varname> is enabled,
1419 defaults to false. Otherwise, defaults to true.</para>
1420
1421 <xi:include href="version-info.xml" xpointer="v215"/>
1422 </listitem>
1423 </varlistentry>
1424 <varlistentry>
1425 <term><varname>IgnoreDontFragment=</varname></term>
1426 <listitem>
1427 <para>Takes a boolean. When true, enables IPv4 Don't Fragment (DF) suppression on
1428 the tunnel. Defaults to false.
1429 Note that if <varname>IgnoreDontFragment=</varname> is set to true,
1430 <varname>DiscoverPathMTU=</varname> cannot be set to true.
1431 Only applicable to GRE, GRETAP, and ERSPAN tunnels.</para>
1432
1433 <xi:include href="version-info.xml" xpointer="v254"/>
1434 </listitem>
1435 </varlistentry>
1436 <varlistentry>
1437 <term><varname>IPv6FlowLabel=</varname></term>
1438 <listitem>
1439 <para>Configures the 20-bit flow label (see <ulink url="https://tools.ietf.org/html/rfc6437">
1440 RFC 6437</ulink>) field in the IPv6 header (see <ulink url="https://tools.ietf.org/html/rfc2460">
1441 RFC 2460</ulink>), which is used by a node to label packets of a flow.
1442 It is only used for IPv6 tunnels.
1443 A flow label of zero is used to indicate packets that have
1444 not been labeled.
1445 It can be configured to a value in the range 0…0xFFFFF, or be
1446 set to <literal>inherit</literal>, in which case the original flowlabel is used.</para>
1447
1448 <xi:include href="version-info.xml" xpointer="v223"/>
1449 </listitem>
1450 </varlistentry>
1451 <varlistentry>
1452 <term><varname>CopyDSCP=</varname></term>
1453 <listitem>
1454 <para>Takes a boolean. When true, the Differentiated Service Code
1455 Point (DSCP) field will be copied to the inner header from
1456 outer header during the decapsulation of an IPv6 tunnel
1457 packet. DSCP is a field in an IP packet that enables different
1458 levels of service to be assigned to network traffic.
1459 Defaults to <literal>no</literal>.
1460 </para>
1461
1462 <xi:include href="version-info.xml" xpointer="v223"/>
1463 </listitem>
1464 </varlistentry>
1465 <varlistentry>
1466 <term><varname>EncapsulationLimit=</varname></term>
1467 <listitem>
1468 <para>The Tunnel Encapsulation Limit option specifies how many additional
1469 levels of encapsulation are permitted to be prepended to the packet.
1470 For example, a Tunnel Encapsulation Limit option containing a limit
1471 value of zero means that a packet carrying that option may not enter
1472 another tunnel before exiting the current tunnel.
1473 (see <ulink url="https://tools.ietf.org/html/rfc2473#section-4.1.1"> RFC 2473</ulink>).
1474 The valid range is 0…255 and <literal>none</literal>. Defaults to 4.
1475 </para>
1476
1477 <xi:include href="version-info.xml" xpointer="v226"/>
1478 </listitem>
1479 </varlistentry>
1480 <varlistentry>
1481 <term><varname>Key=</varname></term>
1482 <listitem>
1483 <para>The <varname>Key=</varname> parameter specifies the same key to use in
1484 both directions (<varname>InputKey=</varname> and <varname>OutputKey=</varname>).
1485 The <varname>Key=</varname> is either a number or an IPv4 address-like dotted quad.
1486 It is used as mark-configured SAD/SPD entry as part of the lookup key (both in data
1487 and control path) in IP XFRM (framework used to implement IPsec protocol).
1488 See <ulink url="https://man7.org/linux/man-pages/man8/ip-xfrm.8.html">
1489 ip-xfrm — transform configuration</ulink> for details. It is only used for VTI/VTI6,
1490 GRE, GRETAP, and ERSPAN tunnels.</para>
1491
1492 <xi:include href="version-info.xml" xpointer="v231"/>
1493 </listitem>
1494 </varlistentry>
1495 <varlistentry>
1496 <term><varname>InputKey=</varname></term>
1497 <listitem>
1498 <para>The <varname>InputKey=</varname> parameter specifies the key to use for input.
1499 The format is same as <varname>Key=</varname>. It is only used for VTI/VTI6, GRE, GRETAP,
1500 and ERSPAN tunnels.</para>
1501
1502 <xi:include href="version-info.xml" xpointer="v231"/>
1503 </listitem>
1504 </varlistentry>
1505 <varlistentry>
1506 <term><varname>OutputKey=</varname></term>
1507 <listitem>
1508 <para>The <varname>OutputKey=</varname> parameter specifies the key to use for output.
1509 The format is same as <varname>Key=</varname>. It is only used for VTI/VTI6, GRE, GRETAP,
1510 and ERSPAN tunnels.</para>
1511
1512 <xi:include href="version-info.xml" xpointer="v231"/>
1513 </listitem>
1514 </varlistentry>
1515 <varlistentry>
1516 <term><varname>Mode=</varname></term>
1517 <listitem>
1518 <para>An <literal>ip6tnl</literal> tunnel can be in one of three
1519 modes
1520 <literal>ip6ip6</literal> for IPv6 over IPv6,
1521 <literal>ipip6</literal> for IPv4 over IPv6 or
1522 <literal>any</literal> for either.
1523 </para>
1524
1525 <xi:include href="version-info.xml" xpointer="v219"/>
1526 </listitem>
1527 </varlistentry>
1528 <varlistentry>
1529 <term><varname>Independent=</varname></term>
1530 <listitem>
1531 <para>Takes a boolean. When false (the default), the tunnel is always created over some network
1532 device, and a .network file that requests this tunnel using <varname>Tunnel=</varname> is required
1533 for the tunnel to be created. When true, the tunnel is created independently of any network as
1534 "tunnel@NONE".</para>
1535
1536 <xi:include href="version-info.xml" xpointer="v235"/>
1537 </listitem>
1538 </varlistentry>
1539 <varlistentry>
1540 <term><varname>AssignToLoopback=</varname></term>
1541 <listitem>
1542 <para>Takes a boolean. If set to <literal>yes</literal>, the loopback interface <literal>lo</literal>
1543 is used as the underlying device of the tunnel interface. Defaults to <literal>no</literal>.</para>
1544
1545 <xi:include href="version-info.xml" xpointer="v243"/>
1546 </listitem>
1547 </varlistentry>
1548 <varlistentry>
1549 <term><varname>AllowLocalRemote=</varname></term>
1550 <listitem>
1551 <para>Takes a boolean. When true allows tunnel traffic on <varname>ip6tnl</varname> devices where the remote endpoint is a local host address.
1552 When unset, the kernel's default will be used.
1553 </para>
1554
1555 <xi:include href="version-info.xml" xpointer="v237"/>
1556 </listitem>
1557 </varlistentry>
1558 <varlistentry>
1559 <term><varname>FooOverUDP=</varname></term>
1560 <listitem>
1561 <para>Takes a boolean. Specifies whether <varname>FooOverUDP=</varname> tunnel is to be configured.
1562 Defaults to false. This takes effects only for IPIP, SIT, GRE, and GRETAP tunnels.
1563 For more detail information see
1564 <ulink url="https://lwn.net/Articles/614348">Foo over UDP</ulink></para>
1565
1566 <xi:include href="version-info.xml" xpointer="v240"/>
1567 </listitem>
1568 </varlistentry>
1569 <varlistentry>
1570 <term><varname>FOUDestinationPort=</varname></term>
1571 <listitem>
1572 <para>This setting specifies the UDP destination port for encapsulation.
1573 This field is mandatory when <varname>FooOverUDP=yes</varname>, and is not set by default.</para>
1574
1575 <xi:include href="version-info.xml" xpointer="v240"/>
1576 </listitem>
1577 </varlistentry>
1578 <varlistentry>
1579 <term><varname>FOUSourcePort=</varname></term>
1580 <listitem>
1581 <para>This setting specifies the UDP source port for encapsulation. Defaults to <constant>0</constant>
1582 — that is, the source port for packets is left to the network stack to decide.</para>
1583
1584 <xi:include href="version-info.xml" xpointer="v240"/>
1585 </listitem>
1586 </varlistentry>
1587 <varlistentry>
1588 <term><varname>Encapsulation=</varname></term>
1589 <listitem>
1590 <para>Accepts the same key as in the [FooOverUDP] section.</para>
1591
1592 <xi:include href="version-info.xml" xpointer="v240"/>
1593 </listitem>
1594 </varlistentry>
1595 <varlistentry>
1596 <term><varname>IPv6RapidDeploymentPrefix=</varname></term>
1597 <listitem>
1598 <para>Reconfigure the tunnel for <ulink url="https://tools.ietf.org/html/rfc5569">IPv6 Rapid
1599 Deployment</ulink>, also known as 6rd. The value is an ISP-specific IPv6 prefix with a non-zero length. Only
1600 applicable to SIT tunnels.</para>
1601
1602 <xi:include href="version-info.xml" xpointer="v240"/>
1603 </listitem>
1604 </varlistentry>
1605 <varlistentry>
1606 <term><varname>ISATAP=</varname></term>
1607 <listitem>
1608 <para>Takes a boolean. If set, configures the tunnel as Intra-Site Automatic Tunnel Addressing Protocol (ISATAP) tunnel.
1609 Only applicable to SIT tunnels. When unset, the kernel's default will be used.</para>
1610
1611 <xi:include href="version-info.xml" xpointer="v240"/>
1612 </listitem>
1613 </varlistentry>
1614 <varlistentry>
1615 <term><varname>SerializeTunneledPackets=</varname></term>
1616 <listitem>
1617 <para>Takes a boolean. If set to yes, then packets are serialized. Only applies for GRE,
1618 GRETAP, and ERSPAN tunnels. When unset, the kernel's default will be used.
1619 </para>
1620
1621 <xi:include href="version-info.xml" xpointer="v240"/>
1622 </listitem>
1623 </varlistentry>
1624 <varlistentry>
1625 <term><varname>ERSPANVersion=</varname></term>
1626 <listitem>
1627 <para>Specifies the ERSPAN version number. Takes 0 for version 0 (a.k.a. type I), 1 for version 1
1628 (a.k.a. type II), or 2 for version 2 (a.k.a. type III). Defaults to 1.</para>
1629
1630 <xi:include href="version-info.xml" xpointer="v252"/>
1631 </listitem>
1632 </varlistentry>
1633 <varlistentry>
1634 <term><varname>ERSPANIndex=</varname></term>
1635 <listitem>
1636 <para>Specifies the ERSPAN v1 index field for the interface. Takes an integer in the range
1637 0…1048575, which is associated with the ERSPAN traffic's source port and direction. Only used when
1638 <varname>ERSPANVersion=1</varname>. Defaults to 0.</para>
1639
1640 <xi:include href="version-info.xml" xpointer="v240"/>
1641 </listitem>
1642 </varlistentry>
1643 <varlistentry>
1644 <term><varname>ERSPANDirection=</varname></term>
1645 <listitem>
1646 <para>Specifies the ERSPAN v2 mirrored traffic's direction. Takes <literal>ingress</literal> or
1647 <literal>egress</literal>. Only used when <varname>ERSPANVersion=2</varname>. Defaults to
1648 <literal>ingress</literal>.</para>
1649
1650 <xi:include href="version-info.xml" xpointer="v252"/>
1651 </listitem>
1652 </varlistentry>
1653 <varlistentry>
1654 <term><varname>ERSPANHardwareId=</varname></term>
1655 <listitem>
1656 <para>Specifies an unique identifier of the ERSPAN v2 engine. Takes an integer in the range 0…63.
1657 Only used when <varname>ERSPANVersion=2</varname>. Defaults to 0.</para>
1658
1659 <xi:include href="version-info.xml" xpointer="v252"/>
1660 </listitem>
1661 </varlistentry>
1662 </variablelist>
1663 </refsect1>
1664
1665 <refsect1>
1666 <title>[FooOverUDP] Section Options</title>
1667
1668 <para>The [FooOverUDP] section only applies for
1669 netdevs of kind <literal>fou</literal> and accepts the
1670 following keys:</para>
1671
1672 <variablelist class='network-directives'>
1673 <varlistentry>
1674 <term><varname>Encapsulation=</varname></term>
1675 <listitem>
1676 <para>Specifies the encapsulation mechanism used to store networking packets of various protocols
1677 inside the UDP packets. Supports the following values:
1678
1679 <literal>FooOverUDP</literal> provides the simplest no-frills model of UDP encapsulation, it simply
1680 encapsulates packets directly in the UDP payload. <literal>GenericUDPEncapsulation</literal> is a
1681 generic and extensible encapsulation, it allows encapsulation of packets for any IP protocol and
1682 optional data as part of the encapsulation. For more detailed information see <ulink
1683 url="https://lwn.net/Articles/615044">Generic UDP Encapsulation</ulink>. Defaults to
1684 <literal>FooOverUDP</literal>.
1685 </para>
1686
1687 <xi:include href="version-info.xml" xpointer="v240"/>
1688 </listitem>
1689 </varlistentry>
1690 <varlistentry>
1691 <term><varname>Port=</varname></term>
1692 <listitem>
1693 <para>Specifies the port number where the encapsulated packets will arrive. Those packets will be
1694 removed and manually fed back into the network stack with the encapsulation removed to be sent to
1695 the real destination. This option is mandatory.</para>
1696
1697 <xi:include href="version-info.xml" xpointer="v240"/>
1698 </listitem>
1699 </varlistentry>
1700 <varlistentry>
1701 <term><varname>PeerPort=</varname></term>
1702 <listitem>
1703 <para>Specifies the peer port number. Defaults to unset. Note that when peer port is set
1704 <literal>Peer=</literal> address is mandatory.</para>
1705
1706 <xi:include href="version-info.xml" xpointer="v243"/>
1707 </listitem>
1708 </varlistentry>
1709 <varlistentry>
1710 <term><varname>Protocol=</varname></term>
1711 <listitem>
1712 <para>The <varname>Protocol=</varname> specifies the protocol number of the packets arriving
1713 at the UDP port. When <varname>Encapsulation=FooOverUDP</varname>, this field is mandatory
1714 and is not set by default. Takes an IP protocol name such as <literal>gre</literal> or
1715 <literal>ipip</literal>, or an integer within the range 1…255. When
1716 <varname>Encapsulation=GenericUDPEncapsulation</varname>, this must not be specified.</para>
1717
1718 <xi:include href="version-info.xml" xpointer="v240"/>
1719 </listitem>
1720 </varlistentry>
1721 <varlistentry>
1722 <term><varname>Peer=</varname></term>
1723 <listitem>
1724 <para>Configures peer IP address. Note that when peer address is set <literal>PeerPort=</literal>
1725 is mandatory.</para>
1726
1727 <xi:include href="version-info.xml" xpointer="v243"/>
1728 </listitem>
1729 </varlistentry>
1730 <varlistentry>
1731 <term><varname>Local=</varname></term>
1732 <listitem>
1733 <para>Configures local IP address.</para>
1734
1735 <xi:include href="version-info.xml" xpointer="v243"/>
1736 </listitem>
1737 </varlistentry>
1738 </variablelist>
1739 </refsect1>
1740
1741 <refsect1>
1742 <title>[Peer] Section Options</title>
1743
1744 <para>The [Peer] section only applies for
1745 netdevs of kind <literal>veth</literal> and accepts the
1746 following keys:</para>
1747
1748 <variablelist class='network-directives'>
1749 <varlistentry>
1750 <term><varname>Name=</varname></term>
1751 <listitem>
1752 <para>The interface name used when creating the netdev.
1753 This setting is compulsory.</para>
1754
1755 <xi:include href="version-info.xml" xpointer="v215"/>
1756 </listitem>
1757 </varlistentry>
1758 <varlistentry>
1759 <term><varname>MACAddress=</varname></term>
1760 <listitem>
1761 <para>The peer MACAddress, if not set, it is generated in
1762 the same way as the MAC address of the main
1763 interface.</para>
1764
1765 <xi:include href="version-info.xml" xpointer="v215"/>
1766 </listitem>
1767 </varlistentry>
1768 </variablelist>
1769 </refsect1>
1770
1771 <refsect1>
1772 <title>[VXCAN] Section Options</title>
1773
1774 <para>The [VXCAN] section only applies for
1775 netdevs of kind <literal>vxcan</literal> and accepts the
1776 following key:</para>
1777
1778 <variablelist class='network-directives'>
1779 <varlistentry>
1780 <term><varname>Peer=</varname></term>
1781 <listitem>
1782 <para>The peer interface name used when creating the netdev.
1783 This setting is compulsory.</para>
1784
1785 <xi:include href="version-info.xml" xpointer="v236"/>
1786 </listitem>
1787 </varlistentry>
1788 </variablelist>
1789 </refsect1>
1790
1791 <refsect1>
1792 <title>[Tun] Section Options</title>
1793
1794 <para>The [Tun] section only applies for
1795 netdevs of kind <literal>tun</literal>, and accepts the following
1796 keys:</para>
1797
1798 <variablelist class='network-directives'>
1799 <varlistentry>
1800 <term><varname>MultiQueue=</varname></term>
1801 <listitem><para>Takes a boolean. Configures whether
1802 to use multiple file descriptors (queues) to parallelize
1803 packets sending and receiving. Defaults to
1804 <literal>no</literal>.</para>
1805
1806 <xi:include href="version-info.xml" xpointer="v215"/>
1807 </listitem>
1808 </varlistentry>
1809 <varlistentry>
1810 <term><varname>PacketInfo=</varname></term>
1811 <listitem><para>Takes a boolean. Configures whether
1812 packets should be prepended with four extra bytes (two flag
1813 bytes and two protocol bytes). If disabled, it indicates that
1814 the packets will be pure IP packets. Defaults to
1815 <literal>no</literal>.</para>
1816
1817 <xi:include href="version-info.xml" xpointer="v215"/>
1818 </listitem>
1819 </varlistentry>
1820 <varlistentry>
1821 <term><varname>VNetHeader=</varname></term>
1822 <listitem><para>Takes a boolean. Configures
1823 IFF_VNET_HDR flag for a tun or tap device. It allows sending
1824 and receiving larger Generic Segmentation Offload (GSO)
1825 packets. This may increase throughput significantly.
1826 Defaults to
1827 <literal>no</literal>.</para>
1828
1829 <xi:include href="version-info.xml" xpointer="v223"/>
1830 </listitem>
1831 </varlistentry>
1832 <varlistentry>
1833 <term><varname>User=</varname></term>
1834 <listitem><para>User to grant access to the
1835 <filename>/dev/net/tun</filename> device.</para>
1836
1837 <xi:include href="version-info.xml" xpointer="v215"/>
1838 </listitem>
1839 </varlistentry>
1840 <varlistentry>
1841 <term><varname>Group=</varname></term>
1842 <listitem><para>Group to grant access to the
1843 <filename>/dev/net/tun</filename> device.</para>
1844
1845 <xi:include href="version-info.xml" xpointer="v215"/>
1846 </listitem>
1847 </varlistentry>
1848 <varlistentry>
1849 <term><varname>KeepCarrier=</varname></term>
1850 <listitem>
1851 <para>Takes a boolean. If enabled, to make the interface maintain its carrier status, the file
1852 descriptor of the interface is kept open. This may be useful to keep the interface in running
1853 state, for example while the backing process is temporarily shutdown. Defaults to
1854 <literal>no</literal>.</para>
1855
1856 <xi:include href="version-info.xml" xpointer="v252"/>
1857 </listitem>
1858 </varlistentry>
1859 </variablelist>
1860 </refsect1>
1861
1862 <refsect1>
1863 <title>[Tap] Section Options</title>
1864
1865 <para>The [Tap] section only applies for
1866 netdevs of kind <literal>tap</literal>, and accepts the same keys
1867 as the [Tun] section.</para>
1868 </refsect1>
1869
1870 <refsect1>
1871 <title>[WireGuard] Section Options</title>
1872
1873 <para>The [WireGuard] section accepts the following
1874 keys:</para>
1875
1876 <variablelist class='network-directives'>
1877 <varlistentry>
1878 <term><varname>PrivateKey=</varname></term>
1879 <listitem>
1880 <para>The Base64 encoded private key for the interface. It can be
1881 generated using the <command>wg genkey</command> command
1882 (see <citerefentry project="wireguard"><refentrytitle>wg</refentrytitle><manvolnum>8</manvolnum></citerefentry>).
1883 This option or <varname>PrivateKeyFile=</varname> is mandatory to use WireGuard.
1884 Note that because this information is secret, you may want to set
1885 the permissions of the .netdev file to be owned by <literal>root:systemd-network</literal>
1886 with a <literal>0640</literal> file mode.</para>
1887
1888 <xi:include href="version-info.xml" xpointer="v237"/>
1889 </listitem>
1890 </varlistentry>
1891 <varlistentry>
1892 <term><varname>PrivateKeyFile=</varname></term>
1893 <listitem>
1894 <para>Takes an absolute path to a file which contains the Base64 encoded private key for the
1895 interface. When this option is specified, then <varname>PrivateKey=</varname> is ignored. Note
1896 that the file must be readable by the user <literal>systemd-network</literal>, so it should be,
1897 e.g., owned by <literal>root:systemd-network</literal> with a <literal>0640</literal> file mode. If
1898 the path refers to an <constant>AF_UNIX</constant> stream socket in the file system a connection is
1899 made to it and the key read from it.</para>
1900
1901 <xi:include href="version-info.xml" xpointer="v242"/>
1902 </listitem>
1903 </varlistentry>
1904 <varlistentry>
1905 <term><varname>ListenPort=</varname></term>
1906 <listitem>
1907 <para>Sets UDP port for listening. Takes either value between 1 and 65535
1908 or <literal>auto</literal>. If <literal>auto</literal> is specified,
1909 the port is automatically generated based on interface name.
1910 Defaults to <literal>auto</literal>.</para>
1911
1912 <xi:include href="version-info.xml" xpointer="v237"/>
1913 </listitem>
1914 </varlistentry>
1915 <varlistentry>
1916 <term><varname>FirewallMark=</varname></term>
1917 <listitem>
1918 <para>Sets a firewall mark on outgoing WireGuard packets from this interface. Takes a number between 1 and 4294967295.</para>
1919
1920 <xi:include href="version-info.xml" xpointer="v243"/>
1921 </listitem>
1922 </varlistentry>
1923 <varlistentry>
1924 <term><varname>RouteTable=</varname></term>
1925 <listitem>
1926 <para>The table identifier for the routes to the addresses specified in the
1927 <varname>AllowedIPs=</varname>. Takes a negative boolean value, one of the predefined names
1928 <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, names
1929 defined in <varname>RouteTable=</varname> in
1930 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
1931 or a number in the range 1…4294967295. When <literal>off</literal> the routes to the
1932 addresses specified in the <varname>AllowedIPs=</varname> setting will not be configured.
1933 Defaults to false. This setting will be ignored when the same setting is specified in the
1934 [WireGuardPeer] section.</para>
1935
1936 <xi:include href="version-info.xml" xpointer="v250"/>
1937 </listitem>
1938 </varlistentry>
1939 <varlistentry>
1940 <term><varname>RouteMetric=</varname></term>
1941 <listitem>
1942 <para>The priority of the routes to the addresses specified in the
1943 <varname>AllowedIPs=</varname>. Takes an integer in the range 0…4294967295. Defaults to 0
1944 for IPv4 addresses, and 1024 for IPv6 addresses. This setting will be ignored when the same
1945 setting is specified in the [WireGuardPeer] section.</para>
1946
1947 <xi:include href="version-info.xml" xpointer="v250"/>
1948 </listitem>
1949 </varlistentry>
1950 </variablelist>
1951 </refsect1>
1952
1953 <refsect1>
1954 <title>[WireGuardPeer] Section Options</title>
1955
1956 <para>The [WireGuardPeer] section accepts the following
1957 keys:</para>
1958
1959 <variablelist class='network-directives'>
1960 <varlistentry>
1961 <term><varname>PublicKey=</varname></term>
1962 <listitem>
1963 <para>Sets a Base64 encoded public key calculated by <command>wg pubkey</command>
1964 (see <citerefentry project="wireguard"><refentrytitle>wg</refentrytitle><manvolnum>8</manvolnum></citerefentry>)
1965 from a private key, and usually transmitted out of band to the
1966 author of the configuration file. This option is mandatory for this
1967 section.</para>
1968
1969 <xi:include href="version-info.xml" xpointer="v237"/>
1970 </listitem>
1971 </varlistentry>
1972 <varlistentry>
1973 <term><varname>PresharedKey=</varname></term>
1974 <listitem>
1975 <para>Optional preshared key for the interface. It can be generated
1976 by the <command>wg genpsk</command> command. This option adds an
1977 additional layer of symmetric-key cryptography to be mixed into the
1978 already existing public-key cryptography, for post-quantum
1979 resistance.
1980 Note that because this information is secret, you may want to set
1981 the permissions of the .netdev file to be owned by <literal>root:systemd-network</literal>
1982 with a <literal>0640</literal> file mode.</para>
1983
1984 <xi:include href="version-info.xml" xpointer="v237"/>
1985 </listitem>
1986 </varlistentry>
1987 <varlistentry>
1988 <term><varname>PresharedKeyFile=</varname></term>
1989 <listitem>
1990 <para>Takes an absolute path to a file which contains the Base64 encoded preshared key for the
1991 peer. When this option is specified, then <varname>PresharedKey=</varname> is ignored. Note that
1992 the file must be readable by the user <literal>systemd-network</literal>, so it should be, e.g.,
1993 owned by <literal>root:systemd-network</literal> with a <literal>0640</literal> file mode. If the
1994 path refers to an <constant>AF_UNIX</constant> stream socket in the file system a connection is
1995 made to it and the key read from it.</para>
1996
1997 <xi:include href="version-info.xml" xpointer="v242"/>
1998 </listitem>
1999 </varlistentry>
2000 <varlistentry>
2001 <term><varname>AllowedIPs=</varname></term>
2002 <listitem>
2003 <para>Sets a comma-separated list of IP (v4 or v6) addresses with CIDR masks from which this peer
2004 is allowed to send incoming traffic and to which outgoing traffic for this peer is directed. This
2005 setting can be specified multiple times. If an empty string is assigned, then the all previous
2006 assignments are cleared.</para>
2007
2008 <para>The catch-all 0.0.0.0/0 may be specified for matching all IPv4 addresses,
2009 and ::/0 may be specified for matching all IPv6 addresses.</para>
2010
2011 <para>Note that this only affects <emphasis>routing inside the network interface itself</emphasis>,
2012 i.e. the packets that pass through the tunnel itself. To cause packets to be sent via the tunnel in
2013 the first place, an appropriate route needs to be added as well — either in the
2014 <literal>[Routes]</literal> section on the <literal>.network</literal> matching the wireguard
2015 interface, or externally to <filename>systemd-networkd</filename>.</para>
2016
2017 <xi:include href="version-info.xml" xpointer="v237"/>
2018 </listitem>
2019 </varlistentry>
2020 <varlistentry>
2021 <term><varname>Endpoint=</varname></term>
2022 <listitem>
2023 <para>Sets an endpoint IP address or hostname, followed by a colon, and then
2024 a port number. IPv6 address must be in the square brackets. For example,
2025 <literal>111.222.333.444:51820</literal> for IPv4 and <literal>[1111:2222::3333]:51820</literal>
2026 for IPv6 address. This endpoint will be updated automatically once to
2027 the most recent source IP address and port of correctly
2028 authenticated packets from the peer at configuration time.</para>
2029
2030 <xi:include href="version-info.xml" xpointer="v237"/>
2031 </listitem>
2032 </varlistentry>
2033 <varlistentry>
2034 <term><varname>PersistentKeepalive=</varname></term>
2035 <listitem>
2036 <para>Sets a seconds interval, between 1 and 65535 inclusive, of how often
2037 to send an authenticated empty packet to the peer for the purpose
2038 of keeping a stateful firewall or NAT mapping valid persistently.
2039 For example, if the interface very rarely sends traffic, but it
2040 might at anytime receive traffic from a peer, and it is behind NAT,
2041 the interface might benefit from having a persistent keepalive
2042 interval of 25 seconds. If set to 0 or "off", this option is
2043 disabled. By default or when unspecified, this option is off.
2044 Most users will not need this.</para>
2045
2046 <xi:include href="version-info.xml" xpointer="v237"/>
2047 </listitem>
2048 </varlistentry>
2049 <varlistentry>
2050 <term><varname>RouteTable=</varname></term>
2051 <listitem>
2052 <para>The table identifier for the routes to the addresses specified in the
2053 <varname>AllowedIPs=</varname>. Takes a negative boolean value, one of the predefined names
2054 <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, names
2055 defined in <varname>RouteTable=</varname> in
2056 <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2057 or a number in the range 1…4294967295. Defaults to unset, and the value specified in the
2058 same setting in the [WireGuard] section will be used.</para>
2059
2060 <xi:include href="version-info.xml" xpointer="v250"/>
2061 </listitem>
2062 </varlistentry>
2063 <varlistentry>
2064 <term><varname>RouteMetric=</varname></term>
2065 <listitem>
2066 <para>The priority of the routes to the addresses specified in the
2067 <varname>AllowedIPs=</varname>. Takes an integer in the range 0…4294967295. Defaults to
2068 unset, and the value specified in the same setting in the [WireGuard] section will be used.
2069 </para>
2070
2071 <xi:include href="version-info.xml" xpointer="v250"/>
2072 </listitem>
2073 </varlistentry>
2074 </variablelist>
2075 </refsect1>
2076
2077 <refsect1>
2078 <title>[Bond] Section Options</title>
2079
2080 <para>The [Bond] section accepts the following
2081 key:</para>
2082
2083 <variablelist class='network-directives'>
2084 <varlistentry>
2085 <term><varname>Mode=</varname></term>
2086 <listitem>
2087 <para>Specifies one of the bonding policies. The default is
2088 <literal>balance-rr</literal> (round robin). Possible values are
2089 <literal>balance-rr</literal>,
2090 <literal>active-backup</literal>,
2091 <literal>balance-xor</literal>,
2092 <literal>broadcast</literal>,
2093 <literal>802.3ad</literal>,
2094 <literal>balance-tlb</literal>, and
2095 <literal>balance-alb</literal>.
2096 </para>
2097
2098 <xi:include href="version-info.xml" xpointer="v216"/>
2099 </listitem>
2100 </varlistentry>
2101
2102 <varlistentry>
2103 <term><varname>TransmitHashPolicy=</varname></term>
2104 <listitem>
2105 <para>Selects the transmit hash policy to use for slave
2106 selection in balance-xor, 802.3ad, and tlb modes. Possible
2107 values are
2108 <literal>layer2</literal>,
2109 <literal>layer3+4</literal>,
2110 <literal>layer2+3</literal>,
2111 <literal>encap2+3</literal>, and
2112 <literal>encap3+4</literal>.
2113 </para>
2114
2115 <xi:include href="version-info.xml" xpointer="v216"/>
2116 </listitem>
2117 </varlistentry>
2118
2119 <varlistentry>
2120 <term><varname>LACPTransmitRate=</varname></term>
2121 <listitem>
2122 <para>Specifies the rate with which link partner transmits
2123 Link Aggregation Control Protocol Data Unit packets in
2124 802.3ad mode. Possible values are <literal>slow</literal>,
2125 which requests partner to transmit LACPDUs every 30 seconds,
2126 and <literal>fast</literal>, which requests partner to
2127 transmit LACPDUs every second. The default value is
2128 <literal>slow</literal>.</para>
2129
2130 <xi:include href="version-info.xml" xpointer="v216"/>
2131 </listitem>
2132 </varlistentry>
2133
2134 <varlistentry>
2135 <term><varname>MIIMonitorSec=</varname></term>
2136 <listitem>
2137 <para>Specifies the frequency that Media Independent
2138 Interface link monitoring will occur. A value of zero
2139 disables MII link monitoring. This value is rounded down to
2140 the nearest millisecond. The default value is 0.</para>
2141
2142 <xi:include href="version-info.xml" xpointer="v216"/>
2143 </listitem>
2144 </varlistentry>
2145
2146 <varlistentry>
2147 <term><varname>UpDelaySec=</varname></term>
2148 <listitem>
2149 <para>Specifies the delay before a link is enabled after a
2150 link up status has been detected. This value is rounded down
2151 to a multiple of <varname>MIIMonitorSec=</varname>. The default value is
2152 0.</para>
2153
2154 <xi:include href="version-info.xml" xpointer="v216"/>
2155 </listitem>
2156 </varlistentry>
2157
2158 <varlistentry>
2159 <term><varname>DownDelaySec=</varname></term>
2160 <listitem>
2161 <para>Specifies the delay before a link is disabled after a
2162 link down status has been detected. This value is rounded
2163 down to a multiple of <varname>MIIMonitorSec=</varname>. The default value is
2164 0.</para>
2165
2166 <xi:include href="version-info.xml" xpointer="v216"/>
2167 </listitem>
2168 </varlistentry>
2169
2170 <varlistentry>
2171 <term><varname>LearnPacketIntervalSec=</varname></term>
2172 <listitem>
2173 <para>Specifies the number of seconds between instances where the bonding
2174 driver sends learning packets to each slave peer switch.
2175 The valid range is 1…0x7fffffff; the default value is 1. This option
2176 has an effect only for the balance-tlb and balance-alb modes.</para>
2177
2178 <xi:include href="version-info.xml" xpointer="v220"/>
2179 </listitem>
2180 </varlistentry>
2181
2182 <varlistentry>
2183 <term><varname>AdSelect=</varname></term>
2184 <listitem>
2185 <para>Specifies the 802.3ad aggregation selection logic to use. Possible values are
2186 <literal>stable</literal>,
2187 <literal>bandwidth</literal> and
2188 <literal>count</literal>.
2189 </para>
2190
2191 <xi:include href="version-info.xml" xpointer="v220"/>
2192 </listitem>
2193 </varlistentry>
2194
2195 <varlistentry>
2196 <term><varname>AdActorSystemPriority=</varname></term>
2197 <listitem>
2198 <para>Specifies the 802.3ad actor system priority. Takes a number in the range 1…65535.</para>
2199
2200 <xi:include href="version-info.xml" xpointer="v240"/>
2201 </listitem>
2202 </varlistentry>
2203
2204 <varlistentry>
2205 <term><varname>AdUserPortKey=</varname></term>
2206 <listitem>
2207 <para>Specifies the 802.3ad user defined portion of the port key. Takes a number in the range
2208 0…1023.</para>
2209
2210 <xi:include href="version-info.xml" xpointer="v240"/>
2211 </listitem>
2212 </varlistentry>
2213
2214 <varlistentry>
2215 <term><varname>AdActorSystem=</varname></term>
2216 <listitem>
2217 <para>Specifies the 802.3ad system MAC address. This cannot be a null or multicast address.
2218 </para>
2219
2220 <xi:include href="version-info.xml" xpointer="v240"/>
2221 </listitem>
2222 </varlistentry>
2223
2224 <varlistentry>
2225 <term><varname>FailOverMACPolicy=</varname></term>
2226 <listitem>
2227 <para>Specifies whether the active-backup mode should set all slaves to
2228 the same MAC address at the time of enslavement or, when enabled, to perform special handling of the
2229 bond's MAC address in accordance with the selected policy. The default policy is none.
2230 Possible values are
2231 <literal>none</literal>,
2232 <literal>active</literal> and
2233 <literal>follow</literal>.
2234 </para>
2235
2236 <xi:include href="version-info.xml" xpointer="v220"/>
2237 </listitem>
2238 </varlistentry>
2239
2240 <varlistentry>
2241 <term><varname>ARPValidate=</varname></term>
2242 <listitem>
2243 <para>Specifies whether or not ARP probes and replies should be
2244 validated in any mode that supports ARP monitoring, or whether
2245 non-ARP traffic should be filtered (disregarded) for link
2246 monitoring purposes. Possible values are
2247 <literal>none</literal>,
2248 <literal>active</literal>,
2249 <literal>backup</literal> and
2250 <literal>all</literal>.
2251 </para>
2252
2253 <xi:include href="version-info.xml" xpointer="v220"/>
2254 </listitem>
2255 </varlistentry>
2256
2257 <varlistentry>
2258 <term><varname>ARPIntervalSec=</varname></term>
2259 <listitem>
2260 <para>Specifies the ARP link monitoring frequency. A value of 0 disables ARP monitoring. The
2261 default value is 0, and the default unit seconds.
2262 </para>
2263
2264 <xi:include href="version-info.xml" xpointer="v220"/>
2265 </listitem>
2266 </varlistentry>
2267
2268 <varlistentry>
2269 <term><varname>ARPIPTargets=</varname></term>
2270 <listitem>
2271 <para>Specifies the IP addresses to use as ARP monitoring peers when
2272 <varname>ARPIntervalSec=</varname> is greater than 0. These are the targets of the ARP
2273 request sent to determine the health of the link to the targets.
2274 Specify these values in IPv4 dotted decimal format. At least one IP
2275 address must be given for ARP monitoring to function. The
2276 maximum number of targets that can be specified is 16. The
2277 default value is no IP addresses.
2278 </para>
2279
2280 <xi:include href="version-info.xml" xpointer="v220"/>
2281 </listitem>
2282 </varlistentry>
2283
2284 <varlistentry>
2285 <term><varname>ARPAllTargets=</varname></term>
2286 <listitem>
2287 <para>Specifies the quantity of <varname>ARPIPTargets=</varname> that must be reachable
2288 in order for the ARP monitor to consider a slave as being up.
2289 This option affects only active-backup mode for slaves with
2290 ARPValidate enabled. Possible values are
2291 <literal>any</literal> and
2292 <literal>all</literal>.
2293 </para>
2294
2295 <xi:include href="version-info.xml" xpointer="v220"/>
2296 </listitem>
2297 </varlistentry>
2298
2299 <varlistentry>
2300 <term><varname>PrimaryReselectPolicy=</varname></term>
2301 <listitem>
2302 <para>Specifies the reselection policy for the primary slave. This
2303 affects how the primary slave is chosen to become the active slave
2304 when failure of the active slave or recovery of the primary slave
2305 occurs. This option is designed to prevent flip-flopping between
2306 the primary slave and other slaves. Possible values are
2307 <literal>always</literal>,
2308 <literal>better</literal> and
2309 <literal>failure</literal>.
2310 </para>
2311
2312 <xi:include href="version-info.xml" xpointer="v220"/>
2313 </listitem>
2314 </varlistentry>
2315
2316 <varlistentry>
2317 <term><varname>ResendIGMP=</varname></term>
2318 <listitem>
2319 <para>Specifies the number of IGMP membership reports to be issued after
2320 a failover event. One membership report is issued immediately after
2321 the failover, subsequent packets are sent in each 200ms interval.
2322 The valid range is 0…255. Defaults to 1. A value of 0
2323 prevents the IGMP membership report from being issued in response
2324 to the failover event.
2325 </para>
2326
2327 <xi:include href="version-info.xml" xpointer="v220"/>
2328 </listitem>
2329 </varlistentry>
2330
2331 <varlistentry>
2332 <term><varname>PacketsPerSlave=</varname></term>
2333 <listitem>
2334 <para>Specify the number of packets to transmit through a slave before
2335 moving to the next one. When set to 0, then a slave is chosen at
2336 random. The valid range is 0…65535. Defaults to 1. This option
2337 only has effect when in balance-rr mode.
2338 </para>
2339
2340 <xi:include href="version-info.xml" xpointer="v220"/>
2341 </listitem>
2342 </varlistentry>
2343
2344 <varlistentry>
2345 <term><varname>GratuitousARP=</varname></term>
2346 <listitem>
2347 <para>Specify the number of peer notifications (gratuitous ARPs and
2348 unsolicited IPv6 Neighbor Advertisements) to be issued after a
2349 failover event. As soon as the link is up on the new slave,
2350 a peer notification is sent on the bonding device and each
2351 VLAN sub-device. This is repeated at each link monitor interval
2352 (ARPIntervalSec or MIIMonitorSec, whichever is active) if the number is
2353 greater than 1. The valid range is 0…255. The default value is 1.
2354 These options affect only the active-backup mode.
2355 </para>
2356
2357 <xi:include href="version-info.xml" xpointer="v220"/>
2358 </listitem>
2359 </varlistentry>
2360
2361 <varlistentry>
2362 <term><varname>AllSlavesActive=</varname></term>
2363 <listitem>
2364 <para>Takes a boolean. Specifies that duplicate frames (received on inactive ports)
2365 should be dropped when false, or delivered when true. Normally, bonding will drop
2366 duplicate frames (received on inactive ports), which is desirable for
2367 most users. But there are some times it is nice to allow duplicate
2368 frames to be delivered. The default value is false (drop duplicate frames
2369 received on inactive ports).
2370 </para>
2371
2372 <xi:include href="version-info.xml" xpointer="v220"/>
2373 </listitem>
2374 </varlistentry>
2375
2376 <varlistentry>
2377 <term><varname>DynamicTransmitLoadBalancing=</varname></term>
2378 <listitem>
2379 <para>Takes a boolean. Specifies if dynamic shuffling of flows is enabled. Applies only
2380 for balance-tlb mode. Defaults to unset.
2381 </para>
2382
2383 <xi:include href="version-info.xml" xpointer="v240"/>
2384 </listitem>
2385 </varlistentry>
2386
2387 <varlistentry>
2388 <term><varname>MinLinks=</varname></term>
2389 <listitem>
2390 <para>Specifies the minimum number of links that must be active before
2391 asserting carrier. The default value is 0.
2392 </para>
2393
2394 <xi:include href="version-info.xml" xpointer="v220"/>
2395 </listitem>
2396 </varlistentry>
2397 </variablelist>
2398
2399 <para>For more detail information see
2400 <ulink url="https://docs.kernel.org/networking/bonding.html">
2401 Linux Ethernet Bonding Driver HOWTO</ulink></para>
2402 </refsect1>
2403
2404 <refsect1>
2405 <title>[Xfrm] Section Options</title>
2406
2407 <para>The [Xfrm] section accepts the following
2408 keys:</para>
2409
2410 <variablelist class='network-directives'>
2411 <varlistentry>
2412 <term><varname>InterfaceId=</varname></term>
2413 <listitem>
2414 <para>Sets the ID/key of the xfrm interface which needs to be associated with a SA/policy.
2415 Can be decimal or hexadecimal, valid range is 1-0xffffffff. This is mandatory.</para>
2416
2417 <xi:include href="version-info.xml" xpointer="v243"/>
2418 </listitem>
2419 </varlistentry>
2420 <varlistentry>
2421 <term><varname>Independent=</varname></term>
2422 <listitem>
2423 <para>Takes a boolean. If false (the default), the xfrm interface must have an underlying device
2424 which can be used for hardware offloading.</para>
2425
2426 <xi:include href="version-info.xml" xpointer="v243"/>
2427 </listitem>
2428 </varlistentry>
2429 </variablelist>
2430
2431 <para>For more detail information see
2432 <ulink url="https://lwn.net/Articles/757391">Virtual XFRM Interfaces</ulink>.</para>
2433 </refsect1>
2434
2435 <refsect1>
2436 <title>[VRF] Section Options</title>
2437 <para>The [VRF] section only applies for
2438 netdevs of kind <literal>vrf</literal> and accepts the
2439 following key:</para>
2440
2441 <variablelist class='network-directives'>
2442 <varlistentry>
2443 <term><varname>Table=</varname></term>
2444 <listitem>
2445 <para>The numeric routing table identifier. This setting is compulsory.</para>
2446
2447 <xi:include href="version-info.xml" xpointer="v243"/>
2448 </listitem>
2449 </varlistentry>
2450 </variablelist>
2451 </refsect1>
2452
2453 <refsect1>
2454 <title>[BatmanAdvanced] Section Options</title>
2455
2456 <para>The [BatmanAdvanced] section only applies for netdevs of kind <literal>batadv</literal> and accepts
2457 the following keys:</para>
2458
2459 <variablelist class='network-directives'>
2460 <varlistentry>
2461 <term><varname>GatewayMode=</varname></term>
2462 <listitem>
2463 <para>Takes one of <literal>off</literal>, <literal>server</literal>, or <literal>client</literal>.
2464 A batman-adv node can either run in server mode (sharing its internet
2465 connection with the mesh) or in client mode (searching for the most suitable internet connection
2466 in the mesh) or having the gateway support turned off entirely (which is the default setting).
2467 </para>
2468
2469 <xi:include href="version-info.xml" xpointer="v248"/>
2470 </listitem>
2471 </varlistentry>
2472 <varlistentry>
2473 <term><varname>Aggregation=</varname></term>
2474 <listitem>
2475 <para>Takes a boolean value. Enables or disables aggregation of originator messages. Defaults to
2476 true.
2477 </para>
2478
2479 <xi:include href="version-info.xml" xpointer="v248"/>
2480 </listitem>
2481 </varlistentry>
2482 <varlistentry>
2483 <term><varname>BridgeLoopAvoidance=</varname></term>
2484 <listitem>
2485 <para>Takes a boolean value. Enables or disables avoidance of loops on bridges. Defaults to true.
2486 </para>
2487
2488 <xi:include href="version-info.xml" xpointer="v248"/>
2489 </listitem>
2490 </varlistentry>
2491 <varlistentry>
2492 <term><varname>DistributedArpTable=</varname></term>
2493 <listitem>
2494 <para>Takes a boolean value. Enables or disables the distributed ARP table. Defaults to true.</para>
2495
2496 <xi:include href="version-info.xml" xpointer="v248"/>
2497 </listitem>
2498 </varlistentry>
2499 <varlistentry>
2500 <term><varname>Fragmentation=</varname></term>
2501 <listitem>
2502 <para>Takes a boolean value. Enables or disables fragmentation. Defaults to true.</para>
2503
2504 <xi:include href="version-info.xml" xpointer="v248"/>
2505 </listitem>
2506 </varlistentry>
2507 <varlistentry>
2508 <term><varname>HopPenalty=</varname></term>
2509 <listitem>
2510 <para>The hop penalty setting allows one to modify
2511 <citerefentry project='mankier'><refentrytitle>batctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>
2512 preference for multihop routes vs. short routes. This integer value is applied to the
2513 TQ (Transmit Quality) of each forwarded OGM (Originator Message), thereby propagating the
2514 cost of an extra hop (the packet has to be received and retransmitted which costs airtime).
2515 A higher hop penalty will make it more unlikely that other nodes will choose this node as
2516 intermediate hop towards any given destination. The default hop penalty of '15' is a reasonable
2517 value for most setups and probably does not need to be changed. However, mobile nodes could
2518 choose a value of 255 (maximum value) to avoid being chosen as a router by other nodes.
2519 The minimum value is 0.
2520 </para>
2521
2522 <xi:include href="version-info.xml" xpointer="v248"/>
2523 </listitem>
2524 </varlistentry>
2525 <varlistentry>
2526 <term><varname>OriginatorIntervalSec=</varname></term>
2527 <listitem>
2528 <para>The value specifies the interval in seconds, unless another time unit is specified in which
2529 batman-adv floods the network with its protocol information.
2530 See <citerefentry><refentrytitle>systemd.time</refentrytitle><manvolnum>7</manvolnum></citerefentry>
2531 for more information.</para>
2532
2533 <xi:include href="version-info.xml" xpointer="v248"/>
2534 </listitem>
2535 </varlistentry>
2536 <varlistentry>
2537 <term><varname>GatewayBandwidthDown=</varname></term>
2538 <listitem>
2539 <para>If the node is a server, this
2540 parameter is used to inform other nodes in the network about
2541 this node's internet connection download bandwidth in bits per second. Just enter any number
2542 suffixed with K, M, G or T (base 1000) and the batman-adv
2543 module will propagate the entered value in the mesh.</para>
2544
2545 <xi:include href="version-info.xml" xpointer="v248"/>
2546 </listitem>
2547 </varlistentry>
2548 <varlistentry>
2549 <term><varname>GatewayBandwidthUp=</varname></term>
2550 <listitem>
2551 <para>If the node is a server, this
2552 parameter is used to inform other nodes in the network about
2553 this node's internet connection upload bandwidth in bits per second. Just enter any number
2554 suffixed with K, M, G or T (base 1000) and the batman-adv
2555 module will propagate the entered value in the mesh.</para>
2556
2557 <xi:include href="version-info.xml" xpointer="v248"/>
2558 </listitem>
2559 </varlistentry>
2560 <varlistentry>
2561 <term><varname>RoutingAlgorithm=</varname></term>
2562 <listitem>
2563 <para>This can be either <literal>batman-v</literal> or <literal>batman-iv</literal> and describes which routing_algo
2564 of <citerefentry project='mankier'><refentrytitle>batctl</refentrytitle><manvolnum>8</manvolnum></citerefentry> to use. The algorithm
2565 cannot be changed after interface creation. Defaults to <literal>batman-v</literal>.
2566 </para>
2567
2568 <xi:include href="version-info.xml" xpointer="v248"/>
2569 </listitem>
2570 </varlistentry>
2571 </variablelist>
2572 </refsect1>
2573
2574 <refsect1>
2575 <title>[IPoIB] Section Options</title>
2576 <para>The [IPoIB] section only applies for netdevs of kind <literal>ipoib</literal> and accepts the
2577 following keys:</para>
2578
2579 <variablelist class='network-directives'>
2580 <varlistentry>
2581 <term><varname>PartitionKey=</varname></term>
2582 <listitem>
2583 <para>Takes an integer in the range 1…0xffff, except for 0x8000. Defaults to unset, and the
2584 kernel's default is used.</para>
2585
2586 <xi:include href="version-info.xml" xpointer="v250"/>
2587 </listitem>
2588 </varlistentry>
2589
2590 <varlistentry id='ipoib_mode'>
2591 <term><varname>Mode=</varname></term>
2592 <listitem>
2593 <para>Takes one of the special values <literal>datagram</literal> or
2594 <literal>connected</literal>. Defaults to unset, and the kernel's default is used.</para>
2595
2596 <para>When <literal>datagram</literal>, the Infiniband unreliable datagram (UD) transport is
2597 used, and so the interface MTU is equal to the IB L2 MTU minus the IPoIB encapsulation
2598 header (4 bytes). For example, in a typical IB fabric with a 2K MTU, the IPoIB MTU will be
2599 2048 - 4 = 2044 bytes.</para>
2600
2601 <para>When <literal>connected</literal>, the Infiniband reliable connected (RC) transport is
2602 used. Connected mode takes advantage of the connected nature of the IB transport and allows
2603 an MTU up to the maximal IP packet size of 64K, which reduces the number of IP packets needed
2604 for handling large UDP datagrams, TCP segments, etc and increases the performance for large
2605 messages.</para>
2606
2607 <xi:include href="version-info.xml" xpointer="v250"/>
2608 </listitem>
2609 </varlistentry>
2610
2611 <varlistentry id='ipoib_umcast'>
2612 <term><varname>IgnoreUserspaceMulticastGroup=</varname></term>
2613 <listitem>
2614 <para>Takes an boolean value. When true, the kernel ignores multicast groups handled by
2615 userspace. Defaults to unset, and the kernel's default is used.</para>
2616
2617 <xi:include href="version-info.xml" xpointer="v250"/>
2618 </listitem>
2619 </varlistentry>
2620 </variablelist>
2621 </refsect1>
2622
2623 <refsect1>
2624 <title>[WLAN] Section Options</title>
2625 <para>The [WLAN] section only applies to WLAN interfaces, and accepts the following keys:</para>
2626
2627 <variablelist class='network-directives'>
2628 <varlistentry>
2629 <term><varname>PhysicalDevice=</varname></term>
2630 <listitem>
2631 <para>Specifies the name or index of the physical WLAN device (e.g. <literal>0</literal> or
2632 <literal>phy0</literal>). The list of the physical WLAN devices that exist on the host can be
2633 obtained by <command>iw phy</command> command. This option is mandatory.</para>
2634
2635 <xi:include href="version-info.xml" xpointer="v251"/>
2636 </listitem>
2637 </varlistentry>
2638
2639 <varlistentry>
2640 <term><varname>Type=</varname></term>
2641 <listitem>
2642 <para>Specifies the type of the interface. Takes one of the <literal>ad-hoc</literal>,
2643 <literal>station</literal>, <literal>ap</literal>, <literal>ap-vlan</literal>,
2644 <literal>wds</literal>, <literal>monitor</literal>, <literal>mesh-point</literal>,
2645 <literal>p2p-client</literal>, <literal>p2p-go</literal>, <literal>p2p-device</literal>,
2646 <literal>ocb</literal>, and <literal>nan</literal>. This option is mandatory.</para>
2647
2648 <xi:include href="version-info.xml" xpointer="v251"/>
2649 </listitem>
2650 </varlistentry>
2651
2652 <varlistentry>
2653 <term><varname>WDS=</varname></term>
2654 <listitem>
2655 <para>Enables the Wireless Distribution System (WDS) mode on the interface. The mode is also
2656 known as the <literal>4 address mode</literal>. Takes a boolean value. Defaults to unset, and
2657 the kernel's default will be used.</para>
2658
2659 <xi:include href="version-info.xml" xpointer="v251"/>
2660 </listitem>
2661 </varlistentry>
2662 </variablelist>
2663 </refsect1>
2664
2665 <refsect1>
2666 <title>Examples</title>
2667 <example>
2668 <title>/etc/systemd/network/25-bridge.netdev</title>
2669
2670 <programlisting>[NetDev]
2671 Name=bridge0
2672 Kind=bridge</programlisting>
2673 </example>
2674
2675 <example>
2676 <title>/etc/systemd/network/25-vlan1.netdev</title>
2677
2678 <programlisting>[Match]
2679 Virtualization=no
2680
2681 [NetDev]
2682 Name=vlan1
2683 Kind=vlan
2684
2685 [VLAN]
2686 Id=1</programlisting>
2687 </example>
2688 <example>
2689 <title>/etc/systemd/network/25-ipip.netdev</title>
2690 <programlisting>[NetDev]
2691 Name=ipip-tun
2692 Kind=ipip
2693 MTUBytes=1480
2694
2695 [Tunnel]
2696 Local=192.168.223.238
2697 Remote=192.169.224.239
2698 TTL=64</programlisting>
2699 </example>
2700 <example>
2701 <title>/etc/systemd/network/1-fou-tunnel.netdev</title>
2702 <programlisting>[NetDev]
2703 Name=fou-tun
2704 Kind=fou
2705
2706 [FooOverUDP]
2707 Port=5555
2708 Protocol=4
2709 </programlisting>
2710 </example>
2711 <example>
2712 <title>/etc/systemd/network/25-fou-ipip.netdev</title>
2713 <programlisting>[NetDev]
2714 Name=ipip-tun
2715 Kind=ipip
2716
2717 [Tunnel]
2718 Independent=yes
2719 Local=10.65.208.212
2720 Remote=10.65.208.211
2721 FooOverUDP=yes
2722 FOUDestinationPort=5555
2723 </programlisting>
2724 </example>
2725 <example>
2726 <title>/etc/systemd/network/25-tap.netdev</title>
2727 <programlisting>[NetDev]
2728 Name=tap-test
2729 Kind=tap
2730
2731 [Tap]
2732 MultiQueue=yes
2733 PacketInfo=yes</programlisting> </example>
2734
2735 <example>
2736 <title>/etc/systemd/network/25-sit.netdev</title>
2737 <programlisting>[NetDev]
2738 Name=sit-tun
2739 Kind=sit
2740 MTUBytes=1480
2741
2742 [Tunnel]
2743 Local=10.65.223.238
2744 Remote=10.65.223.239</programlisting>
2745 </example>
2746
2747 <example>
2748 <title>/etc/systemd/network/25-6rd.netdev</title>
2749 <programlisting>[NetDev]
2750 Name=6rd-tun
2751 Kind=sit
2752 MTUBytes=1480
2753
2754 [Tunnel]
2755 Local=10.65.223.238
2756 IPv6RapidDeploymentPrefix=2602::/24</programlisting>
2757 </example>
2758
2759 <example>
2760 <title>/etc/systemd/network/25-gre.netdev</title>
2761 <programlisting>[NetDev]
2762 Name=gre-tun
2763 Kind=gre
2764 MTUBytes=1480
2765
2766 [Tunnel]
2767 Local=10.65.223.238
2768 Remote=10.65.223.239</programlisting>
2769 </example>
2770
2771 <example>
2772 <title>/etc/systemd/network/25-ip6gre.netdev</title>
2773 <programlisting>[NetDev]
2774 Name=ip6gre-tun
2775 Kind=ip6gre
2776
2777 [Tunnel]
2778 Key=123</programlisting>
2779 </example>
2780
2781 <example>
2782 <title>/etc/systemd/network/25-vti.netdev</title>
2783
2784 <programlisting>[NetDev]
2785 Name=vti-tun
2786 Kind=vti
2787 MTUBytes=1480
2788
2789 [Tunnel]
2790 Local=10.65.223.238
2791 Remote=10.65.223.239</programlisting>
2792 </example>
2793
2794 <example>
2795 <title>/etc/systemd/network/25-veth.netdev</title>
2796 <programlisting>[NetDev]
2797 Name=veth-test
2798 Kind=veth
2799
2800 [Peer]
2801 Name=veth-peer</programlisting>
2802 </example>
2803
2804 <example>
2805 <title>/etc/systemd/network/25-bond.netdev</title>
2806 <programlisting>[NetDev]
2807 Name=bond1
2808 Kind=bond
2809
2810 [Bond]
2811 Mode=802.3ad
2812 TransmitHashPolicy=layer3+4
2813 MIIMonitorSec=1s
2814 LACPTransmitRate=fast
2815 </programlisting>
2816 </example>
2817
2818 <example>
2819 <title>/etc/systemd/network/25-dummy.netdev</title>
2820 <programlisting>[NetDev]
2821 Name=dummy-test
2822 Kind=dummy
2823 MACAddress=12:34:56:78:9a:bc</programlisting>
2824 </example>
2825 <example>
2826 <title>/etc/systemd/network/25-vrf.netdev</title>
2827 <para>Create a VRF interface with table 42.</para>
2828 <programlisting>[NetDev]
2829 Name=vrf-test
2830 Kind=vrf
2831
2832 [VRF]
2833 Table=42</programlisting>
2834 </example>
2835
2836 <example>
2837 <title>/etc/systemd/network/25-macvtap.netdev</title>
2838 <para>Create a MacVTap device.</para>
2839 <programlisting>[NetDev]
2840 Name=macvtap-test
2841 Kind=macvtap
2842 </programlisting>
2843 </example>
2844 <example>
2845 <title>/etc/systemd/network/25-wireguard.netdev</title>
2846 <programlisting>[NetDev]
2847 Name=wg0
2848 Kind=wireguard
2849
2850 [WireGuard]
2851 PrivateKey=EEGlnEPYJV//kbvvIqxKkQwOiS+UENyPncC4bF46ong=
2852 ListenPort=51820
2853
2854 [WireGuardPeer]
2855 PublicKey=RDf+LSpeEre7YEIKaxg+wbpsNV7du+ktR99uBEtIiCA=
2856 AllowedIPs=fd31:bf08:57cb::/48,192.168.26.0/24
2857 Endpoint=wireguard.example.com:51820</programlisting>
2858 </example>
2859
2860 <example>
2861 <title>/etc/systemd/network/27-xfrm.netdev</title>
2862 <programlisting>[NetDev]
2863 Name=xfrm0
2864 Kind=xfrm
2865
2866 [Xfrm]
2867 Independent=yes</programlisting>
2868 </example>
2869 </refsect1>
2870
2871 <refsect1>
2872 <title>See Also</title>
2873 <para>
2874 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
2875 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
2876 <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2877 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2878 <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>
2879 </para>
2880 </refsect1>
2881
2882 </refentry>