]>
Commit | Line | Data |
---|---|---|
514094f9 | 1 | <?xml version='1.0'?> |
3a54a157 | 2 | <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN" |
12b42c76 | 3 | "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"> |
db9ecf05 | 4 | <!-- SPDX-License-Identifier: LGPL-2.1-or-later --> |
eac684ef | 5 | |
d9b20454 ZJS |
6 | <refentry id="systemd.network" conditional='ENABLE_NETWORKD' |
7 | xmlns:xi="http://www.w3.org/2001/XInclude"> | |
eac684ef | 8 | |
798d3a52 ZJS |
9 | <refentryinfo> |
10 | <title>systemd.network</title> | |
11 | <productname>systemd</productname> | |
798d3a52 ZJS |
12 | </refentryinfo> |
13 | ||
14 | <refmeta> | |
15 | <refentrytitle>systemd.network</refentrytitle> | |
16 | <manvolnum>5</manvolnum> | |
17 | </refmeta> | |
18 | ||
19 | <refnamediv> | |
20 | <refname>systemd.network</refname> | |
21 | <refpurpose>Network configuration</refpurpose> | |
22 | </refnamediv> | |
23 | ||
24 | <refsynopsisdiv> | |
25 | <para><filename><replaceable>network</replaceable>.network</filename></para> | |
26 | </refsynopsisdiv> | |
27 | ||
28 | <refsect1> | |
29 | <title>Description</title> | |
30 | ||
add469f5 YW |
31 | <para>A plain ini-style text file that encodes network configuration for matching network |
32 | interfaces, used by | |
798d3a52 | 33 | <citerefentry><refentrytitle>systemd-networkd</refentrytitle><manvolnum>8</manvolnum></citerefentry>. |
675fa6ea | 34 | See <citerefentry><refentrytitle>systemd.syntax</refentrytitle><manvolnum>7</manvolnum></citerefentry> |
d4de2b2a | 35 | for a general description of the syntax.</para> |
798d3a52 | 36 | |
bac150e9 ZJS |
37 | <para>The main network file must have the extension <filename>.network</filename>; other |
38 | extensions are ignored. Networks are applied to links whenever the links appear.</para> | |
39 | ||
dc0d4078 ZJS |
40 | <para>The <filename>.network</filename> files are read from the files located in the system network |
41 | directories <filename>/usr/lib/systemd/network</filename> and | |
42 | <filename>/usr/local/lib/systemd/network</filename>, the volatile runtime network directory | |
43 | <filename>/run/systemd/network</filename> and the local administration network directory | |
add469f5 | 44 | <filename>/etc/systemd/network</filename>. All configuration files are collectively sorted and |
cc9b6bdc YW |
45 | processed in alphanumeric order, regardless of the directories in which they live. However, files |
46 | with identical filenames replace each other. It is recommended that each filename is prefixed with | |
47 | a number (e.g. <filename>10-eth0.network</filename>). Otherwise, the default | |
48 | <filename>.network</filename> files or those generated by | |
49 | <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> | |
50 | may take precedence over user configured files. Files in <filename>/etc/</filename> have the highest | |
add469f5 YW |
51 | priority, files in <filename>/run/</filename> take precedence over files with the same name under |
52 | <filename>/usr/</filename>. This can be used to override a system-supplied configuration file with | |
53 | a local file if needed. As a special case, an empty file (file size 0) or symlink with the same | |
54 | name pointing to <filename>/dev/null</filename> disables the configuration file entirely (it is | |
55 | "masked").</para> | |
bac150e9 ZJS |
56 | |
57 | <para>Along with the network file <filename>foo.network</filename>, a "drop-in" directory | |
58 | <filename>foo.network.d/</filename> may exist. All files with the suffix | |
e6655fbe YW |
59 | <literal>.conf</literal> from this directory will be merged in the alphanumeric order and parsed |
60 | after the main file itself has been parsed. This is useful to alter or add configuration settings, | |
61 | without having to modify the main configuration file. Each drop-in file must have appropriate | |
62 | section headers.</para> | |
bac150e9 ZJS |
63 | |
64 | <para>In addition to <filename>/etc/systemd/network</filename>, drop-in <literal>.d</literal> | |
65 | directories can be placed in <filename>/usr/lib/systemd/network</filename> or | |
66 | <filename>/run/systemd/network</filename> directories. Drop-in files in | |
3b121157 ZJS |
67 | <filename>/etc/</filename> take precedence over those in <filename>/run/</filename> which in turn |
68 | take precedence over those in <filename>/usr/lib/</filename>. Drop-in files under any of these | |
b1e91af8 | 69 | directories take precedence over the main network file wherever located.</para> |
798d3a52 ZJS |
70 | </refsect1> |
71 | ||
72 | <refsect1> | |
73 | <title>[Match] Section Options</title> | |
74 | ||
add469f5 | 75 | <para>The network file contains a [Match] section, which determines if a given network file may |
cc9b6bdc YW |
76 | be applied to a given interface; and a [Network] section specifying how the interface should be |
77 | configured. The first (in alphanumeric order) of the network files that matches a given interface | |
78 | is applied, all later files are ignored, even if they match as well.</para> | |
798d3a52 | 79 | |
add469f5 YW |
80 | <para>A network file is said to match a network interface if all matches specified by the [Match] |
81 | section are satisfied. When a network file does not contain valid settings in [Match] section, then | |
82 | the file will match all interfaces and <command>systemd-networkd</command> warns about that. Hint: | |
83 | to avoid the warning and to make it clear that all interfaces shall be matched, add the following: | |
84 | <programlisting>Name=*</programlisting> The following keys are accepted:</para> | |
85 | ||
86 | <variablelist class='network-directives'> | |
87 | <xi:include href="systemd.link.xml" xpointer="mac-address" /> | |
88 | <xi:include href="systemd.link.xml" xpointer="permanent-mac-address" /> | |
89 | <xi:include href="systemd.link.xml" xpointer="path" /> | |
90 | <xi:include href="systemd.link.xml" xpointer="driver" /> | |
91 | <xi:include href="systemd.link.xml" xpointer="type" /> | |
65022cd7 | 92 | <xi:include href="systemd.link.xml" xpointer="kind" /> |
add469f5 YW |
93 | <xi:include href="systemd.link.xml" xpointer="property" /> |
94 | ||
95 | <varlistentry> | |
96 | <term><varname>Name=</varname></term> | |
97 | <listitem> | |
98 | <para>A whitespace-separated list of shell-style globs matching the device name, as exposed | |
99 | by the udev property <literal>INTERFACE</literal>, or device's alternative names. If the | |
100 | list is prefixed with a "!", the test is inverted.</para> | |
101 | </listitem> | |
102 | </varlistentry> | |
103 | ||
104 | <varlistentry> | |
105 | <term><varname>WLANInterfaceType=</varname></term> | |
106 | <listitem> | |
107 | <para>A whitespace-separated list of wireless network type. Supported values are | |
108 | <literal>ad-hoc</literal>, <literal>station</literal>, <literal>ap</literal>, | |
109 | <literal>ap-vlan</literal>, <literal>wds</literal>, <literal>monitor</literal>, | |
110 | <literal>mesh-point</literal>, <literal>p2p-client</literal>, <literal>p2p-go</literal>, | |
111 | <literal>p2p-device</literal>, <literal>ocb</literal>, and <literal>nan</literal>. If the | |
112 | list is prefixed with a "!", the test is inverted. </para> | |
113 | </listitem> | |
114 | </varlistentry> | |
115 | ||
116 | <varlistentry> | |
117 | <term><varname>SSID=</varname></term> | |
118 | <listitem> | |
119 | <para>A whitespace-separated list of shell-style globs matching the SSID of the currently | |
120 | connected wireless LAN. If the list is prefixed with a "!", the test is inverted.</para> | |
121 | </listitem> | |
122 | </varlistentry> | |
123 | ||
124 | <varlistentry> | |
125 | <term><varname>BSSID=</varname></term> | |
126 | <listitem> | |
127 | <para>A whitespace-separated list of hardware address of the currently connected wireless | |
128 | LAN. Use full colon-, hyphen- or dot-delimited hexadecimal. See the example in | |
129 | <varname>MACAddress=</varname>. This option may appear more than once, in which case the | |
130 | lists are merged. If the empty string is assigned to this option, the list is reset.</para> | |
131 | </listitem> | |
132 | </varlistentry> | |
133 | ||
134 | <xi:include href="systemd.link.xml" xpointer="host" /> | |
135 | <xi:include href="systemd.link.xml" xpointer="virtualization" /> | |
136 | <xi:include href="systemd.link.xml" xpointer="kernel-command-line" /> | |
137 | <xi:include href="systemd.link.xml" xpointer="kernel-version" /> | |
4f80cfca | 138 | <xi:include href="systemd.link.xml" xpointer="credential" /> |
add469f5 YW |
139 | <xi:include href="systemd.link.xml" xpointer="architecture" /> |
140 | <xi:include href="systemd.link.xml" xpointer="firmware" /> | |
141 | </variablelist> | |
798d3a52 ZJS |
142 | </refsect1> |
143 | ||
144 | <refsect1> | |
145 | <title>[Link] Section Options</title> | |
146 | ||
a94ed9bd | 147 | <para>The [Link] section accepts the following keys:</para> |
798d3a52 ZJS |
148 | |
149 | <variablelist class='network-directives'> | |
150 | <varlistentry> | |
151 | <term><varname>MACAddress=</varname></term> | |
152 | <listitem> | |
de25aae1 | 153 | <para>The hardware address to set for the device.</para> |
798d3a52 ZJS |
154 | </listitem> |
155 | </varlistentry> | |
add469f5 | 156 | |
798d3a52 ZJS |
157 | <varlistentry> |
158 | <term><varname>MTUBytes=</varname></term> | |
159 | <listitem> | |
add469f5 YW |
160 | <para>The maximum transmission unit in bytes to set for the device. The usual suffixes K, M, |
161 | G, are supported and are understood to the base of 1024.</para> | |
162 | <para>Note that if IPv6 is enabled on the interface, and the MTU is chosen below 1280 (the | |
163 | minimum MTU for IPv6) it will automatically be increased to this value.</para> | |
798d3a52 ZJS |
164 | </listitem> |
165 | </varlistentry> | |
add469f5 | 166 | |
99d2baa2 SS |
167 | <varlistentry> |
168 | <term><varname>ARP=</varname></term> | |
169 | <listitem> | |
9b6ffef3 YW |
170 | <para>Takes a boolean. If set to true, the ARP (low-level Address Resolution Protocol) |
171 | for this interface is enabled. When unset, the kernel's default will be used.</para> | |
99d2baa2 SS |
172 | <para> For example, disabling ARP is useful when creating multiple MACVLAN or VLAN virtual |
173 | interfaces atop a single lower-level physical interface, which will then only serve as a | |
174 | link/"bridge" device aggregating traffic to the same physical link and not participate in | |
937e305e | 175 | the network otherwise. Defaults to unset.</para> |
99d2baa2 SS |
176 | </listitem> |
177 | </varlistentry> | |
add469f5 | 178 | |
e6ebebbe SS |
179 | <varlistentry> |
180 | <term><varname>Multicast=</varname></term> | |
181 | <listitem> | |
add469f5 YW |
182 | <para>Takes a boolean. If set to true, the multicast flag on the device is enabled. Defaults |
183 | to unset.</para> | |
866e6b7a SS |
184 | </listitem> |
185 | </varlistentry> | |
add469f5 | 186 | |
866e6b7a SS |
187 | <varlistentry> |
188 | <term><varname>AllMulticast=</varname></term> | |
189 | <listitem> | |
add469f5 YW |
190 | <para>Takes a boolean. If set to true, the driver retrieves all multicast packets from the |
191 | network. This happens when multicast routing is enabled. Defaults to unset.</para> | |
937e305e SS |
192 | </listitem> |
193 | </varlistentry> | |
add469f5 | 194 | |
937e305e SS |
195 | <varlistentry> |
196 | <term><varname>Promiscuous=</varname></term> | |
197 | <listitem> | |
add469f5 YW |
198 | <para>Takes a boolean. If set to true, promiscuous mode of the interface is enabled. Defaults |
199 | to unset.</para> | |
200 | <para>If this is set to false for the underlying link of a <literal>passthru</literal> mode | |
201 | MACVLAN/MACVTAP, the virtual interface will be created with the <literal>nopromisc</literal> | |
202 | flag set.</para> | |
e6ebebbe SS |
203 | </listitem> |
204 | </varlistentry> | |
add469f5 | 205 | |
a09dc546 DM |
206 | <varlistentry> |
207 | <term><varname>Unmanaged=</varname></term> | |
208 | <listitem> | |
add469f5 YW |
209 | <para>Takes a boolean. When <literal>yes</literal>, no attempts are made to bring up or |
210 | configure matching links, equivalent to when there are no matching network files. Defaults to | |
a09dc546 | 211 | <literal>no</literal>.</para> |
add469f5 YW |
212 | <para>This is useful for preventing later matching network files from interfering with |
213 | certain interfaces that are fully controlled by other applications.</para> | |
a09dc546 DM |
214 | </listitem> |
215 | </varlistentry> | |
add469f5 | 216 | |
89fe6535 SS |
217 | <varlistentry> |
218 | <term><varname>Group=</varname></term> | |
219 | <listitem> | |
add469f5 YW |
220 | <para>Link groups are similar to port ranges found in managed switches. When network |
221 | interfaces are added to a numbered group, operations on all the interfaces from that group | |
222 | can be performed at once. Takes an unsigned integer in the range 0…2147483647. Defaults to | |
223 | unset.</para> | |
89fe6535 | 224 | </listitem> |
0a9fb9ba | 225 | </varlistentry> |
add469f5 | 226 | |
c1a38904 MTL |
227 | <varlistentry> |
228 | <term><varname>RequiredForOnline=</varname></term> | |
229 | <listitem> | |
add469f5 YW |
230 | <para>Takes a boolean or a minimum operational state and an optional maximum operational |
231 | state. Please see | |
232 | <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
233 | for possible operational states. When <literal>yes</literal>, the network is deemed required | |
234 | when determining whether the system is online (including when running | |
235 | <command>systemd-networkd-wait-online</command>). When <literal>no</literal>, the network is | |
236 | ignored when determining the online state. When a minimum operational state and an optional | |
237 | maximum operational state are set, <literal>yes</literal> is implied, and this controls the | |
238 | minimum and maximum operational state required for the network interface to be considered | |
239 | online.</para> | |
240 | ||
241 | <para>Defaults to <literal>yes</literal> when <varname>ActivationPolicy=</varname> is not | |
242 | set, or set to <literal>up</literal>, <literal>always-up</literal>, or | |
243 | <literal>bound</literal>. Defaults to <literal>no</literal> when | |
244 | <varname>ActivationPolicy=</varname> is set to <literal>manual</literal> or | |
245 | <literal>down</literal>. This is forced to <literal>no</literal> when | |
246 | <varname>ActivationPolicy=</varname> is set to <literal>always-down</literal>.</para> | |
247 | ||
248 | <para>The network will be brought up normally (as configured by | |
249 | <varname>ActivationPolicy=</varname>), but in the event that there is no address being | |
250 | assigned by DHCP or the cable is not plugged in, the link will simply remain offline and be | |
251 | skipped automatically by <command>systemd-networkd-wait-online</command> if | |
252 | <literal>RequiredForOnline=no</literal>.</para> | |
c1a38904 MTL |
253 | </listitem> |
254 | </varlistentry> | |
add469f5 | 255 | |
8430841b L |
256 | <varlistentry> |
257 | <term><varname>RequiredFamilyForOnline=</varname></term> | |
258 | <listitem> | |
add469f5 YW |
259 | <para>Takes an address family. When specified, an IP address in the given family is deemed |
260 | required when determining whether the link is online (including when running | |
553022c4 AŠ |
261 | <command>systemd-networkd-wait-online</command>). Takes one of <literal>ipv4</literal>, |
262 | <literal>ipv6</literal>, <literal>both</literal>, or <literal>any</literal>. Defaults to | |
263 | <literal>any</literal>. Note that this option has no effect if | |
add469f5 YW |
264 | <literal>RequiredForOnline=no</literal>, or if <literal>RequiredForOnline=</literal> |
265 | specifies a minimum operational state below <literal>degraded</literal>.</para> | |
8430841b L |
266 | </listitem> |
267 | </varlistentry> | |
add469f5 | 268 | |
61135582 DS |
269 | <varlistentry> |
270 | <term><varname>ActivationPolicy=</varname></term> | |
271 | <listitem> | |
272 | <para>Specifies the policy for <command>systemd-networkd</command> managing the link | |
273 | administrative state. Specifically, this controls how <command>systemd-networkd</command> | |
274 | changes the network device's <literal>IFF_UP</literal> flag, which is sometimes | |
add469f5 YW |
275 | controlled by system administrators by running e.g., |
276 | <command>ip link set dev eth0 up</command> or <command>ip link set dev eth0 down</command>, | |
277 | and can also be changed with <command>networkctl up eth0</command> or | |
278 | <command>networkctl down eth0</command>.</para> | |
61135582 DS |
279 | |
280 | <para>Takes one of <literal>up</literal>, <literal>always-up</literal>, | |
281 | <literal>manual</literal>, <literal>always-down</literal>, <literal>down</literal>, | |
add469f5 YW |
282 | or <literal>bound</literal>. When <literal>manual</literal>, |
283 | <command>systemd-networkd</command> will not change the link's admin state automatically; | |
284 | the system administrator must bring the interface up or down manually, as desired. When | |
285 | <literal>up</literal> (the default) or <literal>always-up</literal>, or | |
286 | <literal>down</literal> or <literal>always-down</literal>, | |
287 | <command>systemd-networkd</command> will set the link up or down, respectively, when the | |
288 | interface is (re)configured. When <literal>always-up</literal> or | |
289 | <literal>always-down</literal>, <command>systemd-networkd</command> will set the link up or | |
290 | down, respectively, any time <command>systemd-networkd</command> detects a change in the | |
291 | administrative state. When <varname>BindCarrier=</varname> is also set, this is automatically | |
292 | set to <literal>bound</literal> and any other value is ignored.</para> | |
293 | ||
294 | <para>When the policy is set to <literal>down</literal> or <literal>manual</literal>, the | |
295 | default value of <varname>RequiredForOnline=</varname> is <literal>no</literal>. When the | |
296 | policy is set to <literal>always-down</literal>, the value of | |
7c644a69 DS |
297 | <varname>RequiredForOnline=</varname> forced to <literal>no</literal>.</para> |
298 | ||
61135582 | 299 | <para>The administrative state is not the same as the carrier state, so using |
add469f5 YW |
300 | <literal>always-up</literal> does not mean the link will never lose carrier. The link carrier |
301 | depends on both the administrative state as well as the network device's physical connection. | |
302 | However, to avoid reconfiguration failures, when using <literal>always-up</literal>, | |
61135582 DS |
303 | <varname>IgnoreCarrierLoss=</varname> is forced to true.</para> |
304 | </listitem> | |
305 | </varlistentry> | |
798d3a52 ZJS |
306 | </variablelist> |
307 | </refsect1> | |
308 | ||
bd29dfef | 309 | <xi:include href="systemd.link.xml" xpointer="sr-iov" /> |
518cd6b5 | 310 | |
798d3a52 ZJS |
311 | <refsect1> |
312 | <title>[Network] Section Options</title> | |
313 | ||
add469f5 YW |
314 | <para>The [Network] section accepts the following keys:</para> |
315 | ||
316 | <variablelist class='network-directives'> | |
317 | <varlistentry> | |
318 | <term><varname>Description=</varname></term> | |
319 | <listitem> | |
320 | <para>A description of the device. This is only used for presentation purposes.</para> | |
321 | </listitem> | |
322 | </varlistentry> | |
323 | ||
324 | <varlistentry> | |
325 | <term><varname>DHCP=</varname></term> | |
326 | <listitem> | |
327 | <para>Enables DHCPv4 and/or DHCPv6 client support. Accepts <literal>yes</literal>, | |
328 | <literal>no</literal>, <literal>ipv4</literal>, or <literal>ipv6</literal>. Defaults to | |
329 | <literal>no</literal>.</para> | |
330 | ||
f217f9a8 ZJS |
331 | <para>Note that DHCPv6 will by default be triggered by Router Advertisements, if reception is |
332 | enabled, regardless of this parameter. By explicitly enabling DHCPv6 support here, the DHCPv6 | |
333 | client will be started in the mode specified by the <varname>WithoutRA=</varname> setting in the | |
334 | [DHCPv6] section, regardless of the presence of routers on the link, or what flags the routers | |
335 | pass. See <varname>IPv6AcceptRA=</varname>.</para> | |
add469f5 YW |
336 | |
337 | <para>Furthermore, note that by default the domain name specified through DHCP is not used | |
338 | for name resolution. See option <option>UseDomains=</option> below.</para> | |
339 | ||
340 | <para>See the [DHCPv4] or [DHCPv6] sections below for further configuration options for the | |
341 | DHCP client support.</para> | |
342 | </listitem> | |
343 | </varlistentry> | |
344 | ||
345 | <varlistentry> | |
346 | <term><varname>DHCPServer=</varname></term> | |
347 | <listitem> | |
348 | <para>Takes a boolean. If set to <literal>yes</literal>, DHCPv4 server will be started. | |
349 | Defaults to <literal>no</literal>. Further settings for the DHCP server may be set in the | |
350 | [DHCPServer] section described below.</para> | |
351 | </listitem> | |
352 | </varlistentry> | |
353 | ||
354 | <varlistentry> | |
355 | <term><varname>LinkLocalAddressing=</varname></term> | |
356 | <listitem> | |
357 | <para>Enables link-local address autoconfiguration. Accepts <option>yes</option>, | |
358 | <option>no</option>, <option>ipv4</option>, and <option>ipv6</option>. An IPv6 link-local | |
359 | address is configured when <option>yes</option> or <option>ipv6</option>. An IPv4 link-local | |
360 | address is configured when <option>yes</option> or <option>ipv4</option> and when DHCPv4 | |
361 | autoconfiguration has been unsuccessful for some time. (IPv4 link-local address | |
362 | autoconfiguration will usually happen in parallel with repeated attempts to acquire a DHCPv4 | |
363 | lease).</para> | |
364 | ||
365 | <para>Defaults to <option>no</option> when <varname>KeepMaster=</varname> or | |
366 | <varname>Bridge=</varname> is set or when the specified | |
367 | <varname>MACVLAN=</varname>/<varname>MACVTAP=</varname> has <varname>Mode=passthru</varname>, | |
368 | or <option>ipv6</option> otherwise.</para> | |
369 | </listitem> | |
370 | </varlistentry> | |
371 | ||
372 | <varlistentry> | |
373 | <term><varname>IPv6LinkLocalAddressGenerationMode=</varname></term> | |
374 | <listitem> | |
f81ac115 | 375 | <para>Specifies how IPv6 link-local address is generated. Takes one of |
add469f5 YW |
376 | <literal>eui64</literal>, <literal>none</literal>, <literal>stable-privacy</literal> and |
377 | <literal>random</literal>. When unset, <literal>stable-privacy</literal> is used if | |
378 | <varname>IPv6StableSecretAddress=</varname> is specified, and if not, | |
379 | <literal>eui64</literal> is used. Note that if <varname>LinkLocalAddressing=</varname> is | |
380 | <literal>no</literal> or <literal>ipv4</literal>, then | |
381 | <varname>IPv6LinkLocalAddressGenerationMode=</varname> will be ignored. Also, even if | |
382 | <varname>LinkLocalAddressing=</varname> is <literal>yes</literal> or <literal>ipv6</literal>, | |
383 | setting <varname>IPv6LinkLocalAddressGenerationMode=none</varname> | |
384 | disables to configure an IPv6 link-local address.</para> | |
385 | </listitem> | |
386 | </varlistentry> | |
387 | ||
388 | <varlistentry> | |
389 | <term><varname>IPv6StableSecretAddress=</varname></term> | |
390 | <listitem> | |
391 | <para>Takes an IPv6 address. The specified address will be used as a stable secret for | |
392 | generating IPv6 link-local address. If this setting is specified, and | |
393 | <varname>IPv6LinkLocalAddressGenerationMode=</varname> is unset, then | |
394 | <varname>IPv6LinkLocalAddressGenerationMode=stable-privacy</varname> is implied. | |
395 | If this setting is not specified, and <literal>stable-privacy</literal> is set to | |
396 | <varname>IPv6LinkLocalAddressGenerationMode=</varname>, | |
397 | then a stable secret address will be generated from the local machine ID and the interface | |
398 | name.</para> | |
399 | </listitem> | |
400 | </varlistentry> | |
401 | ||
34b63c9e AK |
402 | <varlistentry> |
403 | <term><varname>IPv4LLStartAddress=</varname></term> | |
404 | <listitem> | |
d3efcd2d YW |
405 | <para>Specifies the first IPv4 link-local address to try. Takes an IPv4 address for example |
406 | 169.254.1.2, from the link-local address range: 169.254.0.0/16 except for 169.254.0.0/24 and | |
407 | 169.254.255.0/24. This setting may be useful if the device should always have the same address | |
408 | as long as there is no address conflict. When unset, a random address will be automatically | |
409 | selected. Defaults to unset.</para> | |
34b63c9e AK |
410 | </listitem> |
411 | </varlistentry> | |
412 | ||
add469f5 YW |
413 | <varlistentry> |
414 | <term><varname>IPv4LLRoute=</varname></term> | |
415 | <listitem> | |
416 | <para>Takes a boolean. If set to true, sets up the route needed for non-IPv4LL hosts to | |
417 | communicate with IPv4LL-only hosts. Defaults to false.</para> | |
418 | </listitem> | |
419 | </varlistentry> | |
420 | ||
421 | <varlistentry> | |
422 | <term><varname>DefaultRouteOnDevice=</varname></term> | |
423 | <listitem> | |
15f330cf | 424 | <para>Takes a boolean. If set to true, sets up the IPv4 default route bound to the interface. |
add469f5 YW |
425 | Defaults to false. This is useful when creating routes on point-to-point interfaces. This is |
426 | equivalent to e.g. the following, | |
427 | <programlisting>ip route add default dev veth99</programlisting> | |
428 | or, | |
429 | <programlisting>[Route] | |
21d03e6c | 430 | Gateway=0.0.0.0</programlisting></para> |
add469f5 YW |
431 | <para>Currently, there are no way to specify e.g., the table for the route configured by this |
432 | setting. To configure the default route with such an additional property, please use the | |
433 | following instead: | |
434 | <programlisting>[Route] | |
21d03e6c | 435 | Gateway=0.0.0.0 |
15f330cf YW |
436 | Table=1234</programlisting></para> |
437 | <para>If you'd like to create an IPv6 default route bound to the interface, please use the | |
438 | following: | |
439 | <programlisting>[Route] | |
440 | Gateway=:: | |
21d03e6c | 441 | Table=1234</programlisting></para> |
add469f5 YW |
442 | </listitem> |
443 | </varlistentry> | |
c4a05aa1 | 444 | |
dd5f3175 | 445 | <varlistentry> |
add469f5 | 446 | <term><varname>LLMNR=</varname></term> |
dd5f3175 | 447 | <listitem> |
add469f5 YW |
448 | <para>Takes a boolean or <literal>resolve</literal>. When true, enables |
449 | <ulink url="https://tools.ietf.org/html/rfc4795">Link-Local Multicast Name Resolution</ulink> | |
450 | on the link. When set to <literal>resolve</literal>, only resolution is enabled, but not host | |
451 | registration and announcement. Defaults to true. This setting is read by | |
452 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
dd5f3175 SS |
453 | </para> |
454 | </listitem> | |
455 | </varlistentry> | |
add469f5 | 456 | |
dd5f3175 | 457 | <varlistentry> |
add469f5 | 458 | <term><varname>MulticastDNS=</varname></term> |
dd5f3175 | 459 | <listitem> |
add469f5 YW |
460 | <para>Takes a boolean or <literal>resolve</literal>. When true, enables |
461 | <ulink url="https://tools.ietf.org/html/rfc6762">Multicast DNS</ulink> support on the link. | |
462 | When set to <literal>resolve</literal>, only resolution is enabled, but not host or service | |
463 | registration and announcement. Defaults to false. This setting is read by | |
464 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
dd5f3175 SS |
465 | </para> |
466 | </listitem> | |
467 | </varlistentry> | |
add469f5 | 468 | |
dad2d78e | 469 | <varlistentry> |
add469f5 | 470 | <term><varname>DNSOverTLS=</varname></term> |
dad2d78e | 471 | <listitem> |
add469f5 YW |
472 | <para>Takes a boolean or <literal>opportunistic</literal>. When true, enables |
473 | <ulink url="https://tools.ietf.org/html/rfc7858">DNS-over-TLS</ulink> support on the link. | |
474 | When set to <literal>opportunistic</literal>, compatibility with non-DNS-over-TLS servers is | |
475 | increased, by automatically turning off DNS-over-TLS servers in this case. This option | |
476 | defines a per-interface setting for | |
477 | <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s | |
478 | global <varname>DNSOverTLS=</varname> option. Defaults to unset, and the global setting will | |
479 | be used. This setting is read by | |
480 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
dad2d78e SS |
481 | </para> |
482 | </listitem> | |
483 | </varlistentry> | |
add469f5 | 484 | |
93b4dab5 | 485 | <varlistentry> |
add469f5 | 486 | <term><varname>DNSSEC=</varname></term> |
93b4dab5 | 487 | <listitem> |
add469f5 YW |
488 | <para>Takes a boolean or <literal>allow-downgrade</literal>. When true, enables |
489 | <ulink url="https://tools.ietf.org/html/rfc4033">DNSSEC</ulink> DNS validation support on the | |
490 | link. When set to <literal>allow-downgrade</literal>, compatibility with non-DNSSEC capable | |
491 | networks is increased, by automatically turning off DNSSEC in this case. This option defines | |
492 | a per-interface setting for | |
493 | <citerefentry><refentrytitle>resolved.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>'s | |
494 | global <varname>DNSSEC=</varname> option. Defaults to unset, and the global setting will be | |
495 | used. This setting is read by | |
496 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
497 | </para> | |
498 | </listitem> | |
499 | </varlistentry> | |
61135582 | 500 | |
add469f5 YW |
501 | <varlistentry> |
502 | <term><varname>DNSSECNegativeTrustAnchors=</varname></term> | |
503 | <listitem> | |
504 | <para>A space-separated list of DNSSEC negative trust anchor domains. If specified and DNSSEC | |
505 | is enabled, look-ups done via the interface's DNS server will be subject to the list of | |
506 | negative trust anchors, and not require authentication for the specified domains, or anything | |
507 | below it. Use this to disable DNSSEC authentication for specific private domains, that cannot | |
508 | be proven valid using the Internet DNS hierarchy. Defaults to the empty list. This setting is | |
509 | read by | |
510 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
61135582 | 511 | </para> |
93b4dab5 SS |
512 | </listitem> |
513 | </varlistentry> | |
add469f5 | 514 | |
c98d78d3 | 515 | <varlistentry> |
add469f5 | 516 | <term><varname>LLDP=</varname></term> |
c98d78d3 | 517 | <listitem> |
add469f5 YW |
518 | <para>Controls support for Ethernet LLDP packet reception. LLDP is a link-layer protocol |
519 | commonly implemented on professional routers and bridges which announces which physical port | |
520 | a system is connected to, as well as other related data. Accepts a boolean or the special | |
521 | value <literal>routers-only</literal>. When true, incoming LLDP packets are accepted and a | |
522 | database of all LLDP neighbors maintained. If <literal>routers-only</literal> is set only | |
523 | LLDP data of various types of routers is collected and LLDP data about other types of devices | |
524 | ignored (such as stations, telephones and others). If false, LLDP reception is disabled. | |
525 | Defaults to <literal>routers-only</literal>. Use | |
526 | <citerefentry><refentrytitle>networkctl</refentrytitle><manvolnum>1</manvolnum></citerefentry> | |
527 | to query the collected neighbor data. LLDP is only available on Ethernet links. See | |
528 | <varname>EmitLLDP=</varname> below for enabling LLDP packet emission from the local system. | |
80060352 | 529 | </para> |
c98d78d3 YW |
530 | </listitem> |
531 | </varlistentry> | |
798d3a52 | 532 | |
add469f5 YW |
533 | <varlistentry> |
534 | <term><varname>EmitLLDP=</varname></term> | |
535 | <listitem> | |
536 | <para>Controls support for Ethernet LLDP packet emission. Accepts a boolean parameter or the | |
537 | special values <literal>nearest-bridge</literal>, <literal>non-tpmr-bridge</literal> and | |
538 | <literal>customer-bridge</literal>. Defaults to false, which turns off LLDP packet emission. | |
539 | If not false, a short LLDP packet with information about the local system is sent out in | |
540 | regular intervals on the link. The LLDP packet will contain information about the local | |
541 | hostname, the local machine ID (as stored in | |
542 | <citerefentry><refentrytitle>machine-id</refentrytitle><manvolnum>5</manvolnum></citerefentry>) | |
543 | and the local interface name, as well as the pretty hostname of the system (as set in | |
544 | <citerefentry><refentrytitle>machine-info</refentrytitle><manvolnum>5</manvolnum></citerefentry>). | |
545 | LLDP emission is only available on Ethernet links. Note that this setting passes data | |
546 | suitable for identification of host to the network and should thus not be enabled on | |
547 | untrusted networks, where such identification data should not be made available. Use this | |
548 | option to permit other systems to identify on which interfaces they are connected to this | |
549 | system. The three special values control propagation of the LLDP packets. The | |
550 | <literal>nearest-bridge</literal> setting permits propagation only to the nearest connected | |
551 | bridge, <literal>non-tpmr-bridge</literal> permits propagation across Two-Port MAC Relays, | |
552 | but not any other bridges, and <literal>customer-bridge</literal> permits propagation until | |
553 | a customer bridge is reached. For details about these concepts, see | |
554 | <ulink url="https://standards.ieee.org/findstds/standard/802.1AB-2016.html">IEEE 802.1AB-2016</ulink>. | |
555 | Note that configuring this setting to true is equivalent to | |
556 | <literal>nearest-bridge</literal>, the recommended and most restricted level of propagation. | |
557 | See <varname>LLDP=</varname> above for an option to enable LLDP reception.</para> | |
558 | </listitem> | |
559 | </varlistentry> | |
798d3a52 | 560 | |
add469f5 YW |
561 | <varlistentry> |
562 | <term><varname>BindCarrier=</varname></term> | |
563 | <listitem> | |
564 | <para>A link name or a list of link names. When set, controls the behavior of the current | |
565 | link. When all links in the list are in an operational down state, the current link is | |
566 | brought down. When at least one link has carrier, the current interface is brought up.</para> | |
798d3a52 | 567 | |
add469f5 YW |
568 | <para>This forces <varname>ActivationPolicy=</varname> to be set to <literal>bound</literal>. |
569 | </para> | |
570 | </listitem> | |
571 | </varlistentry> | |
e4a71bf3 | 572 | |
add469f5 YW |
573 | <varlistentry> |
574 | <term><varname>Address=</varname></term> | |
575 | <listitem> | |
576 | <para>A static IPv4 or IPv6 address and its prefix length, separated by a | |
577 | <literal>/</literal> character. Specify this key more than once to configure several | |
578 | addresses. The format of the address must be as described in | |
579 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
580 | This is a short-hand for an [Address] section only containing an Address key (see below). | |
581 | This option may be specified more than once.</para> | |
582 | ||
583 | <para>If the specified address is <literal>0.0.0.0</literal> (for IPv4) or | |
584 | <literal>::</literal> (for IPv6), a new address range of the requested size is automatically | |
585 | allocated from a system-wide pool of unused ranges. Note that the prefix length must be equal | |
586 | or larger than 8 for IPv4, and 64 for IPv6. The allocated range is checked against all | |
587 | current network interfaces and all known network configuration files to avoid address range | |
588 | conflicts. The default system-wide pool consists of 192.168.0.0/16, 172.16.0.0/12 and | |
589 | 10.0.0.0/8 for IPv4, and fd00::/8 for IPv6. This functionality is useful to manage a large | |
590 | number of dynamically created network interfaces with the same network configuration and | |
591 | automatic address range assignment.</para> | |
592 | </listitem> | |
593 | </varlistentry> | |
95b74ef6 | 594 | |
add469f5 YW |
595 | <varlistentry> |
596 | <term><varname>Gateway=</varname></term> | |
597 | <listitem> | |
598 | <para>The gateway address, which must be in the format described in | |
599 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
600 | This is a short-hand for a [Route] section only containing a <varname>Gateway=</varname> key. | |
601 | This option may be specified more than once.</para> | |
602 | </listitem> | |
603 | </varlistentry> | |
95b74ef6 | 604 | |
add469f5 YW |
605 | <varlistentry> |
606 | <term><varname>DNS=</varname></term> | |
607 | <listitem> | |
608 | <para>A DNS server address, which must be in the format described in | |
609 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
610 | This option may be specified more than once. Each address can optionally take a port number | |
611 | separated with <literal>:</literal>, a network interface name or index separated with | |
612 | <literal>%</literal>, and a Server Name Indication (SNI) separated with <literal>#</literal>. | |
613 | When IPv6 address is specified with a port number, then the address must be in the square | |
614 | brackets. That is, the acceptable full formats are | |
615 | <literal>111.222.333.444:9953%ifname#example.com</literal> for IPv4 and | |
616 | <literal>[1111:2222::3333]:9953%ifname#example.com</literal> for IPv6. If an empty string is | |
617 | assigned, then the all previous assignments are cleared. This setting is read by | |
618 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
619 | </para> | |
620 | </listitem> | |
621 | </varlistentry> | |
bce67bbe | 622 | |
add469f5 YW |
623 | <varlistentry> |
624 | <term><varname>Domains=</varname></term> | |
625 | <listitem> | |
626 | <para>A whitespace-separated list of domains which should be resolved using the DNS servers | |
627 | on this link. Each item in the list should be a domain name, optionally prefixed with a tilde | |
628 | (<literal>~</literal>). The domains with the prefix are called "routing-only domains". The | |
629 | domains without the prefix are called "search domains" and are first used as search suffixes | |
630 | for extending single-label hostnames (hostnames containing no dots) to become fully qualified | |
631 | domain names (FQDNs). If a single-label hostname is resolved on this interface, each of the | |
632 | specified search domains are appended to it in turn, converting it into a fully qualified | |
633 | domain name, until one of them may be successfully resolved.</para> | |
634 | ||
635 | <para>Both "search" and "routing-only" domains are used for routing of DNS queries: look-ups | |
636 | for hostnames ending in those domains (hence also single label names, if any "search domains" | |
637 | are listed), are routed to the DNS servers configured for this interface. The domain routing | |
638 | logic is particularly useful on multi-homed hosts with DNS servers serving particular private | |
639 | DNS zones on each interface.</para> | |
640 | ||
641 | <para>The "routing-only" domain <literal>~.</literal> (the tilde indicating definition of a | |
642 | routing domain, the dot referring to the DNS root domain which is the implied suffix of all | |
643 | valid DNS names) has special effect. It causes all DNS traffic which does not match another | |
644 | configured domain routing entry to be routed to DNS servers specified for this interface. | |
645 | This setting is useful to prefer a certain set of DNS servers if a link on which they are | |
646 | connected is available.</para> | |
647 | ||
648 | <para>This setting is read by | |
649 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
650 | "Search domains" correspond to the <varname>domain</varname> and <varname>search</varname> | |
651 | entries in | |
652 | <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
653 | Domain name routing has no equivalent in the traditional glibc API, which has no concept of | |
654 | domain name servers limited to a specific link.</para> | |
655 | </listitem> | |
656 | </varlistentry> | |
bce67bbe | 657 | |
add469f5 YW |
658 | <varlistentry> |
659 | <term><varname>DNSDefaultRoute=</varname></term> | |
660 | <listitem> | |
661 | <para>Takes a boolean argument. If true, this link's configured DNS servers are used for | |
662 | resolving domain names that do not match any link's configured <varname>Domains=</varname> | |
663 | setting. If false, this link's configured DNS servers are never used for such domains, and | |
664 | are exclusively used for resolving names that match at least one of the domains configured on | |
665 | this link. If not specified defaults to an automatic mode: queries not matching any link's | |
666 | configured domains will be routed to this link if it has no routing-only domains configured. | |
c953b24c | 667 | </para> |
add469f5 YW |
668 | </listitem> |
669 | </varlistentry> | |
670 | ||
671 | <varlistentry> | |
672 | <term><varname>NTP=</varname></term> | |
cea79e66 | 673 | <listitem> |
add469f5 YW |
674 | <para>An NTP server address (either an IP address, or a hostname). This option may be |
675 | specified more than once. This setting is read by | |
676 | <citerefentry><refentrytitle>systemd-timesyncd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
677 | </para> | |
678 | </listitem> | |
679 | </varlistentry> | |
798d3a52 | 680 | |
add469f5 YW |
681 | <varlistentry> |
682 | <term><varname>IPForward=</varname></term> | |
683 | <listitem> | |
684 | <para>Configures IP packet forwarding for the system. If enabled, incoming packets on any | |
685 | network interface will be forwarded to any other interfaces according to the routing table. | |
686 | Takes a boolean, or the values <literal>ipv4</literal> or <literal>ipv6</literal>, which only | |
687 | enable IP packet forwarding for the specified address family. This controls the | |
688 | <filename>net.ipv4.ip_forward</filename> and <filename>net.ipv6.conf.all.forwarding</filename> | |
689 | sysctl options of the network interface (see | |
0e685823 | 690 | <ulink url="https://docs.kernel.org/networking/ip-sysctl.html">IP Sysctl</ulink> |
add469f5 YW |
691 | for details about sysctl options). Defaults to <literal>no</literal>.</para> |
692 | ||
693 | <para>Note: this setting controls a global kernel option, and does so one way only: if a | |
694 | network that has this setting enabled is set up the global setting is turned on. However, | |
695 | it is never turned off again, even after all networks with this setting enabled are shut | |
696 | down again.</para> | |
697 | ||
698 | <para>To allow IP packet forwarding only between specific network interfaces use a firewall. | |
699 | </para> | |
700 | </listitem> | |
701 | </varlistentry> | |
caa8ca42 | 702 | |
add469f5 YW |
703 | <varlistentry> |
704 | <term><varname>IPMasquerade=</varname></term> | |
705 | <listitem> | |
706 | <para>Configures IP masquerading for the network interface. If enabled, packets forwarded | |
707 | from the network interface will be appear as coming from the local host. Takes one of | |
708 | <literal>ipv4</literal>, <literal>ipv6</literal>, <literal>both</literal>, or | |
709 | <literal>no</literal>. Defaults to <literal>no</literal>. If enabled, this automatically sets | |
710 | <varname>IPForward=</varname> to one of <literal>ipv4</literal>, <literal>ipv6</literal> or | |
711 | <literal>yes</literal>.</para> | |
712 | <para>Note. Any positive boolean values such as <literal>yes</literal> or | |
713 | <literal>true</literal> are now deprecated. Please use one of the values in the above.</para> | |
714 | </listitem> | |
715 | </varlistentry> | |
716 | ||
717 | <varlistentry> | |
718 | <term><varname>IPv6PrivacyExtensions=</varname></term> | |
719 | <listitem> | |
720 | <para>Configures use of stateless temporary addresses that change over time (see | |
721 | <ulink url="https://tools.ietf.org/html/rfc4941">RFC 4941</ulink>, | |
722 | Privacy Extensions for Stateless Address Autoconfiguration in IPv6). Takes a boolean or the | |
723 | special values <literal>prefer-public</literal> and <literal>kernel</literal>. When true, | |
724 | enables the privacy extensions and prefers temporary addresses over public addresses. When | |
725 | <literal>prefer-public</literal>, enables the privacy extensions, but prefers public | |
726 | addresses over temporary addresses. When false, the privacy extensions remain disabled. When | |
727 | <literal>kernel</literal>, the kernel's default setting will be left in place. Defaults to | |
728 | <literal>no</literal>.</para> | |
729 | </listitem> | |
730 | </varlistentry> | |
731 | ||
732 | <varlistentry> | |
733 | <term><varname>IPv6AcceptRA=</varname></term> | |
734 | <listitem> | |
735 | <para>Takes a boolean. Controls IPv6 Router Advertisement (RA) reception support for the | |
736 | interface. If true, RAs are accepted; if false, RAs are ignored. When RAs are accepted, they | |
737 | may trigger the start of the DHCPv6 client if the relevant flags are set in the RA data, or | |
738 | if no routers are found on the link. The default is to disable RA reception for bridge | |
739 | devices or when IP forwarding is enabled, and to enable it otherwise. Cannot be enabled on | |
f81ac115 | 740 | bond devices and when link-local addressing is disabled.</para> |
add469f5 YW |
741 | |
742 | <para>Further settings for the IPv6 RA support may be configured in the [IPv6AcceptRA] | |
743 | section, see below.</para> | |
744 | ||
745 | <para>Also see | |
0e685823 | 746 | <ulink url="https://docs.kernel.org/networking/ip-sysctl.html">IP Sysctl</ulink> |
add469f5 YW |
747 | in the kernel documentation regarding <literal>accept_ra</literal>, but note that systemd's |
748 | setting of <constant>1</constant> (i.e. true) corresponds to kernel's setting of | |
749 | <constant>2</constant>.</para> | |
750 | ||
751 | <para>Note that kernel's implementation of the IPv6 RA protocol is always disabled, | |
752 | regardless of this setting. If this option is enabled, a userspace implementation of the IPv6 | |
753 | RA protocol is used, and the kernel's own implementation remains disabled, since | |
754 | <command>systemd-networkd</command> needs to know all details supplied in the advertisements, | |
755 | and these are not available from the kernel if the kernel's own implementation is used. | |
756 | </para> | |
757 | </listitem> | |
758 | </varlistentry> | |
759 | ||
760 | <varlistentry> | |
761 | <term><varname>IPv6DuplicateAddressDetection=</varname></term> | |
762 | <listitem> | |
763 | <para>Configures the amount of IPv6 Duplicate Address Detection (DAD) probes to send. When | |
764 | unset, the kernel's default will be used.</para> | |
765 | </listitem> | |
766 | </varlistentry> | |
767 | ||
768 | <varlistentry> | |
769 | <term><varname>IPv6HopLimit=</varname></term> | |
770 | <listitem> | |
771 | <para>Configures IPv6 Hop Limit. For each router that forwards the packet, the hop limit is | |
772 | decremented by 1. When the hop limit field reaches zero, the packet is discarded. When unset, | |
773 | the kernel's default will be used.</para> | |
774 | </listitem> | |
775 | </varlistentry> | |
776 | ||
777 | <varlistentry> | |
778 | <term><varname>IPv4AcceptLocal=</varname></term> | |
779 | <listitem> | |
780 | <para>Takes a boolean. Accept packets with local source addresses. In combination with | |
781 | suitable routing, this can be used to direct packets between two local interfaces over the | |
782 | wire and have them accepted properly. When unset, the kernel's default will be used.</para> | |
783 | </listitem> | |
784 | </varlistentry> | |
785 | ||
786 | <varlistentry> | |
787 | <term><varname>IPv4RouteLocalnet=</varname></term> | |
788 | <listitem> | |
789 | <para>Takes a boolean. When true, the kernel does not consider loopback addresses as martian | |
790 | source or destination while routing. This enables the use of 127.0.0.0/8 for local routing | |
791 | purposes. When unset, the kernel's default will be used.</para> | |
792 | </listitem> | |
793 | </varlistentry> | |
794 | ||
795 | <varlistentry> | |
796 | <term><varname>IPv4ProxyARP=</varname></term> | |
797 | <listitem> | |
798 | <para>Takes a boolean. Configures proxy ARP for IPv4. Proxy ARP is the technique in which one | |
799 | host, usually a router, answers ARP requests intended for another machine. By "faking" its | |
800 | identity, the router accepts responsibility for routing packets to the "real" destination. | |
801 | See <ulink url="https://tools.ietf.org/html/rfc1027">RFC 1027</ulink>. When unset, the | |
802 | kernel's default will be used.</para> | |
803 | </listitem> | |
804 | </varlistentry> | |
805 | ||
806 | <varlistentry> | |
807 | <term><varname>IPv6ProxyNDP=</varname></term> | |
808 | <listitem> | |
809 | <para>Takes a boolean. Configures proxy NDP for IPv6. Proxy NDP (Neighbor Discovery Protocol) | |
810 | is a technique for IPv6 to allow routing of addresses to a different destination when peers | |
811 | expect them to be present on a certain physical link. In this case a router answers Neighbour | |
812 | Advertisement messages intended for another machine by offering its own MAC address as | |
813 | destination. Unlike proxy ARP for IPv4, it is not enabled globally, but will only send | |
814 | Neighbour Advertisement messages for addresses in the IPv6 neighbor proxy table, which can | |
815 | also be shown by <command>ip -6 neighbour show proxy</command>. systemd-networkd will control | |
816 | the per-interface `proxy_ndp` switch for each configured interface depending on this option. | |
817 | When unset, the kernel's default will be used.</para> | |
818 | </listitem> | |
819 | </varlistentry> | |
820 | ||
821 | <varlistentry> | |
822 | <term><varname>IPv6ProxyNDPAddress=</varname></term> | |
823 | <listitem> | |
824 | <para>An IPv6 address, for which Neighbour Advertisement messages will be proxied. This | |
825 | option may be specified more than once. systemd-networkd will add the | |
826 | <varname>IPv6ProxyNDPAddress=</varname> entries to the kernel's IPv6 neighbor proxy table. | |
827 | This setting implies <varname>IPv6ProxyNDP=yes</varname> but has no effect if | |
828 | <varname>IPv6ProxyNDP=</varname> has been set to false. When unset, the kernel's default will | |
829 | be used.</para> | |
830 | </listitem> | |
831 | </varlistentry> | |
832 | ||
833 | <varlistentry> | |
834 | <term><varname>IPv6SendRA=</varname></term> | |
835 | <listitem> | |
836 | <para>Whether to enable or disable Router Advertisement sending on a link. Takes a boolean | |
837 | value. When enabled, prefixes configured in [IPv6Prefix] sections and routes configured in | |
838 | the [IPv6RoutePrefix] sections are distributed as defined in the [IPv6SendRA] section. If | |
839 | <varname>DHCPPrefixDelegation=</varname> is enabled, then the delegated prefixes are also | |
840 | distributed. See <varname>DCHPPrefixDelegation=</varname> setting and the [IPv6SendRA], | |
841 | [IPv6Prefix], [IPv6RoutePrefix], and [DHCPPrefixDelegation] sections for more configuration | |
842 | options.</para> | |
843 | </listitem> | |
844 | </varlistentry> | |
845 | ||
846 | <varlistentry> | |
847 | <term><varname>DHCPPrefixDelegation=</varname></term> | |
848 | <listitem> | |
d68c797c ZJS |
849 | <para>Takes a boolean value. When enabled, requests subnet prefixes on another link via the DHCPv6 |
850 | protocol or via the 6RD option in the DHCPv4 protocol. An address within each delegated prefix will | |
851 | be assigned, and the prefixes will be announced through IPv6 Router Advertisement if | |
852 | <varname>IPv6SendRA=</varname> is enabled. This behaviour can be configured in the | |
853 | [DHCPPrefixDelegation] section. Defaults to disabled.</para> | |
add469f5 YW |
854 | </listitem> |
855 | </varlistentry> | |
856 | ||
857 | <varlistentry> | |
858 | <term><varname>IPv6MTUBytes=</varname></term> | |
859 | <listitem> | |
860 | <para>Configures IPv6 maximum transmission unit (MTU). An integer greater than or equal to | |
861 | 1280 bytes. When unset, the kernel's default will be used.</para> | |
862 | </listitem> | |
863 | </varlistentry> | |
864 | ||
865 | <varlistentry> | |
866 | <term><varname>KeepMaster=</varname></term> | |
867 | <listitem> | |
868 | <para>Takes a boolean value. When enabled, the current master interface index will not be | |
869 | changed, and <varname>BatmanAdvanced=</varname>, <varname>Bond=</varname>, | |
870 | <varname>Bridge=</varname>, and <varname>VRF=</varname> settings are ignored. This may be | |
871 | useful when a netdev with a master interface is created by another program, e.g. | |
872 | <citerefentry><refentrytitle>systemd-nspawn</refentrytitle><manvolnum>1</manvolnum></citerefentry>. | |
873 | Defaults to false.</para> | |
874 | </listitem> | |
875 | </varlistentry> | |
876 | ||
877 | <varlistentry> | |
878 | <term><varname>BatmanAdvanced=</varname></term> | |
879 | <term><varname>Bond=</varname></term> | |
880 | <term><varname>Bridge=</varname></term> | |
881 | <term><varname>VRF=</varname></term> | |
882 | <listitem> | |
883 | <para>The name of the B.A.T.M.A.N. Advanced, bond, bridge, or VRF interface to add the link | |
884 | to. See | |
885 | <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
886 | </para> | |
887 | </listitem> | |
888 | </varlistentry> | |
889 | ||
890 | <varlistentry> | |
891 | <term><varname>IPoIB=</varname></term> | |
892 | <term><varname>IPVLAN=</varname></term> | |
893 | <term><varname>IPVTAP=</varname></term> | |
add469f5 YW |
894 | <term><varname>MACsec=</varname></term> |
895 | <term><varname>MACVLAN=</varname></term> | |
896 | <term><varname>MACVTAP=</varname></term> | |
897 | <term><varname>Tunnel=</varname></term> | |
898 | <term><varname>VLAN=</varname></term> | |
899 | <term><varname>VXLAN=</varname></term> | |
900 | <term><varname>Xfrm=</varname></term> | |
901 | <listitem> | |
0c91c7a2 | 902 | <para>The name of an IPoIB, IPVLAN, IPVTAP, MACsec, MACVLAN, MACVTAP, tunnel, VLAN, |
add469f5 YW |
903 | VXLAN, or Xfrm to be created on the link. See |
904 | <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
905 | This option may be specified more than once.</para> | |
906 | </listitem> | |
907 | </varlistentry> | |
908 | ||
909 | <varlistentry> | |
910 | <term><varname>ActiveSlave=</varname></term> | |
911 | <listitem> | |
912 | <para>Takes a boolean. Specifies the new active slave. The <literal>ActiveSlave=</literal> | |
913 | option is only valid for following modes: <literal>active-backup</literal>, | |
914 | <literal>balance-alb</literal>, and <literal>balance-tlb</literal>. Defaults to false.</para> | |
915 | </listitem> | |
916 | </varlistentry> | |
917 | ||
918 | <varlistentry> | |
919 | <term><varname>PrimarySlave=</varname></term> | |
920 | <listitem> | |
921 | <para>Takes a boolean. Specifies which slave is the primary device. The specified device will | |
922 | always be the active slave while it is available. Only when the primary is off-line will | |
923 | alternate devices be used. This is useful when one slave is preferred over another, e.g. | |
924 | when one slave has higher throughput than another. The <literal>PrimarySlave=</literal> | |
925 | option is only valid for following modes: <literal>active-backup</literal>, | |
926 | <literal>balance-alb</literal>, and <literal>balance-tlb</literal>. Defaults to false.</para> | |
927 | </listitem> | |
928 | </varlistentry> | |
929 | ||
930 | <varlistentry> | |
931 | <term><varname>ConfigureWithoutCarrier=</varname></term> | |
932 | <listitem> | |
933 | <para>Takes a boolean. Allows networkd to configure a specific link even if it has no | |
934 | carrier. Defaults to false. If enabled, and the <varname>IgnoreCarrierLoss=</varname> setting | |
935 | is not explicitly set, then it is enabled as well.</para> | |
936 | </listitem> | |
937 | </varlistentry> | |
938 | ||
939 | <varlistentry> | |
940 | <term><varname>IgnoreCarrierLoss=</varname></term> | |
941 | <listitem> | |
b7326069 YW |
942 | <para>Takes a boolean or a timespan. When true, <command>systemd-networkd</command> retains |
943 | both the static and dynamic configuration of the interface even if its carrier is lost. When | |
944 | false, <command>systemd-networkd</command> drops both the static and dynamic configuration of | |
945 | the interface. When a timespan is specified, <command>systemd-networkd</command> waits for | |
946 | the specified timespan, and ignores the carrier loss if the link regain its carrier within | |
947 | the timespan. Setting 0 seconds is equivalent to <literal>no</literal>, and | |
948 | <literal>infinite</literal> is equivalent to <literal>yes</literal>.</para> | |
949 | ||
950 | <para>Setting a finite timespan may be useful when e.g. in the following cases: | |
951 | <itemizedlist> | |
952 | <listitem> | |
953 | <para>A wireless interface connecting to a network which has multiple access points with | |
954 | the same SSID.</para> | |
955 | </listitem> | |
956 | <listitem> | |
957 | <para>Enslaving a wireless interface to a bond interface, which may disconnect from the | |
958 | connected access point and causes its carrier to be lost.</para> | |
959 | </listitem> | |
960 | <listitem> | |
961 | <para>The driver of the interface resets when the MTU is changed.</para> | |
962 | </listitem> | |
963 | </itemizedlist> | |
add469f5 | 964 | </para> |
b7326069 YW |
965 | |
966 | <para>When <varname>Bond=</varname> is specified to a wireless interface, defaults to 3 | |
967 | seconds. When the DHCPv4 client is enabled and <varname>UseMTU=</varname> in the [DHCPv4] | |
b17a681b | 968 | section enabled, defaults to 5 seconds. Otherwise, defaults to the value specified with |
b7326069 YW |
969 | <varname>ConfigureWithoutCarrier=</varname>. When <varname>ActivationPolicy=</varname> is set |
970 | to <literal>always-up</literal>, this is forced to <literal>yes</literal>, and ignored any | |
971 | user specified values.</para> | |
add469f5 YW |
972 | </listitem> |
973 | </varlistentry> | |
974 | ||
975 | <varlistentry> | |
976 | <term><varname>KeepConfiguration=</varname></term> | |
977 | <listitem> | |
978 | <para>Takes a boolean or one of <literal>static</literal>, <literal>dhcp-on-stop</literal>, | |
979 | <literal>dhcp</literal>. When <literal>static</literal>, <command>systemd-networkd</command> | |
980 | will not drop static addresses and routes on starting up process. When set to | |
981 | <literal>dhcp-on-stop</literal>, <command>systemd-networkd</command> will not drop addresses | |
982 | and routes on stopping the daemon. When <literal>dhcp</literal>, | |
983 | the addresses and routes provided by a DHCP server will never be dropped even if the DHCP | |
984 | lease expires. This is contrary to the DHCP specification, but may be the best choice if, | |
985 | e.g., the root filesystem relies on this connection. The setting <literal>dhcp</literal> | |
986 | implies <literal>dhcp-on-stop</literal>, and <literal>yes</literal> implies | |
ea853de5 YW |
987 | <literal>dhcp</literal> and <literal>static</literal>. Defaults to |
988 | <literal>dhcp-on-stop</literal> when <command>systemd-networkd</command> is running in | |
989 | initrd, <literal>yes</literal> when the root filesystem is a network filesystem, and | |
990 | <literal>no</literal> otherwise.</para> | |
add469f5 YW |
991 | </listitem> |
992 | </varlistentry> | |
993 | </variablelist> | |
994 | </refsect1> | |
995 | ||
996 | <refsect1> | |
997 | <title>[Address] Section Options</title> | |
998 | ||
999 | <para>An [Address] section accepts the following keys. Specify several [Address] sections to | |
1000 | configure several addresses.</para> | |
1001 | ||
1002 | <variablelist class='network-directives'> | |
1003 | <varlistentry> | |
1004 | <term><varname>Address=</varname></term> | |
1005 | <listitem> | |
1006 | <para>As in the [Network] section. This setting is mandatory. Each [Address] section can | |
1007 | contain one <varname>Address=</varname> setting.</para> | |
1008 | </listitem> | |
1009 | </varlistentry> | |
1010 | ||
1011 | <varlistentry> | |
1012 | <term><varname>Peer=</varname></term> | |
1013 | <listitem> | |
1014 | <para>The peer address in a point-to-point connection. Accepts the same format as the | |
1015 | <varname>Address=</varname> setting.</para> | |
1016 | </listitem> | |
1017 | </varlistentry> | |
1018 | ||
1019 | <varlistentry> | |
1020 | <term><varname>Broadcast=</varname></term> | |
1021 | <listitem> | |
1022 | <para>Takes an IPv4 address or boolean value. The address must be in the format described in | |
1023 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
1024 | If set to true, then the IPv4 broadcast address will be derived from the | |
1025 | <varname>Address=</varname> setting. If set to false, then the broadcast address will not be | |
1026 | set. Defaults to true, except for wireguard interfaces, where it default to false.</para> | |
1027 | </listitem> | |
1028 | </varlistentry> | |
1029 | ||
1030 | <varlistentry> | |
1031 | <term><varname>Label=</varname></term> | |
1032 | <listitem> | |
1033 | <para>Specifies the label for the IPv4 address. The label must be a 7-bit ASCII string with | |
1034 | a length of 1…15 characters. Defaults to unset.</para> | |
1035 | </listitem> | |
1036 | </varlistentry> | |
1037 | ||
1038 | <varlistentry> | |
1039 | <term><varname>PreferredLifetime=</varname></term> | |
1040 | <listitem> | |
1041 | <para>Allows the default "preferred lifetime" of the address to be overridden. Only three | |
1042 | settings are accepted: <literal>forever</literal>, <literal>infinity</literal>, which is the | |
1043 | default and means that the address never expires, and <literal>0</literal>, which means that | |
1044 | the address is considered immediately "expired" and will not be used, unless explicitly | |
1045 | requested. A setting of <option>PreferredLifetime=0</option> is useful for addresses which | |
1046 | are added to be used only by a specific application, which is then configured to use them | |
1047 | explicitly.</para> | |
1048 | </listitem> | |
1049 | </varlistentry> | |
1050 | ||
1051 | <varlistentry> | |
1052 | <term><varname>Scope=</varname></term> | |
1053 | <listitem> | |
1054 | <para>The scope of the address, which can be <literal>global</literal> (valid everywhere on | |
1055 | the network, even through a gateway), <literal>link</literal> (only valid on this device, | |
1056 | will not traverse a gateway) or <literal>host</literal> (only valid within the device itself, | |
1057 | e.g. 127.0.0.1) or an integer in the range 0…255. Defaults to <literal>global</literal>. | |
1058 | </para> | |
1059 | </listitem> | |
1060 | </varlistentry> | |
1061 | ||
1062 | <varlistentry> | |
1063 | <term><varname>RouteMetric=</varname></term> | |
1064 | <listitem> | |
1065 | <para>The metric of the prefix route, which is pointing to the subnet of the configured IP | |
1066 | address, taking the configured prefix length into account. Takes an unsigned integer in the | |
1067 | range 0…4294967295. When unset or set to 0, the kernel's default value is used. This | |
1068 | setting will be ignored when <varname>AddPrefixRoute=</varname> is false.</para> | |
1069 | </listitem> | |
1070 | </varlistentry> | |
1071 | ||
1072 | <varlistentry> | |
1073 | <term><varname>HomeAddress=</varname></term> | |
1074 | <listitem> | |
1075 | <para>Takes a boolean. Designates this address the "home address" as defined in | |
1076 | <ulink url="https://tools.ietf.org/html/rfc6275">RFC 6275</ulink>. Supported only on IPv6. | |
1077 | Defaults to false.</para> | |
1078 | </listitem> | |
1079 | </varlistentry> | |
1080 | ||
1081 | <varlistentry> | |
1082 | <term><varname>DuplicateAddressDetection=</varname></term> | |
1083 | <listitem> | |
1084 | <para>Takes one of <literal>ipv4</literal>, <literal>ipv6</literal>, <literal>both</literal>, | |
1085 | or <literal>none</literal>. When <literal>ipv4</literal>, performs IPv4 Address Conflict | |
1086 | Detection. See <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5227</ulink>. | |
1087 | When <literal>ipv6</literal>, performs IPv6 Duplicate Address Detection. See | |
1088 | <ulink url="https://tools.ietf.org/html/rfc4862">RFC 4862</ulink>. Defaults to | |
2859932b YW |
1089 | <literal>ipv4</literal> for IPv4 link-local addresses, <literal>ipv6</literal> for IPv6 |
1090 | addresses, and <literal>none</literal> otherwise.</para> | |
add469f5 YW |
1091 | </listitem> |
1092 | </varlistentry> | |
1093 | ||
1094 | <varlistentry> | |
1095 | <term><varname>ManageTemporaryAddress=</varname></term> | |
1096 | <listitem> | |
1097 | <para>Takes a boolean. If true the kernel manage temporary addresses created from this one as | |
1098 | template on behalf of Privacy Extensions | |
1099 | <ulink url="https://tools.ietf.org/html/rfc3041">RFC 3041</ulink>. For this to become active, | |
1100 | the use_tempaddr sysctl setting has to be set to a value greater than zero. The given address | |
1101 | needs to have a prefix length of 64. This flag allows using privacy extensions in a manually | |
1102 | configured network, just like if stateless auto-configuration was active. Defaults to false. | |
1103 | </para> | |
1104 | </listitem> | |
1105 | </varlistentry> | |
1106 | ||
1107 | <varlistentry> | |
1108 | <term><varname>AddPrefixRoute=</varname></term> | |
1109 | <listitem> | |
1110 | <para>Takes a boolean. When true, the prefix route for the address is automatically added. | |
1111 | Defaults to true.</para> | |
1112 | </listitem> | |
1113 | </varlistentry> | |
1114 | ||
1115 | <varlistentry> | |
1116 | <term><varname>AutoJoin=</varname></term> | |
1117 | <listitem> | |
1118 | <para>Takes a boolean. Joining multicast group on ethernet level via | |
1119 | <command>ip maddr</command> command would not work if we have an Ethernet switch that does | |
1120 | IGMP snooping since the switch would not replicate multicast packets on ports that did not | |
1121 | have IGMP reports for the multicast addresses. Linux vxlan interfaces created via | |
1122 | <command>ip link add vxlan</command> or networkd's netdev kind vxlan have the group option | |
6a1d8f11 JJ |
1123 | that enables them to do the required join. By extending <command>ip address</command> command |
1124 | with option <literal>autojoin</literal> we can get similar functionality for openvswitch (OVS) | |
1125 | vxlan interfaces as well as other tunneling mechanisms that need to receive multicast traffic. | |
add469f5 YW |
1126 | Defaults to <literal>no</literal>.</para> |
1127 | </listitem> | |
1128 | </varlistentry> | |
4b3590c3 TM |
1129 | |
1130 | <varlistentry> | |
1131 | <term><varname>NetLabel=</varname><replaceable>label</replaceable></term> | |
1132 | <listitem> | |
1133 | ||
1134 | <para>This setting provides a method for integrating static and dynamic network configuration into | |
1135 | Linux <ulink url="https://docs.kernel.org/netlabel/index.html">NetLabel</ulink> subsystem rules, | |
1136 | used by <ulink url="https://en.wikipedia.org/wiki/Linux_Security_Modules">Linux Security Modules | |
1137 | (LSMs)</ulink> for network access control. The label, with suitable LSM rules, can be used to | |
1138 | control connectivity of (for example) a service with peers in the local network. At least with | |
1139 | SELinux, only the ingress can be controlled but not egress. The benefit of using this setting is | |
1140 | that it may be possible to apply interface independent part of NetLabel configuration at very early | |
1141 | stage of system boot sequence, at the time when the network interfaces are not available yet, with | |
1142 | <citerefentry | |
1143 | project='man-pages'><refentrytitle>netlabelctl</refentrytitle><manvolnum>8</manvolnum></citerefentry>, | |
1144 | and the per-interface configuration with <command>systemd-networkd</command> once the interfaces | |
1145 | appear later. Currently this feature is only implemented for SELinux.</para> | |
1146 | ||
1147 | <para>The option expects a single NetLabel label. The label must conform to lexical restrictions of | |
1148 | LSM labels. When an interface is configured with IP addresses, the addresses and subnetwork masks | |
1149 | will be appended to the <ulink | |
1150 | url="https://github.com/SELinuxProject/selinux-notebook/blob/main/src/network_support.md">NetLabel | |
1151 | Fallback Peer Labeling</ulink> rules. They will be removed when the interface is | |
1152 | deconfigured. Failures to manage the labels will be ignored.</para> | |
1153 | ||
1154 | <para>Warning: Once labeling is enabled for network traffic, a lot of LSM access control points in | |
1155 | Linux networking stack go from dormant to active. Care should be taken to avoid getting into a | |
1156 | situation where for example remote connectivity is broken, when the security policy hasn't been | |
1157 | updated to consider LSM per-packet access controls and no rules would allow any network | |
1158 | traffic. Also note that additional configuration with <citerefentry | |
1159 | project='man-pages'><refentrytitle>netlabelctl</refentrytitle><manvolnum>8</manvolnum></citerefentry> | |
1160 | is needed.</para> | |
1161 | ||
1162 | <para>Example: | |
1163 | <programlisting>[Address] | |
1164 | NetLabel=system_u:object_r:localnet_peer_t:s0</programlisting> | |
1165 | ||
1166 | With the example rules applying for interface <literal>eth0</literal>, when the interface is | |
1167 | configured with an IPv4 address of 10.0.0.123/8, <command>systemd-networkd</command> performs the | |
1168 | equivalent of <command>netlabelctl</command> operation | |
1169 | ||
1170 | <programlisting>netlabelctl unlbl add interface eth0 address:10.0.0.0/8 label:system_u:object_r:localnet_peer_t:s0</programlisting> | |
1171 | ||
1172 | and the reverse operation when the IPv4 address is deconfigured. The configuration can be used with | |
1173 | LSM rules; in case of SELinux to allow a SELinux domain to receive data from objects of SELinux | |
1174 | <literal>peer</literal> class. For example: | |
1175 | ||
1176 | <programlisting>type localnet_peer_t; | |
1177 | allow my_server_t localnet_peer_t:peer recv;</programlisting> | |
1178 | ||
1179 | The effect of the above configuration and rules (in absence of other rules as may be the case) is | |
1180 | to only allow <literal>my_server_t</literal> (and nothing else) to receive data from local subnet | |
1181 | 10.0.0.0/8 of interface <literal>eth0</literal>. | |
1182 | </para> | |
1183 | </listitem> | |
1184 | </varlistentry> | |
add469f5 YW |
1185 | </variablelist> |
1186 | </refsect1> | |
1187 | ||
1188 | <refsect1> | |
1189 | <title>[Neighbor] Section Options</title> | |
1190 | ||
1191 | <para>A [Neighbor] section accepts the following keys. The neighbor section adds a permanent, | |
1192 | static entry to the neighbor table (IPv6) or ARP table (IPv4) for the given hardware address on the | |
1193 | links matched for the network. Specify several [Neighbor] sections to configure several static | |
1194 | neighbors.</para> | |
1195 | ||
1196 | <variablelist class='network-directives'> | |
1197 | <varlistentry> | |
1198 | <term><varname>Address=</varname></term> | |
1199 | <listitem> | |
1200 | <para>The IP address of the neighbor.</para> | |
1201 | </listitem> | |
1202 | </varlistentry> | |
1203 | ||
1204 | <varlistentry> | |
1205 | <term><varname>LinkLayerAddress=</varname></term> | |
1206 | <listitem> | |
1207 | <para>The link layer address (MAC address or IP address) of the neighbor.</para> | |
1208 | </listitem> | |
1209 | </varlistentry> | |
1210 | </variablelist> | |
1211 | </refsect1> | |
1212 | ||
1213 | <refsect1> | |
1214 | <title>[IPv6AddressLabel] Section Options</title> | |
1215 | ||
1216 | <para>An [IPv6AddressLabel] section accepts the following keys. Specify several [IPv6AddressLabel] | |
1217 | sections to configure several address labels. IPv6 address labels are used for address selection. | |
1218 | See <ulink url="https://tools.ietf.org/html/rfc3484">RFC 3484</ulink>. Precedence is managed by | |
1219 | userspace, and only the label itself is stored in the kernel.</para> | |
1220 | ||
1221 | <variablelist class='network-directives'> | |
1222 | <varlistentry> | |
1223 | <term><varname>Label=</varname></term> | |
1224 | <listitem> | |
1225 | <para>The label for the prefix, an unsigned integer in the range 0…4294967294. 0xffffffff is | |
1226 | reserved. This setting is mandatory.</para> | |
1227 | </listitem> | |
1228 | </varlistentry> | |
1229 | ||
1230 | <varlistentry> | |
1231 | <term><varname>Prefix=</varname></term> | |
1232 | <listitem> | |
1233 | <para>IPv6 prefix is an address with a prefix length, separated by a slash | |
1234 | <literal>/</literal> character. This setting is mandatory. </para> | |
1235 | </listitem> | |
1236 | </varlistentry> | |
1237 | </variablelist> | |
1238 | </refsect1> | |
1239 | ||
1240 | <refsect1> | |
1241 | <title>[RoutingPolicyRule] Section Options</title> | |
1242 | ||
1243 | <para>An [RoutingPolicyRule] section accepts the following settings. Specify several | |
1244 | [RoutingPolicyRule] sections to configure several rules.</para> | |
1245 | ||
1246 | <variablelist class='network-directives'> | |
1247 | <varlistentry> | |
1248 | <term><varname>TypeOfService=</varname></term> | |
1249 | <listitem> | |
1250 | <para>Takes a number between 0 and 255 that specifies the type of service to match.</para> | |
1251 | </listitem> | |
1252 | </varlistentry> | |
1253 | ||
1254 | <varlistentry> | |
1255 | <term><varname>From=</varname></term> | |
1256 | <listitem> | |
1257 | <para>Specifies the source address prefix to match. Possibly followed by a slash and the | |
1258 | prefix length.</para> | |
1259 | </listitem> | |
1260 | </varlistentry> | |
1261 | ||
1262 | <varlistentry> | |
1263 | <term><varname>To=</varname></term> | |
1264 | <listitem> | |
1265 | <para>Specifies the destination address prefix to match. Possibly followed by a slash and the | |
1266 | prefix length.</para> | |
1267 | </listitem> | |
1268 | </varlistentry> | |
1269 | ||
1270 | <varlistentry> | |
1271 | <term><varname>FirewallMark=</varname></term> | |
1272 | <listitem> | |
1273 | <para>Specifies the iptables firewall mark value to match (a number in the range | |
1274 | 1…4294967295). Optionally, the firewall mask (also a number between 1…4294967295) can be | |
1275 | suffixed with a slash (<literal>/</literal>), e.g., <literal>7/255</literal>.</para> | |
1276 | </listitem> | |
1277 | </varlistentry> | |
1278 | ||
1279 | <varlistentry> | |
1280 | <term><varname>Table=</varname></term> | |
1281 | <listitem> | |
195427cd | 1282 | <para>Specifies the routing table identifier to look up if the rule selector matches. Takes |
add469f5 YW |
1283 | one of predefined names <literal>default</literal>, <literal>main</literal>, and |
1284 | <literal>local</literal>, and names defined in <varname>RouteTable=</varname> in | |
1285 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
1286 | or a number between 1 and 4294967295. Defaults to <literal>main</literal>.</para> | |
1287 | </listitem> | |
1288 | </varlistentry> | |
1289 | ||
1290 | <varlistentry> | |
1291 | <term><varname>Priority=</varname></term> | |
1292 | <listitem> | |
1293 | <para>Specifies the priority of this rule. <varname>Priority=</varname> is an integer in the | |
1294 | range 0…4294967295. Higher number means lower priority, and rules get processed in order of | |
1295 | increasing number. Defaults to unset, and the kernel will pick a value dynamically.</para> | |
1296 | </listitem> | |
1297 | </varlistentry> | |
1298 | ||
1299 | <varlistentry> | |
1300 | <term><varname>IncomingInterface=</varname></term> | |
1301 | <listitem> | |
1302 | <para>Specifies incoming device to match. If the interface is loopback, the rule only matches | |
1303 | packets originating from this host.</para> | |
1304 | </listitem> | |
1305 | </varlistentry> | |
1306 | ||
1307 | <varlistentry> | |
1308 | <term><varname>OutgoingInterface=</varname></term> | |
1309 | <listitem> | |
1310 | <para>Specifies the outgoing device to match. The outgoing interface is only available for | |
1311 | packets originating from local sockets that are bound to a device.</para> | |
1312 | </listitem> | |
1313 | </varlistentry> | |
1314 | ||
1315 | <varlistentry> | |
1316 | <term><varname>SourcePort=</varname></term> | |
1317 | <listitem> | |
1318 | <para>Specifies the source IP port or IP port range match in forwarding information base | |
1319 | (FIB) rules. A port range is specified by the lower and upper port separated by a dash. | |
1320 | Defaults to unset.</para> | |
1321 | </listitem> | |
1322 | </varlistentry> | |
1323 | ||
1324 | <varlistentry> | |
1325 | <term><varname>DestinationPort=</varname></term> | |
1326 | <listitem> | |
1327 | <para>Specifies the destination IP port or IP port range match in forwarding information base | |
1328 | (FIB) rules. A port range is specified by the lower and upper port separated by a dash. | |
1329 | Defaults to unset.</para> | |
1330 | </listitem> | |
1331 | </varlistentry> | |
1332 | ||
1333 | <varlistentry> | |
1334 | <term><varname>IPProtocol=</varname></term> | |
1335 | <listitem> | |
1336 | <para>Specifies the IP protocol to match in forwarding information base (FIB) rules. Takes IP | |
1337 | protocol name such as <literal>tcp</literal>, <literal>udp</literal> or | |
1338 | <literal>sctp</literal>, or IP protocol number such as <literal>6</literal> for | |
1339 | <literal>tcp</literal> or <literal>17</literal> for <literal>udp</literal>. Defaults to unset. | |
1340 | </para> | |
1341 | </listitem> | |
1342 | </varlistentry> | |
1343 | ||
1344 | <varlistentry> | |
1345 | <term><varname>InvertRule=</varname></term> | |
1346 | <listitem> | |
1347 | <para>A boolean. Specifies whether the rule is to be inverted. Defaults to false.</para> | |
1348 | </listitem> | |
1349 | </varlistentry> | |
1350 | ||
1351 | <varlistentry> | |
1352 | <term><varname>Family=</varname></term> | |
1353 | <listitem> | |
1354 | <para>Takes a special value <literal>ipv4</literal>, <literal>ipv6</literal>, or | |
1355 | <literal>both</literal>. By default, the address family is determined by the address | |
1356 | specified in <varname>To=</varname> or <varname>From=</varname>. If neither | |
1357 | <varname>To=</varname> nor <varname>From=</varname> are specified, then defaults to | |
1358 | <literal>ipv4</literal>.</para> | |
1359 | </listitem> | |
1360 | </varlistentry> | |
1361 | ||
1362 | <varlistentry> | |
1363 | <term><varname>User=</varname></term> | |
1364 | <listitem> | |
1365 | <para>Takes a username, a user ID, or a range of user IDs separated by a dash. Defaults to | |
1366 | unset.</para> | |
1367 | </listitem> | |
1368 | </varlistentry> | |
1369 | ||
1370 | <varlistentry> | |
1371 | <term><varname>SuppressPrefixLength=</varname></term> | |
1372 | <listitem> | |
1373 | <para>Takes a number <replaceable>N</replaceable> in the range 0…128 and rejects routing | |
1374 | decisions that have a prefix length of <replaceable>N</replaceable> or less. Defaults to | |
1375 | unset.</para> | |
1376 | </listitem> | |
1377 | </varlistentry> | |
1378 | ||
1379 | <varlistentry> | |
1380 | <term><varname>SuppressInterfaceGroup=</varname></term> | |
1381 | <listitem> | |
1382 | <para>Takes an integer in the range 0…2147483647 and rejects routing decisions that have | |
1383 | an interface with the same group id. It has the same meaning as | |
1384 | <option>suppress_ifgroup</option> in <command>ip rule</command>. Defaults to unset.</para> | |
1385 | </listitem> | |
1386 | </varlistentry> | |
1387 | ||
1388 | <varlistentry> | |
1389 | <term><varname>Type=</varname></term> | |
1390 | <listitem> | |
1391 | <para>Specifies Routing Policy Database (RPDB) rule type. Takes one of | |
1392 | <literal>blackhole</literal>, <literal>unreachable</literal> or <literal>prohibit</literal>. | |
1393 | </para> | |
1394 | </listitem> | |
1395 | </varlistentry> | |
1396 | </variablelist> | |
1397 | </refsect1> | |
1398 | ||
1399 | <refsect1> | |
1400 | <title>[NextHop] Section Options</title> | |
1401 | ||
1402 | <para>The [NextHop] section is used to manipulate entries in the kernel's "nexthop" tables. The | |
1403 | [NextHop] section accepts the following settings. Specify several [NextHop] sections to configure | |
1404 | several hops.</para> | |
1405 | ||
1406 | <variablelist class='network-directives'> | |
1407 | <varlistentry> | |
1408 | <term><varname>Id=</varname></term> | |
1409 | <listitem> | |
1410 | <para>The id of the next hop. Takes an integer in the range 1…4294967295. If unspecified, | |
1411 | then automatically chosen by kernel.</para> | |
1412 | </listitem> | |
1413 | </varlistentry> | |
1414 | ||
1415 | <varlistentry> | |
1416 | <term><varname>Gateway=</varname></term> | |
1417 | <listitem> | |
1418 | <para>As in the [Network] section.</para> | |
1419 | </listitem> | |
1420 | </varlistentry> | |
1421 | ||
1422 | <varlistentry> | |
1423 | <term><varname>Family=</varname></term> | |
1424 | <listitem> | |
1425 | <para>Takes one of the special values <literal>ipv4</literal> or <literal>ipv6</literal>. | |
1426 | By default, the family is determined by the address specified in | |
1427 | <varname>Gateway=</varname>. If <varname>Gateway=</varname> is not specified, then defaults | |
1428 | to <literal>ipv4</literal>.</para> | |
1429 | </listitem> | |
1430 | </varlistentry> | |
1431 | ||
1432 | <varlistentry> | |
1433 | <term><varname>OnLink=</varname></term> | |
1434 | <listitem> | |
1435 | <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is | |
1436 | reachable directly by the current machine (i.e., attached to the local network), so that we | |
1437 | can insert the nexthop in the kernel table without it being complained about. Defaults to | |
1438 | <literal>no</literal>.</para> | |
1439 | </listitem> | |
1440 | </varlistentry> | |
1441 | ||
1442 | <varlistentry> | |
1443 | <term><varname>Blackhole=</varname></term> | |
1444 | <listitem> | |
1445 | <para>Takes a boolean. If enabled, packets to the corresponding routes are discarded | |
1446 | silently, and <varname>Gateway=</varname> cannot be specified. Defaults to | |
1447 | <literal>no</literal>.</para> | |
1448 | </listitem> | |
1449 | </varlistentry> | |
1450 | ||
1451 | <varlistentry> | |
1452 | <term><varname>Group=</varname></term> | |
1453 | <listitem> | |
1454 | <para>Takes a whitespace separated list of nexthop IDs. Each ID must be in the range | |
1455 | 1…4294967295. Optionally, each nexthop ID can take a weight after a colon | |
1456 | (<literal><replaceable>id</replaceable><optional>:<replaceable>weight</replaceable></optional></literal>). | |
1457 | The weight must be in the range 1…255. If the weight is not specified, then it is assumed | |
1458 | that the weight is 1. This setting cannot be specified with <varname>Gateway=</varname>, | |
1459 | <varname>Family=</varname>, <varname>Blackhole=</varname>. This setting can be specified | |
1460 | multiple times. If an empty string is assigned, then the all previous assignments are | |
1461 | cleared. Defaults to unset.</para> | |
1462 | </listitem> | |
1463 | </varlistentry> | |
1464 | </variablelist> | |
1465 | </refsect1> | |
1466 | ||
1467 | <refsect1> | |
1468 | <title>[Route] Section Options</title> | |
1469 | ||
1470 | <para>The [Route] section accepts the following settings. Specify several [Route] sections to | |
1471 | configure several routes.</para> | |
1472 | ||
1473 | <variablelist class='network-directives'> | |
1474 | <varlistentry> | |
1475 | <term><varname>Gateway=</varname></term> | |
1476 | <listitem> | |
1477 | <para>Takes the gateway address or the special values <literal>_dhcp4</literal> and | |
1478 | <literal>_ipv6ra</literal>. If <literal>_dhcp4</literal> or <literal>_ipv6ra</literal> is | |
1479 | set, then the gateway address provided by DHCPv4 or IPv6 RA is used.</para> | |
1480 | </listitem> | |
1481 | </varlistentry> | |
1482 | ||
1483 | <varlistentry> | |
1484 | <term><varname>GatewayOnLink=</varname></term> | |
1485 | <listitem> | |
1486 | <para>Takes a boolean. If set to true, the kernel does not have to check if the gateway is | |
1487 | reachable directly by the current machine (i.e., attached to the local network), so that we | |
1488 | can insert the route in the kernel table without it being complained about. Defaults to | |
1489 | <literal>no</literal>.</para> | |
1490 | </listitem> | |
1491 | </varlistentry> | |
1492 | ||
1493 | <varlistentry> | |
1494 | <term><varname>Destination=</varname></term> | |
1495 | <listitem> | |
1496 | <para>The destination prefix of the route. Possibly followed by a slash and the prefix | |
1497 | length. If omitted, a full-length host route is assumed.</para> | |
1498 | </listitem> | |
1499 | </varlistentry> | |
1500 | ||
1501 | <varlistentry> | |
1502 | <term><varname>Source=</varname></term> | |
1503 | <listitem> | |
1504 | <para>The source prefix of the route. Possibly followed by a slash and the prefix length. If | |
1505 | omitted, a full-length host route is assumed.</para> | |
1506 | </listitem> | |
1507 | </varlistentry> | |
1508 | ||
1509 | <varlistentry> | |
1510 | <term><varname>Metric=</varname></term> | |
1511 | <listitem> | |
1512 | <para>The metric of the route. Takes an unsigned integer in the range 0…4294967295. Defaults | |
1513 | to unset, and the kernel's default will be used.</para> | |
1514 | </listitem> | |
1515 | </varlistentry> | |
1516 | ||
1517 | <varlistentry> | |
1518 | <term><varname>IPv6Preference=</varname></term> | |
1519 | <listitem> | |
1520 | <para>Specifies the route preference as defined in | |
1521 | <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> for Router Discovery | |
1522 | messages. Which can be one of <literal>low</literal> the route has a lowest priority, | |
1523 | <literal>medium</literal> the route has a default priority or <literal>high</literal> the | |
1524 | route has a highest priority.</para> | |
1525 | </listitem> | |
1526 | </varlistentry> | |
1527 | ||
1528 | <varlistentry> | |
1529 | <term><varname>Scope=</varname></term> | |
1530 | <listitem> | |
1531 | <para>The scope of the IPv4 route, which can be <literal>global</literal>, | |
1532 | <literal>site</literal>, <literal>link</literal>, <literal>host</literal>, or | |
1533 | <literal>nowhere</literal>:</para> | |
1534 | <itemizedlist> | |
1535 | <listitem> | |
1536 | <para><literal>global</literal> means the route can reach hosts more than one hop away. | |
1537 | </para> | |
1538 | </listitem> | |
1539 | ||
1540 | <listitem> | |
1541 | <para><literal>site</literal> means an interior route in the local autonomous system. | |
1542 | </para> | |
1543 | </listitem> | |
1544 | ||
1545 | <listitem> | |
1546 | <para><literal>link</literal> means the route can only reach hosts on the local network | |
1547 | (one hop away).</para> | |
1548 | </listitem> | |
1549 | ||
1550 | <listitem> | |
1551 | <para><literal>host</literal> means the route will not leave the local machine (used for | |
1552 | internal addresses like 127.0.0.1).</para> | |
1553 | </listitem> | |
1554 | ||
1555 | <listitem> | |
1556 | <para><literal>nowhere</literal> means the destination doesn't exist.</para> | |
1557 | </listitem> | |
1558 | </itemizedlist> | |
1559 | ||
1560 | <para>For IPv4 route, defaults to <literal>host</literal> if <varname>Type=</varname> is | |
1561 | <literal>local</literal> or <literal>nat</literal>, and <literal>link</literal> if | |
902bbdc4 | 1562 | <varname>Type=</varname> is <literal>broadcast</literal>, <literal>multicast</literal>, |
6a1d8f11 | 1563 | <literal>anycast</literal>, or <literal>unicast</literal>. In other cases, |
902bbdc4 | 1564 | defaults to <literal>global</literal>. The value is not used for IPv6.</para> |
add469f5 YW |
1565 | </listitem> |
1566 | </varlistentry> | |
1567 | ||
1568 | <varlistentry> | |
1569 | <term><varname>PreferredSource=</varname></term> | |
1570 | <listitem> | |
1571 | <para>The preferred source address of the route. The address must be in the format described | |
1572 | in | |
1573 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
1574 | </para> | |
1575 | </listitem> | |
1576 | </varlistentry> | |
1577 | ||
1578 | <varlistentry> | |
1579 | <term><varname>Table=</varname></term> | |
1580 | <listitem> | |
1581 | <para>The table identifier for the route. Takes one of predefined names | |
1582 | <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, and names | |
1583 | defined in <varname>RouteTable=</varname> in | |
1584 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
1585 | or a number between 1 and 4294967295. The table can be retrieved using | |
1586 | <command>ip route show table <replaceable>num</replaceable></command>. If unset and | |
1587 | <varname>Type=</varname> is <literal>local</literal>, <literal>broadcast</literal>, | |
1588 | <literal>anycast</literal>, or <literal>nat</literal>, then <literal>local</literal> is used. | |
1589 | In other cases, defaults to <literal>main</literal>.</para> | |
1590 | </listitem> | |
1591 | </varlistentry> | |
1592 | ||
1593 | <varlistentry> | |
1594 | <term><varname>Protocol=</varname></term> | |
1595 | <listitem> | |
1596 | <para>The protocol identifier for the route. Takes a number between 0 and 255 or the special | |
1597 | values <literal>kernel</literal>, <literal>boot</literal>, <literal>static</literal>, | |
1598 | <literal>ra</literal> and <literal>dhcp</literal>. Defaults to <literal>static</literal>. | |
1599 | </para> | |
1600 | </listitem> | |
1601 | </varlistentry> | |
1602 | ||
1603 | <varlistentry> | |
1604 | <term><varname>Type=</varname></term> | |
1605 | <listitem> | |
1606 | <para>Specifies the type for the route. Takes one of <literal>unicast</literal>, | |
1607 | <literal>local</literal>, <literal>broadcast</literal>, <literal>anycast</literal>, | |
1608 | <literal>multicast</literal>, <literal>blackhole</literal>, <literal>unreachable</literal>, | |
1609 | <literal>prohibit</literal>, <literal>throw</literal>, <literal>nat</literal>, and | |
1610 | <literal>xresolve</literal>. If <literal>unicast</literal>, a regular route is defined, i.e. | |
1611 | a route indicating the path to take to a destination network address. If | |
1612 | <literal>blackhole</literal>, packets to the defined route are discarded silently. If | |
1613 | <literal>unreachable</literal>, packets to the defined route are discarded and the ICMP | |
1614 | message "Host Unreachable" is generated. If <literal>prohibit</literal>, packets to the | |
1615 | defined route are discarded and the ICMP message "Communication Administratively Prohibited" | |
1616 | is generated. If <literal>throw</literal>, route lookup in the current routing table will | |
1617 | fail and the route selection process will return to Routing Policy Database (RPDB). Defaults | |
1618 | to <literal>unicast</literal>.</para> | |
1619 | </listitem> | |
1620 | </varlistentry> | |
1621 | ||
1622 | <varlistentry> | |
1623 | <term><varname>InitialCongestionWindow=</varname></term> | |
1624 | <listitem> | |
1625 | <para>The TCP initial congestion window is used during the start of a TCP connection. | |
1626 | During the start of a TCP session, when a client requests a resource, the server's initial | |
1627 | congestion window determines how many packets will be sent during the initial burst of data | |
1628 | without waiting for acknowledgement. Takes a number between 1 and 1023. Note that 100 is | |
1629 | considered an extremely large value for this option. When unset, the kernel's default | |
1630 | (typically 10) will be used.</para> | |
1631 | </listitem> | |
1632 | </varlistentry> | |
1633 | ||
1634 | <varlistentry> | |
1635 | <term><varname>InitialAdvertisedReceiveWindow=</varname></term> | |
1636 | <listitem> | |
1637 | <para>The TCP initial advertised receive window is the amount of receive data (in bytes) | |
1638 | that can initially be buffered at one time on a connection. The sending host can send only | |
1639 | that amount of data before waiting for an acknowledgment and window update from the | |
1640 | receiving host. Takes a number between 1 and 1023. Note that 100 is considered an extremely | |
1641 | large value for this option. When unset, the kernel's default will be used.</para> | |
1642 | </listitem> | |
1643 | </varlistentry> | |
1644 | ||
1645 | <varlistentry> | |
1646 | <term><varname>QuickAck=</varname></term> | |
1647 | <listitem> | |
1648 | <para>Takes a boolean. When true enables TCP quick ack mode for the route. When unset, the | |
1649 | kernel's default will be used.</para> | |
1650 | </listitem> | |
1651 | </varlistentry> | |
1652 | ||
1653 | <varlistentry> | |
1654 | <term><varname>FastOpenNoCookie=</varname></term> | |
1655 | <listitem> | |
1656 | <para>Takes a boolean. When true enables TCP fastopen without a cookie on a per-route basis. | |
1657 | When unset, the kernel's default will be used.</para> | |
1658 | </listitem> | |
1659 | </varlistentry> | |
1660 | ||
1661 | <varlistentry> | |
1662 | <term><varname>TTLPropagate=</varname></term> | |
1663 | <listitem> | |
1664 | <para>Takes a boolean. When true enables TTL propagation at Label Switched Path (LSP) egress. | |
1665 | When unset, the kernel's default will be used.</para> | |
1666 | </listitem> | |
1667 | </varlistentry> | |
1668 | ||
1669 | <varlistentry> | |
1670 | <term><varname>MTUBytes=</varname></term> | |
1671 | <listitem> | |
1672 | <para>The maximum transmission unit in bytes to set for the route. The usual suffixes K, M, | |
1673 | G, are supported and are understood to the base of 1024.</para> | |
1674 | </listitem> | |
1675 | </varlistentry> | |
1676 | ||
1677 | <varlistentry> | |
1678 | <term><varname>TCPAdvertisedMaximumSegmentSize=</varname></term> | |
1679 | <listitem> | |
1680 | <para>Specifies the Path MSS (in bytes) hints given on TCP layer. The usual suffixes K, M, G, | |
1681 | are supported and are understood to the base of 1024. An unsigned integer in the range | |
1682 | 1…4294967294. When unset, the kernel's default will be used.</para> | |
1683 | </listitem> | |
1684 | </varlistentry> | |
1685 | ||
dc7c21f0 YW |
1686 | <varlistentry> |
1687 | <term><varname>TCPCongestionControlAlgorithm=</varname></term> | |
1688 | <listitem> | |
1689 | <para>Specifies the TCP congestion control algorithm for the route. Takes a name of the algorithm, | |
1690 | e.g. <literal>bbr</literal>, <literal>dctcp</literal>, or <literal>vegas</literal>. When unset, | |
1691 | the kernel's default will be used.</para> | |
1692 | </listitem> | |
1693 | </varlistentry> | |
1694 | ||
add469f5 YW |
1695 | <varlistentry> |
1696 | <term><varname>MultiPathRoute=<replaceable>address</replaceable>[@<replaceable>name</replaceable>] [<replaceable>weight</replaceable>]</varname></term> | |
1697 | <listitem> | |
1698 | <para>Configures multipath route. Multipath routing is the technique of using multiple | |
1699 | alternative paths through a network. Takes gateway address. Optionally, takes a network | |
1700 | interface name or index separated with <literal>@</literal>, and a weight in 1..256 for this | |
1701 | multipath route separated with whitespace. This setting can be specified multiple times. If | |
1702 | an empty string is assigned, then the all previous assignments are cleared.</para> | |
1703 | </listitem> | |
1704 | </varlistentry> | |
1705 | ||
1706 | <varlistentry> | |
1707 | <term><varname>NextHop=</varname></term> | |
1708 | <listitem> | |
1709 | <para>Specifies the nexthop id. Takes an unsigned integer in the range 1…4294967295. If set, | |
1710 | the corresponding [NextHop] section must be configured. Defaults to unset.</para> | |
1711 | </listitem> | |
1712 | </varlistentry> | |
1713 | </variablelist> | |
1714 | </refsect1> | |
1715 | ||
1716 | <refsect1> | |
1717 | <title>[DHCPv4] Section Options</title> | |
1718 | ||
1719 | <para>The [DHCPv4] section configures the DHCPv4 client, if it is enabled with the | |
1720 | <varname>DHCP=</varname> setting described above:</para> | |
1721 | ||
1722 | <variablelist class='network-directives'> | |
1723 | ||
1724 | <!-- DHCP packet contents --> | |
1725 | ||
1726 | <varlistentry> | |
1727 | <term><varname>SendHostname=</varname></term> | |
1728 | <listitem> | |
1729 | <para>When true (the default), the machine's hostname (or the value specified with | |
1730 | <varname>Hostname=</varname>, described below) will be sent to the DHCP server. Note that the | |
1731 | hostname must consist only of 7-bit ASCII lower-case characters and no spaces or dots, and be | |
1732 | formatted as a valid DNS domain name. Otherwise, the hostname is not sent even if this option | |
1733 | is true.</para> | |
1734 | </listitem> | |
1735 | </varlistentry> | |
1736 | ||
1737 | <varlistentry> | |
1738 | <term><varname>Hostname=</varname></term> | |
1739 | <listitem> | |
1740 | <para>Use this value for the hostname which is sent to the DHCP server, instead of machine's | |
1741 | hostname. Note that the specified hostname must consist only of 7-bit ASCII lower-case | |
1742 | characters and no spaces or dots, and be formatted as a valid DNS domain name.</para> | |
1743 | </listitem> | |
1744 | </varlistentry> | |
1745 | ||
1746 | <varlistentry> | |
1747 | <term><varname>MUDURL=</varname></term> | |
1748 | <listitem> | |
1749 | <para>When configured, the specified Manufacturer Usage Description (MUD) URL will be sent | |
1750 | to the DHCPv4 server. Takes a URL of length up to 255 characters. A superficial verification | |
1751 | that the string is a valid URL will be performed. DHCPv4 clients are intended to have at most | |
1752 | one MUD URL associated with them. See | |
1753 | <ulink url="https://tools.ietf.org/html/rfc8520">RFC 8520</ulink>.</para> | |
1754 | ||
1755 | <para>MUD is an embedded software standard defined by the IETF that allows IoT device makers | |
1756 | to advertise device specifications, including the intended communication patterns for their | |
1757 | device when it connects to the network. The network can then use this to author a | |
1758 | context-specific access policy, so the device functions only within those parameters.</para> | |
1759 | </listitem> | |
1760 | </varlistentry> | |
1761 | ||
1762 | <varlistentry> | |
1763 | <term><varname>ClientIdentifier=</varname></term> | |
1764 | <listitem> | |
1765 | <para>The DHCPv4 client identifier to use. Takes one of <option>mac</option>, | |
1766 | <option>duid</option> or <option>duid-only</option>. If set to <option>mac</option>, the | |
1767 | MAC address of the link is used. If set to <option>duid</option>, an RFC4361-compliant Client | |
1768 | ID, which is the combination of IAID and DUID (see below), is used. If set to | |
1769 | <option>duid-only</option>, only DUID is used, this may not be RFC compliant, but some setups | |
1770 | may require to use this. Defaults to <option>duid</option>.</para> | |
1771 | </listitem> | |
1772 | </varlistentry> | |
1773 | ||
1774 | <varlistentry> | |
1775 | <term><varname>VendorClassIdentifier=</varname></term> | |
1776 | <listitem> | |
1777 | <para>The vendor class identifier used to identify vendor type and configuration.</para> | |
1778 | </listitem> | |
1779 | </varlistentry> | |
1780 | ||
1781 | <varlistentry> | |
1782 | <term><varname>UserClass=</varname></term> | |
1783 | <listitem> | |
1784 | <para>A DHCPv4 client can use UserClass option to identify the type or category of user or | |
1785 | applications it represents. The information contained in this option is a string that | |
1786 | represents the user class of which the client is a member. Each class sets an identifying | |
1787 | string of information to be used by the DHCP service to classify clients. Takes a | |
1788 | whitespace-separated list of strings.</para> | |
1789 | </listitem> | |
1790 | </varlistentry> | |
1791 | ||
1792 | <varlistentry> | |
1793 | <term><varname>DUIDType=</varname></term> | |
1794 | <listitem> | |
1795 | <para>Override the global <varname>DUIDType=</varname> setting for this network. See | |
1796 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
1797 | for a description of possible values.</para> | |
1798 | </listitem> | |
1799 | </varlistentry> | |
1800 | ||
1801 | <varlistentry> | |
1802 | <term><varname>DUIDRawData=</varname></term> | |
1803 | <listitem> | |
1804 | <para>Override the global <varname>DUIDRawData=</varname> setting for this network. See | |
1805 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry> | |
1806 | for a description of possible values.</para> | |
1807 | </listitem> | |
1808 | </varlistentry> | |
1809 | ||
1810 | <varlistentry> | |
1811 | <term><varname>IAID=</varname></term> | |
1812 | <listitem> | |
1813 | <para>The DHCP Identity Association Identifier (IAID) for the interface, a 32-bit unsigned | |
1814 | integer.</para> | |
1815 | </listitem> | |
1816 | </varlistentry> | |
1817 | ||
1818 | <varlistentry> | |
1819 | <term><varname>Anonymize=</varname></term> | |
1820 | <listitem> | |
1821 | <para>Takes a boolean. When true, the options sent to the DHCP server will follow the | |
1822 | <ulink url="https://tools.ietf.org/html/rfc7844">RFC 7844</ulink> (Anonymity Profiles for | |
1823 | DHCP Clients) to minimize disclosure of identifying information. Defaults to false.</para> | |
1824 | ||
1825 | <para>This option should only be set to true when <varname>MACAddressPolicy=</varname> is set | |
1826 | to <option>random</option> (see | |
1827 | <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>). | |
1828 | </para> | |
1829 | ||
1830 | <para>When true, <varname>SendHostname=</varname>, <varname>ClientIdentifier=</varname>, | |
1831 | <varname>VendorClassIdentifier=</varname>, <varname>UserClass=</varname>, | |
1832 | <varname>RequestOptions=</varname>, <varname>SendOption=</varname>, | |
1833 | <varname>SendVendorOption=</varname>, and <varname>MUDURL=</varname> are ignored.</para> | |
1834 | ||
1835 | <para>With this option enabled DHCP requests will mimic those generated by Microsoft | |
1836 | Windows, in order to reduce the ability to fingerprint and recognize installations. This | |
1837 | means DHCP request sizes will grow and lease data will be more comprehensive than normally, | |
1838 | though most of the requested data is not actually used.</para> | |
1839 | </listitem> | |
1840 | </varlistentry> | |
1841 | ||
1842 | <varlistentry> | |
1843 | <term><varname>RequestOptions=</varname></term> | |
1844 | <listitem> | |
1845 | <para>Sets request options to be sent to the server in the DHCPv4 request options list. A | |
1846 | whitespace-separated list of integers in the range 1…254. Defaults to unset.</para> | |
1847 | </listitem> | |
1848 | </varlistentry> | |
1849 | ||
1850 | <varlistentry> | |
1851 | <term><varname>SendOption=</varname></term> | |
1852 | <listitem> | |
1853 | <para>Send an arbitrary raw option in the DHCPv4 request. Takes a DHCP option number, data | |
1854 | type and data separated with a colon | |
1855 | (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). | |
1856 | The option number must be an integer in the range 1…254. The type takes one of | |
1857 | <literal>uint8</literal>, <literal>uint16</literal>, <literal>uint32</literal>, | |
1858 | <literal>ipv4address</literal>, or <literal>string</literal>. Special characters in the data | |
1859 | string may be escaped using | |
1860 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
1861 | escapes</ulink>. This setting can be specified multiple times. If an empty string is | |
1862 | specified, then all options specified earlier are cleared. Defaults to unset.</para> | |
1863 | </listitem> | |
1864 | </varlistentry> | |
1865 | ||
1866 | <varlistentry> | |
1867 | <term><varname>SendVendorOption=</varname></term> | |
1868 | <listitem> | |
1869 | <para>Send an arbitrary vendor option in the DHCPv4 request. Takes a DHCP option number, data | |
1870 | type and data separated with a colon | |
1871 | (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). | |
1872 | The option number must be an integer in the range 1…254. The type takes one of | |
1873 | <literal>uint8</literal>, <literal>uint16</literal>, <literal>uint32</literal>, | |
1874 | <literal>ipv4address</literal>, or <literal>string</literal>. Special characters in the data | |
1875 | string may be escaped using | |
1876 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
1877 | escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, | |
1878 | then all options specified earlier are cleared. Defaults to unset.</para> | |
1879 | </listitem> | |
1880 | </varlistentry> | |
1881 | ||
1882 | <varlistentry> | |
1883 | <term><varname>IPServiceType=</varname></term> | |
1884 | <listitem> | |
1885 | <para>Takes one of the special values <literal>none</literal>, <literal>CS6</literal>, or | |
1886 | <literal>CS4</literal>. When <literal>none</literal> no IP service type is set to the packet | |
1887 | sent from the DHCPv4 client. When <literal>CS6</literal> (network control) or | |
1888 | <literal>CS4</literal> (realtime), the corresponding service type will be set. Defaults to | |
1889 | <literal>CS6</literal>.</para> | |
1890 | </listitem> | |
1891 | </varlistentry> | |
1892 | ||
1893 | <!-- How to use the DHCP lease --> | |
1894 | ||
1895 | <varlistentry> | |
1896 | <term><varname>Label=</varname></term> | |
1897 | <listitem> | |
1898 | <para>Specifies the label for the IPv4 address received from the DHCP server. The label must | |
1899 | be a 7-bit ASCII string with a length of 1…15 characters. Defaults to unset.</para> | |
1900 | </listitem> | |
1901 | </varlistentry> | |
1902 | ||
1903 | <varlistentry> | |
1904 | <term><varname>UseDNS=</varname></term> | |
1905 | <listitem> | |
1906 | <para>When true (the default), the DNS servers received from the DHCP server will be used. | |
1907 | </para> | |
1908 | ||
1909 | <para>This corresponds to the <option>nameserver</option> option in | |
1910 | <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
1911 | </para> | |
1912 | </listitem> | |
1913 | </varlistentry> | |
1914 | ||
1915 | <varlistentry> | |
1916 | <term><varname>RoutesToDNS=</varname></term> | |
1917 | <listitem> | |
1918 | <para>When true, the routes to the DNS servers received from the DHCP server will be | |
1919 | configured. When <varname>UseDNS=</varname> is disabled, this setting is ignored. Defaults to | |
1920 | true.</para> | |
1921 | </listitem> | |
1922 | </varlistentry> | |
1923 | ||
1924 | <varlistentry> | |
1925 | <term><varname>UseNTP=</varname></term> | |
1926 | <listitem> | |
1927 | <para>When true (the default), the NTP servers received from the DHCP server will be used by | |
1928 | <filename>systemd-timesyncd.service</filename>.</para> | |
1929 | </listitem> | |
1930 | </varlistentry> | |
1931 | ||
1932 | <varlistentry> | |
1933 | <term><varname>RoutesToNTP=</varname></term> | |
1934 | <listitem> | |
1935 | <para>When true, the routes to the NTP servers received from the DHCP server will be | |
1936 | configured. When <varname>UseNTP=</varname> is disabled, this setting is ignored. Defaults to | |
1937 | true.</para> | |
1938 | </listitem> | |
1939 | </varlistentry> | |
1940 | ||
1941 | <varlistentry> | |
1942 | <term><varname>UseSIP=</varname></term> | |
1943 | <listitem> | |
1944 | <para>When true (the default), the SIP servers received from the DHCP server will be collected | |
1945 | and made available to client programs.</para> | |
1946 | </listitem> | |
1947 | </varlistentry> | |
1948 | ||
1949 | <varlistentry> | |
1950 | <term><varname>UseMTU=</varname></term> | |
1951 | <listitem> | |
1952 | <para>When true, the interface maximum transmission unit from the DHCP server will be used on | |
1953 | the current link. If <varname>MTUBytes=</varname> is set, then this setting is ignored. | |
1954 | Defaults to false.</para> | |
1955 | ||
1956 | <para>Note, some drivers will reset the interfaces if the MTU is changed. For such | |
1957 | interfaces, please try to use <varname>IgnoreCarrierLoss=</varname> with a short timespan, | |
1958 | e.g. <literal>3 seconds</literal>.</para> | |
1959 | </listitem> | |
1960 | </varlistentry> | |
1961 | ||
1962 | <varlistentry> | |
1963 | <term><varname>UseHostname=</varname></term> | |
1964 | <listitem> | |
1965 | <para>When true (the default), the hostname received from the DHCP server will be set as the | |
1966 | transient hostname of the system.</para> | |
1967 | </listitem> | |
1968 | </varlistentry> | |
1969 | ||
1970 | <varlistentry> | |
1971 | <term><varname>UseDomains=</varname></term> | |
1972 | <listitem> | |
15102ced ZJS |
1973 | <para>Takes a boolean, or the special value <option>route</option>. When true, the domain name |
1974 | received from the DHCP server will be used as DNS search domain over this link, similarly to the | |
1975 | effect of the <option>Domains=</option> setting. If set to <option>route</option>, the domain name | |
1976 | received from the DHCP server will be used for routing DNS queries only, but not for searching, | |
1977 | similarly to the effect of the <option>Domains=</option> setting when the argument is prefixed with | |
1978 | <literal>~</literal>. Defaults to false.</para> | |
add469f5 YW |
1979 | |
1980 | <para>It is recommended to enable this option only on trusted networks, as setting this | |
1981 | affects resolution of all hostnames, in particular of single-label names. It is generally | |
1982 | safer to use the supplied domain only as routing domain, rather than as search domain, in | |
1983 | order to not have it affect local resolution of single-label names.</para> | |
1984 | ||
1985 | <para>When set to true, this setting corresponds to the <option>domain</option> option in | |
1986 | <citerefentry project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>. | |
1987 | </para> | |
1988 | </listitem> | |
1989 | </varlistentry> | |
1990 | ||
1991 | <varlistentry> | |
1992 | <term><varname>UseRoutes=</varname></term> | |
1993 | <listitem> | |
1994 | <para>When true (the default), the static routes will be requested from the DHCP server and | |
1995 | added to the routing table with a metric of 1024, and a scope of <option>global</option>, | |
1996 | <option>link</option> or <option>host</option>, depending on the route's destination and | |
1997 | gateway. If the destination is on the local host, e.g., 127.x.x.x, or the same as the link's | |
1998 | own address, the scope will be set to <option>host</option>. Otherwise if the gateway is null | |
1999 | (a direct route), a <option>link</option> scope will be used. For anything else, scope | |
2000 | defaults to <option>global</option>.</para> | |
2001 | </listitem> | |
2002 | </varlistentry> | |
2003 | ||
2004 | <varlistentry> | |
2005 | <term><varname>RouteMetric=</varname></term> | |
2006 | <listitem> | |
2007 | <para>Set the routing metric for routes specified by the DHCP server (including the prefix | |
2008 | route added for the specified prefix). Takes an unsigned integer in the range 0…4294967295. | |
2009 | Defaults to 1024.</para> | |
2010 | </listitem> | |
2011 | </varlistentry> | |
2012 | ||
2013 | <varlistentry> | |
2014 | <term><varname>RouteTable=<replaceable>num</replaceable></varname></term> | |
2015 | <listitem> | |
7db98bc9 YW |
2016 | <para>The table identifier for DHCP routes. Takes one of predefined names |
2017 | <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, and names | |
2018 | defined in <varname>RouteTable=</varname> in | |
2019 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
2020 | or a number between 1…4294967295.</para> | |
add469f5 YW |
2021 | |
2022 | <para>When used in combination with <varname>VRF=</varname>, the VRF's routing table is | |
2023 | used when this parameter is not specified.</para> | |
2024 | </listitem> | |
2025 | </varlistentry> | |
2026 | ||
2027 | <varlistentry> | |
2028 | <term><varname>RouteMTUBytes=</varname></term> | |
2029 | <listitem> | |
2030 | <para>Specifies the MTU for the DHCP routes. Please see the [Route] section for further | |
2031 | details.</para> | |
2032 | </listitem> | |
2033 | </varlistentry> | |
2034 | ||
2035 | <varlistentry> | |
2036 | <term><varname>UseGateway=</varname></term> | |
2037 | <listitem> | |
2038 | <para>When true, the gateway will be requested from the DHCP server and added to the routing | |
2039 | table with a metric of 1024, and a scope of <option>link</option>. When unset, the value | |
2040 | specified with <varname>UseRoutes=</varname> is used.</para> | |
2041 | </listitem> | |
2042 | </varlistentry> | |
2043 | ||
2044 | <varlistentry> | |
2045 | <term><varname>UseTimezone=</varname></term> | |
2046 | <listitem><para>When true, the timezone received from the DHCP server will be set as timezone | |
2047 | of the local system. Defaults to false.</para></listitem> | |
2048 | </varlistentry> | |
2049 | ||
2050 | <varlistentry> | |
2051 | <term><varname>Use6RD=</varname></term> | |
2052 | <listitem> | |
2053 | <para>When true, subnets of the received IPv6 prefix are assigned to downstream interfaces | |
2054 | which enables <varname>DHCPPrefixDelegation=</varname>. See also | |
2055 | <varname>DHCPPrefixDelegation=</varname> in the [Network] section, the [DHCPPrefixDelegation] | |
2056 | section, and <ulink url="https://tools.ietf.org/html/rfc5969">RFC 5969</ulink>. Defaults to | |
2057 | false.</para> | |
2058 | </listitem> | |
2059 | </varlistentry> | |
2060 | ||
2061 | <varlistentry> | |
2062 | <term><varname>FallbackLeaseLifetimeSec=</varname></term> | |
2063 | <listitem> | |
6eed65d4 | 2064 | <para>Allows one to set DHCPv4 lease lifetime when DHCPv4 server does not send the lease |
add469f5 YW |
2065 | lifetime. Takes one of <literal>forever</literal> or <literal>infinity</literal>. If |
2066 | specified, the acquired address never expires. Defaults to unset.</para> | |
2067 | </listitem> | |
2068 | </varlistentry> | |
2069 | ||
2070 | <!-- How to communicate with the server --> | |
2071 | ||
2072 | <varlistentry> | |
2073 | <term><varname>RequestBroadcast=</varname></term> | |
2074 | <listitem> | |
2075 | <para>Request the server to use broadcast messages before the IP address has been configured. | |
2076 | This is necessary for devices that cannot receive RAW packets, or that cannot receive packets | |
2077 | at all before an IP address has been configured. On the other hand, this must not be enabled | |
2078 | on networks where broadcasts are filtered out.</para> | |
2079 | </listitem> | |
2080 | </varlistentry> | |
2081 | ||
2082 | <varlistentry> | |
2083 | <term><varname>MaxAttempts=</varname></term> | |
2084 | <listitem> | |
2085 | <para>Specifies how many times the DHCPv4 client configuration should be attempted. Takes a | |
2086 | number or <literal>infinity</literal>. Defaults to <literal>infinity</literal>. Note that the | |
2087 | time between retries is increased exponentially, up to approximately one per minute, so the | |
2088 | network will not be overloaded even if this number is high. The default is suitable in most | |
2089 | circumstances.</para> | |
2090 | </listitem> | |
2091 | </varlistentry> | |
2092 | ||
2093 | <varlistentry> | |
2094 | <term><varname>ListenPort=</varname></term> | |
2095 | <listitem> | |
2096 | <para>Set the port from which the DHCP client packets originate.</para> | |
2097 | </listitem> | |
2098 | </varlistentry> | |
2099 | ||
2100 | <varlistentry> | |
2101 | <term><varname>DenyList=</varname></term> | |
2102 | <listitem> | |
2103 | <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a | |
2104 | prefix length after <literal>/</literal>. DHCP offers from servers in the list are rejected. | |
2105 | Note that if <varname>AllowList=</varname> is configured then <varname>DenyList=</varname> is | |
2106 | ignored.</para> | |
2107 | </listitem> | |
2108 | </varlistentry> | |
2109 | ||
2110 | <varlistentry> | |
2111 | <term><varname>AllowList=</varname></term> | |
2112 | <listitem> | |
2113 | <para>A whitespace-separated list of IPv4 addresses. Each address can optionally take a | |
2114 | prefix length after <literal>/</literal>. DHCP offers from servers in the list are accepted. | |
2115 | </para> | |
2116 | </listitem> | |
2117 | </varlistentry> | |
2118 | ||
2119 | <varlistentry> | |
2120 | <term><varname>SendRelease=</varname></term> | |
2121 | <listitem> | |
2122 | <para>When true, the DHCPv4 client sends a DHCP release packet when it stops. Defaults to | |
2123 | true.</para> | |
2124 | </listitem> | |
2125 | </varlistentry> | |
2126 | ||
2127 | <varlistentry> | |
2128 | <term><varname>SendDecline=</varname></term> | |
2129 | <listitem> | |
2130 | <para>A boolean. When true, <command>systemd-networkd</command> performs IPv4 Duplicate | |
2131 | Address Detection to the acquired address by the DHCPv4 client. If duplicate is detected, | |
2132 | the DHCPv4 client rejects the address by sending a <constant>DHCPDECLINE</constant> packet to | |
2133 | the DHCP server, and tries to obtain an IP address again. See | |
2134 | <ulink url="https://tools.ietf.org/html/rfc5227">RFC 5227</ulink>. Defaults to false.</para> | |
2135 | </listitem> | |
2136 | </varlistentry> | |
4b3590c3 TM |
2137 | |
2138 | <varlistentry> | |
2139 | <term><varname>NetLabel=</varname></term> | |
2140 | <listitem> | |
2141 | <para>This applies the NetLabel for the addresses received with DHCP, like | |
2142 | <varname>NetLabel=</varname> in [Address] section applies it to statically configured | |
2143 | addresses. See <varname>NetLabel=</varname> in [Address] section for more details.</para> | |
2144 | </listitem> | |
2145 | </varlistentry> | |
add469f5 YW |
2146 | </variablelist> |
2147 | </refsect1> | |
2148 | ||
2149 | <refsect1> | |
2150 | <title>[DHCPv6] Section Options</title> | |
2151 | ||
2152 | <para>The [DHCPv6] section configures the DHCPv6 client, if it is enabled with the | |
2153 | <varname>DHCP=</varname> setting described above, or invoked by the IPv6 Router Advertisement: | |
2154 | </para> | |
2155 | ||
2156 | <variablelist class='network-directives'> | |
2157 | ||
2158 | <!-- DHCP packet contents --> | |
2159 | ||
2160 | <varlistentry> | |
2161 | <term><varname>MUDURL=</varname></term> | |
2162 | <term><varname>IAID=</varname></term> | |
2163 | <term><varname>DUIDType=</varname></term> | |
2164 | <term><varname>DUIDRawData=</varname></term> | |
2165 | <term><varname>RequestOptions=</varname></term> | |
2166 | <listitem> | |
2167 | <para>As in the [DHCPv4] section.</para> | |
2168 | </listitem> | |
2169 | </varlistentry> | |
2170 | ||
2171 | <varlistentry> | |
2172 | <term><varname>SendOption=</varname></term> | |
2173 | <listitem> | |
2174 | <para>As in the [DHCPv4] section, however because DHCPv6 uses 16-bit fields to store option | |
2175 | numbers, the option number is an integer in the range 1…65536.</para> | |
2176 | </listitem> | |
2177 | </varlistentry> | |
2178 | ||
2179 | <varlistentry> | |
2180 | <term><varname>SendVendorOption=</varname></term> | |
2181 | <listitem> | |
2182 | <para>Send an arbitrary vendor option in the DHCPv6 request. Takes an enterprise identifier, | |
2183 | DHCP option number, data type, and data separated with a colon | |
2184 | (<literal><replaceable>enterprise identifier</replaceable>:<replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). | |
2185 | Enterprise identifier is an unsigned integer in the range 1…4294967294. The option number | |
2186 | must be an integer in the range 1…254. Data type takes one of <literal>uint8</literal>, | |
2187 | <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, | |
2188 | <literal>ipv6address</literal>, or <literal>string</literal>. Special characters in the data | |
2189 | string may be escaped using | |
2190 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
2191 | escapes</ulink>. This setting can be specified multiple times. If an empty string is | |
2192 | specified, then all options specified earlier are cleared. Defaults to unset.</para> | |
2193 | </listitem> | |
2194 | </varlistentry> | |
2195 | ||
2196 | <varlistentry> | |
2197 | <term><varname>UserClass=</varname></term> | |
2198 | <listitem> | |
2199 | <para>A DHCPv6 client can use User Class option to identify the type or category of user or | |
2200 | applications it represents. The information contained in this option is a string that | |
2201 | represents the user class of which the client is a member. Each class sets an identifying | |
2202 | string of information to be used by the DHCP service to classify clients. Special characters | |
2203 | in the data string may be escaped using | |
2204 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
2205 | escapes</ulink>. This setting can be specified multiple times. If an empty string is | |
2206 | specified, then all options specified earlier are cleared. Takes a whitespace-separated list | |
2207 | of strings. Note that currently <constant>NUL</constant> bytes are not allowed.</para> | |
2208 | </listitem> | |
2209 | </varlistentry> | |
2210 | ||
2211 | <varlistentry> | |
2212 | <term><varname>VendorClass=</varname></term> | |
2213 | <listitem> | |
2214 | <para>A DHCPv6 client can use VendorClass option to identify the vendor that manufactured the | |
2215 | hardware on which the client is running. The information contained in the data area of this | |
2216 | option is contained in one or more opaque fields that identify details of the hardware | |
2217 | configuration. Takes a whitespace-separated list of strings.</para> | |
2218 | </listitem> | |
2219 | </varlistentry> | |
2220 | ||
2221 | <varlistentry> | |
2222 | <term><varname>PrefixDelegationHint=</varname></term> | |
2223 | <listitem> | |
2224 | <para>Takes an IPv6 address with prefix length in the same format as the | |
2225 | <varname>Address=</varname> in the [Network] section. The DHCPv6 client will include a prefix | |
2226 | hint in the DHCPv6 solicitation sent to the server. The prefix length must be in the range | |
2227 | 1…128. Defaults to unset.</para> | |
2228 | </listitem> | |
2229 | </varlistentry> | |
2230 | ||
50ee1fec YW |
2231 | <varlistentry> |
2232 | <term><varname>RapidCommit=</varname></term> | |
2233 | <listitem> | |
2234 | <para>Takes a boolean. The DHCPv6 client can obtain configuration parameters from a DHCPv6 server | |
2235 | through a rapid two-message exchange (solicit and reply). When the rapid commit option is set by | |
2236 | both the DHCPv6 client and the DHCPv6 server, the two-message exchange is used. Otherwise, the | |
2237 | four-message exchange (solicit, advertise, request, and reply) is used. The two-message exchange | |
2238 | provides faster client configuration. See | |
2239 | <ulink url="https://tools.ietf.org/html/rfc3315#section-17.2.1">RFC 3315</ulink> for details. | |
2240 | Defaults to true, and the two-message exchange will be used if the server support it.</para> | |
2241 | </listitem> | |
2242 | </varlistentry> | |
2243 | ||
add469f5 YW |
2244 | <!-- How to use the DHCP lease --> |
2245 | ||
2246 | <varlistentry> | |
2247 | <term><varname>UseAddress=</varname></term> | |
2248 | <listitem> | |
2249 | <para>When true (the default), the IP addresses provided by the DHCPv6 server will be | |
2250 | assigned.</para> | |
2251 | </listitem> | |
2252 | </varlistentry> | |
2253 | ||
2254 | <varlistentry> | |
2255 | <term><varname>UseDelegatedPrefix=</varname></term> | |
2256 | <listitem> | |
2257 | <para>When true (the default), the client will request the DHCPv6 server to delegate | |
2258 | prefixes. If the server provides prefixes to be delegated, then subnets of the prefixes are | |
625d71b9 | 2259 | assigned to the interfaces that have <varname>DHCPPrefixDelegation=yes</varname>. |
add469f5 YW |
2260 | See also the <varname>DHCPPrefixDelegation=</varname> setting in the [Network] section, |
2261 | settings in the [DHCPPrefixDelegation] section, and | |
2262 | <ulink url="https://www.rfc-editor.org/rfc/rfc8415.html#section-6.3">RFC 8415</ulink>. | |
2263 | </para> | |
2264 | </listitem> | |
2265 | </varlistentry> | |
2266 | ||
2267 | <varlistentry> | |
2268 | <term><varname>UseDNS=</varname></term> | |
2269 | <term><varname>UseNTP=</varname></term> | |
2270 | <term><varname>UseHostname=</varname></term> | |
2271 | <term><varname>UseDomains=</varname></term> | |
4b3590c3 | 2272 | <term><varname>NetLabel=</varname></term> |
add469f5 YW |
2273 | <listitem> |
2274 | <para>As in the [DHCPv4] section.</para> | |
2275 | </listitem> | |
2276 | </varlistentry> | |
2277 | ||
2278 | <!-- How to communicate with the server --> | |
2279 | ||
2280 | <varlistentry> | |
2281 | <term><varname>WithoutRA=</varname></term> | |
2282 | <listitem> | |
0bcc6557 AH |
2283 | <para>Allows DHCPv6 client to start without router advertisements's |
2284 | <literal>managed</literal> or <literal>other configuration</literal> flag. Takes one of | |
2285 | <literal>no</literal>, <literal>solicit</literal>, or | |
2286 | <literal>information-request</literal>. If this is not specified, | |
add469f5 YW |
2287 | <literal>solicit</literal> is used when <varname>DHCPPrefixDelegation=</varname> is enabled |
2288 | and <varname>UplinkInterface=:self</varname> is specified in the [DHCPPrefixDelegation] | |
2289 | section. Otherwise, defaults to <literal>no</literal>, and the DHCPv6 client will be started | |
2290 | when an RA is received. See also the <varname>DHCPv6Client=</varname> setting in the | |
2291 | [IPv6AcceptRA] section.</para> | |
2292 | </listitem> | |
2293 | </varlistentry> | |
2294 | </variablelist> | |
caa8ca42 | 2295 | </refsect1> |
99e015e2 YW |
2296 | |
2297 | <refsect1> | |
a27588d4 | 2298 | <title>[DHCPPrefixDelegation] Section Options</title> |
31fc1366 | 2299 | <para>The [DHCPPrefixDelegation] section configures subnet prefixes of the delegated prefixes |
8b9f0921 | 2300 | acquired by a DHCPv6 client or by a DHCPv4 client through the 6RD option on another interface. |
31fc1366 YW |
2301 | The settings in this section are used only when the <varname>DHCPPrefixDelegation=</varname> |
2302 | setting in the [Network] section is enabled.</para> | |
99e015e2 YW |
2303 | |
2304 | <variablelist class='network-directives'> | |
dc5cae6c YW |
2305 | <varlistentry> |
2306 | <term><varname>UplinkInterface=</varname></term> | |
2307 | <listitem> | |
2308 | <para>Specifies the name or the index of the uplink interface, or one of the special values | |
2309 | <literal>:self</literal> and <literal>:auto</literal>. When <literal>:self</literal>, the | |
149cda85 YW |
2310 | interface itself is considered the uplink interface, and |
2311 | <varname>WithoutRA=solicit</varname> is implied if the setting is not explicitly specified. | |
2312 | When <literal>:auto</literal>, the first link which acquired prefixes to be delegated from | |
31fc1366 | 2313 | the DHCPv6 or DHCPv4 server is selected. Defaults to <literal>:auto</literal>.</para> |
dc5cae6c YW |
2314 | </listitem> |
2315 | </varlistentry> | |
2316 | ||
99e015e2 YW |
2317 | <varlistentry> |
2318 | <term><varname>SubnetId=</varname></term> | |
2319 | <listitem> | |
2320 | <para>Configure a specific subnet ID on the interface from a (previously) received prefix | |
2321 | delegation. You can either set "auto" (the default) or a specific subnet ID (as defined in | |
2322 | <ulink url="https://tools.ietf.org/html/rfc4291#section-2.5.4">RFC 4291</ulink>, section | |
2323 | 2.5.4), in which case the allowed value is hexadecimal, from 0 to 0x7fffffffffffffff | |
e5ff2245 YW |
2324 | inclusive.</para> |
2325 | </listitem> | |
2326 | </varlistentry> | |
2327 | ||
2328 | <varlistentry> | |
2329 | <term><varname>Announce=</varname></term> | |
2330 | <listitem> | |
2331 | <para>Takes a boolean. When enabled, and <varname>IPv6SendRA=</varname> in [Network] section | |
2332 | is enabled, the delegated prefixes are distributed through the IPv6 Router Advertisement. | |
31fc1366 YW |
2333 | This setting will be ignored when the <varname>DHCPPrefixDelegation=</varname> setting is |
2334 | enabled on the upstream interface. Defaults to yes.</para> | |
99e015e2 YW |
2335 | </listitem> |
2336 | </varlistentry> | |
2337 | ||
2338 | <varlistentry> | |
2339 | <term><varname>Assign=</varname></term> | |
2340 | <listitem> | |
2341 | <para>Takes a boolean. Specifies whether to add an address from the delegated prefixes which | |
e5ff2245 | 2342 | are received from the WAN interface by the DHCPv6 Prefix Delegation. When true (on LAN |
6c2d70ce | 2343 | interface), the EUI-64 algorithm will be used by default to form an interface identifier from |
e5ff2245 YW |
2344 | the delegated prefixes. See also <varname>Token=</varname> setting below. Defaults to yes. |
2345 | </para> | |
99e015e2 YW |
2346 | </listitem> |
2347 | </varlistentry> | |
2348 | ||
2349 | <varlistentry> | |
2350 | <term><varname>Token=</varname></term> | |
2351 | <listitem> | |
e5ff2245 | 2352 | <para>Specifies an optional address generation mode for assigning an address in each |
f5960e0a YW |
2353 | delegated prefix. This accepts the same syntax as <varname>Token=</varname> in the |
2354 | [IPv6AcceptRA] section. If <varname>Assign=</varname> is set to false, then this setting will | |
2355 | be ignored. Defaults to unset, which means the EUI-64 algorithm will be used.</para> | |
99e015e2 YW |
2356 | </listitem> |
2357 | </varlistentry> | |
fec1b650 YW |
2358 | |
2359 | <varlistentry> | |
2360 | <term><varname>ManageTemporaryAddress=</varname></term> | |
2361 | <listitem> | |
2362 | <para>As in the [Address] section, but defaults to true.</para> | |
2363 | </listitem> | |
2364 | </varlistentry> | |
9fe0b7b4 YW |
2365 | |
2366 | <varlistentry> | |
2367 | <term><varname>RouteMetric=</varname></term> | |
2368 | <listitem> | |
2369 | <para>The metric of the route to the delegated prefix subnet. Takes an unsigned integer in | |
d0619f2c YW |
2370 | the range 0…4294967295. When set to 0, the kernel's default value is used. Defaults to 256. |
2371 | </para> | |
9fe0b7b4 YW |
2372 | </listitem> |
2373 | </varlistentry> | |
4b3590c3 TM |
2374 | |
2375 | <varlistentry> | |
2376 | <term><varname>NetLabel=</varname></term> | |
2377 | <listitem> | |
2378 | <para>This applies the NetLabel for the addresses received with DHCP, like | |
2379 | <varname>NetLabel=</varname> in [Address] section applies it to statically configured | |
2380 | addresses. See <varname>NetLabel=</varname> in [Address] section for more details.</para> | |
2381 | </listitem> | |
2382 | </varlistentry> | |
99e015e2 YW |
2383 | </variablelist> |
2384 | </refsect1> | |
413708d1 | 2385 | |
1e7a0e21 | 2386 | <refsect1> |
f921f573 | 2387 | <title>[IPv6AcceptRA] Section Options</title> |
c463ae74 YW |
2388 | <para>The [IPv6AcceptRA] section configures the IPv6 Router Advertisement (RA) client, if it is enabled |
2389 | with the <varname>IPv6AcceptRA=</varname> setting described above:</para> | |
1e7a0e21 | 2390 | |
c463ae74 YW |
2391 | <variablelist class='network-directives'> |
2392 | <varlistentry> | |
2393 | <term><varname>Token=</varname></term> | |
2394 | <listitem> | |
2395 | <para>Specifies an optional address generation mode for the Stateless Address | |
2396 | Autoconfiguration (SLAAC). The following values are supported:</para> | |
2397 | ||
2398 | <variablelist> | |
2399 | <varlistentry> | |
2400 | <term><option>eui64</option></term> | |
2401 | <listitem> | |
2402 | <para> | |
ab106a60 YW |
2403 | The EUI-64 algorithm will be used to generate an address for that prefix. Only |
2404 | supported by Ethernet or InfiniBand interfaces. | |
c463ae74 YW |
2405 | </para> |
2406 | </listitem> | |
2407 | </varlistentry> | |
2408 | <varlistentry> | |
2409 | <term><option>static:<replaceable>ADDRESS</replaceable></option></term> | |
2410 | <listitem> | |
2411 | <para> | |
2412 | An IPv6 address must be specified after a colon (<literal>:</literal>), and the | |
2413 | lower bits of the supplied address are combined with the upper bits of a prefix | |
2414 | received in a Router Advertisement (RA) message to form a complete address. Note | |
2415 | that if multiple prefixes are received in an RA message, or in multiple RA messages, | |
2416 | addresses will be formed from each of them using the supplied address. This mode | |
2417 | implements SLAAC but uses a static interface identifier instead of an identifier | |
2418 | generated by using the EUI-64 algorithm. Because the interface identifier is static, | |
2419 | if Duplicate Address Detection detects that the computed address is a duplicate | |
2420 | (in use by another node on the link), then this mode will fail to provide an address | |
2421 | for that prefix. If an IPv6 address without mode is specified, then | |
2422 | <literal>static</literal> mode is assumed. | |
2423 | </para> | |
2424 | </listitem> | |
2425 | </varlistentry> | |
2426 | <varlistentry> | |
f2a3a133 | 2427 | <term><option>prefixstable[:<replaceable>ADDRESS</replaceable>][,<replaceable>UUID</replaceable>]</option></term> |
c463ae74 YW |
2428 | <listitem> |
2429 | <para> | |
2430 | The algorithm specified in | |
2431 | <ulink url="https://tools.ietf.org/html/rfc7217">RFC 7217</ulink> will be used to | |
2432 | generate interface identifiers. This mode can optionally take an IPv6 address | |
2433 | separated with a colon (<literal>:</literal>). If an IPv6 address is specified, | |
2434 | then an interface identifier is generated only when a prefix received in an RA | |
2435 | message matches the supplied address. | |
2436 | </para> | |
f2a3a133 YW |
2437 | <para> |
2438 | This mode can also optionally take a non-null UUID in the format which | |
2439 | <function>sd_id128_from_string()</function> accepts, e.g. | |
2440 | <literal>86b123b969ba4b7eb8b3d8605123525a</literal> or | |
2441 | <literal>86b123b9-69ba-4b7e-b8b3-d8605123525a</literal>. If a UUID is specified, the | |
2442 | value is used as the secret key to generate interface identifiers. If not specified, | |
2443 | then an application specific ID generated with the system's machine-ID will be used | |
2444 | as the secret key. See | |
2445 | <citerefentry><refentrytitle>sd-id128</refentrytitle><manvolnum>3</manvolnum></citerefentry>, | |
2446 | <citerefentry><refentrytitle>sd_id128_from_string</refentrytitle><manvolnum>3</manvolnum></citerefentry>, | |
2447 | and | |
fe003f02 | 2448 | <citerefentry><refentrytitle>sd_id128_get_machine</refentrytitle><manvolnum>3</manvolnum></citerefentry>. |
f2a3a133 | 2449 | </para> |
c463ae74 YW |
2450 | <para> |
2451 | Note that the <literal>prefixstable</literal> algorithm uses both the interface | |
2452 | name and MAC address as input to the hash to compute the interface identifier, so | |
2453 | if either of those are changed the resulting interface identifier (and address) | |
2454 | will be changed, even if the prefix received in the RA message has not been | |
2455 | changed. | |
2456 | </para> | |
2457 | </listitem> | |
2458 | </varlistentry> | |
2459 | </variablelist> | |
2460 | ||
2461 | <para>If no address generation mode is specified (which is the default), or a received | |
2462 | prefix does not match any of the addresses provided in <literal>prefixstable</literal> | |
ab106a60 YW |
2463 | mode, then the EUI-64 algorithm will be used for Ethernet or InfiniBand interfaces, |
2464 | otherwise <literal>prefixstable</literal> will be used to form an interface identifier for | |
2465 | that prefix.</para> | |
c463ae74 YW |
2466 | |
2467 | <para>This setting can be specified multiple times. If an empty string is assigned, then | |
2468 | the all previous assignments are cleared.</para> | |
2469 | ||
2470 | <para>Examples: | |
2471 | <programlisting>Token=eui64 | |
140bf8da | 2472 | Token=::1a:2b:3c:4d |
a73628e6 YW |
2473 | Token=static:::1a:2b:3c:4d |
2474 | Token=prefixstable | |
2475 | Token=prefixstable:2002:da8:1::</programlisting></para> | |
c463ae74 YW |
2476 | </listitem> |
2477 | </varlistentry> | |
1e7a0e21 | 2478 | |
c463ae74 YW |
2479 | <varlistentry> |
2480 | <term><varname>UseDNS=</varname></term> | |
2481 | <listitem> | |
2482 | <para>When true (the default), the DNS servers received in the Router Advertisement will be used.</para> | |
1e7a0e21 | 2483 | |
c463ae74 YW |
2484 | <para>This corresponds to the <option>nameserver</option> option in <citerefentry |
2485 | project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> | |
2486 | </listitem> | |
2487 | </varlistentry> | |
1e7a0e21 | 2488 | |
c463ae74 YW |
2489 | <varlistentry> |
2490 | <term><varname>UseDomains=</varname></term> | |
2491 | <listitem> | |
2492 | <para>Takes a boolean, or the special value <literal>route</literal>. When true, the domain name | |
15102ced ZJS |
2493 | received via IPv6 Router Advertisement (RA) will be used as DNS search domain over this link, |
2494 | similarly to the effect of the <option>Domains=</option> setting. If set to | |
2495 | <literal>route</literal>, the domain name received via IPv6 RA will be used for routing DNS queries | |
2496 | only, but not for searching, similarly to the effect of the <option>Domains=</option> setting when | |
2497 | the argument is prefixed with <literal>~</literal>. Defaults to false.</para> | |
c463ae74 YW |
2498 | |
2499 | <para>It is recommended to enable this option only on trusted networks, as setting this affects resolution | |
2500 | of all hostnames, in particular of single-label names. It is generally safer to use the supplied domain | |
2501 | only as routing domain, rather than as search domain, in order to not have it affect local resolution of | |
2502 | single-label names.</para> | |
2503 | ||
2504 | <para>When set to true, this setting corresponds to the <option>domain</option> option in <citerefentry | |
2505 | project='man-pages'><refentrytitle>resolv.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> | |
2506 | </listitem> | |
2507 | </varlistentry> | |
2ba31d29 | 2508 | |
c463ae74 YW |
2509 | <varlistentry> |
2510 | <term><varname>RouteTable=<replaceable>num</replaceable></varname></term> | |
2511 | <listitem> | |
7db98bc9 YW |
2512 | <para>The table identifier for the routes received in the Router Advertisement. Takes one of |
2513 | predefined names <literal>default</literal>, <literal>main</literal>, and <literal>local</literal>, | |
2514 | and names defined in <varname>RouteTable=</varname> in | |
2515 | <citerefentry><refentrytitle>networkd.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>, | |
2516 | or a number between 1…4294967295.</para> | |
2517 | ||
2518 | <para>When used in combination with <varname>VRF=</varname>, the VRF's routing table is | |
2519 | used when this parameter is not specified.</para> | |
c463ae74 YW |
2520 | </listitem> |
2521 | </varlistentry> | |
062c2eea | 2522 | |
c463ae74 YW |
2523 | <varlistentry> |
2524 | <term><varname>RouteMetric=</varname></term> | |
2525 | <listitem> | |
6f812d28 YW |
2526 | <para>Set the routing metric for the routes received in the Router Advertisement. Takes an unsigned |
2527 | integer in the range 0…4294967295, or three unsigned integer separated with <literal>:</literal>, | |
2528 | in that case the first one is used when the router preference is high, the second is for medium | |
2529 | preference, and the last is for low preference | |
2530 | (<literal><replaceable>high</replaceable>:<replaceable>medium</replaceable>:<replaceable>low</replaceable></literal>). | |
2531 | Defaults to <literal>512:1024:2048</literal>.</para> | |
c463ae74 YW |
2532 | </listitem> |
2533 | </varlistentry> | |
8ebafba9 | 2534 | |
c463ae74 YW |
2535 | <varlistentry> |
2536 | <term><varname>UseMTU=</varname></term> | |
2537 | <listitem> | |
2538 | <para>Takes a boolean. When true, the MTU received in the Router Advertisement will be | |
2539 | used. Defaults to true.</para> | |
2540 | </listitem> | |
2541 | </varlistentry> | |
7d93b92f | 2542 | |
c463ae74 YW |
2543 | <varlistentry> |
2544 | <term><varname>UseGateway=</varname></term> | |
2545 | <listitem> | |
2546 | <para>When true (the default), the router address will be configured as the default gateway. | |
2547 | </para> | |
2548 | </listitem> | |
2549 | </varlistentry> | |
610c0db1 | 2550 | |
c463ae74 YW |
2551 | <varlistentry> |
2552 | <term><varname>UseRoutePrefix=</varname></term> | |
2553 | <listitem> | |
2554 | <para>When true (the default), the routes corresponding to the route prefixes received in | |
2555 | the Router Advertisement will be configured.</para> | |
2556 | </listitem> | |
2557 | </varlistentry> | |
610c0db1 | 2558 | |
c463ae74 YW |
2559 | <varlistentry> |
2560 | <term><varname>UseAutonomousPrefix=</varname></term> | |
2561 | <listitem> | |
2562 | <para>When true (the default), the autonomous prefix received in the Router Advertisement will be used and take | |
2563 | precedence over any statically configured ones.</para> | |
2564 | </listitem> | |
2565 | </varlistentry> | |
062c2eea | 2566 | |
c463ae74 YW |
2567 | <varlistentry> |
2568 | <term><varname>UseOnLinkPrefix=</varname></term> | |
2569 | <listitem> | |
2570 | <para>When true (the default), the onlink prefix received in the Router Advertisement will be | |
2571 | used and takes precedence over any statically configured ones.</para> | |
2572 | </listitem> | |
2573 | </varlistentry> | |
062c2eea | 2574 | |
c463ae74 YW |
2575 | <varlistentry> |
2576 | <term><varname>RouterDenyList=</varname></term> | |
2577 | <listitem> | |
2578 | <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally | |
2579 | take a prefix length after <literal>/</literal>. Any information advertised by the listed | |
2580 | router is ignored.</para> | |
2581 | </listitem> | |
2582 | </varlistentry> | |
75d26411 | 2583 | |
c463ae74 YW |
2584 | <varlistentry> |
2585 | <term><varname>RouterAllowList=</varname></term> | |
2586 | <listitem> | |
2587 | <para>A whitespace-separated list of IPv6 router addresses. Each address can optionally | |
2588 | take a prefix length after <literal>/</literal>. Only information advertised by the listed | |
2589 | router is accepted. Note that if <varname>RouterAllowList=</varname> is configured then | |
2590 | <varname>RouterDenyList=</varname> is ignored.</para> | |
2591 | </listitem> | |
2592 | </varlistentry> | |
75d26411 | 2593 | |
c463ae74 YW |
2594 | <varlistentry> |
2595 | <term><varname>PrefixDenyList=</varname></term> | |
2596 | <listitem> | |
2597 | <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its | |
2598 | prefix length after <literal>/</literal>. IPv6 prefixes supplied via router advertisements | |
2599 | in the list are ignored.</para> | |
2600 | </listitem> | |
2601 | </varlistentry> | |
16c89e64 | 2602 | |
c463ae74 YW |
2603 | <varlistentry> |
2604 | <term><varname>PrefixAllowList=</varname></term> | |
2605 | <listitem> | |
2606 | <para>A whitespace-separated list of IPv6 prefixes. Each prefix can optionally take its | |
2607 | prefix length after <literal>/</literal>. IPv6 prefixes supplied via router advertisements | |
2608 | in the list are allowed. Note that if <varname>PrefixAllowList=</varname> is configured | |
2609 | then <varname>PrefixDenyList=</varname> is ignored.</para> | |
2610 | </listitem> | |
2611 | </varlistentry> | |
de6b6ff8 | 2612 | |
c463ae74 YW |
2613 | <varlistentry> |
2614 | <term><varname>RouteDenyList=</varname></term> | |
2615 | <listitem> | |
2616 | <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take | |
2617 | its prefix length after <literal>/</literal>. IPv6 route prefixes supplied via router | |
2618 | advertisements in the list are ignored.</para> | |
2619 | </listitem> | |
2620 | </varlistentry> | |
e520ce64 | 2621 | |
c463ae74 YW |
2622 | <varlistentry> |
2623 | <term><varname>RouteAllowList=</varname></term> | |
2624 | <listitem> | |
2625 | <para>A whitespace-separated list of IPv6 route prefixes. Each prefix can optionally take | |
2626 | its prefix length after <literal>/</literal>. IPv6 route prefixes supplied via router | |
2627 | advertisements in the list are allowed. Note that if <varname>RouteAllowList=</varname> is | |
2628 | configured then <varname>RouteDenyList=</varname> is ignored.</para> | |
2629 | </listitem> | |
2630 | </varlistentry> | |
de6b6ff8 | 2631 | |
c463ae74 YW |
2632 | <varlistentry> |
2633 | <term><varname>DHCPv6Client=</varname></term> | |
2634 | <listitem> | |
2635 | <para>Takes a boolean, or the special value <literal>always</literal>. When true, the | |
0bcc6557 AH |
2636 | DHCPv6 client will be started in <literal>solicit</literal> mode if the RA has the |
2637 | <literal>managed</literal> flag or <literal>information-request</literal> mode if the RA | |
2638 | lacks the <literal>managed</literal> flag but has the | |
2639 | <literal>other configuration</literal> flag. If set to <literal>always</literal>, the | |
2640 | DHCPv6 client will be started in <literal>solicit</literal> mode when an RA is received, | |
2641 | even if neither the <literal>managed</literal> nor the | |
2642 | <literal>other configuration</literal> flag is set in the RA. This will be ignored when | |
2643 | <varname>WithoutRA=</varname> in the [DHCPv6] section is enabled, or | |
a27588d4 | 2644 | <varname>UplinkInterface=:self</varname> in the [DHCPPrefixDelegation] section is |
c463ae74 YW |
2645 | specified. Defaults to true.</para> |
2646 | </listitem> | |
2647 | </varlistentry> | |
4b3590c3 TM |
2648 | |
2649 | <varlistentry> | |
2650 | <term><varname>NetLabel=</varname></term> | |
2651 | <listitem> | |
2652 | <para>This applies the NetLabel for the addresses received with RA, like | |
2653 | <varname>NetLabel=</varname> in [Address] section applies it to statically configured | |
2654 | addresses. See <varname>NetLabel=</varname> in [Address] section for more details.</para> | |
2655 | </listitem> | |
2656 | </varlistentry> | |
c463ae74 | 2657 | </variablelist> |
1e7a0e21 LP |
2658 | </refsect1> |
2659 | ||
ad943783 LP |
2660 | <refsect1> |
2661 | <title>[DHCPServer] Section Options</title> | |
bdac5608 | 2662 | <para>The [DHCPServer] section contains settings for the DHCP server, if enabled via the |
ad943783 LP |
2663 | <varname>DHCPServer=</varname> option described above:</para> |
2664 | ||
2665 | <variablelist class='network-directives'> | |
2666 | ||
0017ba31 YW |
2667 | <varlistentry> |
2668 | <term><varname>ServerAddress=</varname></term> | |
2669 | <listitem><para>Specifies server address for the DHCP server. Takes an IPv4 address with prefix | |
1df62018 | 2670 | length, for example 192.168.0.1/24. This setting may be useful when the link on |
be0d27ee ZJS |
2671 | which the DHCP server is running has multiple static addresses. When unset, one of static addresses |
2672 | in the link will be automatically selected. Defaults to unset.</para></listitem> | |
0017ba31 YW |
2673 | </varlistentry> |
2674 | ||
9b3a67c5 TG |
2675 | <varlistentry> |
2676 | <term><varname>PoolOffset=</varname></term> | |
2677 | <term><varname>PoolSize=</varname></term> | |
2678 | ||
2679 | <listitem><para>Configures the pool of addresses to hand out. The pool | |
2680 | is a contiguous sequence of IP addresses in the subnet configured for | |
2681 | the server address, which does not include the subnet nor the broadcast | |
2682 | address. <varname>PoolOffset=</varname> takes the offset of the pool | |
2683 | from the start of subnet, or zero to use the default value. | |
2684 | <varname>PoolSize=</varname> takes the number of IP addresses in the | |
b938cb90 | 2685 | pool or zero to use the default value. By default, the pool starts at |
9b3a67c5 TG |
2686 | the first address after the subnet address and takes up the rest of |
2687 | the subnet, excluding the broadcast address. If the pool includes | |
2688 | the server address (the default), this is reserved and not handed | |
2689 | out to clients.</para></listitem> | |
2690 | </varlistentry> | |
2691 | ||
ad943783 LP |
2692 | <varlistentry> |
2693 | <term><varname>DefaultLeaseTimeSec=</varname></term> | |
2694 | <term><varname>MaxLeaseTimeSec=</varname></term> | |
2695 | ||
2696 | <listitem><para>Control the default and maximum DHCP lease | |
2697 | time to pass to clients. These settings take time values in seconds or | |
2698 | another common time unit, depending on the suffix. The default | |
2699 | lease time is used for clients that did not ask for a specific | |
2700 | lease time. If a client asks for a lease time longer than the | |
b938cb90 | 2701 | maximum lease time, it is automatically shortened to the |
ad943783 LP |
2702 | specified time. The default lease time defaults to 1h, the |
2703 | maximum lease time to 12h. Shorter lease times are beneficial | |
2704 | if the configuration data in DHCP leases changes frequently | |
2705 | and clients shall learn the new settings with shorter | |
2706 | latencies. Longer lease times reduce the generated DHCP | |
2707 | network traffic.</para></listitem> | |
2708 | </varlistentry> | |
2709 | ||
165d7c5c YW |
2710 | <varlistentry> |
2711 | <term><varname>UplinkInterface=</varname></term> | |
2b242926 YW |
2712 | <listitem><para>Specifies the name or the index of the uplink interface, or one of the special |
2713 | values <literal>:none</literal> and <literal>:auto</literal>. When emitting DNS, NTP, or SIP | |
2714 | servers is enabled but no servers are specified, the servers configured in the uplink interface | |
2715 | will be emitted. When <literal>:auto</literal>, the link which has a default gateway with the | |
2716 | highest priority will be automatically selected. When <literal>:none</literal>, no uplink | |
2717 | interface will be selected. Defaults to <literal>:auto</literal>.</para></listitem> | |
165d7c5c YW |
2718 | </varlistentry> |
2719 | ||
ad943783 LP |
2720 | <varlistentry> |
2721 | <term><varname>EmitDNS=</varname></term> | |
2722 | <term><varname>DNS=</varname></term> | |
2723 | ||
2a71d57f | 2724 | <listitem><para><varname>EmitDNS=</varname> takes a boolean. Configures whether the DHCP leases |
5f468b9f YW |
2725 | handed out to clients shall contain DNS server information. Defaults to <literal>yes</literal>. |
2726 | The DNS servers to pass to clients may be configured with the <varname>DNS=</varname> option, | |
2727 | which takes a list of IPv4 addresses, or special value <literal>_server_address</literal> which | |
faa1b3c6 YW |
2728 | will be converted to the address used by the DHCP server.</para> |
2729 | ||
2730 | <para>If the <varname>EmitDNS=</varname> option is enabled but no servers configured, the | |
2731 | servers are automatically propagated from an "uplink" interface that has appropriate servers | |
2732 | set. The "uplink" interface is determined by the default route of the system with the highest | |
2733 | priority. Note that this information is acquired at the time the lease is handed out, and does | |
2734 | not take uplink interfaces into account that acquire DNS server information at a later point. | |
2735 | If no suitable uplink interface is found the DNS server data from | |
2736 | <filename>/etc/resolv.conf</filename> is used. Also, note that the leases are not refreshed if | |
2737 | the uplink network configuration changes. To ensure clients regularly acquire the most current | |
2738 | uplink DNS server information, it is thus advisable to shorten the DHCP lease time via | |
2739 | <varname>MaxLeaseTimeSec=</varname> described above.</para> | |
2740 | ||
2741 | <para>This setting can be specified multiple times. If an empty string is specified, then all | |
2742 | DNS servers specified earlier are cleared.</para></listitem> | |
ad943783 LP |
2743 | </varlistentry> |
2744 | ||
2745 | <varlistentry> | |
2746 | <term><varname>EmitNTP=</varname></term> | |
2747 | <term><varname>NTP=</varname></term> | |
299d578f SS |
2748 | <term><varname>EmitSIP=</varname></term> |
2749 | <term><varname>SIP=</varname></term> | |
2a71d57f LP |
2750 | <term><varname>EmitPOP3=</varname></term> |
2751 | <term><varname>POP3=</varname></term> | |
2752 | <term><varname>EmitSMTP=</varname></term> | |
2753 | <term><varname>SMTP=</varname></term> | |
2754 | <term><varname>EmitLPR=</varname></term> | |
2755 | <term><varname>LPR=</varname></term> | |
2756 | ||
2757 | <listitem><para>Similar to the <varname>EmitDNS=</varname> and <varname>DNS=</varname> settings | |
2758 | described above, these settings configure whether and what server information for the indicate | |
2759 | protocol shall be emitted as part of the DHCP lease. The same syntax, propagation semantics and | |
2760 | defaults apply as for <varname>EmitDNS=</varname> and <varname>DNS=</varname>.</para></listitem> | |
284e8fd0 SS |
2761 | </varlistentry> |
2762 | ||
77ff6022 CG |
2763 | <varlistentry> |
2764 | <term><varname>EmitRouter=</varname></term> | |
59aa6220 YW |
2765 | <term><varname>Router=</varname></term> |
2766 | ||
2767 | <listitem><para>The <varname>EmitRouter=</varname> setting takes a boolean value, and configures | |
2768 | whether the DHCP lease should contain the router option. The <varname>Router=</varname> setting | |
2769 | takes an IPv4 address, and configures the router address to be emitted. When the | |
2770 | <varname>Router=</varname> setting is not specified, then the server address will be used for | |
2771 | the router option. When the <varname>EmitRouter=</varname> setting is disabled, the | |
2772 | <varname>Router=</varname> setting will be ignored. The <varname>EmitRouter=</varname> setting | |
2773 | defaults to true, and the <varname>Router=</varname> setting defaults to unset. | |
2774 | </para></listitem> | |
77ff6022 CG |
2775 | </varlistentry> |
2776 | ||
ad943783 LP |
2777 | <varlistentry> |
2778 | <term><varname>EmitTimezone=</varname></term> | |
2779 | <term><varname>Timezone=</varname></term> | |
2780 | ||
9b6ffef3 YW |
2781 | <listitem><para>Takes a boolean. Configures whether the DHCP leases handed out |
2782 | to clients shall contain timezone information. Defaults to <literal>yes</literal>. The | |
ad943783 LP |
2783 | <varname>Timezone=</varname> setting takes a timezone string |
2784 | (such as <literal>Europe/Berlin</literal> or | |
2785 | <literal>UTC</literal>) to pass to clients. If no explicit | |
b938cb90 | 2786 | timezone is set, the system timezone of the local host is |
ad943783 LP |
2787 | propagated, as determined by the |
2788 | <filename>/etc/localtime</filename> symlink.</para></listitem> | |
2789 | </varlistentry> | |
2790 | ||
369ac192 | 2791 | <varlistentry> |
6278e428 | 2792 | <term><varname>BootServerAddress=</varname></term> |
369ac192 YW |
2793 | |
2794 | <listitem> | |
94f7ee97 ZJS |
2795 | <para>Takes an IPv4 address of the boot server used by e.g. PXE boot systems. When specified, this |
2796 | address is sent in the <option>siaddr</option> field of the DHCP message header. See <ulink | |
2797 | url="https://www.rfc-editor.org/rfc/rfc2131.html">RFC 2131</ulink> for more details. Defaults to | |
2798 | unset.</para> | |
369ac192 YW |
2799 | </listitem> |
2800 | </varlistentry> | |
2801 | ||
2802 | <varlistentry> | |
6278e428 | 2803 | <term><varname>BootServerName=</varname></term> |
369ac192 YW |
2804 | |
2805 | <listitem> | |
94f7ee97 ZJS |
2806 | <para>Takes a name of the boot server used by e.g. PXE boot systems. When specified, this name is |
2807 | sent in the DHCP option 66 ("TFTP server name"). See <ulink | |
2808 | url="https://www.rfc-editor.org/rfc/rfc2132.html">RFC 2132</ulink> for more details. Defaults to | |
2809 | unset.</para> | |
2810 | ||
2811 | <para>Note that typically setting one of <varname>BootServerName=</varname> or | |
2812 | <varname>BootServerAddress=</varname> is sufficient, but both can be set too, if desired.</para> | |
6278e428 YW |
2813 | </listitem> |
2814 | </varlistentry> | |
2815 | ||
2816 | <varlistentry> | |
2817 | <term><varname>BootFilename=</varname></term> | |
2818 | ||
2819 | <listitem> | |
94f7ee97 ZJS |
2820 | <para>Takes a path or URL to a file loaded by e.g. a PXE boot loader. When specified, this path is |
2821 | sent in the DHCP option 67 ("Bootfile name"). See <ulink | |
2822 | url="https://www.rfc-editor.org/rfc/rfc2132.html">RFC 2132</ulink> for more details. Defaults to | |
2823 | unset.</para> | |
369ac192 YW |
2824 | </listitem> |
2825 | </varlistentry> | |
2826 | ||
564ca984 | 2827 | <varlistentry> |
d8b736bd YW |
2828 | <term><varname>SendOption=</varname></term> |
2829 | <listitem> | |
2830 | <para>Send a raw option with value via DHCPv4 server. Takes a DHCP option number, data type | |
2831 | and data (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). | |
1d3a473b | 2832 | The option number is an integer in the range 1…254. The type takes one of <literal>uint8</literal>, |
e7d5fe17 | 2833 | <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, <literal>ipv6address</literal>, or |
7354900d DW |
2834 | <literal>string</literal>. Special characters in the data string may be escaped using |
2835 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
2836 | escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, | |
2837 | then all options specified earlier are cleared. Defaults to unset.</para> | |
2838 | </listitem> | |
2839 | </varlistentry> | |
2840 | ||
2841 | <varlistentry> | |
2842 | <term><varname>SendVendorOption=</varname></term> | |
2843 | <listitem> | |
2844 | <para>Send a vendor option with value via DHCPv4 server. Takes a DHCP option number, data type | |
2845 | and data (<literal><replaceable>option</replaceable>:<replaceable>type</replaceable>:<replaceable>value</replaceable></literal>). | |
1d3a473b | 2846 | The option number is an integer in the range 1…254. The type takes one of <literal>uint8</literal>, |
d8b736bd YW |
2847 | <literal>uint16</literal>, <literal>uint32</literal>, <literal>ipv4address</literal>, or |
2848 | <literal>string</literal>. Special characters in the data string may be escaped using | |
2849 | <ulink url="https://en.wikipedia.org/wiki/Escape_sequences_in_C#Table_of_escape_sequences">C-style | |
2850 | escapes</ulink>. This setting can be specified multiple times. If an empty string is specified, | |
2851 | then all options specified earlier are cleared. Defaults to unset.</para> | |
2852 | </listitem> | |
564ca984 | 2853 | </varlistentry> |
21b6b87e YA |
2854 | <varlistentry> |
2855 | <term><varname>BindToInterface=</varname></term> | |
11c38d3e YA |
2856 | <listitem> |
2857 | <para>Takes a boolean value. When <literal>yes</literal>, DHCP server socket will be bound | |
2858 | to its network interface and all socket communication will be restricted to this interface. | |
2859 | Defaults to <literal>yes</literal>, except if <varname>RelayTarget=</varname> is used (see below), | |
84b10e53 | 2860 | in which case it defaults to <literal>no</literal>.</para> |
11c38d3e YA |
2861 | </listitem> |
2862 | </varlistentry> | |
2863 | <varlistentry> | |
2864 | <term><varname>RelayTarget=</varname></term> | |
2865 | <listitem> | |
2866 | <para>Takes an IPv4 address, which must be in the format described in | |
2867 | <citerefentry project='man-pages'><refentrytitle>inet_pton</refentrytitle><manvolnum>3</manvolnum></citerefentry>. | |
2868 | Turns this DHCP server into a DHCP relay agent. See <ulink url="https://tools.ietf.org/html/rfc1542">RFC 1542</ulink>. | |
2869 | The address is the address of DHCP server or another relay agent to forward DHCP messages to and from.</para> | |
2870 | </listitem> | |
2871 | </varlistentry> | |
2872 | <varlistentry> | |
2873 | <term><varname>RelayAgentCircuitId=</varname></term> | |
2874 | <listitem> | |
2875 | <para>Specifies value for Agent Circuit ID suboption of Relay Agent Information option. | |
2876 | Takes a string, which must be in the format <literal>string:<replaceable>value</replaceable></literal>, | |
2877 | where <literal><replaceable>value</replaceable></literal> should be replaced with the value of the suboption. | |
2878 | Defaults to unset (means no Agent Circuit ID suboption is generated). | |
2879 | Ignored if <varname>RelayTarget=</varname> is not specified.</para> | |
2880 | </listitem> | |
2881 | </varlistentry> | |
2882 | <varlistentry> | |
2883 | <term><varname>RelayAgentRemoteId=</varname></term> | |
2884 | <listitem> | |
2885 | <para>Specifies value for Agent Remote ID suboption of Relay Agent Information option. | |
2886 | Takes a string, which must be in the format <literal>string:<replaceable>value</replaceable></literal>, | |
2887 | where <literal><replaceable>value</replaceable></literal> should be replaced with the value of the suboption. | |
2888 | Defaults to unset (means no Agent Remote ID suboption is generated). | |
2889 | Ignored if <varname>RelayTarget=</varname> is not specified.</para> | |
21b6b87e YA |
2890 | </listitem> |
2891 | </varlistentry> | |
564ca984 | 2892 | |
ad943783 LP |
2893 | </variablelist> |
2894 | </refsect1> | |
2895 | ||
c517a49b | 2896 | <refsect1> |
2897 | <title>[DHCPServerStaticLease] Section Options</title> | |
be0d27ee ZJS |
2898 | <para>The <literal>[DHCPServerStaticLease]</literal> section configures a static DHCP lease to assign a |
2899 | fixed IPv4 address to a specific device based on its MAC address. This section can be specified multiple | |
2900 | times.</para> | |
c517a49b | 2901 | |
2902 | <variablelist class='network-directives'> | |
2903 | <varlistentry> | |
2904 | <term><varname>MACAddress=</varname></term> | |
2905 | ||
be0d27ee | 2906 | <listitem><para>The hardware address of a device to match. This key is mandatory.</para></listitem> |
c517a49b | 2907 | </varlistentry> |
2908 | ||
2909 | <varlistentry> | |
2910 | <term><varname>Address=</varname></term> | |
2911 | ||
be0d27ee ZJS |
2912 | <listitem><para>The IPv4 address that should be assigned to the device that was matched with |
2913 | <varname>MACAddress=</varname>. This key is mandatory.</para></listitem> | |
c517a49b | 2914 | </varlistentry> |
2915 | </variablelist> | |
2916 | </refsect1> | |
2917 | ||
798d3a52 | 2918 | <refsect1> |
e5ff2245 YW |
2919 | <title>[IPv6SendRA] Section Options</title> |
2920 | <para>The [IPv6SendRA] section contains settings for sending IPv6 Router Advertisements and whether | |
2921 | to act as a router, if enabled via the <varname>IPv6SendRA=</varname> option described above. IPv6 | |
2922 | network prefixes or routes are defined with one or more [IPv6Prefix] or [IPv6RoutePrefix] sections. | |
2923 | </para> | |
3f9e0236 PF |
2924 | |
2925 | <variablelist class='network-directives'> | |
2926 | ||
2927 | <varlistentry> | |
2928 | <term><varname>Managed=</varname></term> | |
2929 | <term><varname>OtherInformation=</varname></term> | |
2930 | ||
9b6ffef3 YW |
2931 | <listitem><para>Takes a boolean. Controls whether a DHCPv6 server is used to acquire IPv6 |
2932 | addresses on the network link when <varname>Managed=</varname> | |
3f9e0236 PF |
2933 | is set to <literal>true</literal> or if only additional network |
2934 | information can be obtained via DHCPv6 for the network link when | |
9b6ffef3 | 2935 | <varname>OtherInformation=</varname> is set to |
3f9e0236 PF |
2936 | <literal>true</literal>. Both settings default to |
2937 | <literal>false</literal>, which means that a DHCPv6 server is not being | |
2938 | used.</para></listitem> | |
2939 | </varlistentry> | |
2940 | ||
2941 | <varlistentry> | |
2942 | <term><varname>RouterLifetimeSec=</varname></term> | |
2943 | ||
17cd1f62 ZJS |
2944 | <listitem><para>Takes a timespan. Configures the IPv6 router lifetime in seconds. The value must be 0 |
2945 | seconds, or between 4 seconds and 9000 seconds. When set to 0, the host is not acting as a router. | |
2946 | Defaults to 1800 seconds (30 minutes).</para> | |
3f9e0236 PF |
2947 | </listitem> |
2948 | </varlistentry> | |
2949 | ||
2950 | <varlistentry> | |
2951 | <term><varname>RouterPreference=</varname></term> | |
2952 | ||
2953 | <listitem><para>Configures IPv6 router preference if | |
2954 | <varname>RouterLifetimeSec=</varname> is non-zero. Valid values are | |
2955 | <literal>high</literal>, <literal>medium</literal> and | |
2956 | <literal>low</literal>, with <literal>normal</literal> and | |
2957 | <literal>default</literal> added as synonyms for | |
2958 | <literal>medium</literal> just to make configuration easier. See | |
2959 | <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> | |
2960 | for details. Defaults to <literal>medium</literal>.</para></listitem> | |
2961 | </varlistentry> | |
2962 | ||
63295b42 YW |
2963 | <varlistentry> |
2964 | <term><varname>UplinkInterface=</varname></term> | |
2965 | <listitem><para>Specifies the name or the index of the uplink interface, or one of the special | |
2966 | values <literal>:none</literal> and <literal>:auto</literal>. When emitting DNS servers or | |
2967 | search domains is enabled but no servers are specified, the servers configured in the uplink | |
f6032ff3 | 2968 | interface will be emitted. When <literal>:auto</literal>, the value specified to the same |
a27588d4 YW |
2969 | setting in the [DHCPPrefixDelegation] section will be used if |
2970 | <varname>DHCPPrefixDelegation=</varname> is enabled, otherwise the link which has a default | |
f6032ff3 YW |
2971 | gateway with the highest priority will be automatically selected. When <literal>:none</literal>, |
2972 | no uplink interface will be selected. Defaults to <literal>:auto</literal>.</para></listitem> | |
63295b42 YW |
2973 | </varlistentry> |
2974 | ||
3f9e0236 | 2975 | <varlistentry> |
4cb8478c | 2976 | <term><varname>EmitDNS=</varname></term> |
3f9e0236 PF |
2977 | <term><varname>DNS=</varname></term> |
2978 | ||
63295b42 YW |
2979 | <listitem><para><varname>DNS=</varname> specifies a list of recursive DNS server IPv6 addresses |
2980 | that are distributed via Router Advertisement messages when <varname>EmitDNS=</varname> is true. | |
2981 | <varname>DNS=</varname> also takes special value <literal>_link_local</literal>; in that case | |
f81ac115 | 2982 | the IPv6 link-local address is distributed. If <varname>DNS=</varname> is empty, DNS servers are |
63295b42 YW |
2983 | read from the [Network] section. If the [Network] section does not contain any DNS servers |
2984 | either, DNS servers from the uplink interface specified in <varname>UplinkInterface=</varname> | |
2985 | will be used. When <varname>EmitDNS=</varname> is false, no DNS server information is sent in | |
2986 | Router Advertisement messages. <varname>EmitDNS=</varname> defaults to true.</para></listitem> | |
3f9e0236 PF |
2987 | </varlistentry> |
2988 | ||
760021c0 | 2989 | <varlistentry> |
4cb8478c | 2990 | <term><varname>EmitDomains=</varname></term> |
760021c0 PF |
2991 | <term><varname>Domains=</varname></term> |
2992 | ||
bdac5608 | 2993 | <listitem><para>A list of DNS search domains distributed via Router Advertisement messages when |
63295b42 YW |
2994 | <varname>EmitDomains=</varname> is true. If <varname>Domains=</varname> is empty, DNS search |
2995 | domains are read from the [Network] section. If the [Network] section does not contain any DNS | |
2996 | search domains either, DNS search domains from the uplink interface specified in | |
2997 | <varname>UplinkInterface=</varname> will be used. When <varname>EmitDomains=</varname> is false, | |
2998 | no DNS search domain information is sent in Router Advertisement messages. | |
2999 | <varname>EmitDomains=</varname> defaults to true.</para></listitem> | |
760021c0 PF |
3000 | </varlistentry> |
3001 | ||
3f9e0236 PF |
3002 | <varlistentry> |
3003 | <term><varname>DNSLifetimeSec=</varname></term> | |
3004 | ||
9fa25e07 YW |
3005 | <listitem><para>Lifetime in seconds for the DNS server addresses listed in |
3006 | <varname>DNS=</varname> and search domains listed in <varname>Domains=</varname>. Defaults to | |
c9e2c2da | 3007 | 3600 seconds (one hour).</para></listitem> |
3f9e0236 PF |
3008 | </varlistentry> |
3009 | ||
3010 | </variablelist> | |
3011 | </refsect1> | |
3012 | ||
203d4df5 | 3013 | <refsect1> |
3f9e0236 | 3014 | <title>[IPv6Prefix] Section Options</title> |
e9dd6984 ZJS |
3015 | <para>One or more [IPv6Prefix] sections contain the IPv6 prefixes that are announced via Router |
3016 | Advertisements. See <ulink url="https://tools.ietf.org/html/rfc4861">RFC 4861</ulink> for further | |
3017 | details.</para> | |
3f9e0236 PF |
3018 | |
3019 | <variablelist class='network-directives'> | |
3020 | ||
3021 | <varlistentry> | |
3022 | <term><varname>AddressAutoconfiguration=</varname></term> | |
3023 | <term><varname>OnLink=</varname></term> | |
3024 | ||
9b6ffef3 | 3025 | <listitem><para>Takes a boolean to specify whether IPv6 addresses can be |
3f9e0236 PF |
3026 | autoconfigured with this prefix and whether the prefix can be used for |
3027 | onlink determination. Both settings default to <literal>true</literal> | |
3028 | in order to ease configuration. | |
3029 | </para></listitem> | |
3030 | </varlistentry> | |
3031 | ||
3032 | <varlistentry> | |
3033 | <term><varname>Prefix=</varname></term> | |
3034 | ||
15102ced | 3035 | <listitem><para>The IPv6 prefix that is to be distributed to hosts. Similarly to configuring static |
bdac5608 ZJS |
3036 | IPv6 addresses, the setting is configured as an IPv6 prefix and its prefix length, separated by a |
3037 | <literal>/</literal> character. Use multiple [IPv6Prefix] sections to configure multiple IPv6 | |
3038 | prefixes since prefix lifetimes, address autoconfiguration and onlink status may differ from one | |
3039 | prefix to another.</para></listitem> | |
3f9e0236 PF |
3040 | </varlistentry> |
3041 | ||
3042 | <varlistentry> | |
3043 | <term><varname>PreferredLifetimeSec=</varname></term> | |
3044 | <term><varname>ValidLifetimeSec=</varname></term> | |
3045 | ||
c9e2c2da YW |
3046 | <listitem><para>Preferred and valid lifetimes for the prefix measured in seconds. |
3047 | <varname>PreferredLifetimeSec=</varname> defaults to 1800 seconds (30 minutes) and | |
3048 | <varname>ValidLifetimeSec=</varname> defaults to 3600 seconds (one hour).</para></listitem> | |
203d4df5 SS |
3049 | </varlistentry> |
3050 | ||
bd6379ec SS |
3051 | <varlistentry> |
3052 | <term><varname>Assign=</varname></term> | |
3053 | <listitem><para>Takes a boolean. When true, adds an address from the prefix. Default to false. | |
3054 | </para></listitem> | |
3055 | </varlistentry> | |
0e1fb1d0 | 3056 | |
e609cd06 YW |
3057 | <varlistentry> |
3058 | <term><varname>Token=</varname></term> | |
3059 | <listitem> | |
3060 | <para>Specifies an optional address generation mode for assigning an address in each | |
3061 | prefix. This accepts the same syntax as <varname>Token=</varname> in the [IPv6AcceptRA] | |
3062 | section. If <varname>Assign=</varname> is set to false, then this setting will be ignored. | |
3063 | Defaults to unset, which means the EUI-64 algorithm will be used.</para> | |
3064 | </listitem> | |
3065 | </varlistentry> | |
3066 | ||
0e1fb1d0 YW |
3067 | <varlistentry> |
3068 | <term><varname>RouteMetric=</varname></term> | |
3069 | <listitem> | |
3070 | <para>The metric of the prefix route. Takes an unsigned integer in the range 0…4294967295. | |
3071 | When unset or set to 0, the kernel's default value is used. This setting is ignored when | |
3072 | <varname>Assign=</varname> is false.</para> | |
3073 | </listitem> | |
3074 | </varlistentry> | |
203d4df5 SS |
3075 | </variablelist> |
3076 | </refsect1> | |
3077 | ||
3078 | <refsect1> | |
3079 | <title>[IPv6RoutePrefix] Section Options</title> | |
bdac5608 | 3080 | <para>One or more [IPv6RoutePrefix] sections contain the IPv6 |
203d4df5 SS |
3081 | prefix routes that are announced via Router Advertisements. See |
3082 | <ulink url="https://tools.ietf.org/html/rfc4191">RFC 4191</ulink> | |
3083 | for further details.</para> | |
3084 | ||
3085 | <variablelist class='network-directives'> | |
3086 | ||
3087 | <varlistentry> | |
3088 | <term><varname>Route=</varname></term> | |
3089 | ||
15102ced | 3090 | <listitem><para>The IPv6 route that is to be distributed to hosts. Similarly to configuring static |
bdac5608 | 3091 | IPv6 routes, the setting is configured as an IPv6 prefix routes and its prefix route length, |
69a7d108 | 3092 | separated by a <literal>/</literal> character. Use multiple [IPv6RoutePrefix] sections to configure |
bdac5608 | 3093 | multiple IPv6 prefix routes.</para></listitem> |
203d4df5 SS |
3094 | </varlistentry> |
3095 | ||
3096 | <varlistentry> | |
3097 | <term><varname>LifetimeSec=</varname></term> | |
3098 | ||
c9e2c2da YW |
3099 | <listitem><para>Lifetime for the route prefix measured in seconds. |
3100 | <varname>LifetimeSec=</varname> defaults to 3600 seconds (one hour).</para></listitem> | |
3f9e0236 PF |
3101 | </varlistentry> |
3102 | ||
3103 | </variablelist> | |
3104 | </refsect1> | |
3105 | ||
3106 | <refsect1> | |
798d3a52 | 3107 | <title>[Bridge] Section Options</title> |
bdac5608 | 3108 | <para>The [Bridge] section accepts the following keys:</para> |
798d3a52 | 3109 | <variablelist class='network-directives'> |
165c41a9 SS |
3110 | <varlistentry> |
3111 | <term><varname>UnicastFlood=</varname></term> | |
3112 | <listitem> | |
9b6ffef3 | 3113 | <para>Takes a boolean. Controls whether the bridge should flood |
072f9e4a | 3114 | traffic for which an FDB entry is missing and the destination |
025314d9 | 3115 | is unknown through this port. When unset, the kernel's default will be used. |
47c7dfe2 | 3116 | </para> |
165c41a9 SS |
3117 | </listitem> |
3118 | </varlistentry> | |
7f15b714 TJ |
3119 | <varlistentry> |
3120 | <term><varname>MulticastFlood=</varname></term> | |
3121 | <listitem> | |
3122 | <para>Takes a boolean. Controls whether the bridge should flood | |
3123 | traffic for which an MDB entry is missing and the destination | |
3124 | is unknown through this port. When unset, the kernel's default will be used. | |
3125 | </para> | |
3126 | </listitem> | |
3127 | </varlistentry> | |
d3aa8b49 SS |
3128 | <varlistentry> |
3129 | <term><varname>MulticastToUnicast=</varname></term> | |
3130 | <listitem> | |
3131 | <para>Takes a boolean. Multicast to unicast works on top of the multicast snooping feature of | |
3132 | the bridge. Which means unicast copies are only delivered to hosts which are interested in it. | |
3133 | When unset, the kernel's default will be used. | |
3134 | </para> | |
3135 | </listitem> | |
3136 | </varlistentry> | |
7f15b714 TJ |
3137 | <varlistentry> |
3138 | <term><varname>NeighborSuppression=</varname></term> | |
3139 | <listitem> | |
3140 | <para>Takes a boolean. Configures whether ARP and ND neighbor suppression is enabled for | |
3141 | this port. When unset, the kernel's default will be used. | |
3142 | </para> | |
3143 | </listitem> | |
3144 | </varlistentry> | |
3145 | <varlistentry> | |
3146 | <term><varname>Learning=</varname></term> | |
3147 | <listitem> | |
3148 | <para>Takes a boolean. Configures whether MAC address learning is enabled for | |
3149 | this port. When unset, the kernel's default will be used. | |
3150 | </para> | |
3151 | </listitem> | |
3152 | </varlistentry> | |
165c41a9 SS |
3153 | <varlistentry> |
3154 | <term><varname>HairPin=</varname></term> | |
3155 | <listitem> | |
e9dd6984 ZJS |
3156 | <para>Takes a boolean. Configures whether traffic may be sent back out of the port on which it |
3157 | was received. When this flag is false, then the bridge will not forward traffic back out of the | |
3158 | receiving port. When unset, the kernel's default will be used.</para> | |
165c41a9 SS |
3159 | </listitem> |
3160 | </varlistentry> | |
97f27f8a SW |
3161 | <varlistentry> |
3162 | <term><varname>Isolated=</varname></term> | |
3163 | <listitem> | |
3164 | <para>Takes a boolean. Configures whether this port is isolated or not. Within a bridge, | |
3165 | isolated ports can only communicate with non-isolated ports. When set to true, this port can only | |
3166 | communicate with other ports whose Isolated setting is false. When set to false, this port | |
3167 | can communicate with any other ports. When unset, the kernel's default will be used.</para> | |
3168 | </listitem> | |
3169 | </varlistentry> | |
165c41a9 | 3170 | <varlistentry> |
84c34096 | 3171 | <term><varname>UseBPDU=</varname></term> |
165c41a9 | 3172 | <listitem> |
9b6ffef3 | 3173 | <para>Takes a boolean. Configures whether STP Bridge Protocol Data Units will be |
025314d9 | 3174 | processed by the bridge port. When unset, the kernel's default will be used.</para> |
165c41a9 SS |
3175 | </listitem> |
3176 | </varlistentry> | |
3177 | <varlistentry> | |
3178 | <term><varname>FastLeave=</varname></term> | |
3179 | <listitem> | |
9b6ffef3 | 3180 | <para>Takes a boolean. This flag allows the bridge to immediately stop multicast |
a8eaaee7 | 3181 | traffic on a port that receives an IGMP Leave message. It is only used with |
025314d9 | 3182 | IGMP snooping if enabled on the bridge. When unset, the kernel's default will be used.</para> |
165c41a9 SS |
3183 | </listitem> |
3184 | </varlistentry> | |
3185 | <varlistentry> | |
23da66bb | 3186 | <term><varname>AllowPortToBeRoot=</varname></term> |
165c41a9 | 3187 | <listitem> |
9b6ffef3 | 3188 | <para>Takes a boolean. Configures whether a given port is allowed to |
47c7dfe2 | 3189 | become a root port. Only used when STP is enabled on the bridge. |
025314d9 | 3190 | When unset, the kernel's default will be used.</para> |
165c41a9 SS |
3191 | </listitem> |
3192 | </varlistentry> | |
1087623b SS |
3193 | <varlistentry> |
3194 | <term><varname>ProxyARP=</varname></term> | |
3195 | <listitem> | |
3196 | <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port. | |
3197 | When unset, the kernel's default will be used.</para> | |
3198 | </listitem> | |
3199 | </varlistentry> | |
3200 | <varlistentry> | |
3201 | <term><varname>ProxyARPWiFi=</varname></term> | |
3202 | <listitem> | |
3203 | <para>Takes a boolean. Configures whether proxy ARP to be enabled on this port | |
3204 | which meets extended requirements by IEEE 802.11 and Hotspot 2.0 specifications. | |
3205 | When unset, the kernel's default will be used.</para> | |
3206 | </listitem> | |
3207 | </varlistentry> | |
0fadb2a4 SS |
3208 | <varlistentry> |
3209 | <term><varname>MulticastRouter=</varname></term> | |
3210 | <listitem> | |
3211 | <para>Configures this port for having multicast routers attached. A port with a multicast | |
3212 | router will receive all multicast traffic. Takes one of <literal>no</literal> | |
3213 | to disable multicast routers on this port, <literal>query</literal> to let the system detect | |
3214 | the presence of routers, <literal>permanent</literal> to permanently enable multicast traffic | |
3215 | forwarding on this port, or <literal>temporary</literal> to enable multicast routers temporarily | |
3216 | on this port, not depending on incoming queries. When unset, the kernel's default will be used.</para> | |
3217 | </listitem> | |
3218 | </varlistentry> | |
798d3a52 ZJS |
3219 | <varlistentry> |
3220 | <term><varname>Cost=</varname></term> | |
3221 | <listitem> | |
47c7dfe2 | 3222 | <para>Sets the "cost" of sending packets of this interface. |
a8eaaee7 | 3223 | Each port in a bridge may have a different speed and the cost |
798d3a52 | 3224 | is used to decide which link to use. Faster interfaces |
785889e5 | 3225 | should have lower costs. It is an integer value between 1 and |
b56be296 DJL |
3226 | 65535.</para> |
3227 | </listitem> | |
3228 | </varlistentry> | |
3229 | <varlistentry> | |
3230 | <term><varname>Priority=</varname></term> | |
3231 | <listitem> | |
3232 | <para>Sets the "priority" of sending packets on this interface. | |
3233 | Each port in a bridge may have a different priority which is used | |
3234 | to decide which link to use. Lower value means higher priority. | |
785889e5 | 3235 | It is an integer value between 0 to 63. Networkd does not set any |
b56be296 | 3236 | default, meaning the kernel default value of 32 is used.</para> |
798d3a52 ZJS |
3237 | </listitem> |
3238 | </varlistentry> | |
3239 | </variablelist> | |
3240 | </refsect1> | |
798d3a52 ZJS |
3241 | <refsect1> |
3242 | <title>[BridgeFDB] Section Options</title> | |
bdac5608 ZJS |
3243 | <para>The [BridgeFDB] section manages the forwarding database table of a port and accepts the following |
3244 | keys. Specify several [BridgeFDB] sections to configure several static MAC table entries.</para> | |
798d3a52 ZJS |
3245 | |
3246 | <variablelist class='network-directives'> | |
3247 | <varlistentry> | |
3248 | <term><varname>MACAddress=</varname></term> | |
3249 | <listitem> | |
bdac5608 | 3250 | <para>As in the [Network] section. This key is mandatory.</para> |
798d3a52 ZJS |
3251 | </listitem> |
3252 | </varlistentry> | |
c2c2793f SS |
3253 | <varlistentry> |
3254 | <term><varname>Destination=</varname></term> | |
3255 | <listitem> | |
3256 | <para>Takes an IP address of the destination VXLAN tunnel endpoint.</para> | |
3257 | </listitem> | |
3258 | </varlistentry> | |
798d3a52 ZJS |
3259 | <varlistentry> |
3260 | <term><varname>VLANId=</varname></term> | |
3261 | <listitem> | |
a8eaaee7 | 3262 | <para>The VLAN ID for the new static MAC table entry. If |
db9b9fb9 | 3263 | omitted, no VLAN ID information is appended to the new static MAC |
798d3a52 ZJS |
3264 | table entry.</para> |
3265 | </listitem> | |
3266 | </varlistentry> | |
61b824c5 SS |
3267 | <varlistentry> |
3268 | <term><varname>VNI=</varname></term> | |
3269 | <listitem> | |
3270 | <para>The VXLAN Network Identifier (or VXLAN Segment ID) to use to connect to | |
1d3a473b | 3271 | the remote VXLAN tunnel endpoint. Takes a number in the range 1…16777215. |
61b824c5 SS |
3272 | Defaults to unset.</para> |
3273 | </listitem> | |
3274 | </varlistentry> | |
bdb397ed SS |
3275 | <varlistentry> |
3276 | <term><varname>AssociatedWith=</varname></term> | |
3277 | <listitem> | |
3278 | <para>Specifies where the address is associated with. Takes one of <literal>use</literal>, | |
3279 | <literal>self</literal>, <literal>master</literal> or <literal>router</literal>. | |
3280 | <literal>use</literal> means the address is in use. User space can use this option to | |
3281 | indicate to the kernel that the fdb entry is in use. <literal>self</literal> means | |
3282 | the address is associated with the port drivers fdb. Usually hardware. <literal>master</literal> | |
3283 | means the address is associated with master devices fdb. <literal>router</literal> means | |
3284 | the destination address is associated with a router. Note that it's valid if the referenced | |
3285 | device is a VXLAN type device and has route shortcircuit enabled. Defaults to <literal>self</literal>.</para> | |
3286 | </listitem> | |
3287 | </varlistentry> | |
af99cdf4 SS |
3288 | <varlistentry> |
3289 | <term><varname>OutgoingInterface=</varname></term> | |
3290 | <listitem> | |
3291 | <para>Specifies the name or index of the outgoing interface for the VXLAN device driver to | |
3292 | reach the remote VXLAN tunnel endpoint. Defaults to unset.</para> | |
3293 | </listitem> | |
3294 | </varlistentry> | |
798d3a52 ZJS |
3295 | </variablelist> |
3296 | </refsect1> | |
a1717e9a DM |
3297 | <refsect1> |
3298 | <title>[BridgeMDB] Section Options</title> | |
3299 | <para>The [BridgeMDB] section manages the multicast membership entries forwarding database table of a port and accepts the following | |
3300 | keys. Specify several [BridgeMDB] sections to configure several permanent multicast membership entries.</para> | |
3301 | ||
3302 | <variablelist class='network-directives'> | |
3303 | <varlistentry> | |
3304 | <term><varname>MulticastGroupAddress=</varname></term> | |
3305 | <listitem> | |
3306 | <para>Specifies the IPv4 or IPv6 multicast group address to add. This setting is mandatory.</para> | |
3307 | </listitem> | |
3308 | </varlistentry> | |
3309 | <varlistentry> | |
3310 | <term><varname>VLANId=</varname></term> | |
3311 | <listitem> | |
3312 | <para>The VLAN ID for the new entry. Valid ranges are 0 (no VLAN) to 4094. Optional, defaults to 0.</para> | |
3313 | </listitem> | |
3314 | </varlistentry> | |
3315 | </variablelist> | |
3316 | </refsect1> | |
06828bb6 | 3317 | |
e9a8c550 SS |
3318 | <refsect1> |
3319 | <title>[LLDP] Section Options</title> | |
bdac5608 | 3320 | <para>The [LLDP] section manages the Link Layer Discovery Protocol (LLDP) and accepts the following |
885a4e6c | 3321 | keys:</para> |
e9a8c550 SS |
3322 | <variablelist class='network-directives'> |
3323 | <varlistentry> | |
3324 | <term><varname>MUDURL=</varname></term> | |
3325 | <listitem> | |
0558f303 ZJS |
3326 | <para>When configured, the specified Manufacturer Usage Descriptions (MUD) URL will be sent in |
3327 | LLDP packets. The syntax and semantics are the same as for <varname>MUDURL=</varname> in the | |
3328 | [DHCPv4] section described above.</para> | |
3329 | ||
3330 | <para>The MUD URLs received via LLDP packets are saved and can be read using the | |
e9a8c550 SS |
3331 | <function>sd_lldp_neighbor_get_mud_url()</function> function.</para> |
3332 | </listitem> | |
3333 | </varlistentry> | |
3334 | </variablelist> | |
3335 | </refsect1> | |
3336 | ||
06828bb6 HP |
3337 | <refsect1> |
3338 | <title>[CAN] Section Options</title> | |
bdac5608 ZJS |
3339 | <para>The [CAN] section manages the Controller Area Network (CAN bus) and accepts the |
3340 | following keys:</para> | |
06828bb6 HP |
3341 | <variablelist class='network-directives'> |
3342 | <varlistentry> | |
3343 | <term><varname>BitRate=</varname></term> | |
3344 | <listitem> | |
3345 | <para>The bitrate of CAN device in bits per second. The usual SI prefixes (K, M) with the base of 1000 can | |
1d3a473b | 3346 | be used here. Takes a number in the range 1…4294967295.</para> |
06828bb6 HP |
3347 | </listitem> |
3348 | </varlistentry> | |
3349 | <varlistentry> | |
3350 | <term><varname>SamplePoint=</varname></term> | |
3351 | <listitem> | |
3352 | <para>Optional sample point in percent with one decimal (e.g. <literal>75%</literal>, | |
817561cc YW |
3353 | <literal>87.5%</literal>) or permille (e.g. <literal>875‰</literal>). This will be ignored when |
3354 | <varname>BitRate=</varname> is unspecified.</para> | |
06828bb6 HP |
3355 | </listitem> |
3356 | </varlistentry> | |
b164b570 YW |
3357 | <varlistentry> |
3358 | <term><varname>TimeQuantaNSec=</varname></term> | |
3359 | <term><varname>PropagationSegment=</varname></term> | |
3360 | <term><varname>PhaseBufferSegment1=</varname></term> | |
3361 | <term><varname>PhaseBufferSegment2=</varname></term> | |
3362 | <term><varname>SyncJumpWidth=</varname></term> | |
3363 | <listitem> | |
3364 | <para>Specifies the time quanta, propagation segment, phase buffer segment 1 and 2, and the | |
6eed65d4 | 3365 | synchronization jump width, which allow one to define the CAN bit-timing in a hardware |
b164b570 YW |
3366 | independent format as proposed by the Bosch CAN 2.0 Specification. |
3367 | <varname>TimeQuantaNSec=</varname> takes a timespan in nanoseconds. | |
3368 | <varname>PropagationSegment=</varname>, <varname>PhaseBufferSegment1=</varname>, | |
3369 | <varname>PhaseBufferSegment2=</varname>, and <varname>SyncJumpWidth=</varname> take number | |
3370 | of time quantum specified in <varname>TimeQuantaNSec=</varname> and must be an unsigned | |
3371 | integer in the range 0…4294967295. These settings except for | |
3372 | <varname>SyncJumpWidth=</varname> will be ignored when <varname>BitRate=</varname> is | |
3373 | specified.</para> | |
06828bb6 HP |
3374 | </listitem> |
3375 | </varlistentry> | |
7e025e9c RP |
3376 | <varlistentry> |
3377 | <term><varname>DataBitRate=</varname></term> | |
3378 | <term><varname>DataSamplePoint=</varname></term> | |
3379 | <listitem> | |
3380 | <para>The bitrate and sample point for the data phase, if CAN-FD is used. These settings are | |
3381 | analogous to the <varname>BitRate=</varname> and <varname>SamplePoint=</varname> keys.</para> | |
3382 | </listitem> | |
3383 | </varlistentry> | |
b164b570 YW |
3384 | <varlistentry> |
3385 | <term><varname>DataTimeQuantaNSec=</varname></term> | |
3386 | <term><varname>DataPropagationSegment=</varname></term> | |
3387 | <term><varname>DataPhaseBufferSegment1=</varname></term> | |
3388 | <term><varname>DataPhaseBufferSegment2=</varname></term> | |
3389 | <term><varname>DataSyncJumpWidth=</varname></term> | |
3390 | <listitem> | |
3391 | <para>Specifies the time quanta, propagation segment, phase buffer segment 1 and 2, and the | |
3392 | synchronization jump width for the data phase, if CAN-FD is used. These settings are | |
3393 | analogous to the <varname>TimeQuantaNSec=</varname> or related settings.</para> | |
3394 | </listitem> | |
3395 | </varlistentry> | |
7e025e9c RP |
3396 | <varlistentry> |
3397 | <term><varname>FDMode=</varname></term> | |
3398 | <listitem> | |
3399 | <para>Takes a boolean. When <literal>yes</literal>, CAN-FD mode is enabled for the interface. | |
3400 | Note, that a bitrate and optional sample point should also be set for the CAN-FD data phase using | |
b164b570 YW |
3401 | the <varname>DataBitRate=</varname> and <varname>DataSamplePoint=</varname> keys, or |
3402 | <varname>DataTimeQuanta=</varname> and related settings.</para> | |
7e025e9c RP |
3403 | </listitem> |
3404 | </varlistentry> | |
3405 | <varlistentry> | |
3406 | <term><varname>FDNonISO=</varname></term> | |
3407 | <listitem> | |
3408 | <para>Takes a boolean. When <literal>yes</literal>, non-ISO CAN-FD mode is enabled for the | |
3409 | interface. When unset, the kernel's default will be used.</para> | |
3410 | </listitem> | |
3411 | </varlistentry> | |
06828bb6 HP |
3412 | <varlistentry> |
3413 | <term><varname>RestartSec=</varname></term> | |
3414 | <listitem> | |
3415 | <para>Automatic restart delay time. If set to a non-zero value, a restart of the CAN controller will be | |
3416 | triggered automatically in case of a bus-off condition after the specified delay time. Subsecond delays can | |
3417 | be specified using decimals (e.g. <literal>0.1s</literal>) or a <literal>ms</literal> or | |
3418 | <literal>us</literal> postfix. Using <literal>infinity</literal> or <literal>0</literal> will turn the | |
3419 | automatic restart off. By default automatic restart is disabled.</para> | |
3420 | </listitem> | |
3421 | </varlistentry> | |
52aa38f1 MR |
3422 | <varlistentry> |
3423 | <term><varname>Termination=</varname></term> | |
3424 | <listitem> | |
69978eb9 | 3425 | <para>Takes a boolean or a termination resistor value in ohm in the range 0…65535. When |
239f91f7 YW |
3426 | <literal>yes</literal>, the termination resistor is set to 120 ohm. When |
3427 | <literal>no</literal> or <literal>0</literal> is set, the termination resistor is disabled. | |
3428 | When unset, the kernel's default will be used.</para> | |
52aa38f1 MR |
3429 | </listitem> |
3430 | </varlistentry> | |
c423be28 CG |
3431 | <varlistentry> |
3432 | <term><varname>TripleSampling=</varname></term> | |
3433 | <listitem> | |
3434 | <para>Takes a boolean. When <literal>yes</literal>, three samples (instead of one) are used to determine | |
3435 | the value of a received bit by majority rule. When unset, the kernel's default will be used.</para> | |
3436 | </listitem> | |
3437 | </varlistentry> | |
77b67404 UÖ |
3438 | <varlistentry> |
3439 | <term><varname>BusErrorReporting=</varname></term> | |
3440 | <listitem> | |
3441 | <para>Takes a boolean. When <literal>yes</literal>, reporting of CAN bus errors is activated | |
3442 | (those include single bit, frame format, and bit stuffing errors, unable to send dominant bit, | |
3443 | unable to send recessive bit, bus overload, active error announcement, error occurred on | |
3444 | transmission). When unset, the kernel's default will be used. Note: in case of a CAN bus with a | |
3445 | single CAN device, sending a CAN frame may result in a huge number of CAN bus errors.</para> | |
3446 | </listitem> | |
3447 | </varlistentry> | |
74f0fb90 YW |
3448 | <varlistentry> |
3449 | <term><varname>ListenOnly=</varname></term> | |
3450 | <listitem> | |
3451 | <para>Takes a boolean. When <literal>yes</literal>, listen-only mode is enabled. When the | |
3452 | interface is in listen-only mode, the interface neither transmit CAN frames nor send ACK | |
3453 | bit. Listen-only mode is important to debug CAN networks without interfering with the | |
3454 | communication or acknowledge the CAN frame. When unset, the kernel's default will be used. | |
3455 | </para> | |
3456 | </listitem> | |
3457 | </varlistentry> | |
6dd84c9e YW |
3458 | <varlistentry> |
3459 | <term><varname>Loopback=</varname></term> | |
3460 | <listitem> | |
3461 | <para>Takes a boolean. When <literal>yes</literal>, loopback mode is enabled. When the | |
3462 | loopback mode is enabled, the interface treats messages transmitted by itself as received | |
3463 | messages. The loopback mode is important to debug CAN networks. When unset, the kernel's | |
3464 | default will be used.</para> | |
3465 | </listitem> | |
3466 | </varlistentry> | |
3467 | <varlistentry> | |
3468 | <term><varname>OneShot=</varname></term> | |
3469 | <listitem> | |
3470 | <para>Takes a boolean. When <literal>yes</literal>, one-shot mode is enabled. When unset, | |
3471 | the kernel's default will be used.</para> | |
3472 | </listitem> | |
3473 | </varlistentry> | |
3474 | <varlistentry> | |
3475 | <term><varname>PresumeAck=</varname></term> | |
3476 | <listitem> | |
3477 | <para>Takes a boolean. When <literal>yes</literal>, the interface will ignore missing CAN | |
3478 | ACKs. When unset, the kernel's default will be used.</para> | |
3479 | </listitem> | |
3480 | </varlistentry> | |
3481 | <varlistentry> | |
3482 | <term><varname>ClassicDataLengthCode=</varname></term> | |
3483 | <listitem> | |
3484 | <para>Takes a boolean. When <literal>yes</literal>, the interface will handle the 4bit data | |
3485 | length code (DLC). When unset, the kernel's default will be used.</para> | |
3486 | </listitem> | |
3487 | </varlistentry> | |
06828bb6 | 3488 | </variablelist> |
72e65e6f YW |
3489 | </refsect1> |
3490 | ||
3491 | <refsect1> | |
3492 | <title>[IPoIB] Section Options</title> | |
3493 | <para>The [IPoIB] section manages the IP over Infiniband and accepts the following keys:</para> | |
3494 | <variablelist class='network-directives'> | |
3495 | <xi:include href="systemd.netdev.xml" xpointer="ipoib_mode" /> | |
3496 | <xi:include href="systemd.netdev.xml" xpointer="ipoib_umcast" /> | |
3497 | </variablelist> | |
06828bb6 HP |
3498 | </refsect1> |
3499 | ||
2ed5f6d5 YW |
3500 | <refsect1> |
3501 | <title>[QDisc] Section Options</title> | |
bdac5608 | 3502 | <para>The [QDisc] section manages the traffic control queueing discipline (qdisc).</para> |
2ed5f6d5 YW |
3503 | |
3504 | <variablelist class='network-directives'> | |
3505 | <varlistentry> | |
3506 | <term><varname>Parent=</varname></term> | |
3507 | <listitem> | |
3508 | <para>Specifies the parent Queueing Discipline (qdisc). Takes one of <literal>clsact</literal> | |
3509 | or <literal>ingress</literal>. This is mandatory.</para> | |
3510 | </listitem> | |
3511 | </varlistentry> | |
d8b2396d | 3512 | |
f344a492 | 3513 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> |
2ed5f6d5 YW |
3514 | </variablelist> |
3515 | </refsect1> | |
3516 | ||
0f5bd7fe | 3517 | <refsect1> |
18de0969 | 3518 | <title>[NetworkEmulator] Section Options</title> |
bdac5608 ZJS |
3519 | <para>The [NetworkEmulator] section manages the queueing discipline (qdisc) of the network emulator. It |
3520 | can be used to configure the kernel packet scheduler and simulate packet delay and loss for UDP or TCP | |
3521 | applications, or limit the bandwidth usage of a particular service to simulate internet connections. | |
3522 | </para> | |
0f5bd7fe SS |
3523 | |
3524 | <variablelist class='network-directives'> | |
f344a492 YW |
3525 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3526 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 3527 | |
0f5bd7fe | 3528 | <varlistentry> |
18de0969 | 3529 | <term><varname>DelaySec=</varname></term> |
0f5bd7fe SS |
3530 | <listitem> |
3531 | <para>Specifies the fixed amount of delay to be added to all packets going out of the | |
3532 | interface. Defaults to unset.</para> | |
3533 | </listitem> | |
3534 | </varlistentry> | |
3535 | ||
3536 | <varlistentry> | |
18de0969 | 3537 | <term><varname>DelayJitterSec=</varname></term> |
0f5bd7fe SS |
3538 | <listitem> |
3539 | <para>Specifies the chosen delay to be added to the packets outgoing to the network | |
3540 | interface. Defaults to unset.</para> | |
3541 | </listitem> | |
3542 | </varlistentry> | |
3543 | ||
3544 | <varlistentry> | |
18de0969 | 3545 | <term><varname>PacketLimit=</varname></term> |
0f5bd7fe SS |
3546 | <listitem> |
3547 | <para>Specifies the maximum number of packets the qdisc may hold queued at a time. | |
69978eb9 | 3548 | An unsigned integer in the range 0…4294967294. Defaults to 1000.</para> |
0f5bd7fe SS |
3549 | </listitem> |
3550 | </varlistentry> | |
3551 | ||
3552 | <varlistentry> | |
18de0969 | 3553 | <term><varname>LossRate=</varname></term> |
0f5bd7fe SS |
3554 | <listitem> |
3555 | <para>Specifies an independent loss probability to be added to the packets outgoing from the | |
3556 | network interface. Takes a percentage value, suffixed with "%". Defaults to unset.</para> | |
3557 | </listitem> | |
3558 | </varlistentry> | |
3559 | ||
b9c5aa3c | 3560 | <varlistentry> |
18de0969 | 3561 | <term><varname>DuplicateRate=</varname></term> |
b9c5aa3c SS |
3562 | <listitem> |
3563 | <para>Specifies that the chosen percent of packets is duplicated before queuing them. | |
3564 | Takes a percentage value, suffixed with "%". Defaults to unset.</para> | |
3565 | </listitem> | |
3566 | </varlistentry> | |
18de0969 YW |
3567 | </variablelist> |
3568 | </refsect1> | |
b9c5aa3c | 3569 | |
18de0969 | 3570 | <refsect1> |
60ed2dcf | 3571 | <title>[TokenBucketFilter] Section Options</title> |
e9dd6984 ZJS |
3572 | <para>The [TokenBucketFilter] section manages the queueing discipline (qdisc) of token bucket filter |
3573 | (tbf).</para> | |
18de0969 YW |
3574 | |
3575 | <variablelist class='network-directives'> | |
f344a492 YW |
3576 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3577 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 3578 | |
18de0969 YW |
3579 | <varlistentry> |
3580 | <term><varname>LatencySec=</varname></term> | |
ba5841b5 SS |
3581 | <listitem> |
3582 | <para>Specifies the latency parameter, which specifies the maximum amount of time a | |
60ed2dcf | 3583 | packet can sit in the Token Bucket Filter (TBF). Defaults to unset.</para> |
ba5841b5 SS |
3584 | </listitem> |
3585 | </varlistentry> | |
3586 | ||
dcfc23ae | 3587 | <varlistentry> |
c03ef420 | 3588 | <term><varname>LimitBytes=</varname></term> |
dcfc23ae YW |
3589 | <listitem> |
3590 | <para>Takes the number of bytes that can be queued waiting for tokens to become available. | |
3591 | When the size is suffixed with K, M, or G, it is parsed as Kilobytes, Megabytes, or Gigabytes, | |
c03ef420 | 3592 | respectively, to the base of 1024. Defaults to unset.</para> |
dcfc23ae YW |
3593 | </listitem> |
3594 | </varlistentry> | |
3595 | ||
ba5841b5 | 3596 | <varlistentry> |
c03ef420 | 3597 | <term><varname>BurstBytes=</varname></term> |
ba5841b5 SS |
3598 | <listitem> |
3599 | <para>Specifies the size of the bucket. This is the maximum amount of bytes that tokens | |
3600 | can be available for instantaneous transfer. When the size is suffixed with K, M, or G, it is | |
c03ef420 | 3601 | parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to |
ba5841b5 SS |
3602 | unset.</para> |
3603 | </listitem> | |
3604 | </varlistentry> | |
3605 | ||
3606 | <varlistentry> | |
18de0969 | 3607 | <term><varname>Rate=</varname></term> |
ba5841b5 SS |
3608 | <listitem> |
3609 | <para>Specifies the device specific bandwidth. When suffixed with K, M, or G, the specified | |
6b8fe4c3 | 3610 | bandwidth is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 1000. |
ba5841b5 SS |
3611 | Defaults to unset.</para> |
3612 | </listitem> | |
3613 | </varlistentry> | |
3614 | ||
dcfc23ae | 3615 | <varlistentry> |
18de0969 | 3616 | <term><varname>MPUBytes=</varname></term> |
dcfc23ae YW |
3617 | <listitem> |
3618 | <para>The Minimum Packet Unit (MPU) determines the minimal token usage (specified in bytes) | |
3619 | for a packet. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, | |
c03ef420 | 3620 | Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to zero.</para> |
dcfc23ae YW |
3621 | </listitem> |
3622 | </varlistentry> | |
3623 | ||
3624 | <varlistentry> | |
18de0969 | 3625 | <term><varname>PeakRate=</varname></term> |
dcfc23ae YW |
3626 | <listitem> |
3627 | <para>Takes the maximum depletion rate of the bucket. When suffixed with K, M, or G, the | |
6b8fe4c3 | 3628 | specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of |
dcfc23ae YW |
3629 | 1000. Defaults to unset.</para> |
3630 | </listitem> | |
3631 | </varlistentry> | |
3632 | ||
3633 | <varlistentry> | |
18de0969 | 3634 | <term><varname>MTUBytes=</varname></term> |
dcfc23ae YW |
3635 | <listitem> |
3636 | <para>Specifies the size of the peakrate bucket. When suffixed with K, M, or G, the specified | |
c03ef420 | 3637 | size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. |
dcfc23ae YW |
3638 | Defaults to unset.</para> |
3639 | </listitem> | |
3640 | </varlistentry> | |
18de0969 YW |
3641 | </variablelist> |
3642 | </refsect1> | |
3643 | ||
bde4ae88 SS |
3644 | <refsect1> |
3645 | <title>[PIE] Section Options</title> | |
bdac5608 ZJS |
3646 | <para>The [PIE] section manages the queueing discipline (qdisc) of Proportional Integral |
3647 | controller-Enhanced (PIE).</para> | |
bde4ae88 SS |
3648 | |
3649 | <variablelist class='network-directives'> | |
f344a492 YW |
3650 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3651 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
bde4ae88 SS |
3652 | |
3653 | <varlistentry> | |
3654 | <term><varname>PacketLimit=</varname></term> | |
3655 | <listitem> | |
1d3a473b ZJS |
3656 | <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, |
3657 | incoming packets are dropped. An unsigned integer in the range 1…4294967294. Defaults to unset and | |
3658 | kernel's default is used.</para> | |
8f6b6d70 SS |
3659 | </listitem> |
3660 | </varlistentry> | |
3661 | </variablelist> | |
3662 | </refsect1> | |
3663 | ||
3664 | <refsect1> | |
3665 | <title>[FlowQueuePIE] Section Options</title> | |
3666 | <para>The <literal>[FlowQueuePIE]</literal> section manages the queueing discipline | |
3667 | (qdisc) of Flow Queue Proportional Integral controller-Enhanced (fq_pie).</para> | |
3668 | ||
3669 | <variablelist class='network-directives'> | |
3670 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> | |
3671 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
3672 | ||
3673 | <varlistentry> | |
3674 | <term><varname>PacketLimit=</varname></term> | |
3675 | <listitem> | |
75909cc7 ZJS |
3676 | <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, |
3677 | incoming packets are dropped. An unsigned integer ranges 1 to 4294967294. Defaults to unset and | |
3678 | kernel's default is used.</para> | |
bde4ae88 SS |
3679 | </listitem> |
3680 | </varlistentry> | |
3681 | </variablelist> | |
3682 | </refsect1> | |
3683 | ||
982998b0 SS |
3684 | <refsect1> |
3685 | <title>[StochasticFairBlue] Section Options</title> | |
bdac5608 ZJS |
3686 | <para>The [StochasticFairBlue] section manages the queueing discipline (qdisc) of stochastic fair blue |
3687 | (sfb).</para> | |
982998b0 SS |
3688 | |
3689 | <variablelist class='network-directives'> | |
f344a492 YW |
3690 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3691 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
982998b0 SS |
3692 | |
3693 | <varlistentry> | |
3694 | <term><varname>PacketLimit=</varname></term> | |
3695 | <listitem> | |
e9dd6984 | 3696 | <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, |
69978eb9 | 3697 | incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and |
e9dd6984 | 3698 | kernel's default is used.</para> |
982998b0 SS |
3699 | </listitem> |
3700 | </varlistentry> | |
3701 | </variablelist> | |
3702 | </refsect1> | |
3703 | ||
18de0969 YW |
3704 | <refsect1> |
3705 | <title>[StochasticFairnessQueueing] Section Options</title> | |
bdac5608 ZJS |
3706 | <para>The [StochasticFairnessQueueing] section manages the queueing discipline (qdisc) of stochastic |
3707 | fairness queueing (sfq).</para> | |
18de0969 YW |
3708 | |
3709 | <variablelist class='network-directives'> | |
f344a492 YW |
3710 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3711 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 3712 | |
9942b710 | 3713 | <varlistentry> |
18de0969 | 3714 | <term><varname>PerturbPeriodSec=</varname></term> |
9942b710 SS |
3715 | <listitem> |
3716 | <para>Specifies the interval in seconds for queue algorithm perturbation. Defaults to unset.</para> | |
3717 | </listitem> | |
3718 | </varlistentry> | |
18de0969 YW |
3719 | </variablelist> |
3720 | </refsect1> | |
3721 | ||
c853f594 SS |
3722 | <refsect1> |
3723 | <title>[BFIFO] Section Options</title> | |
bdac5608 ZJS |
3724 | <para>The [BFIFO] section manages the queueing discipline (qdisc) of Byte limited Packet First In First |
3725 | Out (bfifo).</para> | |
c853f594 SS |
3726 | |
3727 | <variablelist class='network-directives'> | |
f344a492 YW |
3728 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3729 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
c853f594 SS |
3730 | |
3731 | <varlistentry> | |
c03ef420 | 3732 | <term><varname>LimitBytes=</varname></term> |
c853f594 | 3733 | <listitem> |
885a4e6c ZJS |
3734 | <para>Specifies the hard limit in bytes on the FIFO buffer size. The size limit prevents overflow |
3735 | in case the kernel is unable to dequeue packets as quickly as it receives them. When this limit is | |
3736 | reached, incoming packets are dropped. When suffixed with K, M, or G, the specified size is parsed | |
3737 | as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and | |
3738 | kernel default is used.</para> | |
c853f594 SS |
3739 | </listitem> |
3740 | </varlistentry> | |
3741 | </variablelist> | |
3742 | </refsect1> | |
3743 | ||
a7476065 SS |
3744 | <refsect1> |
3745 | <title>[PFIFO] Section Options</title> | |
bdac5608 ZJS |
3746 | <para>The [PFIFO] section manages the queueing discipline (qdisc) of Packet First In First Out |
3747 | (pfifo).</para> | |
a7476065 SS |
3748 | |
3749 | <variablelist class='network-directives'> | |
f344a492 YW |
3750 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3751 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
a7476065 SS |
3752 | |
3753 | <varlistentry> | |
3754 | <term><varname>PacketLimit=</varname></term> | |
3755 | <listitem> | |
75909cc7 ZJS |
3756 | <para>Specifies the hard limit on the number of packets in the FIFO queue. The size limit prevents |
3757 | overflow in case the kernel is unable to dequeue packets as quickly as it receives them. When this | |
3758 | limit is reached, incoming packets are dropped. An unsigned integer in the range | |
69978eb9 | 3759 | 0…4294967294. Defaults to unset and kernel's default is used.</para> |
a7476065 SS |
3760 | </listitem> |
3761 | </varlistentry> | |
ad8352f4 SS |
3762 | </variablelist> |
3763 | </refsect1> | |
3764 | ||
053a2ddb SS |
3765 | <refsect1> |
3766 | <title>[PFIFOHeadDrop] Section Options</title> | |
bdac5608 ZJS |
3767 | <para>The [PFIFOHeadDrop] section manages the queueing discipline (qdisc) of Packet First In First Out |
3768 | Head Drop (pfifo_head_drop).</para> | |
053a2ddb SS |
3769 | |
3770 | <variablelist class='network-directives'> | |
f344a492 YW |
3771 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3772 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
053a2ddb SS |
3773 | |
3774 | <varlistentry> | |
3775 | <term><varname>PacketLimit=</varname></term> | |
3776 | <listitem> | |
bdac5608 | 3777 | <para>As in [PFIFO] section.</para></listitem> |
053a2ddb SS |
3778 | </varlistentry> |
3779 | </variablelist> | |
3780 | </refsect1> | |
3781 | ||
1a95964b SS |
3782 | <refsect1> |
3783 | <title>[PFIFOFast] Section Options</title> | |
bdac5608 ZJS |
3784 | <para>The [PFIFOFast] section manages the queueing discipline (qdisc) of Packet First In First Out Fast |
3785 | (pfifo_fast).</para> | |
1a95964b SS |
3786 | |
3787 | <variablelist class='network-directives'> | |
f344a492 YW |
3788 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3789 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
1a95964b SS |
3790 | </variablelist> |
3791 | </refsect1> | |
3792 | ||
ad8352f4 SS |
3793 | <refsect1> |
3794 | <title>[CAKE] Section Options</title> | |
bdac5608 ZJS |
3795 | <para>The [CAKE] section manages the queueing discipline (qdisc) of Common Applications Kept Enhanced |
3796 | (CAKE).</para> | |
ad8352f4 SS |
3797 | |
3798 | <variablelist class='network-directives'> | |
f344a492 YW |
3799 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
3800 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
a7476065 | 3801 | |
ad8352f4 | 3802 | <varlistentry> |
ca2c3e92 | 3803 | <term><varname>Bandwidth=</varname></term> |
ad8352f4 | 3804 | <listitem> |
ca2c3e92 YW |
3805 | <para>Specifies the shaper bandwidth. When suffixed with K, M, or G, the specified size is |
3806 | parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of 1000. Defaults to | |
3807 | unset and kernel's default is used.</para> | |
ad8352f4 | 3808 | </listitem> |
f344a492 | 3809 | </varlistentry> |
ad8352f4 | 3810 | |
025cd94e YW |
3811 | <varlistentry> |
3812 | <term><varname>AutoRateIngress=</varname></term> | |
3813 | <listitem> | |
3814 | <para>Takes a boolean value. Enables automatic capacity estimation based on traffic arriving | |
3815 | at this qdisc. This is most likely to be useful with cellular links, which tend to change | |
3816 | quality randomly. If this setting is enabled, the <varname>Bandwidth=</varname> setting is | |
3817 | used as an initial estimate. Defaults to unset, and the kernel's default is used.</para> | |
3818 | </listitem> | |
3819 | </varlistentry> | |
3820 | ||
ad8352f4 | 3821 | <varlistentry> |
c03ef420 | 3822 | <term><varname>OverheadBytes=</varname></term> |
ad8352f4 | 3823 | <listitem> |
69978eb9 YW |
3824 | <para>Specifies that bytes to be addeded to the size of each packet. Bytes may be negative. |
3825 | Takes an integer in the range -64…256. Defaults to unset and kernel's default is used. | |
3826 | </para> | |
ad8352f4 | 3827 | </listitem> |
f344a492 | 3828 | </varlistentry> |
ad8352f4 SS |
3829 | |
3830 | <varlistentry> | |
863542e1 | 3831 | <term><varname>MPUBytes=</varname></term> |
ad8352f4 | 3832 | <listitem> |
863542e1 YW |
3833 | <para>Rounds each packet (including overhead) up to the specified bytes. Takes an integer in |
3834 | the range 1…256. Defaults to unset and kernel's default is used.</para> | |
3835 | </listitem> | |
3836 | </varlistentry> | |
3837 | ||
b6eccfda YW |
3838 | <varlistentry> |
3839 | <term><varname>CompensationMode=</varname></term> | |
3840 | <listitem> | |
3841 | <para>Takes one of <literal>none</literal>, <literal>atm</literal>, or <literal>ptm</literal>. | |
3842 | Specifies the compensation mode for overhead calculation. When <literal>none</literal>, no | |
3843 | compensation is taken into account. When <literal>atm</literal>, enables the compensation for | |
3844 | ATM cell framing, which is normally found on ADSL links. When <literal>ptm</literal>, enables | |
3845 | the compensation for PTM encoding, which is normally found on VDSL2 links and uses a 64b/65b | |
3846 | encoding scheme. Defaults to unset and the kernel's default is used.</para> | |
3847 | </listitem> | |
3848 | </varlistentry> | |
3849 | ||
1c7a81e6 YW |
3850 | <varlistentry> |
3851 | <term><varname>UseRawPacketSize=</varname></term> | |
3852 | <listitem> | |
3853 | <para>Takes a boolean value. When true, the packet size reported by the Linux kernel will be | |
3854 | used, instead of the underlying IP packet size. Defaults to unset, and the kernel's default | |
3855 | is used.</para> | |
3856 | </listitem> | |
3857 | </varlistentry> | |
3858 | ||
a049cf16 YW |
3859 | <varlistentry> |
3860 | <term><varname>FlowIsolationMode=</varname></term> | |
3861 | <listitem> | |
3862 | <para>CAKE places packets from different flows into different queues, then packets from each | |
3863 | queue are delivered fairly. This specifies whether the fairness is based on source address, | |
3864 | destination address, individual flows, or any combination of those. The available values are: | |
3865 | </para> | |
3866 | ||
3867 | <variablelist> | |
3868 | <varlistentry> | |
3869 | <term><option>none</option></term> | |
3870 | <listitem><para> | |
3871 | The flow isolation is disabled, and all traffic passes through a single queue. | |
3872 | </para></listitem> | |
3873 | </varlistentry> | |
3874 | <varlistentry> | |
3875 | <term><option>src-host</option></term> | |
3876 | <listitem><para> | |
2f7a0648 | 3877 | Flows are defined only by source address. Equivalent to the <literal>srchost</literal> |
a049cf16 YW |
3878 | option for <command>tc qdisc</command> command. See also |
3879 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3880 | </para></listitem> | |
3881 | </varlistentry> | |
3882 | <varlistentry> | |
3883 | <term><option>dst-host</option></term> | |
3884 | <listitem><para> | |
2f7a0648 | 3885 | Flows are defined only by destination address. Equivalent to the |
d68c797c | 3886 | <literal>dsthost</literal> option for <command>tc qdisc</command> command. See also |
a049cf16 YW |
3887 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. |
3888 | </para></listitem> | |
3889 | </varlistentry> | |
3890 | <varlistentry> | |
3891 | <term><option>hosts</option></term> | |
3892 | <listitem><para> | |
3893 | Flows are defined by source-destination host pairs. Equivalent to the same option for | |
3894 | <command>tc qdisc</command> command. See also | |
3895 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3896 | </para></listitem> | |
3897 | </varlistentry> | |
3898 | <varlistentry> | |
3899 | <term><option>flows</option></term> | |
3900 | <listitem><para> | |
3901 | Flows are defined by the entire 5-tuple of source address, destination address, | |
3902 | transport protocol, source port and destination port. Equivalent to the same option for | |
3903 | <command>tc qdisc</command> command. See also | |
3904 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3905 | </para></listitem> | |
3906 | </varlistentry> | |
3907 | <varlistentry> | |
3908 | <term><option>dual-src-host</option></term> | |
3909 | <listitem><para> | |
3910 | Flows are defined by the 5-tuple (see <literal>flows</literal> in the above), and | |
2f7a0648 | 3911 | fairness is applied first over source addresses, then over individual flows. Equivalent |
a049cf16 YW |
3912 | to the <literal>dual-srchost</literal> option for <command>tc qdisc</command> command. |
3913 | See also | |
3914 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3915 | </para></listitem> | |
3916 | </varlistentry> | |
3917 | <varlistentry> | |
3918 | <term><option>dual-dst-host</option></term> | |
3919 | <listitem><para> | |
3920 | Flows are defined by the 5-tuple (see <literal>flows</literal> in the above), and | |
3921 | fairness is applied first over destination addresses, then over individual flows. | |
2f7a0648 | 3922 | Equivalent to the <literal>dual-dsthost</literal> option for |
a049cf16 YW |
3923 | <command>tc qdisc</command> command. See also |
3924 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3925 | </para></listitem> | |
3926 | </varlistentry> | |
3927 | <varlistentry> | |
3928 | <term><option>triple</option></term> | |
3929 | <listitem><para> | |
3930 | Flows are defined by the 5-tuple (see <literal>flows</literal>), and fairness is | |
3931 | applied over source and destination addresses, and also over individual flows. | |
2f7a0648 | 3932 | Equivalent to the <literal>triple-isolate</literal> option for |
a049cf16 YW |
3933 | <command>tc qdisc</command> command. See also |
3934 | <citerefentry project='man-pages'><refentrytitle>tc-cake</refentrytitle><manvolnum>8</manvolnum></citerefentry>. | |
3935 | </para></listitem> | |
3936 | </varlistentry> | |
3937 | </variablelist> | |
3938 | ||
3939 | <para>Defaults to unset and the kernel's default is used.</para> | |
3940 | </listitem> | |
3941 | </varlistentry> | |
3942 | ||
4bff8086 YW |
3943 | <varlistentry> |
3944 | <term><varname>NAT=</varname></term> | |
3945 | <listitem> | |
3946 | <para>Takes a boolean value. When true, CAKE performs a NAT lookup before applying | |
3947 | flow-isolation rules, to determine the true addresses and port numbers of the packet, to | |
3948 | improve fairness between hosts inside the NAT. This has no practical effect when | |
3949 | <varname>FlowIsolationMode=</varname> is <literal>none</literal> or <literal>flows</literal>, | |
3950 | or if NAT is performed on a different host. Defaults to unset, and the kernel's default is | |
3951 | used.</para> | |
3952 | </listitem> | |
3953 | </varlistentry> | |
3954 | ||
fe8e156e YW |
3955 | <varlistentry> |
3956 | <term><varname>PriorityQueueingPreset=</varname></term> | |
3957 | <listitem> | |
3958 | <para>CAKE divides traffic into <literal>tins</literal>, and each tin has its own independent | |
3959 | set of flow-isolation queues, bandwidth threshold, and priority. This specifies the preset of | |
3960 | tin profiles. The available values are:</para> | |
3961 | ||
3962 | <variablelist> | |
3963 | <varlistentry> | |
3964 | <term><option>besteffort</option></term> | |
3965 | <listitem><para> | |
3966 | Disables priority queueing by placing all traffic in one tin. | |
3967 | </para></listitem> | |
3968 | </varlistentry> | |
3969 | <varlistentry> | |
3970 | <term><option>precedence</option></term> | |
3971 | <listitem><para> | |
3972 | Enables priority queueing based on the legacy interpretation of TOS | |
3973 | <literal>Precedence</literal> field. Use of this preset on the modern Internet is | |
3974 | firmly discouraged. | |
3975 | </para></listitem> | |
3976 | </varlistentry> | |
3977 | <varlistentry> | |
3978 | <term><option>diffserv8</option></term> | |
3979 | <listitem><para> | |
3980 | Enables priority queueing based on the Differentiated Service | |
3981 | (<literal>DiffServ</literal>) field with eight tins: Background Traffic, High | |
3982 | Throughput, Best Effort, Video Streaming, Low Latency Transactions, Interactive Shell, | |
3983 | Minimum Latency, and Network Control. | |
3984 | </para></listitem> | |
3985 | </varlistentry> | |
3986 | <varlistentry> | |
3987 | <term><option>diffserv4</option></term> | |
3988 | <listitem><para> | |
3989 | Enables priority queueing based on the Differentiated Service | |
3990 | (<literal>DiffServ</literal>) field with four tins: Background Traffic, Best Effort, | |
3991 | Streaming Media, and Latency Sensitive. | |
3992 | </para></listitem> | |
3993 | </varlistentry> | |
3994 | <varlistentry> | |
3995 | <term><option>diffserv3</option></term> | |
3996 | <listitem><para> | |
3997 | Enables priority queueing based on the Differentiated Service | |
3998 | (<literal>DiffServ</literal>) field with three tins: Background Traffic, Best Effort, | |
3999 | and Latency Sensitive. | |
4000 | </para></listitem> | |
4001 | </varlistentry> | |
4002 | </variablelist> | |
4003 | ||
4004 | <para>Defaults to unset, and the kernel's default is used.</para> | |
ad8352f4 SS |
4005 | </listitem> |
4006 | </varlistentry> | |
fe8e156e | 4007 | |
049b66cc YW |
4008 | <varlistentry> |
4009 | <term><varname>FirewallMark=</varname></term> | |
4010 | <listitem> | |
4011 | <para>Takes an integer in the range 1…4294967295. When specified, firewall-mark-based | |
4012 | overriding of CAKE's tin selection is enabled. Defaults to unset, and the kernel's default is | |
4013 | used.</para> | |
4014 | </listitem> | |
4015 | </varlistentry> | |
4016 | ||
d05dce95 YW |
4017 | <varlistentry> |
4018 | <term><varname>Wash=</varname></term> | |
4019 | <listitem> | |
4020 | <para>Takes a boolean value. When true, CAKE clears the DSCP fields, except for ECN bits, of | |
4021 | any packet passing through CAKE. Defaults to unset, and the kernel's default is used.</para> | |
4022 | </listitem> | |
4023 | </varlistentry> | |
4024 | ||
35896db4 YW |
4025 | <varlistentry> |
4026 | <term><varname>SplitGSO=</varname></term> | |
4027 | <listitem> | |
4028 | <para>Takes a boolean value. When true, CAKE will split General Segmentation Offload (GSO) | |
4029 | super-packets into their on-the-wire components and dequeue them individually. Defaults to | |
4030 | unset, and the kernel's default is used.</para> | |
4031 | </listitem> | |
4032 | </varlistentry> | |
4033 | ||
3af9cd0b YW |
4034 | <varlistentry> |
4035 | <term><varname>RTTSec=</varname></term> | |
4036 | <listitem> | |
4037 | <para>Specifies the RTT for the filter. Takes a timespan. Typical values are e.g. 100us for | |
4038 | extremely high-performance 10GigE+ networks like datacentre, 1ms for non-WiFi LAN connections, | |
4039 | 100ms for typical internet connections. Defaults to unset, and the kernel's default will be used. | |
4040 | </para> | |
4041 | </listitem> | |
4042 | </varlistentry> | |
4043 | ||
8c920636 YW |
4044 | <varlistentry> |
4045 | <term><varname>AckFilter=</varname></term> | |
4046 | <listitem> | |
4047 | <para>Takes a boolean value, or special value <literal>aggressive</literal>. If enabled, ACKs in | |
4048 | each flow are queued and redundant ACKs to the upstream are dropped. If yes, the filter will always | |
4049 | keep at least two redundant ACKs in the queue, while in <literal>aggressive</literal> mode, it will | |
4050 | filter down to a single ACK. This may improve download throughput on links with very asymmetrical | |
4051 | rate limits. Defaults to unset, and the kernel's default will be used.</para> | |
4052 | </listitem> | |
4053 | </varlistentry> | |
4054 | ||
a7476065 SS |
4055 | </variablelist> |
4056 | </refsect1> | |
4057 | ||
18de0969 YW |
4058 | <refsect1> |
4059 | <title>[ControlledDelay] Section Options</title> | |
bdac5608 | 4060 | <para>The [ControlledDelay] section manages the queueing discipline (qdisc) of |
18de0969 | 4061 | controlled delay (CoDel).</para> |
9942b710 | 4062 | |
18de0969 | 4063 | <variablelist class='network-directives'> |
f344a492 YW |
4064 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4065 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 4066 | |
18de0969 YW |
4067 | <varlistentry> |
4068 | <term><varname>PacketLimit=</varname></term> | |
a9a5d632 | 4069 | <listitem> |
e9dd6984 | 4070 | <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, |
69978eb9 | 4071 | incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and |
e9dd6984 | 4072 | kernel's default is used.</para> |
a9a5d632 SS |
4073 | </listitem> |
4074 | </varlistentry> | |
4075 | ||
b078e528 | 4076 | <varlistentry> |
18de0969 | 4077 | <term><varname>TargetSec=</varname></term> |
b078e528 YW |
4078 | <listitem> |
4079 | <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay. | |
4080 | Defaults to unset and kernel's default is used.</para> | |
4081 | </listitem> | |
4082 | </varlistentry> | |
4083 | ||
4084 | <varlistentry> | |
18de0969 | 4085 | <term><varname>IntervalSec=</varname></term> |
b078e528 YW |
4086 | <listitem> |
4087 | <para>Takes a timespan. This is used to ensure that the measured minimum delay does not | |
4088 | become too stale. Defaults to unset and kernel's default is used.</para> | |
4089 | </listitem> | |
4090 | </varlistentry> | |
4091 | ||
4092 | <varlistentry> | |
18de0969 | 4093 | <term><varname>ECN=</varname></term> |
b078e528 YW |
4094 | <listitem> |
4095 | <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to | |
4096 | unset and kernel's default is used.</para> | |
4097 | </listitem> | |
4098 | </varlistentry> | |
4099 | ||
4100 | <varlistentry> | |
18de0969 | 4101 | <term><varname>CEThresholdSec=</varname></term> |
b078e528 YW |
4102 | <listitem> |
4103 | <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN | |
4104 | Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> | |
4105 | </listitem> | |
4106 | </varlistentry> | |
18de0969 YW |
4107 | </variablelist> |
4108 | </refsect1> | |
b078e528 | 4109 | |
f5fc0441 SS |
4110 | <refsect1> |
4111 | <title>[DeficitRoundRobinScheduler] Section Options</title> | |
bdac5608 ZJS |
4112 | <para>The [DeficitRoundRobinScheduler] section manages the queueing discipline (qdisc) of Deficit Round |
4113 | Robin Scheduler (DRR).</para> | |
f5fc0441 SS |
4114 | |
4115 | <variablelist class='network-directives'> | |
f344a492 YW |
4116 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4117 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
f5fc0441 SS |
4118 | </variablelist> |
4119 | </refsect1> | |
4120 | ||
ad365c5d YW |
4121 | <refsect1> |
4122 | <title>[DeficitRoundRobinSchedulerClass] Section Options</title> | |
bdac5608 ZJS |
4123 | <para>The [DeficitRoundRobinSchedulerClass] section manages the traffic control class of Deficit Round |
4124 | Robin Scheduler (DRR).</para> | |
ad365c5d YW |
4125 | |
4126 | <variablelist class='network-directives'> | |
f344a492 YW |
4127 | <xi:include href="tc.xml" xpointer="tclass-parent" /> |
4128 | <xi:include href="tc.xml" xpointer="tclass-classid" /> | |
ad365c5d YW |
4129 | |
4130 | <varlistentry> | |
c03ef420 | 4131 | <term><varname>QuantumBytes=</varname></term> |
ad365c5d | 4132 | <listitem> |
c03ef420 YW |
4133 | <para>Specifies the amount of bytes a flow is allowed to dequeue before the scheduler moves |
4134 | to the next class. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, | |
4135 | Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to the MTU of the | |
4136 | interface.</para> | |
ad365c5d YW |
4137 | </listitem> |
4138 | </varlistentry> | |
4139 | ||
4140 | </variablelist> | |
4141 | </refsect1> | |
4142 | ||
d474aa51 YW |
4143 | <refsect1> |
4144 | <title>[EnhancedTransmissionSelection] Section Options</title> | |
bdac5608 ZJS |
4145 | <para>The [EnhancedTransmissionSelection] section manages the queueing discipline (qdisc) of Enhanced |
4146 | Transmission Selection (ETS).</para> | |
d474aa51 YW |
4147 | |
4148 | <variablelist class='network-directives'> | |
4149 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> | |
4150 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
4151 | ||
4152 | <varlistentry> | |
4153 | <term><varname>Bands=</varname></term> | |
4154 | <listitem> | |
69978eb9 | 4155 | <para>Specifies the number of bands. An unsigned integer in the range 1…16. This value has to be at |
e9dd6984 ZJS |
4156 | least large enough to cover the strict bands specified through the <varname>StrictBands=</varname> |
4157 | and bandwidth-sharing bands specified in <varname>QuantumBytes=</varname>.</para> | |
d474aa51 YW |
4158 | </listitem> |
4159 | </varlistentry> | |
4160 | ||
4161 | <varlistentry> | |
4162 | <term><varname>StrictBands=</varname></term> | |
4163 | <listitem> | |
e9dd6984 | 4164 | <para>Specifies the number of bands that should be created in strict mode. An unsigned integer in |
69978eb9 | 4165 | the range 1…16.</para> |
d474aa51 YW |
4166 | </listitem> |
4167 | </varlistentry> | |
4168 | ||
4169 | <varlistentry> | |
4170 | <term><varname>QuantumBytes=</varname></term> | |
4171 | <listitem> | |
4172 | <para>Specifies the white-space separated list of quantum used in band-sharing bands. When | |
4173 | suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, | |
4174 | respectively, to the base of 1024. This setting can be specified multiple times. If an empty | |
4175 | string is assigned, then the all previous assignments are cleared.</para> | |
4176 | </listitem> | |
4177 | </varlistentry> | |
4178 | ||
4179 | <varlistentry> | |
4180 | <term><varname>PriorityMap=</varname></term> | |
4181 | <listitem> | |
885a4e6c ZJS |
4182 | <para>The priority map maps the priority of a packet to a band. The argument is a whitespace |
4183 | separated list of numbers. The first number indicates which band the packets with priority 0 should | |
4184 | be put to, the second is for priority 1, and so on. There can be up to 16 numbers in the list. If | |
4185 | there are fewer, the default band that traffic with one of the unmentioned priorities goes to is | |
1d3a473b | 4186 | the last one. Each band number must be in the range 0…255. This setting can be specified multiple |
885a4e6c | 4187 | times. If an empty string is assigned, then the all previous assignments are cleared.</para> |
d474aa51 YW |
4188 | </listitem> |
4189 | </varlistentry> | |
4190 | </variablelist> | |
4191 | </refsect1> | |
4192 | ||
609e8340 SS |
4193 | <refsect1> |
4194 | <title>[GenericRandomEarlyDetection] Section Options</title> | |
bdac5608 ZJS |
4195 | <para>The [GenericRandomEarlyDetection] section manages the queueing discipline (qdisc) of Generic Random |
4196 | Early Detection (GRED).</para> | |
609e8340 SS |
4197 | |
4198 | <variablelist class='network-directives'> | |
f344a492 YW |
4199 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4200 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
609e8340 SS |
4201 | |
4202 | <varlistentry> | |
4203 | <term><varname>VirtualQueues=</varname></term> | |
4204 | <listitem> | |
387f6955 | 4205 | <para>Specifies the number of virtual queues. Takes an integer in the range 1…16. Defaults to unset |
1d3a473b | 4206 | and kernel's default is used.</para> |
609e8340 SS |
4207 | </listitem> |
4208 | </varlistentry> | |
4209 | ||
4210 | <varlistentry> | |
4211 | <term><varname>DefaultVirtualQueue=</varname></term> | |
4212 | <listitem> | |
4213 | <para>Specifies the number of default virtual queue. This must be less than <varname>VirtualQueue=</varname>. | |
4214 | Defaults to unset and kernel's default is used.</para> | |
4215 | </listitem> | |
4216 | </varlistentry> | |
4217 | ||
4218 | <varlistentry> | |
4219 | <term><varname>GenericRIO=</varname></term> | |
4220 | <listitem> | |
4221 | <para>Takes a boolean. It turns on the RIO-like buffering scheme. Defaults to | |
4222 | unset and kernel's default is used.</para> | |
4223 | </listitem> | |
4224 | </varlistentry> | |
4225 | </variablelist> | |
4226 | </refsect1> | |
4227 | ||
18de0969 YW |
4228 | <refsect1> |
4229 | <title>[FairQueueingControlledDelay] Section Options</title> | |
bdac5608 ZJS |
4230 | <para>The [FairQueueingControlledDelay] section manages the queueing discipline (qdisc) of fair queuing |
4231 | controlled delay (FQ-CoDel).</para> | |
18de0969 YW |
4232 | |
4233 | <variablelist class='network-directives'> | |
f344a492 YW |
4234 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4235 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 4236 | |
18de0969 YW |
4237 | <varlistentry> |
4238 | <term><varname>PacketLimit=</varname></term> | |
4e5ef149 SS |
4239 | <listitem> |
4240 | <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are | |
4241 | dropped. Defaults to unset and kernel's default is used.</para> | |
4242 | </listitem> | |
4243 | </varlistentry> | |
4244 | ||
ac810b75 | 4245 | <varlistentry> |
c03ef420 | 4246 | <term><varname>MemoryLimitBytes=</varname></term> |
ac810b75 YW |
4247 | <listitem> |
4248 | <para>Specifies the limit on the total number of bytes that can be queued in this FQ-CoDel instance. | |
4249 | When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, | |
4250 | respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para> | |
4251 | </listitem> | |
4252 | </varlistentry> | |
4253 | ||
4254 | <varlistentry> | |
18de0969 | 4255 | <term><varname>Flows=</varname></term> |
ac810b75 YW |
4256 | <listitem> |
4257 | <para>Specifies the number of flows into which the incoming packets are classified. | |
4258 | Defaults to unset and kernel's default is used.</para> | |
4259 | </listitem> | |
4260 | </varlistentry> | |
4261 | ||
4262 | <varlistentry> | |
18de0969 | 4263 | <term><varname>TargetSec=</varname></term> |
ac810b75 YW |
4264 | <listitem> |
4265 | <para>Takes a timespan. Specifies the acceptable minimum standing/persistent queue delay. | |
4266 | Defaults to unset and kernel's default is used.</para> | |
4267 | </listitem> | |
4268 | </varlistentry> | |
4269 | ||
4270 | <varlistentry> | |
18de0969 | 4271 | <term><varname>IntervalSec=</varname></term> |
ac810b75 YW |
4272 | <listitem> |
4273 | <para>Takes a timespan. This is used to ensure that the measured minimum delay does not | |
4274 | become too stale. Defaults to unset and kernel's default is used.</para> | |
4275 | </listitem> | |
4276 | </varlistentry> | |
4277 | ||
4278 | <varlistentry> | |
c03ef420 | 4279 | <term><varname>QuantumBytes=</varname></term> |
ac810b75 | 4280 | <listitem> |
e9dd6984 | 4281 | <para>Specifies the number of bytes used as the "deficit" in the fair queuing algorithm timespan. |
ac810b75 YW |
4282 | When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, |
4283 | respectively, to the base of 1024. Defaults to unset and kernel's default is used.</para> | |
4284 | </listitem> | |
4285 | </varlistentry> | |
4286 | ||
4287 | <varlistentry> | |
18de0969 | 4288 | <term><varname>ECN=</varname></term> |
ac810b75 YW |
4289 | <listitem> |
4290 | <para>Takes a boolean. This can be used to mark packets instead of dropping them. Defaults to | |
4291 | unset and kernel's default is used.</para> | |
4292 | </listitem> | |
4293 | </varlistentry> | |
4294 | ||
4295 | <varlistentry> | |
18de0969 | 4296 | <term><varname>CEThresholdSec=</varname></term> |
ac810b75 YW |
4297 | <listitem> |
4298 | <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN | |
4299 | Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> | |
4300 | </listitem> | |
4301 | </varlistentry> | |
18de0969 YW |
4302 | </variablelist> |
4303 | </refsect1> | |
4304 | ||
4305 | <refsect1> | |
ca58d00c | 4306 | <title>[FairQueueing] Section Options</title> |
bdac5608 ZJS |
4307 | <para>The [FairQueueing] section manages the queueing discipline (qdisc) of fair queue traffic policing |
4308 | (FQ).</para> | |
18de0969 YW |
4309 | |
4310 | <variablelist class='network-directives'> | |
f344a492 YW |
4311 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4312 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 4313 | |
7234b915 | 4314 | <varlistentry> |
18de0969 | 4315 | <term><varname>PacketLimit=</varname></term> |
7234b915 SS |
4316 | <listitem> |
4317 | <para>Specifies the hard limit on the real queue size. When this limit is reached, incoming packets are | |
4318 | dropped. Defaults to unset and kernel's default is used.</para> | |
4319 | </listitem> | |
4320 | </varlistentry> | |
4321 | ||
e83562e5 | 4322 | <varlistentry> |
18de0969 | 4323 | <term><varname>FlowLimit=</varname></term> |
e83562e5 YW |
4324 | <listitem> |
4325 | <para>Specifies the hard limit on the maximum number of packets queued per flow. Defaults to | |
4326 | unset and kernel's default is used.</para> | |
4327 | </listitem> | |
4328 | </varlistentry> | |
4329 | ||
4330 | <varlistentry> | |
c03ef420 | 4331 | <term><varname>QuantumBytes=</varname></term> |
e83562e5 YW |
4332 | <listitem> |
4333 | <para>Specifies the credit per dequeue RR round, i.e. the amount of bytes a flow is allowed | |
4334 | to dequeue at once. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, | |
4335 | Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and kernel's | |
4336 | default is used.</para> | |
4337 | </listitem> | |
4338 | </varlistentry> | |
4339 | ||
4340 | <varlistentry> | |
c03ef420 | 4341 | <term><varname>InitialQuantumBytes=</varname></term> |
e83562e5 YW |
4342 | <listitem> |
4343 | <para>Specifies the initial sending rate credit, i.e. the amount of bytes a new flow is | |
4344 | allowed to dequeue initially. When suffixed with K, M, or G, the specified size is parsed as | |
4345 | Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024. Defaults to unset and | |
4346 | kernel's default is used.</para> | |
4347 | </listitem> | |
4348 | </varlistentry> | |
4349 | ||
4350 | <varlistentry> | |
18de0969 | 4351 | <term><varname>MaximumRate=</varname></term> |
e83562e5 YW |
4352 | <listitem> |
4353 | <para>Specifies the maximum sending rate of a flow. When suffixed with K, M, or G, the | |
6b8fe4c3 | 4354 | specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, to the base of |
e83562e5 YW |
4355 | 1000. Defaults to unset and kernel's default is used.</para> |
4356 | </listitem> | |
4357 | </varlistentry> | |
4358 | ||
4359 | <varlistentry> | |
18de0969 | 4360 | <term><varname>Buckets=</varname></term> |
e83562e5 YW |
4361 | <listitem> |
4362 | <para>Specifies the size of the hash table used for flow lookups. Defaults to unset and | |
4363 | kernel's default is used.</para> | |
4364 | </listitem> | |
4365 | </varlistentry> | |
4366 | ||
4367 | <varlistentry> | |
18de0969 | 4368 | <term><varname>OrphanMask=</varname></term> |
e83562e5 YW |
4369 | <listitem> |
4370 | <para>Takes an unsigned integer. For packets not owned by a socket, fq is able to mask a part | |
4371 | of hash and reduce number of buckets associated with the traffic. Defaults to unset and | |
4372 | kernel's default is used.</para> | |
4373 | </listitem> | |
4374 | </varlistentry> | |
4375 | ||
4376 | <varlistentry> | |
18de0969 | 4377 | <term><varname>Pacing=</varname></term> |
e83562e5 YW |
4378 | <listitem> |
4379 | <para>Takes a boolean, and enables or disables flow pacing. Defaults to unset and kernel's | |
4380 | default is used.</para> | |
4381 | </listitem> | |
4382 | </varlistentry> | |
4383 | ||
4384 | <varlistentry> | |
18de0969 | 4385 | <term><varname>CEThresholdSec=</varname></term> |
e83562e5 YW |
4386 | <listitem> |
4387 | <para>Takes a timespan. This sets a threshold above which all packets are marked with ECN | |
4388 | Congestion Experienced (CE). Defaults to unset and kernel's default is used.</para> | |
4389 | </listitem> | |
4390 | </varlistentry> | |
0f5bd7fe SS |
4391 | </variablelist> |
4392 | </refsect1> | |
4393 | ||
9b749c11 YW |
4394 | <refsect1> |
4395 | <title>[TrivialLinkEqualizer] Section Options</title> | |
bdac5608 ZJS |
4396 | <para>The [TrivialLinkEqualizer] section manages the queueing discipline (qdisc) of trivial link |
4397 | equalizer (teql).</para> | |
9b749c11 YW |
4398 | |
4399 | <variablelist class='network-directives'> | |
f344a492 YW |
4400 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4401 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
d8b2396d | 4402 | |
9b749c11 YW |
4403 | <varlistentry> |
4404 | <term><varname>Id=</varname></term> | |
4405 | <listitem> | |
4406 | <para>Specifies the interface ID <literal>N</literal> of teql. Defaults to <literal>0</literal>. | |
4407 | Note that when teql is used, currently, the module <constant>sch_teql</constant> with | |
4408 | <constant>max_equalizers=N+1</constant> option must be loaded before | |
4409 | <command>systemd-networkd</command> is started.</para> | |
4410 | </listitem> | |
4411 | </varlistentry> | |
4412 | </variablelist> | |
4413 | </refsect1> | |
4414 | ||
b934ac3d YW |
4415 | <refsect1> |
4416 | <title>[HierarchyTokenBucket] Section Options</title> | |
bdac5608 ZJS |
4417 | <para>The [HierarchyTokenBucket] section manages the queueing discipline (qdisc) of hierarchy token |
4418 | bucket (htb).</para> | |
b934ac3d YW |
4419 | |
4420 | <variablelist class='network-directives'> | |
f344a492 YW |
4421 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4422 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
b934ac3d YW |
4423 | |
4424 | <varlistentry> | |
4425 | <term><varname>DefaultClass=</varname></term> | |
4426 | <listitem> | |
4427 | <para>Takes the minor id in hexadecimal of the default class. Unclassified traffic gets sent | |
4428 | to the class. Defaults to unset.</para> | |
4429 | </listitem> | |
4430 | </varlistentry> | |
d9eacc1c YW |
4431 | |
4432 | <varlistentry> | |
4433 | <term><varname>RateToQuantum=</varname></term> | |
4434 | <listitem> | |
4435 | <para>Takes an unsigned integer. The DRR quantums are calculated by dividing the value | |
4436 | configured in <varname>Rate=</varname> by <varname>RateToQuantum=</varname>.</para> | |
4437 | </listitem> | |
4438 | </varlistentry> | |
b934ac3d YW |
4439 | </variablelist> |
4440 | </refsect1> | |
4441 | ||
19f86a63 YW |
4442 | <refsect1> |
4443 | <title>[HierarchyTokenBucketClass] Section Options</title> | |
bdac5608 ZJS |
4444 | <para>The [HierarchyTokenBucketClass] section manages the traffic control class of hierarchy token bucket |
4445 | (htb).</para> | |
19f86a63 YW |
4446 | |
4447 | <variablelist class='network-directives'> | |
f344a492 YW |
4448 | <xi:include href="tc.xml" xpointer="tclass-parent" /> |
4449 | <xi:include href="tc.xml" xpointer="tclass-classid" /> | |
19f86a63 YW |
4450 | |
4451 | <varlistentry> | |
4452 | <term><varname>Priority=</varname></term> | |
4453 | <listitem> | |
4454 | <para>Specifies the priority of the class. In the round-robin process, classes with the lowest | |
d9eacc1c YW |
4455 | priority field are tried for packets first.</para> |
4456 | </listitem> | |
4457 | </varlistentry> | |
4458 | ||
4459 | <varlistentry> | |
4460 | <term><varname>QuantumBytes=</varname></term> | |
4461 | <listitem> | |
4462 | <para>Specifies how many bytes to serve from leaf at once. When suffixed with K, M, or G, the | |
4463 | specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of | |
4464 | 1024.</para> | |
4465 | </listitem> | |
4466 | </varlistentry> | |
4467 | ||
4468 | <varlistentry> | |
4469 | <term><varname>MTUBytes=</varname></term> | |
4470 | <listitem> | |
4471 | <para>Specifies the maximum packet size we create. When suffixed with K, M, or G, the specified | |
4472 | size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of 1024.</para> | |
4473 | </listitem> | |
4474 | </varlistentry> | |
4475 | ||
4476 | <varlistentry> | |
4477 | <term><varname>OverheadBytes=</varname></term> | |
4478 | <listitem> | |
4479 | <para>Takes an unsigned integer which specifies per-packet size overhead used in rate | |
4480 | computations. When suffixed with K, M, or G, the specified size is parsed as Kilobytes, | |
4481 | Megabytes, or Gigabytes, respectively, to the base of 1024.</para> | |
19f86a63 YW |
4482 | </listitem> |
4483 | </varlistentry> | |
4484 | ||
4485 | <varlistentry> | |
4486 | <term><varname>Rate=</varname></term> | |
4487 | <listitem> | |
4488 | <para>Specifies the maximum rate this class and all its children are guaranteed. When suffixed | |
4489 | with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits, respectively, | |
4490 | to the base of 1000. This setting is mandatory.</para> | |
4491 | </listitem> | |
4492 | </varlistentry> | |
4493 | ||
4494 | <varlistentry> | |
4495 | <term><varname>CeilRate=</varname></term> | |
4496 | <listitem> | |
4497 | <para>Specifies the maximum rate at which a class can send, if its parent has bandwidth to spare. | |
4498 | When suffixed with K, M, or G, the specified size is parsed as Kilobits, Megabits, or Gigabits, | |
4499 | respectively, to the base of 1000. When unset, the value specified with <varname>Rate=</varname> | |
4500 | is used.</para> | |
4501 | </listitem> | |
4502 | </varlistentry> | |
d9eacc1c YW |
4503 | |
4504 | <varlistentry> | |
4505 | <term><varname>BufferBytes=</varname></term> | |
4506 | <listitem> | |
4507 | <para>Specifies the maximum bytes burst which can be accumulated during idle period. When suffixed | |
4508 | with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, | |
4509 | to the base of 1024.</para> | |
4510 | </listitem> | |
4511 | </varlistentry> | |
4512 | ||
4513 | <varlistentry> | |
4514 | <term><varname>CeilBufferBytes=</varname></term> | |
4515 | <listitem> | |
4516 | <para>Specifies the maximum bytes burst for ceil which can be accumulated during idle period. | |
4517 | When suffixed with K, M, or G, the specified size is parsed as Kilobytes, Megabytes, or Gigabytes, | |
4518 | respectively, to the base of 1024.</para> | |
4519 | </listitem> | |
4520 | </varlistentry> | |
7f224020 SS |
4521 | </variablelist> |
4522 | </refsect1> | |
4523 | ||
4524 | <refsect1> | |
4525 | <title>[HeavyHitterFilter] Section Options</title> | |
bdac5608 ZJS |
4526 | <para>The [HeavyHitterFilter] section manages the queueing discipline (qdisc) of Heavy Hitter Filter |
4527 | (hhf).</para> | |
7f224020 SS |
4528 | |
4529 | <variablelist class='network-directives'> | |
f344a492 YW |
4530 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> |
4531 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
19f86a63 | 4532 | |
7f224020 SS |
4533 | <varlistentry> |
4534 | <term><varname>PacketLimit=</varname></term> | |
4535 | <listitem> | |
e9dd6984 | 4536 | <para>Specifies the hard limit on the queue size in number of packets. When this limit is reached, |
69978eb9 | 4537 | incoming packets are dropped. An unsigned integer in the range 0…4294967294. Defaults to unset and |
e9dd6984 | 4538 | kernel's default is used.</para> |
7f224020 SS |
4539 | </listitem> |
4540 | </varlistentry> | |
19f86a63 YW |
4541 | </variablelist> |
4542 | </refsect1> | |
4543 | ||
b12aaee5 SS |
4544 | <refsect1> |
4545 | <title>[QuickFairQueueing] Section Options</title> | |
bdac5608 ZJS |
4546 | <para>The [QuickFairQueueing] section manages the queueing discipline (qdisc) of Quick Fair Queueing |
4547 | (QFQ).</para> | |
b12aaee5 SS |
4548 | |
4549 | <variablelist class='network-directives'> | |
4550 | <xi:include href="tc.xml" xpointer="qdisc-parent" /> | |
4551 | <xi:include href="tc.xml" xpointer="qdisc-handle" /> | |
4552 | </variablelist> | |
4553 | </refsect1> | |
4554 | ||
4d7ddaf9 YW |
4555 | <refsect1> |
4556 | <title>[QuickFairQueueingClass] Section Options</title> | |
bdac5608 ZJS |
4557 | <para>The [QuickFairQueueingClass] section manages the traffic control class of Quick Fair Queueing |
4558 | (qfq).</para> | |
4d7ddaf9 YW |
4559 | |
4560 | <variablelist class='network-directives'> | |
4561 | <xi:include href="tc.xml" xpointer="tclass-parent" /> | |
4562 | <xi:include href="tc.xml" xpointer="tclass-classid" /> | |
4563 | ||
4564 | <varlistentry> | |
4565 | <term><varname>Weight=</varname></term> | |
4566 | <listitem> | |
1d3a473b | 4567 | <para>Specifies the weight of the class. Takes an integer in the range 1…1023. Defaults to |
4d7ddaf9 YW |
4568 | unset in which case the kernel default is used.</para> |
4569 | </listitem> | |
4570 | </varlistentry> | |
4571 | ||
4572 | <varlistentry> | |
c03ef420 | 4573 | <term><varname>MaxPacketBytes=</varname></term> |
4d7ddaf9 | 4574 | <listitem> |
75909cc7 ZJS |
4575 | <para>Specifies the maximum packet size in bytes for the class. When suffixed with K, M, or G, the |
4576 | specified size is parsed as Kilobytes, Megabytes, or Gigabytes, respectively, to the base of | |
4577 | 1024. When unset, the kernel default is used.</para> | |
4d7ddaf9 YW |
4578 | </listitem> |
4579 | </varlistentry> | |
4580 | </variablelist> | |
4581 | </refsect1> | |
4582 | ||
13b498f9 TJ |
4583 | <refsect1> |
4584 | <title>[BridgeVLAN] Section Options</title> | |
bdac5608 ZJS |
4585 | <para>The [BridgeVLAN] section manages the VLAN ID configuration of a bridge port and accepts the |
4586 | following keys. Specify several [BridgeVLAN] sections to configure several VLAN entries. The | |
4587 | <varname>VLANFiltering=</varname> option has to be enabled, see the [Bridge] section in | |
13b498f9 TJ |
4588 | <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>.</para> |
4589 | ||
4590 | <variablelist class='network-directives'> | |
4591 | <varlistentry> | |
4592 | <term><varname>VLAN=</varname></term> | |
4593 | <listitem> | |
69978eb9 YW |
4594 | <para>The VLAN ID allowed on the port. This can be either a single ID or a range M-N. Takes |
4595 | an integer in the range 1…4094.</para> | |
13b498f9 TJ |
4596 | </listitem> |
4597 | </varlistentry> | |
4598 | <varlistentry> | |
4599 | <term><varname>EgressUntagged=</varname></term> | |
4600 | <listitem> | |
4601 | <para>The VLAN ID specified here will be used to untag frames on egress. Configuring | |
4602 | <varname>EgressUntagged=</varname> implicates the use of <varname>VLAN=</varname> above and will enable the | |
4603 | VLAN ID for ingress as well. This can be either a single ID or a range M-N.</para> | |
4604 | </listitem> | |
4605 | </varlistentry> | |
4606 | <varlistentry> | |
4607 | <term><varname>PVID=</varname></term> | |
4608 | <listitem> | |
4609 | <para>The Port VLAN ID specified here is assigned to all untagged frames at ingress. | |
4610 | <varname>PVID=</varname> can be used only once. Configuring <varname>PVID=</varname> implicates the use of | |
4611 | <varname>VLAN=</varname> above and will enable the VLAN ID for ingress as well.</para> | |
4612 | </listitem> | |
4613 | </varlistentry> | |
4614 | </variablelist> | |
4615 | </refsect1> | |
798d3a52 ZJS |
4616 | |
4617 | <refsect1> | |
9e35b3de | 4618 | <title>Examples</title> |
798d3a52 | 4619 | <example> |
9e35b3de | 4620 | <title>Static network configuration</title> |
798d3a52 | 4621 | |
9e35b3de ZJS |
4622 | <programlisting># /etc/systemd/network/50-static.network |
4623 | [Match] | |
eac684ef TG |
4624 | Name=enp2s0 |
4625 | ||
4626 | [Network] | |
4627 | Address=192.168.0.15/24 | |
4628 | Gateway=192.168.0.1</programlisting> | |
9e35b3de ZJS |
4629 | |
4630 | <para>This brings interface <literal>enp2s0</literal> up with a static address. The | |
4631 | specified gateway will be used for a default route.</para> | |
798d3a52 | 4632 | </example> |
eac684ef | 4633 | |
798d3a52 | 4634 | <example> |
9e35b3de | 4635 | <title>DHCP on ethernet links</title> |
eac684ef | 4636 | |
9e35b3de ZJS |
4637 | <programlisting># /etc/systemd/network/80-dhcp.network |
4638 | [Match] | |
eac684ef TG |
4639 | Name=en* |
4640 | ||
4641 | [Network] | |
9c8ca3f7 | 4642 | DHCP=yes</programlisting> |
9e35b3de ZJS |
4643 | |
4644 | <para>This will enable DHCPv4 and DHCPv6 on all interfaces with names starting with | |
4645 | <literal>en</literal> (i.e. ethernet interfaces).</para> | |
798d3a52 | 4646 | </example> |
eac684ef | 4647 | |
4c94a4c2 | 4648 | <example> |
d4579825 | 4649 | <title>IPv6 Prefix Delegation (DHCPv6 PD)</title> |
4c94a4c2 | 4650 | |
d4579825 | 4651 | <programlisting># /etc/systemd/network/55-dhcpv6-pd-upstream.network |
4c94a4c2 | 4652 | [Match] |
4653 | Name=enp1s0 | |
4654 | ||
4655 | [Network] | |
d4579825 | 4656 | DHCP=ipv6 |
4c94a4c2 | 4657 | |
d4579825 YW |
4658 | # The below setting is optional, to also assign an address in the delegated prefix |
4659 | # to the upstream interface. If not necessary, then comment out the line below and | |
4660 | # the [DHCPPrefixDelegation] section. | |
4661 | DHCPPrefixDelegation=yes | |
4662 | ||
4663 | # If the upstream network provides Router Advertisement with Managed bit set, | |
4664 | # then comment out the line below and WithoutRA= setting in the [DHCPv6] section. | |
4665 | IPv6AcceptRA=no | |
4666 | ||
4667 | [DHCPv6] | |
4668 | WithoutRA=solicit | |
4669 | ||
4670 | [DHCPPrefixDelegation] | |
4671 | UplinkInterface=:self | |
4672 | SubnetId=0 | |
4673 | Announce=no</programlisting> | |
4674 | ||
4675 | <programlisting># /etc/systemd/network/55-dhcpv6-pd-downstream.network | |
4c94a4c2 | 4676 | [Match] |
4677 | Name=enp2s0 | |
4678 | ||
4679 | [Network] | |
d4579825 | 4680 | DHCPPrefixDelegation=yes |
e5ff2245 | 4681 | IPv6SendRA=yes |
d4579825 YW |
4682 | |
4683 | # It is expected that the host is acting as a router. So, usually it is not | |
4684 | # necessary to receive Router Advertisement from other hosts in the downstream network. | |
4685 | IPv6AcceptRA=no | |
4686 | ||
4687 | [DHCPPrefixDelegation] | |
4688 | UplinkInterface=enp1s0 | |
4689 | SubnetId=1 | |
4690 | Announce=yes</programlisting> | |
4c94a4c2 | 4691 | |
e5ff2245 YW |
4692 | <para>This will enable DHCPv6-PD on the interface enp1s0 as an upstream interface where the |
4693 | DHCPv6 client is running and enp2s0 as a downstream interface where the prefix is delegated to. | |
4694 | The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network. | |
4695 | </para> | |
4c94a4c2 | 4696 | </example> |
4697 | ||
d4579825 YW |
4698 | <example> |
4699 | <title>IPv6 Prefix Delegation (DHCPv4 6RD)</title> | |
4700 | ||
4701 | <programlisting># /etc/systemd/network/55-dhcpv4-6rd-upstream.network | |
4702 | [Match] | |
4703 | Name=enp1s0 | |
4704 | ||
4705 | [Network] | |
4706 | DHCP=ipv4 | |
4707 | ||
4708 | # When DHCPv4-6RD is used, the upstream network does not support IPv6. | |
4709 | # Hence, it is not necessary to wait for Router Advertisement, which is enabled by default. | |
4710 | IPv6AcceptRA=no | |
4711 | ||
4712 | [DHCPv4] | |
4713 | Use6RD=yes</programlisting> | |
4714 | ||
4715 | <programlisting># /etc/systemd/network/55-dhcpv4-6rd-downstream.network | |
4716 | [Match] | |
4717 | Name=enp2s0 | |
4718 | ||
4719 | [Network] | |
4720 | DHCPPrefixDelegation=yes | |
4721 | IPv6SendRA=yes | |
4722 | ||
4723 | # It is expected that the host is acting as a router. So, usually it is not | |
4724 | # necessary to receive Router Advertisement from other hosts in the downstream network. | |
4725 | IPv6AcceptRA=no | |
4726 | ||
4727 | [DHCPPrefixDelegation] | |
4728 | UplinkInterface=enp1s0 | |
4729 | SubnetId=1 | |
4730 | Announce=yes</programlisting> | |
4731 | ||
4732 | <para>This will enable DHCPv4-6RD on the interface enp1s0 as an upstream interface where the | |
4733 | DHCPv4 client is running and enp2s0 as a downstream interface where the prefix is delegated to. | |
4734 | The delegated prefixes are distributed by IPv6 Router Advertisement on the downstream network. | |
4735 | </para> | |
4736 | </example> | |
4737 | ||
798d3a52 | 4738 | <example> |
9e35b3de | 4739 | <title>A bridge with two enslaved links</title> |
f47c5c47 | 4740 | |
bc33789a JB |
4741 | <programlisting># /etc/systemd/network/25-bridge-static.netdev |
4742 | [NetDev] | |
4743 | Name=bridge0 | |
4744 | Kind=bridge</programlisting> | |
4745 | ||
9e35b3de ZJS |
4746 | <programlisting># /etc/systemd/network/25-bridge-static.network |
4747 | [Match] | |
f47c5c47 | 4748 | Name=bridge0 |
4749 | ||
4750 | [Network] | |
4751 | Address=192.168.0.15/24 | |
4752 | Gateway=192.168.0.1 | |
4753 | DNS=192.168.0.1</programlisting> | |
f47c5c47 | 4754 | |
9e35b3de ZJS |
4755 | <programlisting># /etc/systemd/network/25-bridge-slave-interface-1.network |
4756 | [Match] | |
f47c5c47 | 4757 | Name=enp2s0 |
4758 | ||
4759 | [Network] | |
4760 | Bridge=bridge0</programlisting> | |
9e35b3de ZJS |
4761 | |
4762 | <programlisting># /etc/systemd/network/25-bridge-slave-interface-2.network | |
4763 | [Match] | |
4764 | Name=wlp3s0 | |
4765 | ||
4766 | [Network] | |
4767 | Bridge=bridge0</programlisting> | |
4768 | ||
4769 | <para>This creates a bridge and attaches devices <literal>enp2s0</literal> and | |
4770 | <literal>wlp3s0</literal> to it. The bridge will have the specified static address | |
4771 | and network assigned, and a default route via the specified gateway will be | |
4772 | added. The specified DNS server will be added to the global list of DNS resolvers. | |
4773 | </para> | |
13b498f9 | 4774 | </example> |
9e35b3de | 4775 | |
13b498f9 | 4776 | <example> |
55ac274e | 4777 | <title>Bridge port with VLAN forwarding</title> |
13b498f9 | 4778 | |
9e35b3de | 4779 | <programlisting> |
55ac274e | 4780 | # /etc/systemd/network/25-bridge-slave-interface-1.network |
9e35b3de | 4781 | [Match] |
13b498f9 TJ |
4782 | Name=enp2s0 |
4783 | ||
4784 | [Network] | |
4785 | Bridge=bridge0 | |
4786 | ||
4787 | [BridgeVLAN] | |
4788 | VLAN=1-32 | |
4789 | PVID=42 | |
4790 | EgressUntagged=42 | |
4791 | ||
4792 | [BridgeVLAN] | |
4793 | VLAN=100-200 | |
4794 | ||
4795 | [BridgeVLAN] | |
4796 | EgressUntagged=300-400</programlisting> | |
0a8a0fad | 4797 | |
9e35b3de ZJS |
4798 | <para>This overrides the configuration specified in the previous example for the |
4799 | interface <literal>enp2s0</literal>, and enables VLAN on that bridge port. VLAN IDs | |
4800 | 1-32, 42, 100-400 will be allowed. Packets tagged with VLAN IDs 42, 300-400 will be | |
4801 | untagged when they leave on this interface. Untagged packets which arrive on this | |
4802 | interface will be assigned VLAN ID 42.</para> | |
798d3a52 | 4803 | </example> |
0a8a0fad | 4804 | |
798d3a52 | 4805 | <example> |
9e35b3de | 4806 | <title>Various tunnels</title> |
0a8a0fad | 4807 | |
9e35b3de ZJS |
4808 | <programlisting>/etc/systemd/network/25-tunnels.network |
4809 | [Match] | |
4810 | Name=ens1 | |
0a8a0fad TG |
4811 | |
4812 | [Network] | |
9e35b3de ZJS |
4813 | Tunnel=ipip-tun |
4814 | Tunnel=sit-tun | |
4815 | Tunnel=gre-tun | |
4816 | Tunnel=vti-tun | |
4817 | </programlisting> | |
4818 | ||
4819 | <programlisting>/etc/systemd/network/25-tunnel-ipip.netdev | |
4820 | [NetDev] | |
4821 | Name=ipip-tun | |
4822 | Kind=ipip | |
4823 | </programlisting> | |
4824 | ||
4825 | <programlisting>/etc/systemd/network/25-tunnel-sit.netdev | |
4826 | [NetDev] | |
4827 | Name=sit-tun | |
4828 | Kind=sit | |
4829 | </programlisting> | |
4830 | ||
4831 | <programlisting>/etc/systemd/network/25-tunnel-gre.netdev | |
4832 | [NetDev] | |
4833 | Name=gre-tun | |
4834 | Kind=gre | |
4835 | </programlisting> | |
4836 | ||
4837 | <programlisting>/etc/systemd/network/25-tunnel-vti.netdev | |
4838 | [NetDev] | |
4839 | Name=vti-tun | |
4840 | Kind=vti | |
4841 | </programlisting> | |
4842 | ||
4843 | <para>This will bring interface <literal>ens1</literal> up and create an IPIP tunnel, | |
4844 | a SIT tunnel, a GRE tunnel, and a VTI tunnel using it.</para> | |
798d3a52 | 4845 | </example> |
0a8a0fad | 4846 | |
798d3a52 | 4847 | <example> |
9e35b3de | 4848 | <title>A bond device</title> |
0a8a0fad | 4849 | |
9e35b3de ZJS |
4850 | <programlisting># /etc/systemd/network/30-bond1.network |
4851 | [Match] | |
4852 | Name=bond1 | |
0a8a0fad TG |
4853 | |
4854 | [Network] | |
9e35b3de ZJS |
4855 | DHCP=ipv6 |
4856 | </programlisting> | |
0a8a0fad | 4857 | |
9e35b3de ZJS |
4858 | <programlisting># /etc/systemd/network/30-bond1.netdev |
4859 | [NetDev] | |
4860 | Name=bond1 | |
4861 | Kind=bond | |
4862 | </programlisting> | |
0a8a0fad | 4863 | |
301a21a8 | 4864 | <programlisting># /etc/systemd/network/30-bond1-dev1.network |
9e35b3de ZJS |
4865 | [Match] |
4866 | MACAddress=52:54:00:e9:64:41 | |
0a8a0fad TG |
4867 | |
4868 | [Network] | |
9e35b3de ZJS |
4869 | Bond=bond1 |
4870 | </programlisting> | |
d94facdc | 4871 | |
301a21a8 | 4872 | <programlisting># /etc/systemd/network/30-bond1-dev2.network |
9e35b3de ZJS |
4873 | [Match] |
4874 | MACAddress=52:54:00:e9:64:42 | |
d94facdc MH |
4875 | |
4876 | [Network] | |
9e35b3de | 4877 | Bond=bond1 |
6cb955c6 | 4878 | </programlisting> |
9e35b3de ZJS |
4879 | |
4880 | <para>This will create a bond device <literal>bond1</literal> and enslave the two | |
4881 | devices with MAC addresses 52:54:00:e9:64:41 and 52:54:00:e9:64:42 to it. IPv6 DHCP | |
4882 | will be used to acquire an address.</para> | |
6cb955c6 AR |
4883 | </example> |
4884 | ||
4885 | <example> | |
9e35b3de ZJS |
4886 | <title>Virtual Routing and Forwarding (VRF)</title> |
4887 | <para>Add the <literal>bond1</literal> interface to the VRF master interface | |
4888 | <literal>vrf1</literal>. This will redirect routes generated on this interface to be | |
11d38b90 AR |
4889 | within the routing table defined during VRF creation. For kernels before 4.8 traffic |
4890 | won't be redirected towards the VRFs routing table unless specific ip-rules are added. | |
4891 | </para> | |
9e35b3de ZJS |
4892 | <programlisting># /etc/systemd/network/25-vrf.network |
4893 | [Match] | |
6cb955c6 AR |
4894 | Name=bond1 |
4895 | ||
4896 | [Network] | |
9e35b3de | 4897 | VRF=vrf1 |
d94facdc MH |
4898 | </programlisting> |
4899 | </example> | |
4900 | ||
42125eda SS |
4901 | <example> |
4902 | <title>MacVTap</title> | |
4903 | <para>This brings up a network interface <literal>macvtap-test</literal> | |
4904 | and attaches it to <literal>enp0s25</literal>.</para> | |
83ddf5d3 | 4905 | <programlisting># /usr/lib/systemd/network/25-macvtap.network |
42125eda SS |
4906 | [Match] |
4907 | Name=enp0s25 | |
4908 | ||
4909 | [Network] | |
4910 | MACVTAP=macvtap-test | |
4911 | </programlisting> | |
4912 | </example> | |
98d20a17 | 4913 | |
4914 | <example> | |
4915 | <title>A Xfrm interface with physical underlying device.</title> | |
4916 | ||
4917 | <programlisting># /etc/systemd/network/27-xfrm.netdev | |
4918 | [NetDev] | |
4919 | Name=xfrm0 | |
0d03e672 | 4920 | Kind=xfrm |
98d20a17 | 4921 | |
4922 | [Xfrm] | |
4923 | InterfaceId=7</programlisting> | |
4924 | ||
4925 | <programlisting># /etc/systemd/network/27-eth0.network | |
4926 | [Match] | |
4927 | Name=eth0 | |
4928 | ||
4929 | [Network] | |
4930 | Xfrm=xfrm0</programlisting> | |
4931 | ||
4932 | <para>This creates a <literal>xfrm0</literal> interface and binds it to the <literal>eth0</literal> device. | |
4933 | This allows hardware based ipsec offloading to the <literal>eth0</literal> nic. | |
4934 | If offloading is not needed, xfrm interfaces can be assigned to the <literal>lo</literal> device. | |
4935 | </para> | |
4936 | </example> | |
798d3a52 ZJS |
4937 | </refsect1> |
4938 | ||
4939 | <refsect1> | |
4940 | <title>See Also</title> | |
4941 | <para> | |
4942 | <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>, | |
f41b446a | 4943 | <citerefentry><refentrytitle>systemd-networkd.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, |
798d3a52 | 4944 | <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry>, |
aaa297d4 | 4945 | <citerefentry><refentrytitle>systemd.netdev</refentrytitle><manvolnum>5</manvolnum></citerefentry>, |
cc9b6bdc | 4946 | <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry>, |
aaa297d4 | 4947 | <citerefentry><refentrytitle>systemd-resolved.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> |
798d3a52 ZJS |
4948 | </para> |
4949 | </refsect1> | |
eac684ef TG |
4950 | |
4951 | </refentry> |