Repository navigation
Fix coriolis alias udev rule - #552
Conversation
62f6701 to
8fc6aad
Compare
| break | ||
| if ip_addresses and nic_ips: | ||
| if set(ip_addresses) & set(nic_ips): | ||
| # ens192:SAB is an address label. The udev NAME has to |
There was a problem hiding this comment.
NIT: Let's keep these comments generalized. ens192:SAB is a specific scenario that is being handled here. What we're really handling here are filtering out address labels.
| if set(ip_addresses) & set(nic_ips): | ||
| # ens192:SAB is an address label. The udev NAME has to | ||
| # be the parent device, which has no ':' in its name. | ||
| if ":" in iface: |
There was a problem hiding this comment.
How do other network renderers/managers handle the creation or management of these address labels? Is : used for netplan or nmconnections for example? Do we need different handlers?
There was a problem hiding this comment.
The : form is a legacy address label and the kernel treats eth0:0 as an alias of eth0: it is not a real netdev, so a udev NAME has to be the parent device.
An ifcfg alias file is like this: ifcfg-<if>:<label> with DEVICE=eth0:0, and NetworkManager stores that as a label on the master interface.
netplan and NetworkManager don't have this format:
Netplanlists extra addresses under the real interface idNetworkManagerbinds the profile withconnection.interface-nameand adds further addresses asaddress1,address2, and so on...
8fc6aad to
cff020d
Compare
This PR refactors the method that defined the udev rule so that aliases (
eth0:ABC) are skipped in favor of parent devices (eth0).