nixos/doc: improve example of renaming network interfaces

For reliably identifying network interfaces, `PermanentMACAddress` is
likely to be preferable to `MACAddress`. NetworkManager in particular
commonly changes the MAC address of wireless interfaces.

Reference:

  - https://www.freedesktop.org/software/systemd/man/systemd.link.html#PermanentMACAddress=
main
Andrew Kvalheim 3 years ago
parent 726f7c9688
commit 12bab91d3b
  1. 2
      nixos/doc/manual/configuration/renaming-interfaces.section.md
  2. 2
      nixos/doc/manual/from_md/configuration/renaming-interfaces.section.xml

@ -26,7 +26,7 @@ we assign the name `wan` to the interface with MAC address
```nix
systemd.network.links."10-wan" = {
matchConfig.MACAddress = "52:54:00:12:01:01";
matchConfig.PermanentMACAddress = "52:54:00:12:01:01";
linkConfig.Name = "wan";
};
```

@ -32,7 +32,7 @@
</para>
<programlisting language="bash">
systemd.network.links.&quot;10-wan&quot; = {
matchConfig.MACAddress = &quot;52:54:00:12:01:01&quot;;
matchConfig.PermanentMACAddress = &quot;52:54:00:12:01:01&quot;;
linkConfig.Name = &quot;wan&quot;;
};
</programlisting>

Loading…
Cancel
Save