Changes between Version 28 and Version 29 of ubuntu


Ignore:
Timestamp:
06/21/2023 08:26:48 PM (17 months ago)
Author:
Ryan Erbstoesser
Comment:

add default and add example for wlan0

Legend:

Unmodified
Added
Removed
Modified
  • ubuntu

    v28 v29  
    277277
    278278Predictable interface names is enabled by default on systems using {{{systemd}}}/{{{udev}}} however you can disable it in a couple of ways:
    279  * pass in a kernel command-line parameter of {{{net.ifnames=0}}}. Note that this is 'not' a kernel feature (thus is independent of what kernel version you are using) but the {{{systemd}}}/{{{udev}}} components that implement this feature look for that on the command-line.
    280  * remove {{{/lib/systemd/network/99-default.link}}} from the root filesystem.
     279 * Pass in a kernel command-line parameter of {{{net.ifnames=0}}}. Note that this is 'not' a kernel feature (thus is independent of what kernel version you are using) but the {{{systemd}}}/{{{udev}}} components that implement this feature look for that on the command-line. (default on Gateworks)
     280 * Remove {{{/lib/systemd/network/99-default.link}}} from the root filesystem.
    281281
    282282Alternatively you can also create your own {{{link}}} files to name interfaces to your liking. A {{{link}}} file defines matching criteria and link criteria for naming. You can use 'udevadm info <device>' to obtain details that {{{udev}}} knows about devices (ie 'udevadm info /sys/class/net/eth0' or /udevadm info /dev/ttyUSB0'). Your link files should be placed in {{{/etc/systemd/network}}} and should sort before {{{99-default.link}}} from {{{/lib/systemd/network}}}.
     283
     284An example to force a wlan0 name by MAC address c0:ee:40:99:
     285{{{
     286root@gw7301:/lib/systemd/network# cat 90-wlan0.link
     287[Match]
     288MACAddress=c0:ee:40:99
     289
     290[Link]
     291Name=wlan0
     292}}}
    283293
    284294References: