[systemd-devel] Proposal: integrate biosdevname into systemd tree
Kay Sievers
kay at vrfy.org
Fri Jan 4 03:47:38 PST 2013
On Fri, Jan 4, 2013 at 10:02 AM, Alexander E. Patrakov
<patrakov at gmail.com> wrote:
> What worries me now is that I was able to learn about the recommended
> replacement (biosdevname) only via IRC, from Kay Sievers. There are no
> pointers to biosdevname in any documentation that comes with
> systemd-196. How are distributions supposed to learn that they have to
> install it by default? And some of them don't learn. Here are some
> examples from rolling-release or beta distributions:
We plan to have something in a future systemd version, which should be
able to cover all the common use cases. It will be similar to the
/dev/disk/by-*/ symlinks, just with the obvious limitations of a
single name that is 15 characters long.
The current systemd git code:
http://cgit.freedesktop.org/systemd/systemd/tree/src/udev/udev-builtin-net_id.c
has some explanations in it. It already adds (currently unused)
candidates for names in the udev database:
# for i in /sys/class/net/*; do echo $(realpath $i); udevadm
test-builtin net_id $i 2>/dev/null; echo; done
/sys/devices/pci0000:00/0000:00:19.0/net/enp0s25
ID_NET_NAME_MAC=enxf0def180d479
ID_OUI_FROM_DATABASE=Wistron InfoComm (Kunshan)Co
ID_NET_NAME_PATH=enp0s25
/sys/devices/pci0000:00/0000:00:1c.3/0000:05:00.0/net/ens1
ID_NET_NAME_MAC=enx000000000466
ID_NET_NAME_PATH=enp5s0
ID_NET_NAME_SLOT=ens1
/sys/devices/pci0000:00/0000:00:1c.1/0000:03:00.0/net/wlp3s0
ID_NET_NAME_MAC=wlx0024d7e31130
ID_OUI_FROM_DATABASE=Intel Corporate
ID_NET_NAME_PATH=wlp3s0
/sys/devices/pci0000:00/0000:00:1d.0/usb2/2-1/2-1.4/2-1.4:1.6/net/wwp0s29u1u4i6
ID_NET_NAME_MAC=wwx028037ec0200
ID_NET_NAME_PATH=wwp0s29u1u4i6
We originally planned to use the biosdevname naming scheme, but it
turns out that it on one hand not flexible enough, and on the other
hand it "invents" its own enumeration based on crawling the entire
system for all network hardware, and coming up with new numbers. This
wasn't what we envision for systemd, so we decided to stick with the
model closer to what we already use for the disks and other
subsystems. It will not use the same names as biosdevname, especially
not invent new numbers when the PCI spec and the kernel already have
numbers sufficiently stable enough.
It's all still blurry, how the facility will look like in the end, and
it we need to find out with which policy to apply the currently "dead"
names to the actual interfaces.
Thanks,
Kay
More information about the systemd-devel
mailing list