mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 07:23:20 +00:00
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=
This commit is contained in:
parent
726f7c9688
commit
12bab91d3b
@ -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."10-wan" = {
|
||||
matchConfig.MACAddress = "52:54:00:12:01:01";
|
||||
matchConfig.PermanentMACAddress = "52:54:00:12:01:01";
|
||||
linkConfig.Name = "wan";
|
||||
};
|
||||
</programlisting>
|
||||
|
Loading…
Reference in New Issue
Block a user