Re: systemd-networkd and interface names

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



That seems to be working as expected.

The initial, kernel-assigned name is always going to be an incrementing eth#, wlan#, or something similar. It's up to the userspace (i.e. udev) to rename it to something custom.

However, interfaces can only be renamed while they're *not* up, otherwise the kernel refuses it with EBUSY. If some program brings eth1 up without waiting for udev to finish rule processing, renaming will fail and it'll just remain eth1.


On Mon, Aug 10, 2020, 21:45 Matt Zagrabelny <mzagrabe@xxxxxxxxx> wrote:
Greetings,

I am using systemd-networkd and I am wondering how/why the interface names get chosen.

Scenario:

I am expecting an interface name to be enp1s0. Instead I get eth1.

It appears that eth1 is being referenced in things like:
/etc/default/isc-dhcp-server
/etc/default/minissdpd

If I change those instances of eth1 to enp1s0, then the interface rename happens as expected:

# dmesg | grep eth1
[    1.751611] tg3 0000:01:00.0 eth1: Tigon3 [partno(BCM95722A2202G) rev a200] (PCI Express) MAC address 00:10:18:59:c3:6f
[    1.751613] tg3 0000:01:00.0 eth1: attached PHY is 5722/5756 (10/100/1000Base-T Ethernet) (WireSpeed[1], EEE[0])
[    1.751614] tg3 0000:01:00.0 eth1: RXcsums[1] LinkChgREG[0] MIirq[0] ASF[0] TSOcap[1]
[    1.751616] tg3 0000:01:00.0 eth1: dma_rwctrl[76180000] dma_mask[64-bit]
[   17.763317] tg3 0000:01:00.0 enp1s0: renamed from eth1

Is this expected behavior with the kernel, udev, etc.?

Thanks for any help!

-m
_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel
_______________________________________________
systemd-devel mailing list
systemd-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/systemd-devel

[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux