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