]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/systemd.netdev.xml
Merge pull request #15697 from OhNoMoreGit/fix-path-units
[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+ -->
5
6 <refentry id="systemd.netdev" conditional='ENABLE_NETWORKD'>
7
8 <refentryinfo>
9 <title>systemd.network</title>
10 <productname>systemd</productname>
11 </refentryinfo>
12
13 <refmeta>
14 <refentrytitle>systemd.netdev</refentrytitle>
15 <manvolnum>5</manvolnum>
16 </refmeta>
17
18 <refnamediv>
19 <refname>systemd.netdev</refname>
20 <refpurpose>Virtual Network Device configuration</refpurpose>
21 </refnamediv>
22
23 <refsynopsisdiv>
24 <para><filename><replaceable>netdev</replaceable>.netdev</filename></para>
25 </refsynopsisdiv>
26
27 <refsect1>
28 <title>Description</title>
29
30 <para>A plain ini-style text file that encodes configuration about a virtual network device, used by
31 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>.
32 See <citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>5</manvolnum></citerefentry>
33 for a general description of the syntax.</para>
34
35 <para>The main Virtual Network Device file must have the extension <filename>.netdev</filename>;
36 other extensions are ignored. Virtual network devices are created as soon as networkd is
37 started. If a netdev with the specified name already exists, networkd will use that as-is rather
38 than create its own. Note that the settings of the pre-existing netdev will not be changed by
39 networkd.</para>
40
41 <para>The <filename>.netdev</filename> files are read from the files located in the system
42 network directory <filename>/usr/lib/systemd/network</filename>, the volatile runtime network
43 directory <filename>/run/systemd/network</filename> and the local administration network
44 directory <filename>/etc/systemd/network</filename>. All configuration files are collectively
45 sorted and processed in lexical order, regardless of the directories in which they live.
46 However, files with identical filenames replace each other. Files in <filename>/etc</filename>
47 have the highest priority, files in <filename>/run</filename> take precedence over files with
48 the same name in <filename>/usr/lib</filename>. This can be used to override a system-supplied
49 configuration file with a local file if needed. As a special case, an empty file (file size 0)
50 or symlink with the same name pointing to <filename>/dev/null</filename> disables the
51 configuration file entirely (it is "masked").</para>
52
53 <para>Along with the netdev file <filename>foo.netdev</filename>, a "drop-in" directory
54 <filename>foo.netdev.d/</filename> may exist. All files with the suffix <literal>.conf</literal>
55 from this directory will be parsed after the file itself is parsed. This is useful to alter or
56 add configuration settings, without having to modify the main configuration file. Each drop-in
57 file must have appropriate section headers.</para>
58
59 <para>In addition to <filename>/etc/systemd/network</filename>, drop-in <literal>.d</literal>
60 directories can be placed in <filename>/usr/lib/systemd/network</filename> or
61 <filename>/run/systemd/network</filename> directories. Drop-in files in
62 <filename>/etc</filename> take precedence over those in <filename>/run</filename> which in turn
63 take precedence over those in <filename>/usr/lib</filename>. Drop-in files under any of these
64 directories take precedence over the main netdev file wherever located. (Of course, since
65 <filename>/run</filename> is temporary and <filename>/usr/lib</filename> is for vendors, it is
66 unlikely drop-ins should be used in either of those places.)</para>
67 </refsect1>
68
69 <refsect1>
70 <title>Supported netdev kinds</title>
71
72 <para>The following kinds of virtual network devices may be
73 configured in <filename>.netdev</filename> files:</para>
74
75 <table>
76 <title>Supported kinds of virtual network devices</title>
77
78 <tgroup cols='2'>
79 <colspec colname='kind' />
80 <colspec colname='explanation' />
81 <thead><row>
82 <entry>Kind</entry>
83 <entry>Description</entry>
84 </row></thead>
85 <tbody>
86 <row><entry><varname>bond</varname></entry>
87 <entry>A bond device is an aggregation of all its slave devices. See <ulink url="https://www.kernel.org/doc/Documentation/networking/bonding.txt">Linux Ethernet Bonding Driver HOWTO</ulink> for details.Local configuration</entry></row>
88
89 <row><entry><varname>bridge</varname></entry>
90 <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>
91
92 <row><entry><varname>dummy</varname></entry>
93 <entry>A dummy device drops all packets sent to it.</entry></row>
94
95 <row><entry><varname>gre</varname></entry>
96 <entry>A Level 3 GRE tunnel over IPv4. See <ulink url="https://tools.ietf.org/html/rfc2784">RFC 2784</ulink> for details.</entry></row>
97
98 <row><entry><varname>gretap</varname></entry>
99 <entry>A Level 2 GRE tunnel over IPv4.</entry></row>
100
101 <row><entry><varname>erspan</varname></entry>
102 <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.</entry></row>
103
104 <row><entry><varname>ip6gre</varname></entry>
105 <entry>A Level 3 GRE tunnel over IPv6.</entry></row>
106
107 <row><entry><varname>ip6tnl</varname></entry>
108 <entry>An IPv4 or IPv6 tunnel over IPv6</entry></row>
109
110 <row><entry><varname>ip6gretap</varname></entry>
111 <entry>A Level 2 GRE tunnel over IPv6.</entry></row>
112
113 <row><entry><varname>ipip</varname></entry>
114 <entry>An IPv4 over IPv4 tunnel.</entry></row>
115
116 <row><entry><varname>ipvlan</varname></entry>
117 <entry>An ipvlan device is a stacked device which receives packets from its underlying device based on IP address filtering.</entry></row>
118
119 <row><entry><varname>ipvtap</varname></entry>
120 <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>
121
122 <row><entry><varname>macvlan</varname></entry>
123 <entry>A macvlan device is a stacked device which receives packets from its underlying device based on MAC address filtering.</entry></row>
124
125 <row><entry><varname>macvtap</varname></entry>
126 <entry>A macvtap device is a stacked device which receives packets from its underlying device based on MAC address filtering.</entry></row>
127
128 <row><entry><varname>sit</varname></entry>
129 <entry>An IPv6 over IPv4 tunnel.</entry></row>
130
131 <row><entry><varname>tap</varname></entry>
132 <entry>A persistent Level 2 tunnel between a network device and a device node.</entry></row>
133
134 <row><entry><varname>tun</varname></entry>
135 <entry>A persistent Level 3 tunnel between a network device and a device node.</entry></row>
136
137 <row><entry><varname>veth</varname></entry>
138 <entry>An Ethernet tunnel between a pair of network devices.</entry></row>
139
140 <row><entry><varname>vlan</varname></entry>
141 <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>
142
143 <row><entry><varname>vti</varname></entry>
144 <entry>An IPv4 over IPSec tunnel.</entry></row>
145
146 <row><entry><varname>vti6</varname></entry>
147 <entry>An IPv6 over IPSec tunnel.</entry></row>
148
149 <row><entry><varname>vxlan</varname></entry>
150 <entry>A virtual extensible LAN (vxlan), for connecting Cloud computing deployments.</entry></row>
151
152 <row><entry><varname>geneve</varname></entry>
153 <entry>A GEneric NEtwork Virtualization Encapsulation (GENEVE) netdev driver.</entry></row>
154
155 <row><entry><varname>l2tp</varname></entry>
156 <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>
157
158 <row><entry><varname>macsec</varname></entry>
159 <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>
160
161 <row><entry><varname>vrf</varname></entry>
162 <entry>A Virtual Routing and Forwarding (<ulink url="https://www.kernel.org/doc/Documentation/networking/vrf.txt">VRF</ulink>) interface to create separate routing and forwarding domains.</entry></row>
163
164 <row><entry><varname>vcan</varname></entry>
165 <entry>The virtual CAN driver (vcan). Similar to the network loopback devices, vcan offers a virtual local CAN interface.</entry></row>
166
167 <row><entry><varname>vxcan</varname></entry>
168 <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.
169 </entry></row>
170
171 <row><entry><varname>wireguard</varname></entry>
172 <entry>WireGuard Secure Network Tunnel.</entry></row>
173
174 <row><entry><varname>netdevsim</varname></entry>
175 <entry>A simulator. This simulated networking device is used for testing various networking APIs and at this time is particularly focused on testing hardware offloading related interfaces.</entry></row>
176
177 <row><entry><varname>nlmon</varname></entry>
178 <entry>A Netlink monitor device. Use an nlmon device when you want to monitor system Netlink messages.</entry></row>
179
180 <row><entry><varname>fou</varname></entry>
181 <entry>Foo-over-UDP tunneling.</entry></row>
182
183 <row><entry><varname>xfrm</varname></entry>
184 <entry>A virtual tunnel interface like vti/vti6 but with several advantages.</entry></row>
185
186 <row><entry><varname>ifb</varname></entry>
187 <entry> The Intermediate Functional Block (ifb) pseudo network interface acts as a QoS concentrator for multiple different sources of traffic.</entry></row>
188
189 </tbody>
190 </tgroup>
191 </table>
192
193 </refsect1>
194
195 <refsect1>
196 <title>[Match] Section Options</title>
197
198 <para>A virtual network device is only created if the
199 <literal>[Match]</literal> section matches the current
200 environment, or if the section is empty. The following keys are
201 accepted:</para>
202
203 <variablelist class='network-directives'>
204 <varlistentry>
205 <term><varname>Host=</varname></term>
206 <listitem>
207 <para>Matches against the hostname or machine ID of the host. See
208 <literal>ConditionHost=</literal> in
209 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
210 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
211 If an empty string is assigned, then previously assigned value is cleared.
212 </para>
213 </listitem>
214 </varlistentry>
215 <varlistentry>
216 <term><varname>Virtualization=</varname></term>
217 <listitem>
218 <para>Checks whether the system is executed in a virtualized environment and optionally test
219 whether it is a specific implementation. See <literal>ConditionVirtualization=</literal> in
220 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
221 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
222 If an empty string is assigned, then previously assigned value is cleared.
223 </para>
224 </listitem>
225 </varlistentry>
226 <varlistentry>
227 <term><varname>KernelCommandLine=</varname></term>
228 <listitem>
229 <para>Checks whether a specific kernel command line option is set. See
230 <literal>ConditionKernelCommandLine=</literal> in
231 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
232 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
233 If an empty string is assigned, then previously assigned value is cleared.
234 </para>
235 </listitem>
236 </varlistentry>
237 <varlistentry>
238 <term><varname>KernelVersion=</varname></term>
239 <listitem>
240 <para>Checks whether the kernel version (as reported by <command>uname -r</command>) matches a
241 certain expression. See <literal>ConditionKernelVersion=</literal> in
242 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
243 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
244 If an empty string is assigned, then previously assigned value is cleared.
245 </para>
246 </listitem>
247 </varlistentry>
248 <varlistentry>
249 <term><varname>Architecture=</varname></term>
250 <listitem>
251 <para>Checks whether the system is running on a specific architecture. See
252 <literal>ConditionArchitecture=</literal> in
253 <citerefentry><refentrytitle>systemd.unit</refentrytitle><manvolnum>5</manvolnum></citerefentry>
254 for details. When prefixed with an exclamation mark (<literal>!</literal>), the result is negated.
255 If an empty string is assigned, then previously assigned value is cleared.
256 </para>
257 </listitem>
258 </varlistentry>
259 </variablelist>
260 </refsect1>
261
262 <refsect1>
263 <title>[NetDev] Section Options</title>
264
265 <para>The <literal>[NetDev]</literal> section accepts the
266 following keys:</para>
267
268 <variablelist class='network-directives'>
269 <varlistentry>
270 <term><varname>Description=</varname></term>
271 <listitem>
272 <para>A free-form description of the netdev.</para>
273 </listitem>
274 </varlistentry>
275 <varlistentry>
276 <term><varname>Name=</varname></term>
277 <listitem>
278 <para>The interface name used when creating the netdev.
279 This option is compulsory.</para>
280 </listitem>
281 </varlistentry>
282 <varlistentry>
283 <term><varname>Kind=</varname></term>
284 <listitem>
285 <para>The netdev kind. This option is compulsory. See the
286 <literal>Supported netdev kinds</literal> section for the
287 valid keys.</para>
288 </listitem>
289 </varlistentry>
290 <varlistentry>
291 <term><varname>MTUBytes=</varname></term>
292 <listitem>
293 <para>The maximum transmission unit in bytes to set for the device. The usual suffixes K, M, G,
294 are supported and are understood to the base of 1024. For <literal>tun</literal> or
295 <literal>tap</literal> devices, <varname>MTUBytes=</varname> setting is not currently supported in
296 <literal>[NetDev]</literal> section. Please specify it in <literal>[Link]</literal> section of
297 corresponding
298 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
299 files.</para>
300 </listitem>
301 </varlistentry>
302 <varlistentry>
303 <term><varname>MACAddress=</varname></term>
304 <listitem>
305 <para>The MAC address to use for the device. For <literal>tun</literal> or <literal>tap</literal>
306 devices, setting <varname>MACAddress=</varname> in the <literal>[NetDev]</literal> section is not
307 supported. Please specify it in <literal>[Link]</literal> section of the corresponding
308 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
309 file. If this option is not set, <literal>vlan</literal> devices inherit the MAC address of the
310 physical interface. For other kind of netdevs, if this option is not set, then MAC address is
311 generated based on the interface name and the
312 <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
313 </para>
314 </listitem>
315 </varlistentry>
316 </variablelist>
317 </refsect1>
318
319 <refsect1>
320 <title>[Bridge] Section Options</title>
321
322 <para>The <literal>[Bridge]</literal> section only applies for
323 netdevs of kind <literal>bridge</literal>, and accepts the
324 following keys:</para>
325
326 <variablelist class='network-directives'>
327 <varlistentry>
328 <term><varname>HelloTimeSec=</varname></term>
329 <listitem>
330 <para>HelloTimeSec specifies the number of seconds between two hello packets
331 sent out by the root bridge and the designated bridges. Hello packets are
332 used to communicate information about the topology throughout the entire
333 bridged local area network.</para>
334 </listitem>
335 </varlistentry>
336 <varlistentry>
337 <term><varname>MaxAgeSec=</varname></term>
338 <listitem>
339 <para>MaxAgeSec specifies the number of seconds of maximum message age.
340 If the last seen (received) hello packet is more than this number of
341 seconds old, the bridge in question will start the takeover procedure
342 in attempt to become the Root Bridge itself.</para>
343 </listitem>
344 </varlistentry>
345 <varlistentry>
346 <term><varname>ForwardDelaySec=</varname></term>
347 <listitem>
348 <para>ForwardDelaySec specifies the number of seconds spent in each
349 of the Listening and Learning states before the Forwarding state is entered.</para>
350 </listitem>
351 </varlistentry>
352 <varlistentry>
353 <term><varname>AgeingTimeSec=</varname></term>
354 <listitem>
355 <para>This specifies the number of seconds a MAC Address will be kept in
356 the forwarding database after having a packet received from this MAC Address.</para>
357 </listitem>
358 </varlistentry>
359 <varlistentry>
360 <term><varname>Priority=</varname></term>
361 <listitem>
362 <para>The priority of the bridge. An integer between 0 and 65535. A lower value
363 means higher priority. The bridge having the lowest priority will be elected as root bridge.</para>
364 </listitem>
365 </varlistentry>
366 <varlistentry>
367 <term><varname>GroupForwardMask=</varname></term>
368 <listitem>
369 <para>A 16-bit bitmask represented as an integer which allows forwarding of link
370 local frames with 802.1D reserved addresses (01:80:C2:00:00:0X). A logical AND
371 is performed between the specified bitmask and the exponentiation of 2^X, the
372 lower nibble of the last octet of the MAC address. For example, a value of 8
373 would allow forwarding of frames addressed to 01:80:C2:00:00:03 (802.1X PAE).</para>
374 </listitem>
375 </varlistentry>
376 <varlistentry>
377 <term><varname>DefaultPVID=</varname></term>
378 <listitem>
379 <para>This specifies the default port VLAN ID of a newly attached bridge port.
380 Set this to an integer in the range 1–4094 or <literal>none</literal> to disable the PVID.</para>
381 </listitem>
382 </varlistentry>
383 <varlistentry>
384 <term><varname>MulticastQuerier=</varname></term>
385 <listitem>
386 <para>Takes a boolean. This setting controls the IFLA_BR_MCAST_QUERIER option in the kernel.
387 If enabled, the kernel will send general ICMP queries from a zero source address.
388 This feature should allow faster convergence on startup, but it causes some
389 multicast-aware switches to misbehave and disrupt forwarding of multicast packets.
390 When unset, the kernel's default will be used.
391 </para>
392 </listitem>
393 </varlistentry>
394 <varlistentry>
395 <term><varname>MulticastSnooping=</varname></term>
396 <listitem>
397 <para>Takes a boolean. This setting controls the IFLA_BR_MCAST_SNOOPING option in the kernel.
398 If enabled, IGMP snooping monitors the Internet Group Management Protocol (IGMP) traffic
399 between hosts and multicast routers. When unset, the kernel's default will be used.
400 </para>
401 </listitem>
402 </varlistentry>
403 <varlistentry>
404 <term><varname>VLANFiltering=</varname></term>
405 <listitem>
406 <para>Takes a boolean. This setting controls the IFLA_BR_VLAN_FILTERING option in the kernel.
407 If enabled, the bridge will be started in VLAN-filtering mode. When unset, the kernel's default will be used.
408 </para>
409 </listitem>
410 </varlistentry>
411 <varlistentry>
412 <term><varname>VLANProtocol=</varname></term>
413 <listitem>
414 <para>Allows setting the protocol used for VLAN filtering. Takes
415 <option>802.1q</option> or,
416 <option>802.1ad</option>, and defaults to unset and kernel's default is used.
417 </para>
418 </listitem>
419 </varlistentry>
420 <varlistentry>
421 <term><varname>STP=</varname></term>
422 <listitem>
423 <para>Takes a boolean. This enables the bridge's Spanning Tree Protocol (STP).
424 When unset, the kernel's default will be used.
425 </para>
426 </listitem>
427 </varlistentry>
428 <varlistentry>
429 <term><varname>MulticastIGMPVersion=</varname></term>
430 <listitem>
431 <para>Allows changing bridge's multicast Internet Group Management Protocol (IGMP) version.
432 Takes an integer 2 or 3. When unset, the kernel's default will be used.
433 </para>
434 </listitem>
435 </varlistentry>
436 </variablelist>
437 </refsect1>
438
439 <refsect1>
440 <title>[VLAN] Section Options</title>
441
442 <para>The <literal>[VLAN]</literal> section only applies for
443 netdevs of kind <literal>vlan</literal>, and accepts the
444 following key:</para>
445
446 <variablelist class='network-directives'>
447 <varlistentry>
448 <term><varname>Id=</varname></term>
449 <listitem>
450 <para>The VLAN ID to use. An integer in the range 0–4094.
451 This option is compulsory.</para>
452 </listitem>
453 </varlistentry>
454 <varlistentry>
455 <term><varname>GVRP=</varname></term>
456 <listitem>
457 <para>Takes a boolean. The Generic VLAN Registration Protocol (GVRP) is a protocol that
458 allows automatic learning of VLANs on a network.
459 When unset, the kernel's default will be used.
460 </para>
461 </listitem>
462 </varlistentry>
463 <varlistentry>
464 <term><varname>MVRP=</varname></term>
465 <listitem>
466 <para>Takes a boolean. Multiple VLAN Registration Protocol (MVRP) formerly known as GARP VLAN
467 Registration Protocol (GVRP) is a standards-based Layer 2 network protocol,
468 for automatic configuration of VLAN information on switches. It was defined
469 in the 802.1ak amendment to 802.1Q-2005. When unset, the kernel's default will be used.
470 </para>
471 </listitem>
472 </varlistentry>
473 <varlistentry>
474 <term><varname>LooseBinding=</varname></term>
475 <listitem>
476 <para>Takes a boolean. The VLAN loose binding mode, in which only the operational state is passed
477 from the parent to the associated VLANs, but the VLAN device state is not changed.
478 When unset, the kernel's default will be used.</para>
479 </listitem>
480 </varlistentry>
481 <varlistentry>
482 <term><varname>ReorderHeader=</varname></term>
483 <listitem>
484 <para>Takes a boolean. The VLAN reorder header is set VLAN interfaces behave like physical interfaces.
485 When unset, the kernel's default will be used.</para>
486 </listitem>
487 </varlistentry>
488 </variablelist>
489 </refsect1>
490
491 <refsect1>
492 <title>[MACVLAN] Section Options</title>
493
494 <para>The <literal>[MACVLAN]</literal> section only applies for
495 netdevs of kind <literal>macvlan</literal>, and accepts the
496 following key:</para>
497
498 <variablelist class='network-directives'>
499 <varlistentry>
500 <term><varname>Mode=</varname></term>
501 <listitem>
502 <para>The MACVLAN mode to use. The supported options are
503 <literal>private</literal>,
504 <literal>vepa</literal>,
505 <literal>bridge</literal>, and
506 <literal>passthru</literal>.
507 </para>
508 </listitem>
509 </varlistentry>
510 </variablelist>
511 </refsect1>
512
513 <refsect1>
514 <title>[MACVTAP] Section Options</title>
515
516 <para>The <literal>[MACVTAP]</literal> section applies for
517 netdevs of kind <literal>macvtap</literal> and accepts the
518 same key as <literal>[MACVLAN]</literal>.</para>
519 </refsect1>
520
521 <refsect1>
522 <title>[IPVLAN] Section Options</title>
523
524 <para>The <literal>[IPVLAN]</literal> section only applies for
525 netdevs of kind <literal>ipvlan</literal>, and accepts the
526 following key:</para>
527
528 <variablelist class='network-directives'>
529 <varlistentry>
530 <term><varname>Mode=</varname></term>
531 <listitem>
532 <para>The IPVLAN mode to use. The supported options are
533 <literal>L2</literal>,<literal>L3</literal> and <literal>L3S</literal>.
534 </para>
535 </listitem>
536 </varlistentry>
537 <varlistentry>
538 <term><varname>Flags=</varname></term>
539 <listitem>
540 <para>The IPVLAN flags to use. The supported options are
541 <literal>bridge</literal>,<literal>private</literal> and <literal>vepa</literal>.
542 </para>
543 </listitem>
544 </varlistentry>
545 </variablelist>
546 </refsect1>
547
548 <refsect1>
549 <title>[IPVTAP] Section Options</title>
550
551 <para>The <literal>[IPVTAP]</literal> section only applies for
552 netdevs of kind <literal>ipvtap</literal> and accepts the
553 same key as <literal>[IPVLAN]</literal>.</para>
554 </refsect1>
555
556 <refsect1>
557 <title>[VXLAN] Section Options</title>
558
559 <para>The <literal>[VXLAN]</literal> section only applies for
560 netdevs of kind <literal>vxlan</literal>, and accepts the
561 following keys:</para>
562
563 <variablelist class='network-directives'>
564 <varlistentry>
565 <term><varname>VNI=</varname></term>
566 <listitem>
567 <para>The VXLAN Network Identifier (or VXLAN Segment ID). Takes a number in the range 1-16777215.</para>
568 </listitem>
569 </varlistentry>
570 <varlistentry>
571 <term><varname>Remote=</varname></term>
572 <listitem>
573 <para>Configures destination IP address.</para>
574 </listitem>
575 </varlistentry>
576 <varlistentry>
577 <term><varname>Local=</varname></term>
578 <listitem>
579 <para>Configures local IP address.</para>
580 </listitem>
581 </varlistentry>
582 <varlistentry>
583 <term><varname>Group=</varname></term>
584 <listitem>
585 <para>Configures VXLAN multicast group IP address. All members of a VXLAN must use the same multicast group address.</para>
586 </listitem>
587 </varlistentry>
588 <varlistentry>
589 <term><varname>TOS=</varname></term>
590 <listitem>
591 <para>The Type Of Service byte value for a vxlan interface.</para>
592 </listitem>
593 </varlistentry>
594 <varlistentry>
595 <term><varname>TTL=</varname></term>
596 <listitem>
597 <para>A fixed Time To Live N on Virtual eXtensible Local Area Network packets.
598 Takes <literal>inherit</literal> or a number in the range 0–255. 0 is a special
599 value meaning inherit the inner protocol's TTL value. <literal>inherit</literal>
600 means that it will inherit the outer protocol's TTL value.</para>
601 </listitem>
602 </varlistentry>
603 <varlistentry>
604 <term><varname>MacLearning=</varname></term>
605 <listitem>
606 <para>Takes a boolean. When true, enables dynamic MAC learning
607 to discover remote MAC addresses.</para>
608 </listitem>
609 </varlistentry>
610 <varlistentry>
611 <term><varname>FDBAgeingSec=</varname></term>
612 <listitem>
613 <para>The lifetime of Forwarding Database entry learnt by
614 the kernel, in seconds.</para>
615 </listitem>
616 </varlistentry>
617 <varlistentry>
618 <term><varname>MaximumFDBEntries=</varname></term>
619 <listitem>
620 <para>Configures maximum number of FDB entries.</para>
621 </listitem>
622 </varlistentry>
623 <varlistentry>
624 <term><varname>ReduceARPProxy=</varname></term>
625 <listitem>
626 <para>Takes a boolean. When true, bridge-connected VXLAN tunnel
627 endpoint answers ARP requests from the local bridge on behalf
628 of remote Distributed Overlay Virtual Ethernet
629 <ulink url="https://en.wikipedia.org/wiki/Distributed_Overlay_Virtual_Ethernet">
630 (DVOE)</ulink> clients. Defaults to false.</para>
631 </listitem>
632 </varlistentry>
633 <varlistentry>
634 <term><varname>L2MissNotification=</varname></term>
635 <listitem>
636 <para>Takes a boolean. When true, enables netlink LLADDR miss
637 notifications.</para>
638 </listitem>
639 </varlistentry>
640 <varlistentry>
641 <term><varname>L3MissNotification=</varname></term>
642 <listitem>
643 <para>Takes a boolean. When true, enables netlink IP address miss
644 notifications.</para>
645 </listitem>
646 </varlistentry>
647 <varlistentry>
648 <term><varname>RouteShortCircuit=</varname></term>
649 <listitem>
650 <para>Takes a boolean. When true, route short circuiting is turned
651 on.</para>
652 </listitem>
653 </varlistentry>
654 <varlistentry>
655 <term><varname>UDPChecksum=</varname></term>
656 <listitem>
657 <para>Takes a boolean. When true, transmitting UDP checksums when doing VXLAN/IPv4 is turned on.</para>
658 </listitem>
659 </varlistentry>
660 <varlistentry>
661 <term><varname>UDP6ZeroChecksumTx=</varname></term>
662 <listitem>
663 <para>Takes a boolean. When true, sending zero checksums in VXLAN/IPv6 is turned on.</para>
664 </listitem>
665 </varlistentry>
666 <varlistentry>
667 <term><varname>UDP6ZeroChecksumRx=</varname></term>
668 <listitem>
669 <para>Takes a boolean. When true, receiving zero checksums in VXLAN/IPv6 is turned on.</para>
670 </listitem>
671 </varlistentry>
672 <varlistentry>
673 <term><varname>RemoteChecksumTx=</varname></term>
674 <listitem>
675 <para>Takes a boolean. When true, remote transmit checksum offload of VXLAN is turned on.</para>
676 </listitem>
677 </varlistentry>
678 <varlistentry>
679 <term><varname>RemoteChecksumRx=</varname></term>
680 <listitem>
681 <para>Takes a boolean. When true, remote receive checksum offload in VXLAN is turned on.</para>
682 </listitem>
683 </varlistentry>
684 <varlistentry>
685 <term><varname>GroupPolicyExtension=</varname></term>
686 <listitem>
687 <para>Takes a boolean. When true, it enables Group Policy VXLAN extension security label mechanism
688 across network peers based on VXLAN. For details about the Group Policy VXLAN, see the
689 <ulink url="https://tools.ietf.org/html/draft-smith-vxlan-group-policy">
690 VXLAN Group Policy </ulink> document. Defaults to false.</para>
691 </listitem>
692 </varlistentry>
693 <varlistentry>
694 <term><varname>GenericProtocolExtension=</varname></term>
695 <listitem>
696 <para>Takes a boolean. When true, Generic Protocol Extension extends the existing VXLAN protocol
697 to provide protocol typing, OAM, and versioning capabilities. For details about the VXLAN GPE
698 Header, see the <ulink url="https://tools.ietf.org/html/draft-ietf-nvo3-vxlan-gpe-07">
699 Generic Protocol Extension for VXLAN </ulink> document. If destination port is not specified and
700 Generic Protocol Extension is set then default port of 4790 is used. Defaults to false.</para>
701 </listitem>
702 </varlistentry>
703 <varlistentry>
704 <term><varname>DestinationPort=</varname></term>
705 <listitem>
706 <para>Configures the default destination UDP port on a per-device basis.
707 If destination port is not specified then Linux kernel default will be used.
708 Set destination port 4789 to get the IANA assigned value. If not set or if the
709 destination port is assigned the empty string the default port of 4789 is used.</para>
710 </listitem>
711 </varlistentry>
712 <varlistentry>
713 <term><varname>PortRange=</varname></term>
714 <listitem>
715 <para>Configures VXLAN port range. VXLAN bases source
716 UDP port based on flow to help the receiver to be able
717 to load balance based on outer header flow. It
718 restricts the port range to the normal UDP local
719 ports, and allows overriding via configuration.</para>
720 </listitem>
721 </varlistentry>
722 <varlistentry>
723 <term><varname>FlowLabel=</varname></term>
724 <listitem>
725 <para>Specifies the flow label to use in outgoing packets.
726 The valid range is 0-1048575.
727 </para>
728 </listitem>
729 </varlistentry>
730 <varlistentry>
731 <term><varname>IPDoNotFragment=</varname></term>
732 <listitem>
733 <para>Allows setting the IPv4 Do not Fragment (DF) bit in outgoing packets, or to inherit its
734 value from the IPv4 inner header. Takes a boolean value, or <literal>inherit</literal>. Set
735 to <literal>inherit</literal> if the encapsulated protocol is IPv6. When unset, the kernel's
736 default will be used.</para>
737 </listitem>
738 </varlistentry>
739 </variablelist>
740 </refsect1>
741
742 <refsect1>
743 <title>[GENEVE] Section Options</title>
744
745 <para>The <literal>[GENEVE]</literal> section only applies for
746 netdevs of kind <literal>geneve</literal>, and accepts the
747 following keys:</para>
748
749 <variablelist class='network-directives'>
750 <varlistentry>
751 <term><varname>Id=</varname></term>
752 <listitem>
753 <para>Specifies the Virtual Network Identifier (VNI) to use. Ranges [0-16777215]. This field is mandatory.</para>
754 </listitem>
755 </varlistentry>
756 <varlistentry>
757 <term><varname>Remote=</varname></term>
758 <listitem>
759 <para>Specifies the unicast destination IP address to use in outgoing packets.</para>
760 </listitem>
761 </varlistentry>
762 <varlistentry>
763 <term><varname>TOS=</varname></term>
764 <listitem>
765 <para>Specifies the TOS value to use in outgoing packets. Ranges [1-255].</para>
766 </listitem>
767 </varlistentry>
768 <varlistentry>
769 <term><varname>TTL=</varname></term>
770 <listitem>
771 <para>Accepts the same key in <literal>[VXLAN]</literal> section except when unset or
772 set to 0, the kernel's default will be used meaning that packets TTL will be set from
773 <filename>/proc/sys/net/ipv4/ip_default_ttl</filename>.</para>
774 </listitem>
775 </varlistentry>
776 <varlistentry>
777 <term><varname>UDPChecksum=</varname></term>
778 <listitem>
779 <para>Takes a boolean. When true, specifies if UDP checksum is calculated for transmitted packets over IPv4.</para>
780 </listitem>
781 </varlistentry>
782 <varlistentry>
783 <term><varname>UDP6ZeroChecksumTx=</varname></term>
784 <listitem>
785 <para>Takes a boolean. When true, skip UDP checksum calculation for transmitted packets over IPv6.</para>
786 </listitem>
787 </varlistentry>
788 <varlistentry>
789 <term><varname>UDP6ZeroChecksumRx=</varname></term>
790 <listitem>
791 <para>Takes a boolean. When true, allows incoming UDP packets over IPv6 with zero checksum field.</para>
792 </listitem>
793 </varlistentry>
794 <varlistentry>
795 <term><varname>DestinationPort=</varname></term>
796 <listitem>
797 <para>Specifies destination port. Defaults to 6081. If not set or assigned the empty string, the default
798 port of 6081 is used.</para>
799 </listitem>
800 </varlistentry>
801 <varlistentry>
802 <term><varname>FlowLabel=</varname></term>
803 <listitem>
804 <para>Specifies the flow label to use in outgoing packets.</para>
805 </listitem>
806 </varlistentry>
807 <varlistentry>
808 <term><varname>IPDoNotFragment=</varname></term>
809 <listitem>
810 <para>Accepts the same key in <literal>[VXLAN]</literal> section.</para>
811 </listitem>
812 </varlistentry>
813 </variablelist>
814 </refsect1>
815
816 <refsect1>
817 <title>[L2TP] Section Options</title>
818
819 <para>The <literal>[L2TP]</literal> section only applies for
820 netdevs of kind <literal>l2tp</literal>, and accepts the
821 following keys:</para>
822
823 <variablelist class='network-directives'>
824 <varlistentry>
825 <term><varname>TunnelId=</varname></term>
826 <listitem>
827 <para>Specifies the tunnel id. The value used must match the <literal>PeerTunnelId=</literal> value being used at the peer.
828 Ranges a number between 1 and 4294967295). This option is compulsory.</para>
829 </listitem>
830 </varlistentry>
831 <varlistentry>
832 <term><varname>PeerTunnelId=</varname></term>
833 <listitem>
834 <para>Specifies the peer tunnel id. The value used must match the <literal>PeerTunnelId=</literal> value being used at the peer.
835 Ranges a number between 1 and 4294967295). This option is compulsory.</para>
836 </listitem>
837 </varlistentry>
838 <varlistentry>
839 <term><varname>Remote=</varname></term>
840 <listitem>
841 <para>Specifies the IP address of the remote peer. This option is compulsory.</para>
842 </listitem>
843 </varlistentry>
844 <varlistentry>
845 <term><varname>Local=</varname></term>
846 <listitem>
847 <para>Specifies the IP address of the local interface. Takes an IP address, or the special values
848 <literal>auto</literal>, <literal>static</literal>, or <literal>dynamic</literal>. When an address
849 is set, then the local interface must have the address. If <literal>auto</literal>, then one of the
850 addresses on the local interface is used. Similarly, if <literal>static</literal> or
851 <literal>dynamic</literal> is set, then one of the static or dynamic addresses on the local
852 interface is used. Defaults to <literal>auto</literal>.</para>
853 </listitem>
854 </varlistentry>
855 <varlistentry>
856 <term><varname>EncapsulationType=</varname></term>
857 <listitem>
858 <para>Specifies the encapsulation type of the tunnel. Takes one of <literal>udp</literal> or <literal>ip</literal>.</para>
859 </listitem>
860 </varlistentry>
861 <varlistentry>
862 <term><varname>UDPSourcePort=</varname></term>
863 <listitem>
864 <para>Specifies the UDP source port to be used for the tunnel. When UDP encapsulation is selected it's mandotory. Ignored when ip
865 encapsulation is selected.</para>
866 </listitem>
867 </varlistentry>
868 <varlistentry>
869 <term><varname>UDPDestinationPort=</varname></term>
870 <listitem>
871 <para>Specifies destination port. When UDP encapsulation is selected it's mandotory. Ignored when ip
872 encapsulation is selected.</para>
873 </listitem>
874 </varlistentry>
875 <varlistentry>
876 <term><varname>UDPChecksum=</varname></term>
877 <listitem>
878 <para>Takes a boolean. When true, specifies if UDP checksum is calculated for transmitted packets over IPv4.</para>
879 </listitem>
880 </varlistentry>
881 <varlistentry>
882 <term><varname>UDP6ZeroChecksumTx=</varname></term>
883 <listitem>
884 <para>Takes a boolean. When true, skip UDP checksum calculation for transmitted packets over IPv6.</para>
885 </listitem>
886 </varlistentry>
887 <varlistentry>
888 <term><varname>UDP6ZeroChecksumRx=</varname></term>
889 <listitem>
890 <para>Takes a boolean. When true, allows incoming UDP packets over IPv6 with zero checksum field.</para>
891 </listitem>
892 </varlistentry>
893 </variablelist>
894 </refsect1>
895
896 <refsect1>
897 <title>[L2TPSession] Section Options</title>
898
899 <para>The <literal>[L2TPSession]</literal> section only applies for
900 netdevs of kind <literal>l2tp</literal>, and accepts the
901 following keys:</para>
902 <variablelist class='network-directives'>
903 <varlistentry>
904 <term><varname>Name=</varname></term>
905 <listitem>
906 <para>Specifies the name of the session. This option is compulsory.</para>
907 </listitem>
908 </varlistentry>
909 <varlistentry>
910 <term><varname>SessionId=</varname></term>
911 <listitem>
912 <para>Specifies the session id. The value used must match the <literal>SessionId=</literal> value being used at the peer.
913 Ranges a number between 1 and 4294967295). This option is compulsory.</para>
914 </listitem>
915 </varlistentry>
916 <varlistentry>
917 <term><varname>PeerSessionId=</varname></term>
918 <listitem>
919 <para>Specifies the peer session id. The value used must match the <literal>PeerSessionId=</literal> value being used at the peer.
920 Ranges a number between 1 and 4294967295). This option is compulsory.</para>
921 </listitem>
922 </varlistentry>
923 <varlistentry>
924 <term><varname>Layer2SpecificHeader=</varname></term>
925 <listitem>
926 <para>Specifies layer2specific header type of the session. One of <literal>none</literal> or <literal>default</literal>. Defaults to <literal>default</literal>.</para>
927 </listitem>
928 </varlistentry>
929 </variablelist>
930 </refsect1>
931
932 <refsect1>
933 <title>[MACsec] Section Options</title>
934
935 <para>The <literal>[MACsec]</literal> section only applies for network devices of kind
936 <literal>macsec</literal>, and accepts the following keys:</para>
937
938 <variablelist class='network-directives'>
939 <varlistentry>
940 <term><varname>Port=</varname></term>
941 <listitem>
942 <para>Specifies the port to be used for the MACsec transmit channel. The port is used to make
943 secure channel identifier (SCI). Takes a value between 1 and 65535. Defaults to unset.
944 </para>
945 </listitem>
946 </varlistentry>
947 <varlistentry>
948 <term><varname>Encrypt=</varname></term>
949 <listitem>
950 <para>Takes a boolean. When true, enable encryption. Defaults to unset.</para>
951 </listitem>
952 </varlistentry>
953 </variablelist>
954 </refsect1>
955
956 <refsect1>
957 <title>[MACsecReceiveChannel] Section Options</title>
958 <para>The <literal>[MACsecReceiveChannel]</literal> section only applies for network devices of
959 kind <literal>macsec</literal>, and accepts the following keys:</para>
960
961 <variablelist class='network-directives'>
962 <varlistentry>
963 <term><varname>Port=</varname></term>
964 <listitem>
965 <para>Specifies the port to be used for the MACsec receive channel. The port is used to make
966 secure channel identifier (SCI). Takes a value between 1 and 65535. This option is
967 compulsory, and is not set by default.</para>
968 </listitem>
969 </varlistentry>
970 <varlistentry>
971 <term><varname>MACAddress=</varname></term>
972 <listitem>
973 <para>Specifies the MAC address to be used for the MACsec receive channel. The MAC address
974 used to make secure channel identifier (SCI). This option is compulsory, and is not set by
975 default.</para>
976 </listitem>
977 </varlistentry>
978 </variablelist>
979 </refsect1>
980
981 <refsect1>
982 <title>[MACsecTransmitAssociation] Section Options</title>
983
984 <para>The <literal>[MACsecTransmitAssociation]</literal> section only applies for network devices
985 of kind <literal>macsec</literal>, and accepts the following keys:</para>
986
987 <variablelist class='network-directives'>
988 <varlistentry>
989 <term><varname>PacketNumber=</varname></term>
990 <listitem>
991 <para>Specifies the packet number to be used for replay protection and the construction of
992 the initialization vector (along with the secure channel identifier [SCI]). Takes a value
993 between 1-4,294,967,295. Defaults to unset.
994 </para>
995 </listitem>
996 </varlistentry>
997 <varlistentry>
998 <term><varname>KeyId=</varname></term>
999 <listitem>
1000 <para>Specifies the identification for the key. Takes a number between 0-255. This option
1001 is compulsory, and is not set by default.</para>
1002 </listitem>
1003 </varlistentry>
1004 <varlistentry>
1005 <term><varname>Key=</varname></term>
1006 <listitem>
1007 <para>Specifies the encryption key used in the transmission channel. The same key must be
1008 configured on the peer’s matching receive channel. This option is compulsory, and is not set
1009 by default. Takes a 128-bit key encoded in a hexadecimal string, for example
1010 <literal>dffafc8d7b9a43d5b9a3dfbbf6a30c16</literal>.</para>
1011 </listitem>
1012 </varlistentry>
1013 <varlistentry>
1014 <term><varname>KeyFile=</varname></term>
1015 <listitem>
1016 <para>Takes a absolute path to a file which contains a 128-bit key encoded in a hexadecimal
1017 string, which will be used in the transmission channel. When this option is specified,
1018 <varname>Key=</varname> is ignored. Note that the file must be readable by the user
1019 <literal>systemd-network</literal>, so it should be, e.g., owned by
1020 <literal>root:systemd-network</literal> with a <literal>0640</literal> file mode.</para>
1021 </listitem>
1022 </varlistentry>
1023 <varlistentry>
1024 <term><varname>Activate=</varname></term>
1025 <listitem>
1026 <para>Takes a boolean. If enabled, then the security association is activated. Defaults to
1027 unset.</para>
1028 </listitem>
1029 </varlistentry>
1030 <varlistentry>
1031 <term><varname>UseForEncoding=</varname></term>
1032 <listitem>
1033 <para>Takes a boolean. If enabled, then the security association is used for encoding. Only
1034 one <literal>[MACsecTransmitAssociation]</literal> section can enable this option. When enabled,
1035 <varname>Activate=yes</varname> is implied. Defaults to unset.</para>
1036 </listitem>
1037 </varlistentry>
1038 </variablelist>
1039 </refsect1>
1040
1041 <refsect1>
1042 <title>[MACsecReceiveAssociation] Section Options</title>
1043
1044 <para>The <literal>[MACsecReceiveAssociation]</literal> section only applies for
1045 network devices of kind <literal>macsec</literal>, and accepts the
1046 following keys:</para>
1047
1048 <variablelist class='network-directives'>
1049 <varlistentry>
1050 <term><varname>Port=</varname></term>
1051 <listitem>
1052 <para>Accepts the same key in <literal>[MACsecReceiveChannel]</literal> section.</para>
1053 </listitem>
1054 </varlistentry>
1055 <varlistentry>
1056 <term><varname>MACAddress=</varname></term>
1057 <listitem>
1058 <para>Accepts the same key in <literal>[MACsecReceiveChannel]</literal> section.</para>
1059 </listitem>
1060 </varlistentry>
1061 <varlistentry>
1062 <term><varname>PacketNumber=</varname></term>
1063 <listitem>
1064 <para>Accepts the same key in <literal>[MACsecTransmitAssociation]</literal> section.</para>
1065 </listitem>
1066 </varlistentry>
1067 <varlistentry>
1068 <term><varname>KeyId=</varname></term>
1069 <listitem>
1070 <para>Accepts the same key in <literal>[MACsecTransmitAssociation]</literal> section.</para>
1071 </listitem>
1072 </varlistentry>
1073 <varlistentry>
1074 <term><varname>Key=</varname></term>
1075 <listitem>
1076 <para>Accepts the same key in <literal>[MACsecTransmitAssociation]</literal> section.</para>
1077 </listitem>
1078 </varlistentry>
1079 <varlistentry>
1080 <term><varname>KeyFile=</varname></term>
1081 <listitem>
1082 <para>Accepts the same key in <literal>[MACsecTransmitAssociation]</literal> section.</para>
1083 </listitem>
1084 </varlistentry>
1085 <varlistentry>
1086 <term><varname>Activate=</varname></term>
1087 <listitem>
1088 <para>Accepts the same key in <literal>[MACsecTransmitAssociation]</literal> section.</para>
1089 </listitem>
1090 </varlistentry>
1091 </variablelist>
1092 </refsect1>
1093
1094 <refsect1>
1095 <title>[Tunnel] Section Options</title>
1096
1097 <para>The <literal>[Tunnel]</literal> section only applies for
1098 netdevs of kind
1099 <literal>ipip</literal>,
1100 <literal>sit</literal>,
1101 <literal>gre</literal>,
1102 <literal>gretap</literal>,
1103 <literal>ip6gre</literal>,
1104 <literal>ip6gretap</literal>,
1105 <literal>vti</literal>,
1106 <literal>vti6</literal>,
1107 <literal>ip6tnl</literal>, and
1108 <literal>erspan</literal> and accepts
1109 the following keys:</para>
1110
1111 <variablelist class='network-directives'>
1112 <varlistentry>
1113 <term><varname>Local=</varname></term>
1114 <listitem>
1115 <para>A static local address for tunneled packets. It must be an address on another interface of
1116 this host, or the special value <literal>any</literal>.</para>
1117 </listitem>
1118 </varlistentry>
1119 <varlistentry>
1120 <term><varname>Remote=</varname></term>
1121 <listitem>
1122 <para>The remote endpoint of the tunnel. Takes an IP address or the special value
1123 <literal>any</literal>.</para>
1124 </listitem>
1125 </varlistentry>
1126 <varlistentry>
1127 <term><varname>TOS=</varname></term>
1128 <listitem>
1129 <para>The Type Of Service byte value for a tunnel interface.
1130 For details about the TOS, see the
1131 <ulink url="http://tools.ietf.org/html/rfc1349"> Type of
1132 Service in the Internet Protocol Suite </ulink> document.
1133 </para>
1134 </listitem>
1135 </varlistentry>
1136 <varlistentry>
1137 <term><varname>TTL=</varname></term>
1138 <listitem>
1139 <para>A fixed Time To Live N on tunneled packets. N is a
1140 number in the range 1–255. 0 is a special value meaning that
1141 packets inherit the TTL value. The default value for IPv4
1142 tunnels is: inherit. The default value for IPv6 tunnels is
1143 64.</para>
1144 </listitem>
1145 </varlistentry>
1146 <varlistentry>
1147 <term><varname>DiscoverPathMTU=</varname></term>
1148 <listitem>
1149 <para>Takes a boolean. When true, enables Path MTU Discovery on
1150 the tunnel.</para>
1151 </listitem>
1152 </varlistentry>
1153 <varlistentry>
1154 <term><varname>IPv6FlowLabel=</varname></term>
1155 <listitem>
1156 <para>Configures the 20-bit flow label (see <ulink url="https://tools.ietf.org/html/rfc6437">
1157 RFC 6437</ulink>) field in the IPv6 header (see <ulink url="https://tools.ietf.org/html/rfc2460">
1158 RFC 2460</ulink>), which is used by a node to label packets of a flow.
1159 It is only used for IPv6 tunnels.
1160 A flow label of zero is used to indicate packets that have
1161 not been labeled.
1162 It can be configured to a value in the range 0–0xFFFFF, or be
1163 set to <literal>inherit</literal>, in which case the original flowlabel is used.</para>
1164 </listitem>
1165 </varlistentry>
1166 <varlistentry>
1167 <term><varname>CopyDSCP=</varname></term>
1168 <listitem>
1169 <para>Takes a boolean. When true, the Differentiated Service Code
1170 Point (DSCP) field will be copied to the inner header from
1171 outer header during the decapsulation of an IPv6 tunnel
1172 packet. DSCP is a field in an IP packet that enables different
1173 levels of service to be assigned to network traffic.
1174 Defaults to <literal>no</literal>.
1175 </para>
1176 </listitem>
1177 </varlistentry>
1178 <varlistentry>
1179 <term><varname>EncapsulationLimit=</varname></term>
1180 <listitem>
1181 <para>The Tunnel Encapsulation Limit option specifies how many additional
1182 levels of encapsulation are permitted to be prepended to the packet.
1183 For example, a Tunnel Encapsulation Limit option containing a limit
1184 value of zero means that a packet carrying that option may not enter
1185 another tunnel before exiting the current tunnel.
1186 (see <ulink url="https://tools.ietf.org/html/rfc2473#section-4.1.1"> RFC 2473</ulink>).
1187 The valid range is 0–255 and <literal>none</literal>. Defaults to 4.
1188 </para>
1189 </listitem>
1190 </varlistentry>
1191 <varlistentry>
1192 <term><varname>Key=</varname></term>
1193 <listitem>
1194 <para>The <varname>Key=</varname> parameter specifies the same key to use in
1195 both directions (<varname>InputKey=</varname> and <varname>OutputKey=</varname>).
1196 The <varname>Key=</varname> is either a number or an IPv4 address-like dotted quad.
1197 It is used as mark-configured SAD/SPD entry as part of the lookup key (both in data
1198 and control path) in ip xfrm (framework used to implement IPsec protocol).
1199 See <ulink url="http://man7.org/linux/man-pages/man8/ip-xfrm.8.html">
1200 ip-xfrm — transform configuration</ulink> for details. It is only used for VTI/VTI6,
1201 GRE, GRETAP, and ERSPAN tunnels.</para>
1202 </listitem>
1203 </varlistentry>
1204 <varlistentry>
1205 <term><varname>InputKey=</varname></term>
1206 <listitem>
1207 <para>The <varname>InputKey=</varname> parameter specifies the key to use for input.
1208 The format is same as <varname>Key=</varname>. It is only used for VTI/VTI6, GRE, GRETAP,
1209 and ERSPAN tunnels.</para>
1210 </listitem>
1211 </varlistentry>
1212 <varlistentry>
1213 <term><varname>OutputKey=</varname></term>
1214 <listitem>
1215 <para>The <varname>OutputKey=</varname> parameter specifies the key to use for output.
1216 The format is same as <varname>Key=</varname>. It is only used for VTI/VTI6, GRE, GRETAP,
1217 and ERSPAN tunnels.</para>
1218 </listitem>
1219 </varlistentry>
1220 <varlistentry>
1221 <term><varname>Mode=</varname></term>
1222 <listitem>
1223 <para>An <literal>ip6tnl</literal> tunnel can be in one of three
1224 modes
1225 <literal>ip6ip6</literal> for IPv6 over IPv6,
1226 <literal>ipip6</literal> for IPv4 over IPv6 or
1227 <literal>any</literal> for either.
1228 </para>
1229 </listitem>
1230 </varlistentry>
1231 <varlistentry>
1232 <term><varname>Independent=</varname></term>
1233 <listitem>
1234 <para>Takes a boolean. When true tunnel does not require .network file. Created as "tunnel@NONE".
1235 Defaults to <literal>false</literal>.
1236 </para>
1237 </listitem>
1238 </varlistentry>
1239 <varlistentry>
1240 <term><varname>AssignToLoopback=</varname></term>
1241 <listitem>
1242 <para>Takes a boolean. If set to <literal>yes</literal>, the loopback interface <literal>lo</literal>
1243 is used as the underlying device of the tunnel interface. Defaults to <literal>no</literal>.</para>
1244 </listitem>
1245 </varlistentry>
1246 <varlistentry>
1247 <term><varname>AllowLocalRemote=</varname></term>
1248 <listitem>
1249 <para>Takes a boolean. When true allows tunnel traffic on <varname>ip6tnl</varname> devices where the remote endpoint is a local host address.
1250 When unset, the kernel's default will be used.
1251 </para>
1252 </listitem>
1253 </varlistentry>
1254 <varlistentry>
1255 <term><varname>FooOverUDP=</varname></term>
1256 <listitem>
1257 <para>Takes a boolean. Specifies whether <varname>FooOverUDP=</varname> tunnel is to be configured.
1258 Defaults to false. This takes effects only for IPIP, SIT, GRE, and GRETAP tunnels.
1259 For more detail information see
1260 <ulink url="https://lwn.net/Articles/614348">Foo over UDP</ulink></para>
1261 </listitem>
1262 </varlistentry>
1263 <varlistentry>
1264 <term><varname>FOUDestinationPort=</varname></term>
1265 <listitem>
1266 <para>This setting specifies the UDP destination port for encapsulation.
1267 This field is mandatory when <varname>FooOverUDP=yes</varname>, and is not set by default.</para>
1268 </listitem>
1269 </varlistentry>
1270 <varlistentry>
1271 <term><varname>FOUSourcePort=</varname></term>
1272 <listitem>
1273 <para>This setting specifies the UDP source port for encapsulation. Defaults to <constant>0</constant>
1274 — that is, the source port for packets is left to the network stack to decide.</para>
1275 </listitem>
1276 </varlistentry>
1277 <varlistentry>
1278 <term><varname>Encapsulation=</varname></term>
1279 <listitem>
1280 <para>Accepts the same key as in the <literal>[FooOverUDP]</literal> section.</para>
1281 </listitem>
1282 </varlistentry>
1283 <varlistentry>
1284 <term><varname>IPv6RapidDeploymentPrefix=</varname></term>
1285 <listitem>
1286 <para>Reconfigure the tunnel for <ulink url="https://tools.ietf.org/html/rfc5569">IPv6 Rapid
1287 Deployment</ulink>, also known as 6rd. The value is an ISP-specific IPv6 prefix with a non-zero length. Only
1288 applicable to SIT tunnels.</para>
1289 </listitem>
1290 </varlistentry>
1291 <varlistentry>
1292 <term><varname>ISATAP=</varname></term>
1293 <listitem>
1294 <para>Takes a boolean. If set, configures the tunnel as Intra-Site Automatic Tunnel Addressing Protocol (ISATAP) tunnel.
1295 Only applicable to SIT tunnels. When unset, the kernel's default will be used.</para>
1296 </listitem>
1297 </varlistentry>
1298 <varlistentry>
1299 <term><varname>SerializeTunneledPackets=</varname></term>
1300 <listitem>
1301 <para>Takes a boolean. If set to yes, then packets are serialized. Only applies for GRE,
1302 GRETAP, and ERSPAN tunnels. When unset, the kernel's default will be used.
1303 </para>
1304 </listitem>
1305 </varlistentry>
1306 <varlistentry>
1307 <term><varname>ERSPANIndex=</varname></term>
1308 <listitem>
1309 <para>Specifies the ERSPAN index field for the interface, an integer in the range 1-1048575 associated with
1310 the ERSPAN traffic's source port and direction. This field is mandatory.
1311 </para>
1312 </listitem>
1313 </varlistentry>
1314 </variablelist>
1315 </refsect1>
1316
1317 <refsect1>
1318 <title>[FooOverUDP] Section Options</title>
1319
1320 <para>The <literal>[FooOverUDP]</literal> section only applies for
1321 netdevs of kind <literal>fou</literal> and accepts the
1322 following keys:</para>
1323
1324 <variablelist class='network-directives'>
1325 <varlistentry>
1326 <term><varname>Encapsulation=</varname></term>
1327 <listitem>
1328 <para>Specifies the encapsulation mechanism used to store networking packets of various protocols inside the UDP packets. Supports the following values:
1329
1330 <literal>FooOverUDP</literal> provides the simplest no frills model of UDP encapsulation, it simply encapsulates
1331 packets directly in the UDP payload.
1332 <literal>GenericUDPEncapsulation</literal> is a generic and extensible encapsulation, it allows encapsulation of packets for any IP
1333 protocol and optional data as part of the encapsulation.
1334 For more detailed information see <ulink url="https://lwn.net/Articles/615044">Generic UDP Encapsulation</ulink>.
1335 Defaults to <literal>FooOverUDP</literal>.
1336 </para>
1337 </listitem>
1338 </varlistentry>
1339 <varlistentry>
1340 <term><varname>Port=</varname></term>
1341 <listitem>
1342 <para>Specifies the port number, where the IP encapsulation packets will arrive. Please take note that the packets
1343 will arrive with the encapsulation will be removed. Then they will be manually fed back into the network stack, and sent ahead
1344 for delivery to the real destination. This option is mandatory.</para>
1345 </listitem>
1346 </varlistentry>
1347 <varlistentry>
1348 <term><varname>PeerPort=</varname></term>
1349 <listitem>
1350 <para>Specifies the peer port number. Defaults to unset. Note that when peer port is set <literal>Peer=</literal> address is mandotory.</para>
1351 </listitem>
1352 </varlistentry>
1353 <varlistentry>
1354 <term><varname>Protocol=</varname></term>
1355 <listitem>
1356 <para>The <varname>Protocol=</varname> specifies the protocol number of the packets arriving
1357 at the UDP port. When <varname>Encapsulation=FooOverUDP</varname>, this field is mandatory
1358 and is not set by default. Takes an IP protocol name such as <literal>gre</literal> or
1359 <literal>ipip</literal>, or an integer within the range 1-255. When
1360 <varname>Encapsulation=GenericUDPEncapsulation</varname>, this must not be specified.</para>
1361 </listitem>
1362 </varlistentry>
1363 <varlistentry>
1364 <term><varname>Peer=</varname></term>
1365 <listitem>
1366 <para>Configures peer IP address. Note that when peer address is set <literal>PeerPort=</literal> is mandotory.</para>
1367 </listitem>
1368 </varlistentry>
1369 <varlistentry>
1370 <term><varname>Local=</varname></term>
1371 <listitem>
1372 <para>Configures local IP address.</para>
1373 </listitem>
1374 </varlistentry>
1375 </variablelist>
1376 </refsect1>
1377
1378 <refsect1>
1379 <title>[Peer] Section Options</title>
1380
1381 <para>The <literal>[Peer]</literal> section only applies for
1382 netdevs of kind <literal>veth</literal> and accepts the
1383 following keys:</para>
1384
1385 <variablelist class='network-directives'>
1386 <varlistentry>
1387 <term><varname>Name=</varname></term>
1388 <listitem>
1389 <para>The interface name used when creating the netdev.
1390 This option is compulsory.</para>
1391 </listitem>
1392 </varlistentry>
1393 <varlistentry>
1394 <term><varname>MACAddress=</varname></term>
1395 <listitem>
1396 <para>The peer MACAddress, if not set, it is generated in
1397 the same way as the MAC address of the main
1398 interface.</para>
1399 </listitem>
1400 </varlistentry>
1401 </variablelist>
1402 </refsect1>
1403
1404 <refsect1>
1405 <title>[VXCAN] Section Options</title>
1406
1407 <para>The <literal>[VXCAN]</literal> section only applies for
1408 netdevs of kind <literal>vxcan</literal> and accepts the
1409 following key:</para>
1410
1411 <variablelist class='network-directives'>
1412 <varlistentry>
1413 <term><varname>Peer=</varname></term>
1414 <listitem>
1415 <para>The peer interface name used when creating the netdev.
1416 This option is compulsory.</para>
1417 </listitem>
1418 </varlistentry>
1419 </variablelist>
1420 </refsect1>
1421
1422 <refsect1>
1423 <title>[Tun] Section Options</title>
1424
1425 <para>The <literal>[Tun]</literal> section only applies for
1426 netdevs of kind <literal>tun</literal>, and accepts the following
1427 keys:</para>
1428
1429 <variablelist class='network-directives'>
1430 <varlistentry>
1431 <term><varname>MultiQueue=</varname></term>
1432 <listitem><para>Takes a boolean. Configures whether
1433 to use multiple file descriptors (queues) to parallelize
1434 packets sending and receiving. Defaults to
1435 <literal>no</literal>.</para>
1436 </listitem>
1437 </varlistentry>
1438 <varlistentry>
1439 <term><varname>PacketInfo=</varname></term>
1440 <listitem><para>Takes a boolean. Configures whether
1441 packets should be prepended with four extra bytes (two flag
1442 bytes and two protocol bytes). If disabled, it indicates that
1443 the packets will be pure IP packets. Defaults to
1444 <literal>no</literal>.</para>
1445 </listitem>
1446 </varlistentry>
1447 <varlistentry>
1448 <term><varname>VNetHeader=</varname></term>
1449 <listitem><para>Takes a boolean. Configures
1450 IFF_VNET_HDR flag for a tun or tap device. It allows sending
1451 and receiving larger Generic Segmentation Offload (GSO)
1452 packets. This may increase throughput significantly.
1453 Defaults to
1454 <literal>no</literal>.</para>
1455 </listitem>
1456 </varlistentry>
1457 <varlistentry>
1458 <term><varname>User=</varname></term>
1459 <listitem><para>User to grant access to the
1460 <filename>/dev/net/tun</filename> device.</para>
1461 </listitem>
1462 </varlistentry>
1463 <varlistentry>
1464 <term><varname>Group=</varname></term>
1465 <listitem><para>Group to grant access to the
1466 <filename>/dev/net/tun</filename> device.</para>
1467 </listitem>
1468 </varlistentry>
1469 </variablelist>
1470 </refsect1>
1471
1472 <refsect1>
1473 <title>[Tap] Section Options</title>
1474
1475 <para>The <literal>[Tap]</literal> section only applies for
1476 netdevs of kind <literal>tap</literal>, and accepts the same keys
1477 as the <literal>[Tun]</literal> section.</para>
1478 </refsect1>
1479
1480 <refsect1>
1481 <title>[WireGuard] Section Options</title>
1482
1483 <para>The <literal>[WireGuard]</literal> section accepts the following
1484 keys:</para>
1485
1486 <variablelist class='network-directives'>
1487 <varlistentry>
1488 <term><varname>PrivateKey=</varname></term>
1489 <listitem>
1490 <para>The Base64 encoded private key for the interface. It can be
1491 generated using the <command>wg genkey</command> command
1492 (see <citerefentry project="wireguard"><refentrytitle>wg</refentrytitle><manvolnum>8</manvolnum></citerefentry>).
1493 This option or <varname>PrivateKeyFile=</varname> is mandatory to use WireGuard.
1494 Note that because this information is secret, you may want to set
1495 the permissions of the .netdev file to be owned by <literal>root:systemd-network</literal>
1496 with a <literal>0640</literal> file mode.</para>
1497 </listitem>
1498 </varlistentry>
1499 <varlistentry>
1500 <term><varname>PrivateKeyFile=</varname></term>
1501 <listitem>
1502 <para>Takes an absolute path to a file which contains the Base64 encoded private key for the interface.
1503 When this option is specified, then <varname>PrivateKey=</varname> is ignored.
1504 Note that the file must be readable by the user <literal>systemd-network</literal>, so it
1505 should be, e.g., owned by <literal>root:systemd-network</literal> with a
1506 <literal>0640</literal> file mode.</para>
1507 </listitem>
1508 </varlistentry>
1509 <varlistentry>
1510 <term><varname>ListenPort=</varname></term>
1511 <listitem>
1512 <para>Sets UDP port for listening. Takes either value between 1 and 65535
1513 or <literal>auto</literal>. If <literal>auto</literal> is specified,
1514 the port is automatically generated based on interface name.
1515 Defaults to <literal>auto</literal>.</para>
1516 </listitem>
1517 </varlistentry>
1518 <varlistentry>
1519 <term><varname>FirewallMark=</varname></term>
1520 <listitem>
1521 <para>Sets a firewall mark on outgoing WireGuard packets from this interface. Takes a number between 1 and 4294967295.</para>
1522 </listitem>
1523 </varlistentry>
1524 </variablelist>
1525 </refsect1>
1526
1527 <refsect1>
1528 <title>[WireGuardPeer] Section Options</title>
1529
1530 <para>The <literal>[WireGuardPeer]</literal> section accepts the following
1531 keys:</para>
1532
1533 <variablelist class='network-directives'>
1534 <varlistentry>
1535 <term><varname>PublicKey=</varname></term>
1536 <listitem>
1537 <para>Sets a Base64 encoded public key calculated by <command>wg pubkey</command>
1538 (see <citerefentry project="wireguard"><refentrytitle>wg</refentrytitle><manvolnum>8</manvolnum></citerefentry>)
1539 from a private key, and usually transmitted out of band to the
1540 author of the configuration file. This option is mandatory for this
1541 section.</para>
1542 </listitem>
1543 </varlistentry>
1544 <varlistentry>
1545 <term><varname>PresharedKey=</varname></term>
1546 <listitem>
1547 <para>Optional preshared key for the interface. It can be generated
1548 by the <command>wg genpsk</command> command. This option adds an
1549 additional layer of symmetric-key cryptography to be mixed into the
1550 already existing public-key cryptography, for post-quantum
1551 resistance.
1552 Note that because this information is secret, you may want to set
1553 the permissions of the .netdev file to be owned by <literal>root:systemd-network</literal>
1554 with a <literal>0640</literal> file mode.</para>
1555 </listitem>
1556 </varlistentry>
1557 <varlistentry>
1558 <term><varname>PresharedKeyFile=</varname></term>
1559 <listitem>
1560 <para>Takes an absolute path to a file which contains the Base64 encoded preshared key for the
1561 peer. When this option is specified, then <varname>PresharedKey=</varname> is ignored.
1562 Note that the file must be readable by the user <literal>systemd-network</literal>, so it
1563 should be, e.g., owned by <literal>root:systemd-network</literal> with a
1564 <literal>0640</literal> file mode.</para>
1565 </listitem>
1566 </varlistentry>
1567 <varlistentry>
1568 <term><varname>AllowedIPs=</varname></term>
1569 <listitem>
1570 <para>Sets a comma-separated list of IP (v4 or v6) addresses with CIDR masks
1571 from which this peer is allowed to send incoming traffic and to
1572 which outgoing traffic for this peer is directed. The catch-all
1573 0.0.0.0/0 may be specified for matching all IPv4 addresses, and
1574 ::/0 may be specified for matching all IPv6 addresses. </para>
1575 </listitem>
1576 </varlistentry>
1577 <varlistentry>
1578 <term><varname>Endpoint=</varname></term>
1579 <listitem>
1580 <para>Sets an endpoint IP address or hostname, followed by a colon, and then
1581 a port number. This endpoint will be updated automatically once to
1582 the most recent source IP address and port of correctly
1583 authenticated packets from the peer at configuration time.</para>
1584 </listitem>
1585 </varlistentry>
1586 <varlistentry>
1587 <term><varname>PersistentKeepalive=</varname></term>
1588 <listitem>
1589 <para>Sets a seconds interval, between 1 and 65535 inclusive, of how often
1590 to send an authenticated empty packet to the peer for the purpose
1591 of keeping a stateful firewall or NAT mapping valid persistently.
1592 For example, if the interface very rarely sends traffic, but it
1593 might at anytime receive traffic from a peer, and it is behind NAT,
1594 the interface might benefit from having a persistent keepalive
1595 interval of 25 seconds. If set to 0 or "off", this option is
1596 disabled. By default or when unspecified, this option is off.
1597 Most users will not need this.</para>
1598 </listitem>
1599 </varlistentry>
1600 </variablelist>
1601 </refsect1>
1602
1603 <refsect1>
1604 <title>[Bond] Section Options</title>
1605
1606 <para>The <literal>[Bond]</literal> section accepts the following
1607 key:</para>
1608
1609 <variablelist class='network-directives'>
1610 <varlistentry>
1611 <term><varname>Mode=</varname></term>
1612 <listitem>
1613 <para>Specifies one of the bonding policies. The default is
1614 <literal>balance-rr</literal> (round robin). Possible values are
1615 <literal>balance-rr</literal>,
1616 <literal>active-backup</literal>,
1617 <literal>balance-xor</literal>,
1618 <literal>broadcast</literal>,
1619 <literal>802.3ad</literal>,
1620 <literal>balance-tlb</literal>, and
1621 <literal>balance-alb</literal>.
1622 </para>
1623 </listitem>
1624 </varlistentry>
1625
1626 <varlistentry>
1627 <term><varname>TransmitHashPolicy=</varname></term>
1628 <listitem>
1629 <para>Selects the transmit hash policy to use for slave
1630 selection in balance-xor, 802.3ad, and tlb modes. Possible
1631 values are
1632 <literal>layer2</literal>,
1633 <literal>layer3+4</literal>,
1634 <literal>layer2+3</literal>,
1635 <literal>encap2+3</literal>, and
1636 <literal>encap3+4</literal>.
1637 </para>
1638 </listitem>
1639 </varlistentry>
1640
1641 <varlistentry>
1642 <term><varname>LACPTransmitRate=</varname></term>
1643 <listitem>
1644 <para>Specifies the rate with which link partner transmits
1645 Link Aggregation Control Protocol Data Unit packets in
1646 802.3ad mode. Possible values are <literal>slow</literal>,
1647 which requests partner to transmit LACPDUs every 30 seconds,
1648 and <literal>fast</literal>, which requests partner to
1649 transmit LACPDUs every second. The default value is
1650 <literal>slow</literal>.</para>
1651 </listitem>
1652 </varlistentry>
1653
1654 <varlistentry>
1655 <term><varname>MIIMonitorSec=</varname></term>
1656 <listitem>
1657 <para>Specifies the frequency that Media Independent
1658 Interface link monitoring will occur. A value of zero
1659 disables MII link monitoring. This value is rounded down to
1660 the nearest millisecond. The default value is 0.</para>
1661 </listitem>
1662 </varlistentry>
1663
1664 <varlistentry>
1665 <term><varname>UpDelaySec=</varname></term>
1666 <listitem>
1667 <para>Specifies the delay before a link is enabled after a
1668 link up status has been detected. This value is rounded down
1669 to a multiple of MIIMonitorSec. The default value is
1670 0.</para>
1671 </listitem>
1672 </varlistentry>
1673
1674 <varlistentry>
1675 <term><varname>DownDelaySec=</varname></term>
1676 <listitem>
1677 <para>Specifies the delay before a link is disabled after a
1678 link down status has been detected. This value is rounded
1679 down to a multiple of MIIMonitorSec. The default value is
1680 0.</para>
1681 </listitem>
1682 </varlistentry>
1683
1684 <varlistentry>
1685 <term><varname>LearnPacketIntervalSec=</varname></term>
1686 <listitem>
1687 <para>Specifies the number of seconds between instances where the bonding
1688 driver sends learning packets to each slave peer switch.
1689 The valid range is 1–0x7fffffff; the default value is 1. This option
1690 has an effect only for the balance-tlb and balance-alb modes.</para>
1691 </listitem>
1692 </varlistentry>
1693
1694 <varlistentry>
1695 <term><varname>AdSelect=</varname></term>
1696 <listitem>
1697 <para>Specifies the 802.3ad aggregation selection logic to use. Possible values are
1698 <literal>stable</literal>,
1699 <literal>bandwidth</literal> and
1700 <literal>count</literal>.
1701 </para>
1702 </listitem>
1703 </varlistentry>
1704
1705 <varlistentry>
1706 <term><varname>AdActorSystemPriority=</varname></term>
1707 <listitem>
1708 <para>Specifies the 802.3ad actor system priority. Ranges [1-65535].</para>
1709 </listitem>
1710 </varlistentry>
1711
1712 <varlistentry>
1713 <term><varname>AdUserPortKey=</varname></term>
1714 <listitem>
1715 <para>Specifies the 802.3ad user defined portion of the port key. Ranges [0-1023].</para>
1716 </listitem>
1717 </varlistentry>
1718
1719 <varlistentry>
1720 <term><varname>AdActorSystem=</varname></term>
1721 <listitem>
1722 <para>Specifies the 802.3ad system mac address. This can not be either NULL or Multicast.</para>
1723 </listitem>
1724 </varlistentry>
1725
1726 <varlistentry>
1727 <term><varname>FailOverMACPolicy=</varname></term>
1728 <listitem>
1729 <para>Specifies whether the active-backup mode should set all slaves to
1730 the same MAC address at the time of enslavement or, when enabled, to perform special handling of the
1731 bond's MAC address in accordance with the selected policy. The default policy is none.
1732 Possible values are
1733 <literal>none</literal>,
1734 <literal>active</literal> and
1735 <literal>follow</literal>.
1736 </para>
1737 </listitem>
1738 </varlistentry>
1739
1740 <varlistentry>
1741 <term><varname>ARPValidate=</varname></term>
1742 <listitem>
1743 <para>Specifies whether or not ARP probes and replies should be
1744 validated in any mode that supports ARP monitoring, or whether
1745 non-ARP traffic should be filtered (disregarded) for link
1746 monitoring purposes. Possible values are
1747 <literal>none</literal>,
1748 <literal>active</literal>,
1749 <literal>backup</literal> and
1750 <literal>all</literal>.
1751 </para>
1752 </listitem>
1753 </varlistentry>
1754
1755 <varlistentry>
1756 <term><varname>ARPIntervalSec=</varname></term>
1757 <listitem>
1758 <para>Specifies the ARP link monitoring frequency. A value of 0 disables ARP monitoring. The
1759 default value is 0, and the default unit seconds.
1760 </para>
1761 </listitem>
1762 </varlistentry>
1763
1764 <varlistentry>
1765 <term><varname>ARPIPTargets=</varname></term>
1766 <listitem>
1767 <para>Specifies the IP addresses to use as ARP monitoring peers when
1768 ARPIntervalSec is greater than 0. These are the targets of the ARP request
1769 sent to determine the health of the link to the targets.
1770 Specify these values in IPv4 dotted decimal format. At least one IP
1771 address must be given for ARP monitoring to function. The
1772 maximum number of targets that can be specified is 16. The
1773 default value is no IP addresses.
1774 </para>
1775 </listitem>
1776 </varlistentry>
1777
1778 <varlistentry>
1779 <term><varname>ARPAllTargets=</varname></term>
1780 <listitem>
1781 <para>Specifies the quantity of ARPIPTargets that must be reachable
1782 in order for the ARP monitor to consider a slave as being up.
1783 This option affects only active-backup mode for slaves with
1784 ARPValidate enabled. Possible values are
1785 <literal>any</literal> and
1786 <literal>all</literal>.
1787 </para>
1788 </listitem>
1789 </varlistentry>
1790
1791 <varlistentry>
1792 <term><varname>PrimaryReselectPolicy=</varname></term>
1793 <listitem>
1794 <para>Specifies the reselection policy for the primary slave. This
1795 affects how the primary slave is chosen to become the active slave
1796 when failure of the active slave or recovery of the primary slave
1797 occurs. This option is designed to prevent flip-flopping between
1798 the primary slave and other slaves. Possible values are
1799 <literal>always</literal>,
1800 <literal>better</literal> and
1801 <literal>failure</literal>.
1802 </para>
1803 </listitem>
1804 </varlistentry>
1805
1806 <varlistentry>
1807 <term><varname>ResendIGMP=</varname></term>
1808 <listitem>
1809 <para>Specifies the number of IGMP membership reports to be issued after
1810 a failover event. One membership report is issued immediately after
1811 the failover, subsequent packets are sent in each 200ms interval.
1812 The valid range is 0–255. Defaults to 1. A value of 0
1813 prevents the IGMP membership report from being issued in response
1814 to the failover event.
1815 </para>
1816 </listitem>
1817 </varlistentry>
1818
1819 <varlistentry>
1820 <term><varname>PacketsPerSlave=</varname></term>
1821 <listitem>
1822 <para>Specify the number of packets to transmit through a slave before
1823 moving to the next one. When set to 0, then a slave is chosen at
1824 random. The valid range is 0–65535. Defaults to 1. This option
1825 only has effect when in balance-rr mode.
1826 </para>
1827 </listitem>
1828 </varlistentry>
1829
1830 <varlistentry>
1831 <term><varname>GratuitousARP=</varname></term>
1832 <listitem>
1833 <para>Specify the number of peer notifications (gratuitous ARPs and
1834 unsolicited IPv6 Neighbor Advertisements) to be issued after a
1835 failover event. As soon as the link is up on the new slave,
1836 a peer notification is sent on the bonding device and each
1837 VLAN sub-device. This is repeated at each link monitor interval
1838 (ARPIntervalSec or MIIMonitorSec, whichever is active) if the number is
1839 greater than 1. The valid range is 0–255. The default value is 1.
1840 These options affect only the active-backup mode.
1841 </para>
1842 </listitem>
1843 </varlistentry>
1844
1845 <varlistentry>
1846 <term><varname>AllSlavesActive=</varname></term>
1847 <listitem>
1848 <para>Takes a boolean. Specifies that duplicate frames (received on inactive ports)
1849 should be dropped when false, or delivered when true. Normally, bonding will drop
1850 duplicate frames (received on inactive ports), which is desirable for
1851 most users. But there are some times it is nice to allow duplicate
1852 frames to be delivered. The default value is false (drop duplicate frames
1853 received on inactive ports).
1854 </para>
1855 </listitem>
1856 </varlistentry>
1857
1858 <varlistentry>
1859 <term><varname>DynamicTransmitLoadBalancing=</varname></term>
1860 <listitem>
1861 <para>Takes a boolean. Specifies if dynamic shuffling of flows is enabled. Applies only
1862 for balance-tlb mode. Defaults to unset.
1863 </para>
1864 </listitem>
1865 </varlistentry>
1866
1867 <varlistentry>
1868 <term><varname>MinLinks=</varname></term>
1869 <listitem>
1870 <para>Specifies the minimum number of links that must be active before
1871 asserting carrier. The default value is 0.
1872 </para>
1873 </listitem>
1874 </varlistentry>
1875 </variablelist>
1876
1877 <para>For more detail information see
1878 <ulink url="https://www.kernel.org/doc/Documentation/networking/bonding.txt">
1879 Linux Ethernet Bonding Driver HOWTO</ulink></para>
1880 </refsect1>
1881
1882 <refsect1>
1883 <title>[Xfrm] Section Options</title>
1884
1885 <para>The <literal>[Xfrm]</literal> section accepts the following
1886 keys:</para>
1887
1888 <variablelist class='network-directives'>
1889 <varlistentry>
1890 <term><varname>InterfaceId=</varname></term>
1891 <listitem>
1892 <para>Sets the ID/key of the xfrm interface which needs to be associated with a SA/policy.
1893 Can be decimal or hexadecimal, valid range is 0-0xffffffff, defaults to 0.</para>
1894 </listitem>
1895 </varlistentry>
1896 <varlistentry>
1897 <term><varname>Independent=</varname></term>
1898 <listitem>
1899 <para>Takes a boolean. If set to <literal>no</literal>, the xfrm interface should have an
1900 underlying device which can be used for hardware offloading. Defaults to <literal>no</literal>.
1901 See <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
1902 for how to configure the underlying device.</para>
1903 </listitem>
1904 </varlistentry>
1905 </variablelist>
1906
1907 <para>For more detail information see
1908 <ulink url="https://lwn.net/Articles/757391">
1909 Virtual xfrm interfaces</ulink></para>
1910 </refsect1>
1911
1912 <refsect1>
1913 <title>[VRF] Section Options</title>
1914 <para>The <literal>[VRF]</literal> section only applies for
1915 netdevs of kind <literal>vrf</literal> and accepts the
1916 following key:</para>
1917
1918 <variablelist class='network-directives'>
1919 <varlistentry>
1920 <term><varname>Table=</varname></term>
1921 <listitem>
1922 <para>The numeric routing table identifier. This option is compulsory.</para>
1923 </listitem>
1924 </varlistentry>
1925 </variablelist>
1926 </refsect1>
1927
1928 <refsect1>
1929 <title>Examples</title>
1930 <example>
1931 <title>/etc/systemd/network/25-bridge.netdev</title>
1932
1933 <programlisting>[NetDev]
1934 Name=bridge0
1935 Kind=bridge</programlisting>
1936 </example>
1937
1938 <example>
1939 <title>/etc/systemd/network/25-vlan1.netdev</title>
1940
1941 <programlisting>[Match]
1942 Virtualization=no
1943
1944 [NetDev]
1945 Name=vlan1
1946 Kind=vlan
1947
1948 [VLAN]
1949 Id=1</programlisting>
1950 </example>
1951 <example>
1952 <title>/etc/systemd/network/25-ipip.netdev</title>
1953 <programlisting>[NetDev]
1954 Name=ipip-tun
1955 Kind=ipip
1956 MTUBytes=1480
1957
1958 [Tunnel]
1959 Local=192.168.223.238
1960 Remote=192.169.224.239
1961 TTL=64</programlisting>
1962 </example>
1963 <example>
1964 <title>/etc/systemd/network/1-fou-tunnel.netdev</title>
1965 <programlisting>[NetDev]
1966 Name=fou-tun
1967 Kind=fou
1968
1969 [FooOverUDP]
1970 Port=5555
1971 Protocol=4
1972 </programlisting>
1973 </example>
1974 <example>
1975 <title>/etc/systemd/network/25-fou-ipip.netdev</title>
1976 <programlisting>[NetDev]
1977 Name=ipip-tun
1978 Kind=ipip
1979
1980 [Tunnel]
1981 Independent=yes
1982 Local=10.65.208.212
1983 Remote=10.65.208.211
1984 FooOverUDP=yes
1985 FOUDestinationPort=5555
1986 </programlisting>
1987 </example>
1988 <example>
1989 <title>/etc/systemd/network/25-tap.netdev</title>
1990 <programlisting>[NetDev]
1991 Name=tap-test
1992 Kind=tap
1993
1994 [Tap]
1995 MultiQueue=yes
1996 PacketInfo=yes</programlisting> </example>
1997
1998 <example>
1999 <title>/etc/systemd/network/25-sit.netdev</title>
2000 <programlisting>[NetDev]
2001 Name=sit-tun
2002 Kind=sit
2003 MTUBytes=1480
2004
2005 [Tunnel]
2006 Local=10.65.223.238
2007 Remote=10.65.223.239</programlisting>
2008 </example>
2009
2010 <example>
2011 <title>/etc/systemd/network/25-6rd.netdev</title>
2012 <programlisting>[NetDev]
2013 Name=6rd-tun
2014 Kind=sit
2015 MTUBytes=1480
2016
2017 [Tunnel]
2018 Local=10.65.223.238
2019 IPv6RapidDeploymentPrefix=2602::/24</programlisting>
2020 </example>
2021
2022 <example>
2023 <title>/etc/systemd/network/25-gre.netdev</title>
2024 <programlisting>[NetDev]
2025 Name=gre-tun
2026 Kind=gre
2027 MTUBytes=1480
2028
2029 [Tunnel]
2030 Local=10.65.223.238
2031 Remote=10.65.223.239</programlisting>
2032 </example>
2033
2034 <example>
2035 <title>/etc/systemd/network/25-ip6gre.netdev</title>
2036 <programlisting>[NetDev]
2037 Name=ip6gre-tun
2038 Kind=ip6gre
2039
2040 [Tunnel]
2041 Key=123</programlisting>
2042 </example>
2043
2044 <example>
2045 <title>/etc/systemd/network/25-vti.netdev</title>
2046
2047 <programlisting>[NetDev]
2048 Name=vti-tun
2049 Kind=vti
2050 MTUBytes=1480
2051
2052 [Tunnel]
2053 Local=10.65.223.238
2054 Remote=10.65.223.239</programlisting>
2055 </example>
2056
2057 <example>
2058 <title>/etc/systemd/network/25-veth.netdev</title>
2059 <programlisting>[NetDev]
2060 Name=veth-test
2061 Kind=veth
2062
2063 [Peer]
2064 Name=veth-peer</programlisting>
2065 </example>
2066
2067 <example>
2068 <title>/etc/systemd/network/25-bond.netdev</title>
2069 <programlisting>[NetDev]
2070 Name=bond1
2071 Kind=bond
2072
2073 [Bond]
2074 Mode=802.3ad
2075 TransmitHashPolicy=layer3+4
2076 MIIMonitorSec=1s
2077 LACPTransmitRate=fast
2078 </programlisting>
2079 </example>
2080
2081 <example>
2082 <title>/etc/systemd/network/25-dummy.netdev</title>
2083 <programlisting>[NetDev]
2084 Name=dummy-test
2085 Kind=dummy
2086 MACAddress=12:34:56:78:9a:bc</programlisting>
2087 </example>
2088 <example>
2089 <title>/etc/systemd/network/25-vrf.netdev</title>
2090 <para>Create a VRF interface with table 42.</para>
2091 <programlisting>[NetDev]
2092 Name=vrf-test
2093 Kind=vrf
2094
2095 [VRF]
2096 Table=42</programlisting>
2097 </example>
2098
2099 <example>
2100 <title>/etc/systemd/network/25-macvtap.netdev</title>
2101 <para>Create a MacVTap device.</para>
2102 <programlisting>[NetDev]
2103 Name=macvtap-test
2104 Kind=macvtap
2105 </programlisting>
2106 </example>
2107 <example>
2108 <title>/etc/systemd/network/25-wireguard.netdev</title>
2109 <programlisting>[NetDev]
2110 Name=wg0
2111 Kind=wireguard
2112
2113 [WireGuard]
2114 PrivateKey=EEGlnEPYJV//kbvvIqxKkQwOiS+UENyPncC4bF46ong=
2115 ListenPort=51820
2116
2117 [WireGuardPeer]
2118 PublicKey=RDf+LSpeEre7YEIKaxg+wbpsNV7du+ktR99uBEtIiCA=
2119 AllowedIPs=fd31:bf08:57cb::/48,192.168.26.0/24
2120 Endpoint=wireguard.example.com:51820</programlisting>
2121 </example>
2122
2123 <example>
2124 <title>/etc/systemd/network/27-xfrm.netdev</title>
2125 <programlisting>[NetDev]
2126 Name=xfrm0
2127 Kind=xfrm
2128
2129 [Xfrm]
2130 Independent=yes</programlisting>
2131 </example>
2132 </refsect1>
2133
2134 <refsect1>
2135 <title>See Also</title>
2136 <para>
2137 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
2138 <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
2139 <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>,
2140 <citerefentry><refentrytitle>systemd.network</refentrytitle><manvolnum>5</manvolnum></citerefentry>
2141 </para>
2142 </refsect1>
2143
2144 </refentry>