diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2021-12-14 11:29:08 +0900 |
---|---|---|
committer | Yu Watanabe <watanabe.yu+github@gmail.com> | 2021-12-16 01:55:37 +0900 |
commit | a4c9bf2e51c92b411c88804070373f1e2123331a (patch) | |
tree | e46731dab159f8efd31c4a19579c581003f93b03 /man/systemd-udevd.service.xml | |
parent | ff516b4341eb869b450ab0c0e0d7fd0bd555e99f (diff) | |
download | systemd-a4c9bf2e51c92b411c88804070373f1e2123331a.tar.gz |
network-generator: support to set NamePolicy= through kernel command line argument
Closes #16296.
Diffstat (limited to 'man/systemd-udevd.service.xml')
-rw-r--r-- | man/systemd-udevd.service.xml | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/man/systemd-udevd.service.xml b/man/systemd-udevd.service.xml index 32cb82bac3..1bc86469be 100644 --- a/man/systemd-udevd.service.xml +++ b/man/systemd-udevd.service.xml @@ -224,6 +224,45 @@ appear, which affects older name derivation algorithms, too.</para> </listitem> </varlistentry> + <varlistentry> + <term><varname>net.ifname-policy=<replaceable>policy1</replaceable>[,<replaceable>policy2</replaceable>,…][,<replaceable>MAC</replaceable>]</varname></term> + <listitem> + <para>Specifies naming policies applied when renaming network interfaces. Takes a list of + policies and an optional MAC address separated with comma. Each policy value must be one of + the policies understood by the <varname>NamePolicy=</varname> setting in .link files, e.g. + <literal>onboard</literal> or <literal>path</literal>. See + <citerefentry><refentrytitle>systemd.link</refentrytitle><manvolnum>5</manvolnum></citerefentry> + for more details. When the MAC address is specified, the policies are applied to the + interface which has the address. When no MAC address is specified, the policies are applied + to all interfaces. This kernel command line argument can be specified multiple times. This + argument is not directly read from <command>systemd-udevd</command>, but read and converted + to a .link file by <command>systemd-network-generator</command>. So, to make this argument + take effect, <filename>systemd-network-generator.service</filename> must be enabled and + started before starting <filename>systemd-udevd.service</filename>. See + <citerefentry><refentrytitle>systemd-network-generator.service</refentrytitle><manvolnum>8</manvolnum></citerefentry> + for more details about the service.</para> + <para>Example: + <programlisting>net.ifname-policy=keep,kernel,path,slot,onboard,01:23:45:67:89:ab +net.ifname-policy=keep,kernel,path,slot,onboard,mac</programlisting> + This is mostly equivalent to creating the following .link files: + <programlisting># 91-name-policy-with-mac.link +[Match] +MACAddress=01:23:45:67:89:ab + +[Link] +NamePolicy=keep kernel path slot onboard +AlternativeNamePolicy=path slot onboard</programlisting> + and + <programlisting># 92-name-policy-for-all.link +[Match] +OriginalName=* + +[Link] +NamePolicy=keep kernel path slot onboard mac +AlternativeNamePolicy=path slot onboard mac</programlisting> + </para> + </listitem> + </varlistentry> </variablelist> <!-- when adding entries here, consider also adding them in kernel-command-line.xml --> </refsect1> |